JDBaccess API 1.0

com.jdbaccess.da
Class DAFactory

java.lang.Object
  extended by com.jdbaccess.da.DAFactory

public class DAFactory
extends java.lang.Object

Factory for all types of data access such as Select, Insert, Update, Delete, Function, Procedure and also Transaction.


Constructor Summary
DAFactory()
           
 
Method Summary
static Delete getDelete(Transaction t)
          Get a new Delete object for that transaction
static Delete getDelete(Transaction t, java.lang.String objectType, java.lang.String name, java.lang.Class startClass)
          Looks for a Delete in xml data access files beginning in directory of the given start class for that objectType and name and for that transaction
static Function getFunction(Transaction t)
          Get a new Function object for that transaction.
static Function getFunction(Transaction t, java.lang.String objectType, java.lang.String name, java.lang.Class startClass)
          Looks for a Function in xml data access files beginning in directory of the given start class for that objectType and name and for that transaction
static Insert getInsert(Transaction t)
          Get a new Insert object for that transaction.
static Insert getInsert(Transaction t, java.lang.String objectType, java.lang.String name, java.lang.Class startClass)
          Looks for an Insert in xml data access files beginning in directory of the given start class for that objectType and name and for that transaction
static Procedure getProcedure(Transaction t)
          Get a new Procedure object for that transaction.
static Procedure getProcedure(Transaction t, java.lang.String objectType, java.lang.String name, java.lang.Class startClass)
          Looks for a Procedure in xml data access files beginning in directory of the given start class for that objectType and name and for that transaction
static Select getSelect()
          Get a new Select object.
static Select getSelect(java.lang.String objectType, java.lang.String name, java.lang.Class startClass)
          Looks for a Select in xml data access files beginning in directory of the given start class for that objectType and name
static Select getSelect(Transaction t)
          Get a new Select object for that transaction.
static Transaction getTransaction()
          Get a new transaction object.
static Update getUpdate(Transaction t)
          Get a new Update object for that transaction.
static Update getUpdate(Transaction t, java.lang.String objectType, java.lang.String name, java.lang.Class startClass)
          Looks for an Update in xml data access files beginning in directory of the given start class for that objectType and name and for that transaction
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DAFactory

public DAFactory()
Method Detail

getTransaction

public static Transaction getTransaction()
Get a new transaction object.

Returns:
a new Transaction object

getInsert

public static Insert getInsert(Transaction t)
Get a new Insert object for that transaction.

Parameters:
t - transaction
Returns:
a new Insert object for that transaction

getInsert

public static Insert getInsert(Transaction t,
                               java.lang.String objectType,
                               java.lang.String name,
                               java.lang.Class startClass)
                        throws ApplicationException
Looks for an Insert in xml data access files beginning in directory of the given start class for that objectType and name and for that transaction

Parameters:
t - transaction
objectType - type of Insert (e.g. "employee")
name - name of Insert (e.g. "insertWithoutLobs")
startClass - start class where to look for a da.xml file
Returns:
a new Insert object in xml data access files beginning in directory of the given start class for that objectType and name and for that transaction
Throws:
ApplicationException

getUpdate

public static Update getUpdate(Transaction t)
Get a new Update object for that transaction.

Parameters:
t - transaction
Returns:
a new Update object for that transaction

getUpdate

public static Update getUpdate(Transaction t,
                               java.lang.String objectType,
                               java.lang.String name,
                               java.lang.Class startClass)
                        throws ApplicationException
Looks for an Update in xml data access files beginning in directory of the given start class for that objectType and name and for that transaction

Parameters:
t - transaction
objectType - type of Update (e.g. "employee")
name - name of Update (e.g. "byName")
startClass - start class where to look for a da.xml file
Returns:
a new Update object in xml data access files beginning in directory of the given start class for that objectType and name and for that transaction
Throws:
ApplicationException

getDelete

public static Delete getDelete(Transaction t)
Get a new Delete object for that transaction

Parameters:
t - transaction
Returns:
a new Delete object for that transaction

getDelete

public static Delete getDelete(Transaction t,
                               java.lang.String objectType,
                               java.lang.String name,
                               java.lang.Class startClass)
                        throws ApplicationException
Looks for a Delete in xml data access files beginning in directory of the given start class for that objectType and name and for that transaction

Parameters:
t - transaction
objectType - type of Delete (e.g. "employee")
name - name of Delete (e.g. "byName")
startClass - start class where to look for a da.xml file
Returns:
a new Delete object in xml data access files beginning in directory of the given start class for that objectType and name and for that transaction
Throws:
ApplicationException

getSelect

public static Select getSelect()
Get a new Select object.

Returns:
a new Select object

getSelect

public static Select getSelect(Transaction t)
Get a new Select object for that transaction.

Parameters:
t - transaction
Returns:
a new Select object for that transaction

getSelect

public static Select getSelect(java.lang.String objectType,
                               java.lang.String name,
                               java.lang.Class startClass)
                        throws ApplicationException
Looks for a Select in xml data access files beginning in directory of the given start class for that objectType and name

Parameters:
objectType - type of Select (e.g. "employee")
name - name of Select (e.g. "byName")
startClass - start class where to look for a da.xml file
Returns:
a new Select object in xml data access files beginning in directory of the given start class for that objectType and name
Throws:
ApplicationException

getProcedure

public static Procedure getProcedure(Transaction t)
Get a new Procedure object for that transaction.

Parameters:
t - transaction
Returns:
a new Procedure object for that transaction

getProcedure

public static Procedure getProcedure(Transaction t,
                                     java.lang.String objectType,
                                     java.lang.String name,
                                     java.lang.Class startClass)
                              throws ApplicationException
Looks for a Procedure in xml data access files beginning in directory of the given start class for that objectType and name and for that transaction

Parameters:
t - transaction
objectType - type of Procedure (e.g. "employee")
name - name of Procedure (e.g. "prc_updateSalaryById")
startClass - start class where to look for a da.xml file
Returns:
a new Procedure object in xml data access files beginning in directory of the given start class for that objectType and name and for that transaction
Throws:
ApplicationException

getFunction

public static Function getFunction(Transaction t)
Get a new Function object for that transaction.

Parameters:
t - transaction
Returns:
a new Function object for that transaction

getFunction

public static Function getFunction(Transaction t,
                                   java.lang.String objectType,
                                   java.lang.String name,
                                   java.lang.Class startClass)
                            throws ApplicationException
Looks for a Function in xml data access files beginning in directory of the given start class for that objectType and name and for that transaction

Parameters:
t - transaction
objectType - type of Function (e.g. "employee")
name - name of Function (e.g. "fnc_updateSalaryById")
startClass - start class where to look for a da.xml file
Returns:
a new Function object in xml data access files beginning in directory of the given start class for that objectType and name and for that transaction
Throws:
ApplicationException

JDBaccess API 1.0

Copyright © 2005-2006 JDBaccess.com, Königsweg 210, D-14129 Berlin, Germany. All Rights Reserved.