|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.openmobileis.database.fastobjectdb.FastObjectDB | +--org.openmobileis.database.fastobjectdb.synchro.client.SynchroFastObjectDB
Title: OpenMobileIS project source
Description: Synchronisable version of FastDBObject
Fields inherited from class org.openmobileis.database.fastobjectdb.FastObjectDB |
ACTION_CREATE, ACTION_OPEN, colManager |
Method Summary | |
boolean |
add(java.lang.String colName,
java.lang.Object obj)
Add an element to a Collection of the database. |
boolean |
addFODB(java.lang.String colName,
java.lang.Object obj)
Add an element to a Collection of the database without saving modification data needed to synchronize synchronizable collection. |
boolean |
createCollection(java.lang.String collectionName,
java.lang.Class objectType)
Add a new collection to the database. the synchro parameter is set to true. |
boolean |
createCollection(java.lang.String collectionName,
java.lang.Class objectType,
boolean synchro)
Add a new collection to the database. |
boolean |
delete(java.lang.String colName,
java.lang.Object obj)
Delete an element of a Collection |
boolean |
deleteWithId(java.lang.String colName,
java.lang.Object id)
Delete an object of a Collection with its id |
boolean |
deleteWithIdFODB(java.lang.String colName,
java.lang.Object id)
Delete an object of a Collection with its id Doas not generate syncho action. |
java.lang.Object |
getObjectFromCollectionWithId(java.lang.String colName,
java.lang.String id)
return the object from the specified collection with specified id. id is the string format of the id object. |
boolean |
isObjectInCollection(java.lang.String colName,
java.lang.Object obj)
return true if the specified object from the specified collection is in the collection. return false otherwise |
static FastObjectDB |
open(java.lang.String dbRootDir,
java.lang.String dbName)
The function is called to open a database. |
protected boolean |
openCollection(java.lang.String collectionName)
Open an existing collection. |
void |
registerSynchroFODBReturnListener(java.lang.String collectionName,
SynchroFODBReturnListener listener)
Register a synchroListener call during synchronisation processus. |
boolean |
replace(java.lang.String colName,
java.lang.Object obj)
Replace an existing element in a Collection of the database. |
boolean |
replaceFODB(java.lang.String colName,
java.lang.Object obj)
Replace an existing element in a Collection of the database without saving modification data needed to synchronize synchronizable collection. |
Methods inherited from class org.openmobileis.database.fastobjectdb.FastObjectDB |
addIndex, getCollection, getDatabaseCollectionArray, getName, getRootDir, getTransactionManager, isCollectionEmpty, isCollectionExist, query, toString |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Method Detail |
public static FastObjectDB open(java.lang.String dbRootDir, java.lang.String dbName) throws java.io.IOException, java.lang.ClassNotFoundException, BadDataFormatException, FODBException
dbRootDir
- - database directorydbName
- - database namejava.io.IOException
- java.lang.ClassNotFoundException
- BadDataFormatException
- FODBDataFileException
- FODBCollectionException
- public boolean createCollection(java.lang.String collectionName, java.lang.Class objectType, boolean synchro) throws java.io.IOException, java.lang.ClassNotFoundException, BadDataFormatException, FODBException
createCollection
in class FastObjectDB
collectionName
- - name of the new colletionobjectType
- - type of objects stored in this collection.synchro
- - if set to false the collection wont be synchronized when FODB is in synchro mode.java.io.IOException
- java.lang.ClassNotFoundException
- BadDataFormatException
- FODBDataFileException
- FODBCollectionException
- public boolean createCollection(java.lang.String collectionName, java.lang.Class objectType) throws java.io.IOException, java.lang.ClassNotFoundException, BadDataFormatException, FODBException
createCollection
in class FastObjectDB
collectionName
- - name of the new colletionobjectType
- - type of objects stored in this collection.java.io.IOException
- java.lang.ClassNotFoundException
- BadDataFormatException
- FODBDataFileException
- FODBCollectionException
- protected boolean openCollection(java.lang.String collectionName) throws java.io.IOException, java.lang.ClassNotFoundException, BadDataFormatException, FODBException
openCollection
in class FastObjectDB
collectionName
- - name of the collectionjava.io.IOException
- java.lang.ClassNotFoundException
- BadDataFormatException
- FODBDataFileException
- FODBCollectionException
- public void registerSynchroFODBReturnListener(java.lang.String collectionName, SynchroFODBReturnListener listener)
collectionName
- listener
- public boolean isObjectInCollection(java.lang.String colName, java.lang.Object obj) throws DatabaseException
colName
- - name of the Collectionobject
- - object to look for.public java.lang.Object getObjectFromCollectionWithId(java.lang.String colName, java.lang.String id) throws DatabaseException
colName
- - name of the Collectionid
- - object id.public boolean addFODB(java.lang.String colName, java.lang.Object obj) throws FODBException
colName
- - Name of the collectionobj
- - object to add.FODBDataFileException
- FODBCollectionException
- FODBIndexException
- BTreeException
- public boolean add(java.lang.String colName, java.lang.Object obj) throws FODBException
add
in class FastObjectDB
colName
- - Name of the collectionobj
- - object to add.FODBException
- public boolean replaceFODB(java.lang.String colName, java.lang.Object obj) throws FODBException
colName
- - Name of the Collectionobj
- - Object to replace.FODBException
- public boolean replace(java.lang.String colName, java.lang.Object obj) throws FODBException
replace
in class FastObjectDB
colName
- - Name of the Collectionobj
- - Object to replace.FODBException
- public boolean delete(java.lang.String colName, java.lang.Object obj) throws FODBException
delete
in class FastObjectDB
colName
- - name of the Collection.obj
- - object to delete.FODBCollectionException
- FODBIndexException
- public boolean deleteWithIdFODB(java.lang.String colName, java.lang.Object id) throws FODBException
colName
- - name of the Collection.id
- - id of the object to delete.FODBCollectionException
- FODBIndexException
- public boolean deleteWithId(java.lang.String colName, java.lang.Object id) throws FODBException
deleteWithId
in class FastObjectDB
colName
- - name of the Collection.id
- - id of the object to delete.FODBCollectionException
- FODBIndexException
-
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |