Package: com.appistry.fam
Class FAM_Session
createFabricExternalSession
FAM_Session createFabricExternalSession(String lockId,
String version)
This function creates a FAM session. Use this function when accessing the FAM API outside a fabric task.
| string |
lock identifier |
| string |
session version |
| FAM_Session |
FAM session object |
| Exceptions |
NullPointerException |
getLockID
This function returns the lock identifier.
getVersion
This function returns the session version.
getLeaseTimeout
This function returns the amount of time the data is locked.
| int |
the maximum amount of time the data is locked |
setLeaseTimeout
void setLeaseTimeout(int leaseTimeout)
This function sets the maximum amount of time, in milliseconds, the data is locked.
| int |
maximum amount of time, in milliseconds, the data is locked |
getSpacesTouchedCount
int getSpacesTouchedCount( )
This function returns the number of spaces accessed during the session.
| int |
number of spaces accessed during the session |
commit
This function commits the data manipulations performed in the session.
rollback
This function deletes the data manipulations performed in the session and returns the data to the last commit.
Note. The FAM does not keep past versions of the data. When data is locked, a copy is created. Once data has been committed, by sending the commit function or by the successful completion of a task, that copy is deleted. You can not go back to a previous version of data.
commitPrep
This function is the first phase of a two-phase commit. To complete the commit you must call the commit function.
invalidate
This function executes a rollback without releasing the lock.