Sample
Class Employee

java.lang.Object
  extended bycom.intersys.classes.CacheGeneric
      extended bycom.intersys.classes.CacheRootObject
          extended bycom.intersys.classes.RegisteredObject
              extended bycom.intersys.classes.Persistent
                  extended bySample.Person
                      extended bySample.Employee
All Implemented Interfaces:
ObjectHandle, java.io.Serializable

public class Employee
extends Person

See Also:
Serialized Form

Field Summary
 
Fields inherited from class com.intersys.classes.CacheRootObject
mInternal
 
Constructor Summary
Employee(CacheObject ref)
          NB: DO NOT USE IN APPLICATION(!!!).
Employee(Database db)
          Creates a new instance of object "Employee" in Cache database and corresponding object of class Employee.
Employee(Database db, java.lang.String initstr)
           
 
Method Summary
static void _deleteId(Database db, Id id)
          Runs method %Delete in Cache to delete an object from Cache database.
static void _deleteId(Database db, Id id, int concurrency)
          Runs method %Delete in Cache to delete an object from Cache database.
static java.lang.Boolean _existsId(Database db, Id id)
          Runs method %Exists in Cache to see if an object exists.
static RegisteredObject _open(Database db, Id id)
          Runs method %OpenId in Cache to open an object from Cache database and creates corresponding object of class Employee.
static RegisteredObject _open(Database db, Id id, int concurrency)
          Runs method %OpenId in Cache to open an object from Cache database and creates corresponding object of class Employee.
static RegisteredObject _open(Database db, Oid oid)
          Runs method %Open in Cache to open an object from Cache database and creates corresponding object of class Employee.
static RegisteredObject _open(Database db, Oid oid, int concurrency)
          Runs method %Open in Cache to open an object from Cache database and creates corresponding object of class Employee.
static java.lang.Object addToBatchInsert(java.lang.Object batch, java.sql.Connection con, java.lang.Integer Company, java.sql.Date DOB, java.util.List FavoriteColors, java.lang.String Name, java.lang.String SSN, java.lang.Integer Salary, java.lang.Integer Spouse, java.lang.String Title, java.lang.String Home_City, java.lang.String Home_State, java.lang.String Home_Street, java.lang.String Home_Zip, java.lang.String Office_City, java.lang.String Office_State, java.lang.String Office_Street, java.lang.String Office_Zip)
           
static void checkAllFieldsValid(Database db)
          Verifies that all fields from Cache class are exposed with accessor methods in Java class and that values for indexes in zObjVal are the same as in Cache.
static void checkAllMethods(Database db)
          Verifies that all fields from Cache class are exposed with accessor methods in Java class and that values for indexes in zObjVal are the same as in Cache.
static void checkCompanyValid(Database db)
          Verifies that indexes for property Company in zObjVal are the same as in Cache.
static void checkNotesValid(Database db)
          Verifies that indexes for property Notes in zObjVal are the same as in Cache.
static void checkSalaryValid(Database db)
          Verifies that indexes for property Salary in zObjVal are the same as in Cache.
static void checkTitleValid(Database db)
          Verifies that indexes for property Title in zObjVal are the same as in Cache.
static java.lang.Integer CurrentAge(Database db)
          Runs method CurrentAge in Cache.
static java.lang.Integer CurrentAge(Database db, java.sql.Date date)
          Runs method CurrentAge in Cache.
static void delete(Database db, Id id)
          Runs method %Delete in Cache to delete an object from Cache database.
static void delete(Database db, Id id, int concurrency)
          Runs method %Delete in Cache to delete an object from Cache database.
static java.util.List executeBatchInsert(java.sql.Connection con, java.lang.Object batch, int nolock)
           
static boolean exists(Database db, Id id)
          Runs method %Exists in Cache to see if an object exists.
static boolean exists(Database db, Oid oid)
          Runs method %Exists in Cache to see if an object exists.
 CacheClass getCacheClass()
          Allows access metadata information about type of this object in Cache database.
static java.lang.String getCacheClassName()
          Returns class name of the class Employee as it is in Cache Database.
 Company getCompany()
          Returns value of property Company.
 CacheReader getNotesIn()
           
 CacheWriter getNotesOut()
           
 java.lang.Integer getSalary()
          Returns value of property Salary.
 java.lang.String getTitle()
          Returns value of property Title.
static java.lang.Integer Populate(Database db)
          Runs method Populate in Cache.
static java.lang.Integer Populate(Database db, java.lang.Integer count)
          Runs method Populate in Cache.
static java.lang.Integer Populate(Database db, java.lang.Integer count, java.lang.Integer verbose)
          Runs method Populate in Cache.
static java.lang.Integer Populate(Database db, java.lang.Integer count, java.lang.Integer verbose, java.lang.Integer DeferIndices)
          Runs method Populate in Cache.
static java.lang.Integer Populate(Database db, java.lang.Integer count, java.lang.Integer verbose, java.lang.Integer DeferIndices, IntegerHolder objects)
          Runs method Populate in Cache.
static java.lang.String PopulateSerial(Database db)
          Runs method PopulateSerial in Cache.
 void PrintPerson()
          Runs method PrintPerson in Cache.
static void PrintPersons(Database db)
          Runs method PrintPersons in Cache.
static void PrintPersonsSQL(Database db)
          Runs method PrintPersonsSQL in Cache.
static CacheQuery query_ByName(Database db)
          Returns a CallableStatement for query ByName.
static CacheQuery query_Extent(Database db)
          Returns a CallableStatement for query Extent.
 void setCompany(Company value)
          Sets new value for Company.
 void setSalary(java.lang.Integer value)
          Sets new value for Salary.
 void setTitle(java.lang.String value)
          Sets new value for Title.
static java.lang.Integer StoredProcTest(Database db, java.lang.String name, StringHolder response)
          Runs method StoredProcTest in Cache.
static java.lang.Boolean sys_BMEBuilt(Database db, StringHolder bmeName)
          Runs method sys_BMEBuilt in Cache.
static void sys_BuildIndices(Database db)
          Runs method sys_BuildIndices in Cache.
static void sys_BuildIndices(Database db, SList idxlist)
          Runs method sys_BuildIndices in Cache.
static void sys_CheckUnique(Database db)
          Runs method sys_CheckUnique in Cache.
static void sys_CheckUnique(Database db, SList idxlist)
          Runs method sys_CheckUnique in Cache.
static java.lang.String sys_ClassName(Database db, java.lang.Boolean fullname)
          Runs method sys_ClassName in Cache.
static void sys_Delete(Database db)
          Runs method sys_Delete in Cache.
static void sys_Delete(Database db, Oid oid)
          Runs method sys_Delete in Cache.
static void sys_Delete(Database db, Oid oid, java.lang.Integer concurrency)
          Runs method sys_Delete in Cache.
static void sys_DeleteExtent(Database db, java.lang.Integer concurrency, StringHolder deletecount, StringHolder instancecount)
          Runs method sys_DeleteExtent in Cache.
static void sys_DeleteId(Database db, java.lang.String id)
          Runs method sys_DeleteId in Cache.
static void sys_DeleteId(Database db, java.lang.String id, java.lang.Integer concurrency)
          Runs method sys_DeleteId in Cache.
static java.lang.Boolean sys_Exists(Database db)
          Runs method sys_Exists in Cache.
static java.lang.Boolean sys_Exists(Database db, Oid oid)
          Runs method sys_Exists in Cache.
static java.lang.Boolean sys_ExistsId(Database db, java.lang.String id)
          Runs method sys_ExistsId in Cache.
static java.lang.Integer sys_Extends(Database db, java.lang.String isclass)
          Runs method sys_Extends in Cache.
static java.lang.String sys_GetParameter(Database db)
          Runs method sys_GetParameter in Cache.
static java.lang.String sys_GetParameter(Database db, java.lang.String paramname)
          Runs method sys_GetParameter in Cache.
static java.lang.Integer sys_IsA(Database db, java.lang.String isclass)
          Runs method sys_IsA in Cache.
static void sys_KillExtent(Database db)
          Runs method sys_KillExtent in Cache.
static java.lang.String sys_PackageName(Database db)
          Runs method sys_PackageName in Cache.
static void sys_PurgeIndices(Database db)
          Runs method sys_PurgeIndices in Cache.
static void sys_PurgeIndices(Database db, SList idxlist)
          Runs method sys_PurgeIndices in Cache.
static void sys_SortBegin(Database db)
          Runs method sys_SortBegin in Cache.
static void sys_SortBegin(Database db, SList idxlist)
          Runs method sys_SortBegin in Cache.
static void sys_SortBegin(Database db, SList idxlist, java.lang.Integer excludeunique)
          Runs method sys_SortBegin in Cache.
static void sys_SortEnd(Database db)
          Runs method sys_SortEnd in Cache.
static void sys_SortEnd(Database db, SList idxlist)
          Runs method sys_SortEnd in Cache.
static void sys_SortEnd(Database db, SList idxlist, java.lang.Integer commit)
          Runs method sys_SortEnd in Cache.
static java.lang.Integer UpdateProcTest(Database db, java.lang.String zip, java.lang.String city, java.lang.String state)
          Runs method UpdateProcTest in Cache.
 
Methods inherited from class Sample.Person
Addition, Addition, Addition, addToBatchInsert, AgeGet, checkAgeValid, checkDOBValid, checkFavoriteColorsValid, checkHomeValid, checkNameValid, checkOfficeValid, checkSpouseValid, checkSSNValid, getAge, getDOB, getFavoriteColors, getHome, getName, getOffice, getSpouse, getSSN, NameIDXExists, NinetyNine, OnPopulate, prepare_Person_UpdateProcTest, prepare_Stored_Procedure_Test, setDOB, setFavoriteColors, setHome, setName, setOffice, setSpouse, setSSN, SSNKeyExists
 
Methods inherited from class com.intersys.classes.Persistent
_buildIndices, _buildIndices, _delete, _delete, _downgradeConcurrency, _downgradeConcurrency, _exists, _id, _oid, _reload, _save, _upgradeConcurrency, _upgradeConcurrency, delete, delete, exists, getId, getOid, JournalObject, JournalObject, save, save
 
Methods inherited from class com.intersys.classes.RegisteredObject
_className, _className, _constructClone, _constructClone, _constructClone, _isA, _isModified, _normalizeObject, _packageName, _validateObject, _validateObject, constructClone, constructClone, getZRef
 
Methods inherited from class com.intersys.classes.CacheRootObject
_close, castTo, changeInternal, equals, finalize, getDatabase, getField, getOref, getProxy, getString, getUserData, hashCode, release, releaseInternal, setUserData, toString
 
Methods inherited from class com.intersys.classes.CacheGeneric
checkAllFieldsValid, checkAllMethods, checkFieldsLimited, checkZobjValid, reset
 
Methods inherited from class java.lang.Object
clone, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Employee

public Employee(CacheObject ref)
         throws CacheException

NB: DO NOT USE IN APPLICATION(!!!).
Use Employee._open instead!

Used to construct a Java object, corresponding to existing object in Cache database.

See Also:
_open(com.intersys.objects.Database, com.intersys.objects.Oid)

Employee

public Employee(Database db,
                java.lang.String initstr)
         throws CacheException

Employee

public Employee(Database db)
         throws CacheException
Creates a new instance of object "Employee" in Cache database and corresponding object of class Employee.

Parameters:
db - Database object used for connection with Cache database.
Throws:
CacheException - in case of error.
See Also:
_open(com.intersys.objects.Database, com.intersys.objects.Oid)
Method Detail

_open

public static RegisteredObject _open(Database db,
                                     Id id)
                              throws CacheException
Runs method %OpenId in Cache to open an object from Cache database and creates corresponding object of class Employee.

Parameters:
db - Database object used for connection with Cache database.
id - ID as specified in Cache represented as Id.
Returns:
RegisteredObject , corresponding to opened object. This object may be of Employee or of any of its subclasses. Cast to Employee is guaranteed to pass without ClassCastException exception.
Throws:
CacheException - in case of error.
See Also:
ClassCastException, _open(com.intersys.objects.Database, com.intersys.objects.Oid), Employee(com.intersys.objects.Database)

_open

public static RegisteredObject _open(Database db,
                                     Id id,
                                     int concurrency)
                              throws CacheException
Runs method %OpenId in Cache to open an object from Cache database and creates corresponding object of class Employee.

Parameters:
db - Database object used for connection with Cache database.
id - ID as specified in Cache represented as Id.
concurrency - Concurrency level. represented as Concurrency. Here are concurrency values, see Object Concurrency Options in your on-line Cache' documentation for more information.
Returns:
RegisteredObject , corresponding to opened object. This object may be of Employee or of any of its subclasses. Cast to Employee is guaranteed to pass without ClassCastException exception.
Throws:
CacheException - in case of error.
See Also:
Object Concurrency Options.
Object Concurrency Options
0 No locking, no locks are used
1 Atomic
2 Shared
3 Shared/Retained
4 Exclusive
, ClassCastException, _open(com.intersys.objects.Database, com.intersys.objects.Oid), Employee(com.intersys.objects.Database)

_open

public static RegisteredObject _open(Database db,
                                     Oid oid)
                              throws CacheException
Runs method %Open in Cache to open an object from Cache database and creates corresponding object of class Employee.

Parameters:
db - Database object used for connection with Cache database.
oid - Object ID as specified in Cache. represented as Oid.
Returns:
RegisteredObject , corresponding to opened object. This object may be of Employee or of any of its subclasses. Cast to Employee is guaranteed to pass without ClassCastException exception.
Throws:
CacheException - in case of error.
See Also:
ClassCastException, _open(com.intersys.objects.Database, com.intersys.objects.Oid), Employee(com.intersys.objects.Database)

_open

public static RegisteredObject _open(Database db,
                                     Oid oid,
                                     int concurrency)
                              throws CacheException
Runs method %Open in Cache to open an object from Cache database and creates corresponding object of class Employee.

Parameters:
db - Database object used for connection with Cache database.
oid - Object ID as specified in Cache. represented as Oid.
concurrency - Concurrency level. represented as Concurrency. Here are concurrency values, see Object Concurrency Options in your on-line Cache' documentation for more information.
Returns:
RegisteredObject , corresponding to opened object. This object may be of Employee or of any of its subclasses. Cast to Employee is guaranteed to pass without ClassCastException exception.
Throws:
CacheException - in case of error.
See Also:
Object Concurrency Options.
Object Concurrency Options
0 No locking, no locks are used
1 Atomic
2 Shared
3 Shared/Retained
4 Exclusive
, ClassCastException, _open(com.intersys.objects.Database, com.intersys.objects.Oid), Employee(com.intersys.objects.Database)

delete

public static void delete(Database db,
                          Id id)
                   throws CacheException
Runs method %Delete in Cache to delete an object from Cache database. Deletes the stored version of the object with OID oid from the database. It does not remove any in-memory versions of the object that may be present.

Parameters:
db - Database object used for connection with Cache database.
id - ID as specified in Cache represented as Id.
Throws:
CacheException - in case of error.
See Also:
ClassCastException, _open(com.intersys.objects.Database, com.intersys.objects.Id), Employee(com.intersys.objects.Database)

delete

public static void delete(Database db,
                          Id id,
                          int concurrency)
                   throws CacheException
Runs method %Delete in Cache to delete an object from Cache database. Deletes the stored version of the object with OID oid from the database. It does not remove any in-memory versions of the object that may be present.

Parameters:
db - Database object used for connection with Cache database.
id - ID as specified in Cache represented as Id.
concurrency - Concurrency level. represented as Concurrency. Here are concurrency values, see Object Concurrency Options in your on-line Cache' documentation for more information.
Throws:
CacheException - in case of error.
See Also:
Object Concurrency Options.
Object Concurrency Options
0 No locking, no locks are used
1 Atomic
2 Shared
3 Shared/Retained
4 Exclusive
, ClassCastException, _open(com.intersys.objects.Database, com.intersys.objects.Id), Employee(com.intersys.objects.Database)

_deleteId

public static void _deleteId(Database db,
                             Id id)
                      throws CacheException
Runs method %Delete in Cache to delete an object from Cache database. Deletes the stored version of the object with OID oid from the database. It does not remove any in-memory versions of the object that may be present.

Parameters:
db - Database object used for connection with Cache database.
id - ID as specified in Cache represented as Id.
Throws:
CacheException - in case of error.
See Also:
ClassCastException, _open(com.intersys.objects.Database, com.intersys.objects.Id), Employee(com.intersys.objects.Database)

_deleteId

public static void _deleteId(Database db,
                             Id id,
                             int concurrency)
                      throws CacheException
Runs method %Delete in Cache to delete an object from Cache database. Deletes the stored version of the object with OID oid from the database. It does not remove any in-memory versions of the object that may be present.

Parameters:
db - Database object used for connection with Cache database.
id - ID as specified in Cache represented as Id.
concurrency - Concurrency level. represented as Concurrency. Here are concurrency values, see Object Concurrency Options in your on-line Cache' documentation for more information.
Throws:
CacheException - in case of error.
See Also:
Object Concurrency Options.
Object Concurrency Options
0 No locking, no locks are used
1 Atomic
2 Shared
3 Shared/Retained
4 Exclusive
, ClassCastException, _open(com.intersys.objects.Database, com.intersys.objects.Id), Employee(com.intersys.objects.Database)

exists

public static boolean exists(Database db,
                             Id id)
                      throws CacheException
Runs method %Exists in Cache to see if an object exists.

Parameters:
db - Database object used for connection with Cache database.
id - ID as specified in Cache represented as Id.
Throws:
CacheException - in case of error.
See Also:
ClassCastException, _existsId(com.intersys.objects.Database, com.intersys.objects.Id), Employee(com.intersys.objects.Database)

_existsId

public static java.lang.Boolean _existsId(Database db,
                                          Id id)
                                   throws CacheException
Runs method %Exists in Cache to see if an object exists.

Parameters:
db - Database object used for connection with Cache database.
id - ID as specified in Cache represented as Id.
Throws:
CacheException - in case of error.
See Also:
ClassCastException, _existsId(com.intersys.objects.Database, com.intersys.objects.Id), Employee(com.intersys.objects.Database)

getCacheClassName

public static java.lang.String getCacheClassName()
Returns class name of the class Employee as it is in Cache Database. Note, that this is a static method, so no object specific information can be returned. Use getCacheClass().geName() to get the class name for specific object.

Returns:
Cache class name as a String
See Also:
getCacheClass(), CacheClass.getName()

getCacheClass

public CacheClass getCacheClass()
                         throws CacheException
Allows access metadata information about type of this object in Cache database. Also can be used for dynamic binding (accessing properties and calling methods without particular class known).

Overrides:
getCacheClass in class Person
Returns:
CacheClass object for this object type.
Throws:
CacheException

checkAllFieldsValid

public static void checkAllFieldsValid(Database db)
                                throws CacheException
Verifies that all fields from Cache class are exposed with accessor methods in Java class and that values for indexes in zObjVal are the same as in Cache. It does not return anything but it throws an exception in case of inconsistency.

But if there is any inconsistency in zObjVal indexes this is fatal and class can not work correctly and must be regenerated

Parameters:
db - Database used for connection. Note that if you are using multiple databases the class can be consistent with one and inconsistent with another.
Throws:
InvalidClassException - if any inconsistency is found.
CacheException - if any error occurred during verification, e.g. communication error with Database.
See Also:
InvalidPropertyException

exists

public static boolean exists(Database db,
                             Oid oid)
                      throws CacheException
Runs method %Exists in Cache to see if an object exists.

Parameters:
db - Database object used for connection with Cache database.
oid - Object ID as specified in Cache. represented as Oid.
Returns:
RegisteredObject , corresponding to opened object. This object may be of Employee or of any of its subclasses. Cast to Employee is guaranteed to pass without ClassCastException exception.
Throws:
CacheException - in case of error.
See Also:
ClassCastException, _open(com.intersys.objects.Database, com.intersys.objects.Oid), Employee(com.intersys.objects.Database)

checkAllMethods

public static void checkAllMethods(Database db)
                            throws CacheException
Verifies that all fields from Cache class are exposed with accessor methods in Java class and that values for indexes in zObjVal are the same as in Cache. It does not return anything but it throws an exception in case of inconsistency.

But if there is any inconsistency in zObjVal indexes this is fatal and class can not work correctly and must be regenerated

Parameters:
db - Database used for connection. Note that if you are using multiple databases the class can be consistent with one and inconsistent with another.
Throws:
InvalidClassException - if any inconsistency is found.
CacheException - if any error occurred during verification, e.g. communication error with Database.
See Also:
InvalidPropertyException

checkCompanyValid

public static void checkCompanyValid(Database db)
                              throws CacheException
Verifies that indexes for property Company in zObjVal are the same as in Cache. It does not return anything but it throws an exception in case of inconsistency.

Please note, that if there is any inconsistency in zObjVal indexes this is fatal and class can not work correctly and must be regenerated.

Parameters:
db - Database used for connection. Note that if you are using multiple databases the class can be consistent with one and inconsistent with another.
Throws:
InvalidClassException - if any inconsistency is found.
CacheException - if any error occurred during verification, e.g. communication error with Database.
See Also:
checkAllFieldsValid(com.intersys.objects.Database)

getCompany

public Company getCompany()
                   throws CacheException
Returns value of property Company.

Description: The company this employee works for.

Returns:
current value of Company represented as Sample.Company
Throws:
CacheException - if any error occurred during value retrieval.
See Also:
Company

setCompany

public void setCompany(Company value)
                throws CacheException
Sets new value for Company.

Description: The company this employee works for.

Parameters:
value - new value to be set represented as Sample.Company.
Throws:
CacheException - if any error occurred during value setting.
See Also:
Company

checkNotesValid

public static void checkNotesValid(Database db)
                            throws CacheException
Verifies that indexes for property Notes in zObjVal are the same as in Cache. It does not return anything but it throws an exception in case of inconsistency.

Please note, that if there is any inconsistency in zObjVal indexes this is fatal and class can not work correctly and must be regenerated.

Parameters:
db - Database used for connection. Note that if you are using multiple databases the class can be consistent with one and inconsistent with another.
Throws:
InvalidClassException - if any inconsistency is found.
CacheException - if any error occurred during verification, e.g. communication error with Database.
See Also:
checkAllFieldsValid(com.intersys.objects.Database)

getNotesIn

public CacheReader getNotesIn()
                       throws CacheException
Throws:
CacheException

getNotesOut

public CacheWriter getNotesOut()
                        throws CacheException
Throws:
CacheException

checkSalaryValid

public static void checkSalaryValid(Database db)
                             throws CacheException
Verifies that indexes for property Salary in zObjVal are the same as in Cache. It does not return anything but it throws an exception in case of inconsistency.

Please note, that if there is any inconsistency in zObjVal indexes this is fatal and class can not work correctly and must be regenerated.

Parameters:
db - Database used for connection. Note that if you are using multiple databases the class can be consistent with one and inconsistent with another.
Throws:
InvalidClassException - if any inconsistency is found.
CacheException - if any error occurred during verification, e.g. communication error with Database.
See Also:
checkAllFieldsValid(com.intersys.objects.Database)

getSalary

public java.lang.Integer getSalary()
                            throws CacheException
Returns value of property Salary.

Description: The employee's current salary.

Returns:
current value of Salary represented as java.lang.Integer
Throws:
CacheException - if any error occurred during value retrieval.
See Also:
Salary

setSalary

public void setSalary(java.lang.Integer value)
               throws CacheException
Sets new value for Salary.

Description: The employee's current salary.

Parameters:
value - new value to be set represented as java.lang.Integer.
Throws:
CacheException - if any error occurred during value setting.
See Also:
Salary

checkTitleValid

public static void checkTitleValid(Database db)
                            throws CacheException
Verifies that indexes for property Title in zObjVal are the same as in Cache. It does not return anything but it throws an exception in case of inconsistency.

Please note, that if there is any inconsistency in zObjVal indexes this is fatal and class can not work correctly and must be regenerated.

Parameters:
db - Database used for connection. Note that if you are using multiple databases the class can be consistent with one and inconsistent with another.
Throws:
InvalidClassException - if any inconsistency is found.
CacheException - if any error occurred during verification, e.g. communication error with Database.
See Also:
checkAllFieldsValid(com.intersys.objects.Database)

getTitle

public java.lang.String getTitle()
                          throws CacheException
Returns value of property Title.

Description: The employee's job title.

Returns:
current value of Title represented as java.lang.String
Throws:
CacheException - if any error occurred during value retrieval.
See Also:
Title

setTitle

public void setTitle(java.lang.String value)
              throws CacheException
Sets new value for Title.

Description: The employee's job title.

Parameters:
value - new value to be set represented as java.lang.String.
Throws:
CacheException - if any error occurred during value setting.
See Also:
Title

sys_BMEBuilt

public static java.lang.Boolean sys_BMEBuilt(Database db,
                                             StringHolder bmeName)
                                      throws CacheException

Runs method sys_BMEBuilt in Cache.

Parameters:
db - represented as Database
bmeName - represented as com.intersys.objects.StringHolder
Throws:
CacheException - if any error occured while running the method.
See Also:
Method %BMEBuilt

sys_BuildIndices

public static void sys_BuildIndices(Database db)
                             throws CacheException

Runs method sys_BuildIndices in Cache.

Parameters:
db - represented as Database default argument idxlist set to ""
Throws:
CacheException - if any error occured while running the method.
See Also:
sys_BuildIndices(Database,com.intersys.objects.SList), Method %BuildIndices

sys_BuildIndices

public static void sys_BuildIndices(Database db,
                                    SList idxlist)
                             throws CacheException

Runs method sys_BuildIndices in Cache.

Parameters:
db - represented as Database
idxlist - represented as com.intersys.objects.SList
Throws:
CacheException - if any error occured while running the method.
See Also:
Method %BuildIndices

sys_CheckUnique

public static void sys_CheckUnique(Database db)
                            throws CacheException

Runs method sys_CheckUnique in Cache.

Parameters:
db - represented as Database default argument idxlist set to ""
Throws:
CacheException - if any error occured while running the method.
See Also:
sys_CheckUnique(Database,com.intersys.objects.SList), Method %CheckUnique

sys_CheckUnique

public static void sys_CheckUnique(Database db,
                                   SList idxlist)
                            throws CacheException

Runs method sys_CheckUnique in Cache.

Parameters:
db - represented as Database
idxlist - represented as com.intersys.objects.SList
Throws:
CacheException - if any error occured while running the method.
See Also:
Method %CheckUnique

sys_ClassName

public static java.lang.String sys_ClassName(Database db,
                                             java.lang.Boolean fullname)
                                      throws CacheException

Runs method sys_ClassName in Cache.

Description: Returns the object's class name. The fullname determines how the class name is represented. If it is 1 then it returns the full class name including any package qualifier. If it is 0 (the default) then it returns the name of the class without the package, this is mainly for backward compatibility with the pre-package behaviour of %ClassName.

Parameters:
db - represented as Database
fullname - represented as java.lang.Boolean
Throws:
CacheException - if any error occured while running the method.
See Also:
Method %ClassName

sys_Delete

public static void sys_Delete(Database db)
                       throws CacheException

Runs method sys_Delete in Cache.

Description: Deletes the stored version of the object with OID oid from the database. It does not remove any in-memory versions of the object that may be present. Refer to About Concurrency for more details on the optional concurrency argument.

Returns a %Status value indicating success or failure.

Internally, %Delete initiates a transaction and then invokes the storage interface method %DeleteData. If %DeleteData succeeds, the transaction is committed, otherwise it is rolled back.

Parameters:
db - represented as Database default argument oid set to "" default argument concurrency set to -1
Throws:
CacheException - if any error occured while running the method.
See Also:
sys_Delete(Database,com.intersys.objects.Oid,java.lang.Integer), Method %Delete

sys_Delete

public static void sys_Delete(Database db,
                              Oid oid)
                       throws CacheException

Runs method sys_Delete in Cache.

Description: Deletes the stored version of the object with OID oid from the database. It does not remove any in-memory versions of the object that may be present. Refer to About Concurrency for more details on the optional concurrency argument.

Returns a %Status value indicating success or failure.

Internally, %Delete initiates a transaction and then invokes the storage interface method %DeleteData. If %DeleteData succeeds, the transaction is committed, otherwise it is rolled back.

Parameters:
db - represented as Database
oid - represented as com.intersys.objects.Oid default argument concurrency set to -1
Throws:
CacheException - if any error occured while running the method.
See Also:
sys_Delete(Database,com.intersys.objects.Oid,java.lang.Integer), Method %Delete

sys_Delete

public static void sys_Delete(Database db,
                              Oid oid,
                              java.lang.Integer concurrency)
                       throws CacheException

Runs method sys_Delete in Cache.

Description: Deletes the stored version of the object with OID oid from the database. It does not remove any in-memory versions of the object that may be present. Refer to About Concurrency for more details on the optional concurrency argument.

Returns a %Status value indicating success or failure.

Internally, %Delete initiates a transaction and then invokes the storage interface method %DeleteData. If %DeleteData succeeds, the transaction is committed, otherwise it is rolled back.

Parameters:
db - represented as Database
oid - represented as com.intersys.objects.Oid
concurrency - represented as java.lang.Integer
Throws:
CacheException - if any error occured while running the method.
See Also:
Method %Delete

sys_DeleteExtent

public static void sys_DeleteExtent(Database db,
                                    java.lang.Integer concurrency,
                                    StringHolder deletecount,
                                    StringHolder instancecount)
                             throws CacheException

Runs method sys_DeleteExtent in Cache.

Description: Delete all instances of this class from its extent. On exit instancecount contains the original number of instances while deletecount contains the number of instances actually deleted.

Internally, %DeleteExtent iterates over the set of instances in the collection and invokes the %Delete method. Refer to About Concurrency for more details on the optional concurrency argument.

Returns a %Status value indicating success or failure.

Parameters:
db - represented as Database
concurrency - represented as java.lang.Integer
deletecount - represented as com.intersys.objects.StringHolder
instancecount - represented as com.intersys.objects.StringHolder
Throws:
CacheException - if any error occured while running the method.
See Also:
Method %DeleteExtent

sys_DeleteId

public static void sys_DeleteId(Database db,
                                java.lang.String id)
                         throws CacheException

Runs method sys_DeleteId in Cache.

Description: Deletes the stored version of the object with ID id from the database.

%DeleteId is identical in operation to the %Delete method except that it uses and Id value instead of an OID value to find an object. Refer to About Concurrency for more details on the optional concurrency argument.

Parameters:
db - represented as Database
id - represented as java.lang.String default argument concurrency set to -1
Throws:
CacheException - if any error occured while running the method.
See Also:
sys_DeleteId(Database,java.lang.String,java.lang.Integer), Method %DeleteId

sys_DeleteId

public static void sys_DeleteId(Database db,
                                java.lang.String id,
                                java.lang.Integer concurrency)
                         throws CacheException

Runs method sys_DeleteId in Cache.

Description: Deletes the stored version of the object with ID id from the database.

%DeleteId is identical in operation to the %Delete method except that it uses and Id value instead of an OID value to find an object. Refer to About Concurrency for more details on the optional concurrency argument.

Parameters:
db - represented as Database
id - represented as java.lang.String
concurrency - represented as java.lang.Integer
Throws:
CacheException - if any error occured while running the method.
See Also:
Method %DeleteId

sys_Exists

public static java.lang.Boolean sys_Exists(Database db)
                                    throws CacheException

Runs method sys_Exists in Cache.

Parameters:
db - represented as Database default argument oid set to ""
Throws:
CacheException - if any error occured while running the method.
See Also:
sys_Exists(Database,com.intersys.objects.Oid), Method %Exists

sys_Exists

public static java.lang.Boolean sys_Exists(Database db,
                                           Oid oid)
                                    throws CacheException

Runs method sys_Exists in Cache.

Parameters:
db - represented as Database
oid - represented as com.intersys.objects.Oid
Throws:
CacheException - if any error occured while running the method.
See Also:
Method %Exists

sys_ExistsId

public static java.lang.Boolean sys_ExistsId(Database db,
                                             java.lang.String id)
                                      throws CacheException

Runs method sys_ExistsId in Cache.

Parameters:
db - represented as Database
id - represented as java.lang.String
Throws:
CacheException - if any error occured while running the method.
See Also:
Method %ExistsId

sys_Extends

public static java.lang.Integer sys_Extends(Database db,
                                            java.lang.String isclass)
                                     throws CacheException

Runs method sys_Extends in Cache.

Description: Returns true (1) if this class is inherited either via primary or secondary inheritance from 'isclass'.

Parameters:
db - represented as Database
isclass - represented as java.lang.String
Throws:
CacheException - if any error occured while running the method.
See Also:
Method %Extends

sys_GetParameter

public static java.lang.String sys_GetParameter(Database db)
                                         throws CacheException

Runs method sys_GetParameter in Cache.

Description: This method returns the value of a parameter at runtime

Parameters:
db - represented as Database default argument paramname set to ""
Throws:
CacheException - if any error occured while running the method.
See Also:
sys_GetParameter(Database,java.lang.String), Method %GetParameter

sys_GetParameter

public static java.lang.String sys_GetParameter(Database db,
                                                java.lang.String paramname)
                                         throws CacheException

Runs method sys_GetParameter in Cache.

Description: This method returns the value of a parameter at runtime

Parameters:
db - represented as Database
paramname - represented as java.lang.String
Throws:
CacheException - if any error occured while running the method.
See Also:
Method %GetParameter

sys_IsA

public static java.lang.Integer sys_IsA(Database db,
                                        java.lang.String isclass)
                                 throws CacheException

Runs method sys_IsA in Cache.

Description: Returns true (1) if instances of this class are also instances of the isclass parameter. That is 'isclass' is a primary superclass of this object.

Parameters:
db - represented as Database
isclass - represented as java.lang.String
Throws:
CacheException - if any error occured while running the method.
See Also:
Method %IsA

sys_KillExtent

public static void sys_KillExtent(Database db)
                           throws CacheException

Runs method sys_KillExtent in Cache.

Parameters:
db - represented as Database
Throws:
CacheException - if any error occured while running the method.
See Also:
Method %KillExtent

sys_PackageName

public static java.lang.String sys_PackageName(Database db)
                                        throws CacheException

Runs method sys_PackageName in Cache.

Description: Returns the object's package name.

Parameters:
db - represented as Database
Throws:
CacheException - if any error occured while running the method.
See Also:
Method %PackageName

sys_PurgeIndices

public static void sys_PurgeIndices(Database db)
                             throws CacheException

Runs method sys_PurgeIndices in Cache.

Parameters:
db - represented as Database default argument idxlist set to ""
Throws:
CacheException - if any error occured while running the method.
See Also:
sys_PurgeIndices(Database,com.intersys.objects.SList), Method %PurgeIndices

sys_PurgeIndices

public static void sys_PurgeIndices(Database db,
                                    SList idxlist)
                             throws CacheException

Runs method sys_PurgeIndices in Cache.

Parameters:
db - represented as Database
idxlist - represented as com.intersys.objects.SList
Throws:
CacheException - if any error occured while running the method.
See Also:
Method %PurgeIndices

sys_SortBegin

public static void sys_SortBegin(Database db)
                          throws CacheException

Runs method sys_SortBegin in Cache.

Parameters:
db - represented as Database default argument idxlist set to "" default argument excludeunique set to 0
Throws:
CacheException - if any error occured while running the method.
See Also:
sys_SortBegin(Database,com.intersys.objects.SList,java.lang.Integer), Method %SortBegin

sys_SortBegin

public static void sys_SortBegin(Database db,
                                 SList idxlist)
                          throws CacheException

Runs method sys_SortBegin in Cache.

Parameters:
db - represented as Database
idxlist - represented as com.intersys.objects.SList default argument excludeunique set to 0
Throws:
CacheException - if any error occured while running the method.
See Also:
sys_SortBegin(Database,com.intersys.objects.SList,java.lang.Integer), Method %SortBegin

sys_SortBegin

public static void sys_SortBegin(Database db,
                                 SList idxlist,
                                 java.lang.Integer excludeunique)
                          throws CacheException

Runs method sys_SortBegin in Cache.

Parameters:
db - represented as Database
idxlist - represented as com.intersys.objects.SList
excludeunique - represented as java.lang.Integer
Throws:
CacheException - if any error occured while running the method.
See Also:
Method %SortBegin

sys_SortEnd

public static void sys_SortEnd(Database db)
                        throws CacheException

Runs method sys_SortEnd in Cache.

Parameters:
db - represented as Database default argument idxlist set to "" default argument commit set to 1
Throws:
CacheException - if any error occured while running the method.
See Also:
sys_SortEnd(Database,com.intersys.objects.SList,java.lang.Integer), Method %SortEnd

sys_SortEnd

public static void sys_SortEnd(Database db,
                               SList idxlist)
                        throws CacheException

Runs method sys_SortEnd in Cache.

Parameters:
db - represented as Database
idxlist - represented as com.intersys.objects.SList default argument commit set to 1
Throws:
CacheException - if any error occured while running the method.
See Also:
sys_SortEnd(Database,com.intersys.objects.SList,java.lang.Integer), Method %SortEnd

sys_SortEnd

public static void sys_SortEnd(Database db,
                               SList idxlist,
                               java.lang.Integer commit)
                        throws CacheException

Runs method sys_SortEnd in Cache.

Parameters:
db - represented as Database
idxlist - represented as com.intersys.objects.SList
commit - represented as java.lang.Integer
Throws:
CacheException - if any error occured while running the method.
See Also:
Method %SortEnd

CurrentAge

public static java.lang.Integer CurrentAge(Database db)
                                    throws CacheException

Runs method CurrentAge in Cache.

Description: This class method calculates a current age given a date of birth date.

Parameters:
db - represented as Database default argument date set to ""
Throws:
CacheException - if any error occured while running the method.
See Also:
CurrentAge(Database,java.sql.Date), Method CurrentAge

CurrentAge

public static java.lang.Integer CurrentAge(Database db,
                                           java.sql.Date date)
                                    throws CacheException

Runs method CurrentAge in Cache.

Description: This class method calculates a current age given a date of birth date.

Parameters:
db - represented as Database
date - represented as java.sql.Date
Throws:
CacheException - if any error occured while running the method.
See Also:
Method CurrentAge

Populate

public static java.lang.Integer Populate(Database db)
                                  throws CacheException

Runs method Populate in Cache.

Description: Creates up to count instances an object and stores them in the database.

If verbose is true, then details are echoed to the console.

If DeferIndices is true, then indices are sorted at the end of the operation.

Returns the number of instances successfully created.

For more information refer to About Populate.

Parameters:
db - represented as Database default argument count set to 10 default argument verbose set to 0 default argument DeferIndices set to 1 default argument objects set to 0
Throws:
CacheException - if any error occured while running the method.
See Also:
Populate(Database,java.lang.Integer,java.lang.Integer,java.lang.Integer,com.intersys.objects.IntegerHolder), Method Populate

Populate

public static java.lang.Integer Populate(Database db,
                                         java.lang.Integer count)
                                  throws CacheException

Runs method Populate in Cache.

Description: Creates up to count instances an object and stores them in the database.

If verbose is true, then details are echoed to the console.

If DeferIndices is true, then indices are sorted at the end of the operation.

Returns the number of instances successfully created.

For more information refer to About Populate.

Parameters:
db - represented as Database
count - represented as java.lang.Integer default argument verbose set to 0 default argument DeferIndices set to 1 default argument objects set to 0
Throws:
CacheException - if any error occured while running the method.
See Also:
Populate(Database,java.lang.Integer,java.lang.Integer,java.lang.Integer,com.intersys.objects.IntegerHolder), Method Populate

Populate

public static java.lang.Integer Populate(Database db,
                                         java.lang.Integer count,
                                         java.lang.Integer verbose)
                                  throws CacheException

Runs method Populate in Cache.

Description: Creates up to count instances an object and stores them in the database.

If verbose is true, then details are echoed to the console.

If DeferIndices is true, then indices are sorted at the end of the operation.

Returns the number of instances successfully created.

For more information refer to About Populate.

Parameters:
db - represented as Database
count - represented as java.lang.Integer
verbose - represented as java.lang.Integer default argument DeferIndices set to 1 default argument objects set to 0
Throws:
CacheException - if any error occured while running the method.
See Also:
Populate(Database,java.lang.Integer,java.lang.Integer,java.lang.Integer,com.intersys.objects.IntegerHolder), Method Populate

Populate

public static java.lang.Integer Populate(Database db,
                                         java.lang.Integer count,
                                         java.lang.Integer verbose,
                                         java.lang.Integer DeferIndices)
                                  throws CacheException

Runs method Populate in Cache.

Description: Creates up to count instances an object and stores them in the database.

If verbose is true, then details are echoed to the console.

If DeferIndices is true, then indices are sorted at the end of the operation.

Returns the number of instances successfully created.

For more information refer to About Populate.

Parameters:
db - represented as Database
count - represented as java.lang.Integer
verbose - represented as java.lang.Integer
DeferIndices - represented as java.lang.Integer default argument objects set to 0
Throws:
CacheException - if any error occured while running the method.
See Also:
Populate(Database,java.lang.Integer,java.lang.Integer,java.lang.Integer,com.intersys.objects.IntegerHolder), Method Populate

Populate

public static java.lang.Integer Populate(Database db,
                                         java.lang.Integer count,
                                         java.lang.Integer verbose,
                                         java.lang.Integer DeferIndices,
                                         IntegerHolder objects)
                                  throws CacheException

Runs method Populate in Cache.

Description: Creates up to count instances an object and stores them in the database.

If verbose is true, then details are echoed to the console.

If DeferIndices is true, then indices are sorted at the end of the operation.

Returns the number of instances successfully created.

For more information refer to About Populate.

Parameters:
db - represented as Database
count - represented as java.lang.Integer
verbose - represented as java.lang.Integer
DeferIndices - represented as java.lang.Integer
objects - represented as com.intersys.objects.IntegerHolder
Throws:
CacheException - if any error occured while running the method.
See Also:
Method Populate

PopulateSerial

public static java.lang.String PopulateSerial(Database db)
                                       throws CacheException

Runs method PopulateSerial in Cache.

Description: Create a single instance of a serial object.

Parameters:
db - represented as Database
Throws:
CacheException - if any error occured while running the method.
See Also:
Method PopulateSerial

PrintPerson

public void PrintPerson()
                 throws CacheException

Runs method PrintPerson in Cache.

Description: This method overrides the method in Person.
Prints the properties Name and Title to the console.

Overrides:
PrintPerson in class Person
Throws:
CacheException - if any error occured while running the method.
See Also:
Method PrintPerson

PrintPersons

public static void PrintPersons(Database db)
                         throws CacheException

Runs method PrintPersons in Cache.

Description: Invoke the PrintPerson on all Person objects within the database.

Parameters:
db - represented as Database
Throws:
CacheException - if any error occured while running the method.
See Also:
Method PrintPersons

PrintPersonsSQL

public static void PrintPersonsSQL(Database db)
                            throws CacheException

Runs method PrintPersonsSQL in Cache.

Description: Prints out data on all persons within the database using SQL to iterate over all the person data.

Parameters:
db - represented as Database
Throws:
CacheException - if any error occured while running the method.
See Also:
Method PrintPersonsSQL

StoredProcTest

public static java.lang.Integer StoredProcTest(Database db,
                                               java.lang.String name,
                                               StringHolder response)
                                        throws CacheException

Runs method StoredProcTest in Cache.

Description: This is a sample of how to define an SQL stored procedure using a class method. This method can be called as a stored procedure via ODBC or JDBC.
In this case this method returns the concatenation of a string value.

Parameters:
db - represented as Database
name - represented as java.lang.String
response - represented as com.intersys.objects.StringHolder
Throws:
CacheException - if any error occured while running the method.
See Also:
Method StoredProcTest

UpdateProcTest

public static java.lang.Integer UpdateProcTest(Database db,
                                               java.lang.String zip,
                                               java.lang.String city,
                                               java.lang.String state)
                                        throws CacheException

Runs method UpdateProcTest in Cache.

Description: This is a sample of how to define an SQL stored procedure using a class method. This method can be called as a stored procedure via ODBC or JDBC.
This method performs an SQL update operation on the database using embedded SQL. The update modifies the embedded properties Home.City and Home.State for all rows whose Home.Zip is equal to zip.

Parameters:
db - represented as Database
zip - represented as java.lang.String
city - represented as java.lang.String
state - represented as java.lang.String
Throws:
CacheException - if any error occured while running the method.
See Also:
Method UpdateProcTest

query_ByName

public static CacheQuery query_ByName(Database db)
                               throws CacheException

Returns a CallableStatement for query ByName.

Parameters:
db - represented as Database
Throws:
CacheException - if any error occured while running the method.

query_Extent

public static CacheQuery query_Extent(Database db)
                               throws CacheException

Returns a CallableStatement for query Extent.

Parameters:
db - represented as Database
Throws:
CacheException - if any error occured while running the method.

addToBatchInsert

public static java.lang.Object addToBatchInsert(java.lang.Object batch,
                                                java.sql.Connection con,
                                                java.lang.Integer Company,
                                                java.sql.Date DOB,
                                                java.util.List FavoriteColors,
                                                java.lang.String Name,
                                                java.lang.String SSN,
                                                java.lang.Integer Salary,
                                                java.lang.Integer Spouse,
                                                java.lang.String Title,
                                                java.lang.String Home_City,
                                                java.lang.String Home_State,
                                                java.lang.String Home_Street,
                                                java.lang.String Home_Zip,
                                                java.lang.String Office_City,
                                                java.lang.String Office_State,
                                                java.lang.String Office_Street,
                                                java.lang.String Office_Zip)
                                         throws java.sql.SQLException
Throws:
java.sql.SQLException

executeBatchInsert

public static java.util.List executeBatchInsert(java.sql.Connection con,
                                                java.lang.Object batch,
                                                int nolock)
                                         throws java.sql.SQLException
Throws:
java.sql.SQLException