Definition at line 47 of file FODBCollectionFile.java.
Public Member Functions | |
boolean | isSynchronized () |
FODBCypher | getCollectionCypher () throws FODBException |
return the collection cypher if any, null otherwise. | |
void | setCollectionCypher (FODBCypher cypher) throws FODBException |
Init collection encryption with the specified cypher. | |
void | setSynchronized (boolean sync) throws IOException, ClassNotFoundException |
synchronized long | addIndex (long indexPos) throws IOException, ClassNotFoundException |
Add an index to the indexs table. | |
Object | readNode (long pos) throws IOException, ClassNotFoundException |
Read Object at pos. | |
long | writeNode (Object obj) throws IOException, ClassNotFoundException |
Write an object. | |
void | rewriteNode (Object obj, long pos) throws IOException, ClassNotFoundException |
Rewrite an object The object has to be the same size it used to be. | |
Object | readObject (long pos) throws IOException, ClassNotFoundException |
Read Object at pos. | |
long | writeObject (Object obj) throws IOException, ClassNotFoundException |
Write an object. | |
void | rewriteObjectt (Object obj, long pos) throws IOException, ClassNotFoundException |
Rewrite an object The object has to be the same size it used to be. | |
void | deleteObject (long pos) throws IOException, ClassNotFoundException |
Delete an Object. | |
void | writeHeader () throws IOException, ClassNotFoundException |
Write the header at the beginning of the collection file. | |
void | rewriteHeader () throws IOException, ClassNotFoundException |
FODBCollectionFileHeader | readHeader () throws IOException, ClassNotFoundException |
Read the header which is situated at the beginning of the collection file and return it. | |
Class | getObjectType () |
FODBIndexHeader[] | getIndexsHeaders () throws IOException, ClassNotFoundException |
Read the indexs table. | |
String | toString () |
Used for debugging. | |
Static Public Member Functions | |
static FODBCollectionFile | createCollection (String filePath, Class objType, String colname, FastObjectDB db) throws IOException, ClassNotFoundException |
The function that is called to create a new Collection file. | |
static FODBCollectionFile | openCollection (String filePath, String colname, FastObjectDB db) throws IOException, ClassNotFoundException |
The function that is called to open an existing Collection file. |
|
Add an index to the indexs table.
Definition at line 188 of file FODBCollectionFile.java. References org.openmobileis.database.fastobjectdb.db.index.FODBIndexTable.add(). Referenced by org.openmobileis.database.fastobjectdb.db.store.FODBCollectionIndexFile.addIndexPointerToTable(). |
|
The function that is called to create a new Collection file. It just calls the constructor with the argument ACTION_CREATE.
Definition at line 162 of file FODBCollectionFile.java. |
|
Delete an Object.
Definition at line 324 of file FODBCollectionFile.java. References org.openmobileis.database.fastobjectdb.db.store.FODBObjectDatabaseFile.delete(), and org.openmobileis.database.fastobjectdb.db.store.FODBObjectDatabaseFile.seek(). Referenced by org.openmobileis.database.fastobjectdb.db.store.FODBCollectionIndexFile.deleteLongPtr(), org.openmobileis.database.fastobjectdb.db.store.FODBCollectionIndexFile.deleteNode(), and org.openmobileis.database.fastobjectdb.db.FODBCollection.deleteObjectWithId(). |
|
return the collection cypher if any, null otherwise.
Definition at line 122 of file FODBCollectionFile.java. Referenced by org.openmobileis.database.fastobjectdb.db.FODBCollection.getCollectionCypher(). |
|
Read the indexs table. Then get all indexs header, and return them as a table.
Definition at line 378 of file FODBCollectionFile.java. References org.openmobileis.database.fastobjectdb.db.index.FODBIndexTable.getPosByPlace(), org.openmobileis.database.fastobjectdb.db.store.FODBObjectDatabaseFile.readObject(), org.openmobileis.database.fastobjectdb.db.store.FODBObjectDatabaseFile.seek(), and org.openmobileis.database.fastobjectdb.db.index.FODBIndexTable.size(). |
|
The function that is called to open an existing Collection file. It just calls the constructor with the argument ACTION_OPEN.
Definition at line 173 of file FODBCollectionFile.java. |
|
Read the header which is situated at the beginning of the collection file and return it.
Definition at line 351 of file FODBCollectionFile.java. References org.openmobileis.database.fastobjectdb.db.store.FODBObjectDatabaseFile.readObject(), and org.openmobileis.database.fastobjectdb.db.store.FODBObjectDatabaseFile.rewind(). |
|
Read Object at pos.
Definition at line 223 of file FODBCollectionFile.java. References org.openmobileis.database.fastobjectdb.db.store.FODBObjectDatabaseFile.readObject(), and org.openmobileis.database.fastobjectdb.db.store.FODBObjectDatabaseFile.seek(). Referenced by org.openmobileis.database.fastobjectdb.db.FODBCollection.getNodeAtPos(), org.openmobileis.database.fastobjectdb.db.store.FODBCollectionIndexFile.readLongPtr(), and org.openmobileis.database.fastobjectdb.db.store.FODBCollectionIndexFile.readNode(). |
|
Read Object at pos.
Definition at line 260 of file FODBCollectionFile.java. References org.openmobileis.database.fastobjectdb.db.crypto.FODBCypher.decryptObject(), org.openmobileis.database.fastobjectdb.db.store.FODBObjectDatabaseFile.readObject(), and org.openmobileis.database.fastobjectdb.db.store.FODBObjectDatabaseFile.seek(). Referenced by org.openmobileis.database.fastobjectdb.db.FODBCollection.getElementAtPos(). |
|
Rewrite an object The object has to be the same size it used to be. The function doesn't check this. It is the role of the developper.
Definition at line 248 of file FODBCollectionFile.java. References org.openmobileis.database.fastobjectdb.db.store.FODBObjectDatabaseFile.rewriteObject(), and org.openmobileis.database.fastobjectdb.db.store.FODBObjectDatabaseFile.seek(). Referenced by org.openmobileis.database.fastobjectdb.db.store.FODBCollectionIndexFile.rewriteHeader(), org.openmobileis.database.fastobjectdb.db.store.FODBCollectionIndexFile.rewriteLongPtr(), org.openmobileis.database.fastobjectdb.db.store.FODBCollectionIndexFile.rewriteNode(), and org.openmobileis.database.fastobjectdb.db.store.FODBCollectionIndexFile.writeNode(). |
|
Rewrite an object The object has to be the same size it used to be. The function doesn't check this. It is the role of the developper.
Definition at line 303 of file FODBCollectionFile.java. References org.openmobileis.database.fastobjectdb.db.crypto.FODBCypher.encryptObject(), org.openmobileis.database.fastobjectdb.db.store.FODBObjectDatabaseFile.rewriteObject(), and org.openmobileis.database.fastobjectdb.db.store.FODBObjectDatabaseFile.seek(). |
|
Init collection encryption with the specified cypher. Must be call just after collection initialization before storing/reading any data. Same cypher must be provided to read already stored object.
Definition at line 133 of file FODBCollectionFile.java. References org.openmobileis.database.fastobjectdb.db.store.FODBObjectDatabaseFile.close(), org.openmobileis.database.fastobjectdb.db.store.FODBObjectDatabaseFile.open(), and org.openmobileis.database.fastobjectdb.db.store.FODBCollectionFile.rewriteHeader(). Referenced by org.openmobileis.database.fastobjectdb.db.FODBCollection.setCollectionCypher(). |
|
Write the header at the beginning of the collection file.
Definition at line 334 of file FODBCollectionFile.java. References org.openmobileis.database.fastobjectdb.db.store.FODBObjectDatabaseFile.rewind(), and org.openmobileis.database.fastobjectdb.db.store.FODBObjectDatabaseFile.writeObject(). |
|
Write an object.
Definition at line 235 of file FODBCollectionFile.java. References org.openmobileis.database.fastobjectdb.db.store.FODBObjectDatabaseFile.writeObject(). Referenced by org.openmobileis.database.fastobjectdb.db.store.FODBCollectionIndexFile.writeHeader(), org.openmobileis.database.fastobjectdb.db.store.FODBCollectionIndexFile.writeLongPtr(), and org.openmobileis.database.fastobjectdb.db.store.FODBCollectionIndexFile.writeNode(). |
|
Write an object.
Definition at line 280 of file FODBCollectionFile.java. References org.openmobileis.database.fastobjectdb.db.crypto.FODBCypher.encryptObject(), and org.openmobileis.database.fastobjectdb.db.store.FODBObjectDatabaseFile.writeObject(). Referenced by org.openmobileis.database.fastobjectdb.db.FODBCollection.addElement(). |