|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectnet.sourceforge.jpalm.DataBlock
net.sourceforge.jpalm.palmdb.ApplicationInfo
net.sourceforge.jpalm.mobiledb.DatabaseInfo
public class DatabaseInfo
The database info block in a MobileDB database.
ApplicationInfo.getApplicationData(),
ApplicationInfo.setApplicationData(byte[])| Field Summary | |
|---|---|
static int |
DATA_LENGTH
The length of this DataBlock in bytes.152 |
static net.sourceforge.juint.UInt8 |
LOCKED_COLUMN_NONE
No locked columns. |
static net.sourceforge.juint.UInt8 |
PASSWORD_PROTECTION_LOCK
Database is completely locked. |
static net.sourceforge.juint.UInt8 |
PASSWORD_PROTECTION_NONE
No password protection. |
static net.sourceforge.juint.UInt8 |
PASSWORD_PROTECTION_READ_ONLY
Database is read-only. |
| Fields inherited from class net.sourceforge.jpalm.palmdb.ApplicationInfo |
|---|
applicationData, categoryLabels, categoryUniqueIds, lastUniqueId, padding, renamedCategories |
| Constructor Summary | |
|---|---|
DatabaseInfo()
Creates a new database info block. |
|
DatabaseInfo(byte[] data)
Creates a new database info block from the byte array. |
|
| Method Summary | |
|---|---|
void |
deserialize(byte[] data)
Populate class properties from a byte array. |
boolean |
equals(java.lang.Object object)
|
FilterCriterion |
getFilter1()
Gets the first filter criterion. |
FilterCriterion |
getFilter2()
Gets the second filter criterion. |
FilterCriterion |
getFilter3()
Gets the third filter criterion. |
net.sourceforge.juint.UInt8 |
getLockedColumn()
Gets the locked column. |
net.sourceforge.juint.UInt32 |
getPasswordHash()
Gets the password hash. |
net.sourceforge.juint.UInt8 |
getPasswordProtection()
Gets the type of password protection. |
byte[] |
getReserved()
Gets the reserved bytes. |
SortCriterion |
getSort1()
Gets the first sort criterion. |
SortCriterion |
getSort2()
Gets the second sort criterion. |
SortCriterion |
getSort3()
Gets the third sort criterion. |
net.sourceforge.juint.UInt16 |
getVersion()
Gets the header version. |
net.sourceforge.juint.UInt32 |
hashPassword(java.lang.String password)
Creates a password hash for locking the database. |
boolean |
isDisplayLongDates()
Gets the display long dates flag. |
boolean |
isEditOnSelect()
Gets the edit on select flag. |
boolean |
isSearchOnGlobalFind()
Gets the search on global find flag. |
byte[] |
serialize()
Create a byte array of the class properties. |
void |
setDisplayLongDates(boolean displayLongDates)
Sets the display long dates flag. |
void |
setEditOnSelect(boolean editOnSelect)
Sets the edit on select flag. |
void |
setFilter1(FilterCriterion filter)
Sets the first filter criterion. |
void |
setFilter2(FilterCriterion filter)
Sets the second filter criterion. |
void |
setFilter3(FilterCriterion filter)
Sets the third filter criterion. |
void |
setLockedColumn(net.sourceforge.juint.UInt8 lockedColumn)
Sets the locked column. |
void |
setPasswordHash(net.sourceforge.juint.UInt32 passwordHash)
Sets the password hash. |
void |
setPasswordProtection(net.sourceforge.juint.UInt8 passwordProtection)
Sets the type of password protection. |
void |
setReserved(byte[] reserved)
Sets the reserved bytes. |
void |
setSearchOnGlobalFind(boolean searchOnGlobalFind)
Sets the search on global find flag. |
void |
setSort1(SortCriterion sort)
Sets the first sort criterion. |
void |
setSort2(SortCriterion sort)
Sets the second sort criterion. |
void |
setSort3(SortCriterion sort)
Sets the third sort criterion. |
void |
setVersion(net.sourceforge.juint.UInt16 version)
Sets the header version. |
| Methods inherited from class net.sourceforge.jpalm.palmdb.ApplicationInfo |
|---|
getApplicationData, getCategoryLabels, getCategoryUniqueIds, getLastUniqueId, getPadding, getRenamedCategories, setApplicationData, setCategoryLabels, setCategoryUniqueIds, setLastUniqueId, setPadding, setRenamedCategories |
| Methods inherited from class net.sourceforge.jpalm.DataBlock |
|---|
toString |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public static final int DATA_LENGTH
DataBlock in bytes.
public static net.sourceforge.juint.UInt8 LOCKED_COLUMN_NONE
public static net.sourceforge.juint.UInt8 PASSWORD_PROTECTION_NONE
public static net.sourceforge.juint.UInt8 PASSWORD_PROTECTION_READ_ONLY
public static net.sourceforge.juint.UInt8 PASSWORD_PROTECTION_LOCK
| Constructor Detail |
|---|
public DatabaseInfo()
public DatabaseInfo(byte[] data)
byte array.
data - the byte arraydeserialize(byte[])| Method Detail |
|---|
public void deserialize(byte[] data)
DataBlockbyte array.
deserialize in class ApplicationInfodata - the byte arraypublic byte[] serialize()
DataBlockbyte array of the class properties.
serialize in class ApplicationInfobyte arraypublic net.sourceforge.juint.UInt32 hashPassword(java.lang.String password)
password - the password
setPasswordHash(UInt32)public boolean isSearchOnGlobalFind()
true if the database should be visible to find; false
otherwisepublic void setSearchOnGlobalFind(boolean searchOnGlobalFind)
true.
searchOnGlobalFind - true if the database should be visible to find; false
otherwisepublic boolean isEditOnSelect()
true if a record should be edited when selected; false
otherwisepublic void setEditOnSelect(boolean editOnSelect)
true.
editOnSelect - true if a record should be edited when selected; false
otherwisepublic FilterCriterion getFilter1()
public void setFilter1(FilterCriterion filter)
filter - the first filter criterionpublic FilterCriterion getFilter2()
public void setFilter2(FilterCriterion filter)
filter - the second filter criterionpublic FilterCriterion getFilter3()
public void setFilter3(FilterCriterion filter)
filter - the third filter criterionpublic net.sourceforge.juint.UInt32 getPasswordHash()
0 then the database is not password
protected.
0public void setPasswordHash(net.sourceforge.juint.UInt32 passwordHash)
0 to disable password protection.
passwordHash - the password hash or 0hashPassword(String)public boolean isDisplayLongDates()
Example long date: Sep 3, 2006.
Example short date: 9/3/06.
true if long dates should be shown; false otherwisepublic void setDisplayLongDates(boolean displayLongDates)
false.
Example long date: Sep 3, 2006.
Example short date: 9/3/06.
displayLongDates - true if long dates should be shown; false otherwisepublic byte[] getReserved()
public void setReserved(byte[] reserved)
reserved - the reserved bytespublic SortCriterion getSort1()
public void setSort1(SortCriterion sort)
sort - the first sort criterionpublic SortCriterion getSort2()
public void setSort2(SortCriterion sort)
sort - the second sort criterionpublic SortCriterion getSort3()
public void setSort3(SortCriterion sort)
sort - the third sort criterionpublic net.sourceforge.juint.UInt16 getVersion()
1.
public void setVersion(net.sourceforge.juint.UInt16 version)
1.
version - the header versionpublic net.sourceforge.juint.UInt8 getLockedColumn()
LOCKED_COLUMN_NONEpublic void setLockedColumn(net.sourceforge.juint.UInt8 lockedColumn)
lockedColumn - the locked column number or LOCKED_COLUMN_NONEpublic net.sourceforge.juint.UInt8 getPasswordProtection()
PASSWORD_PROTECTION_LOCK, PASSWORD_PROTECTION_NONE, or
PASSWORD_PROTECTION_READ_ONLYpublic void setPasswordProtection(net.sourceforge.juint.UInt8 passwordProtection)
passwordProtection - PASSWORD_PROTECTION_LOCK, PASSWORD_PROTECTION_NONE, or
PASSWORD_PROTECTION_READ_ONLYsetPasswordHash(UInt32)public boolean equals(java.lang.Object object)
equals in class ApplicationInfo
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||