Class JDB2Reader
java.lang.Object
com.pnfsoftware.jeb.core.dao.impl.JDB2Reader
- All Implemented Interfaces:
IFileDatabaseReader,Closeable,AutoCloseable
JDB2 (JEB saved project database) record reader. A JDB2 is made of records.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classDefinition of a JDB2 record. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidclose()Retrieve the backing file, if any.intRetrieve the version-integer of the JEB build that originally created the JDB2 database.getRecord(int type) Retrieve a record.Retrieve a record.getRecordDescription(int type) booleanDetermine if this database is backed by a file.
-
Constructor Details
-
JDB2Reader
- Throws:
IOException
-
-
Method Details
-
getJebVersionInt
public int getJebVersionInt()Retrieve the version-integer of the JEB build that originally created the JDB2 database. On older JDB2, this value is not set and will be 0. If a non-zero value is returned, it can be converted to a partial version object usingVersion.fromInt(int).- Returns:
-
hasBackingFile
public boolean hasBackingFile()Description copied from interface:IFileDatabaseReaderDetermine if this database is backed by a file.- Specified by:
hasBackingFilein interfaceIFileDatabaseReader- Returns:
-
getBackingFile
Description copied from interface:IFileDatabaseReaderRetrieve the backing file, if any.- Specified by:
getBackingFilein interfaceIFileDatabaseReader- Returns:
-
getRecordDescriptions
- Specified by:
getRecordDescriptionsin interfaceIFileDatabaseReader- Returns:
-
getRecordDescription
- Specified by:
getRecordDescriptionin interfaceIFileDatabaseReader- Parameters:
type- record type- Returns:
-
getRecord
Description copied from interface:IFileDatabaseReaderRetrieve a record.- Specified by:
getRecordin interfaceIFileDatabaseReader- Parameters:
type- record type- Returns:
- record data stream
- Throws:
IOException
-
getRecord
Description copied from interface:IFileDatabaseReaderRetrieve a record.- Specified by:
getRecordin interfaceIFileDatabaseReader- Returns:
- Throws:
IOException
-
close
- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable- Throws:
IOException
-