|
|||||||||
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.Header
public class Header
The header in a Palm database.
Field Summary | |
---|---|
protected net.sourceforge.juint.UInt32 |
applicationInfoOffset
|
static net.sourceforge.juint.UInt16 |
ATTRIBUTE_BACKUP_DATABASE
Backup database on next HotSync. |
static net.sourceforge.juint.UInt16 |
ATTRIBUTE_BUNDLE
Database is associated with the application with the same creator. |
static net.sourceforge.juint.UInt16 |
ATTRIBUTE_COPY_PREVENTION
Disallow copies of this database. |
static net.sourceforge.juint.UInt16 |
ATTRIBUTE_DIRTY_APPLICATION_INFO_AREA
Database's application info block is dirty. |
static net.sourceforge.juint.UInt16 |
ATTRIBUTE_HIDDEN
Database should be hidden from view. |
static net.sourceforge.juint.UInt16 |
ATTRIBUTE_LAUNCHABLE_DATA
This data database can be launched by having it's name passed to it's owning application. |
static net.sourceforge.juint.UInt16 |
ATTRIBUTE_OK_TO_INSTALL_NEWER
Replace existing database. |
static net.sourceforge.juint.UInt16 |
ATTRIBUTE_OPEN
Database is open. |
static net.sourceforge.juint.UInt16 |
ATTRIBUTE_READ_ONLY
Database is read-only. |
static net.sourceforge.juint.UInt16 |
ATTRIBUTE_RECYCLABLE
Database will be deleted when closed or upon a system reset. |
static net.sourceforge.juint.UInt16 |
ATTRIBUTE_RESET_DEVICE_AFTER_INSTALL
Reset device after this database is installed. |
static net.sourceforge.juint.UInt16 |
ATTRIBUTE_RESOURCE_DATABASE
Database is a resource database. |
static net.sourceforge.juint.UInt16 |
ATTRIBUTE_STREAM
Database is a file stream. |
protected net.sourceforge.juint.UInt16 |
attributes
|
protected Date |
creationDate
|
protected java.lang.String |
creator
|
static int |
CREATOR_LENGTH
The maximum length of the creator name. 4 |
static int |
DATA_LENGTH
The maximum length of the header in byte s.78 |
protected Date |
lastBackupDate
|
protected Date |
modificationDate
|
protected net.sourceforge.juint.UInt32 |
modificationNumber
|
protected java.lang.String |
name
|
static int |
NAME_LENGTH
The maximum length of the database name, including 1 for the null terminator. 32 |
protected net.sourceforge.juint.UInt32 |
nextRecordListOffset
|
protected net.sourceforge.juint.UInt16 |
numberOfRecords
|
protected net.sourceforge.juint.UInt32 |
sortInfoOffset
|
protected java.lang.String |
type
|
static int |
TYPE_LENGTH
The maximum length of the type name. 4 |
protected net.sourceforge.juint.UInt32 |
uniqueIdSeed
|
protected net.sourceforge.juint.UInt16 |
version
|
Constructor Summary | |
---|---|
Header()
Creates a new header. |
|
Header(byte[] data)
Creates a new header from the byte array. |
Method Summary | |
---|---|
void |
addAttribute(net.sourceforge.juint.UInt16 attribute)
Adds an attribute. |
void |
deserialize(byte[] data)
Populate class properties from a byte array. |
boolean |
equals(java.lang.Object object)
|
net.sourceforge.juint.UInt32 |
getApplicationInfoOffset()
Gets the offset of the application info block. |
net.sourceforge.juint.UInt16 |
getAttributes()
Gets the attributes. |
Date |
getCreationDate()
Gets the creation date. |
java.lang.String |
getCreator()
Gets the creator. |
Date |
getLastBackupDate()
Gets the last backup date. |
Date |
getModificationDate()
Gets the modification date. |
net.sourceforge.juint.UInt32 |
getModificationNumber()
Gets the modification number. |
java.lang.String |
getName()
Gets the name of the Palm database. |
net.sourceforge.juint.UInt32 |
getNextRecordListOffset()
Gets the offset of the next record list. |
net.sourceforge.juint.UInt16 |
getNumberOfRecords()
Gets the number of records in the Palm database. |
net.sourceforge.juint.UInt32 |
getSortInfoOffset()
Gets the offset of the sort info block. |
java.lang.String |
getType()
Gets the type. |
net.sourceforge.juint.UInt32 |
getUniqueIdSeed()
Gets the unique id seed. |
net.sourceforge.juint.UInt16 |
getVersion()
Gets the version. |
void |
removeAttribute(net.sourceforge.juint.UInt16 attribute)
Removes an attribute. |
byte[] |
serialize()
Create a byte array of the class properties. |
void |
setApplicationInfoOffset(net.sourceforge.juint.UInt32 applicationInfoOffset)
Sets the offset of the application info block. |
void |
setAttributes(net.sourceforge.juint.UInt16 attributes)
Sets the attributes. |
void |
setCreationDate(Date creationDate)
Sets the creation date. |
void |
setCreator(java.lang.String creator)
Sets the creator. |
void |
setLastBackupDate(Date lastBackupDate)
Sets the last backup date. |
void |
setModificationDate(Date modificationDate)
Sets the modification date. |
void |
setModificationNumber(net.sourceforge.juint.UInt32 modificationNumber)
Sets the modificaiton number. |
void |
setName(java.lang.String name)
Sets the name of the Palm database. |
void |
setNextRecordListOffset(net.sourceforge.juint.UInt32 nextRecordListOffset)
Sets the offset of the next record list. |
void |
setNumberOfRecords(net.sourceforge.juint.UInt16 numberOfRecords)
Sets the number of records in the Palm database. |
void |
setSortInfoOffset(net.sourceforge.juint.UInt32 sortInfoOffset)
Sets the offset of the sort info block. |
void |
setType(java.lang.String type)
Sets the type. |
void |
setUniqueIdSeed(net.sourceforge.juint.UInt32 uniqueIdSeed)
Sets the unique id seed. |
void |
setVersion(net.sourceforge.juint.UInt16 version)
Sets the version. |
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 NAME_LENGTH
public static final int CREATOR_LENGTH
public static final int TYPE_LENGTH
public static final int DATA_LENGTH
byte
s.
public static final net.sourceforge.juint.UInt16 ATTRIBUTE_RESOURCE_DATABASE
public static final net.sourceforge.juint.UInt16 ATTRIBUTE_READ_ONLY
public static final net.sourceforge.juint.UInt16 ATTRIBUTE_DIRTY_APPLICATION_INFO_AREA
public static final net.sourceforge.juint.UInt16 ATTRIBUTE_BACKUP_DATABASE
public static final net.sourceforge.juint.UInt16 ATTRIBUTE_OK_TO_INSTALL_NEWER
public static final net.sourceforge.juint.UInt16 ATTRIBUTE_RESET_DEVICE_AFTER_INSTALL
public static final net.sourceforge.juint.UInt16 ATTRIBUTE_COPY_PREVENTION
public static final net.sourceforge.juint.UInt16 ATTRIBUTE_STREAM
public static final net.sourceforge.juint.UInt16 ATTRIBUTE_HIDDEN
public static final net.sourceforge.juint.UInt16 ATTRIBUTE_LAUNCHABLE_DATA
public static final net.sourceforge.juint.UInt16 ATTRIBUTE_RECYCLABLE
public static final net.sourceforge.juint.UInt16 ATTRIBUTE_BUNDLE
public static final net.sourceforge.juint.UInt16 ATTRIBUTE_OPEN
protected java.lang.String name
protected net.sourceforge.juint.UInt16 attributes
protected net.sourceforge.juint.UInt16 version
protected Date creationDate
protected Date modificationDate
protected Date lastBackupDate
protected net.sourceforge.juint.UInt32 modificationNumber
protected net.sourceforge.juint.UInt32 applicationInfoOffset
protected net.sourceforge.juint.UInt32 sortInfoOffset
protected java.lang.String type
protected java.lang.String creator
protected net.sourceforge.juint.UInt32 uniqueIdSeed
protected net.sourceforge.juint.UInt32 nextRecordListOffset
protected net.sourceforge.juint.UInt16 numberOfRecords
Constructor Detail |
---|
public Header(byte[] data)
byte
array.
data
- the byte
arraydeserialize(byte[])
public Header()
Method Detail |
---|
public net.sourceforge.juint.UInt32 getApplicationInfoOffset()
public void setApplicationInfoOffset(net.sourceforge.juint.UInt32 applicationInfoOffset)
applicationInfoOffset
- the offsetpublic net.sourceforge.juint.UInt16 getAttributes()
ATTRIBUTE_BACKUP_DATABASE
,
ATTRIBUTE_BUNDLE
,
ATTRIBUTE_COPY_PREVENTION
,
ATTRIBUTE_DIRTY_APPLICATION_INFO_AREA
,
ATTRIBUTE_HIDDEN
,
ATTRIBUTE_LAUNCHABLE_DATA
,
ATTRIBUTE_OK_TO_INSTALL_NEWER
,
ATTRIBUTE_OPEN
,
ATTRIBUTE_READ_ONLY
,
ATTRIBUTE_RECYCLABLE
,
ATTRIBUTE_RESET_DEVICE_AFTER_INSTALL
,
ATTRIBUTE_RESOURCE_DATABASE
,
ATTRIBUTE_STREAM
public void setAttributes(net.sourceforge.juint.UInt16 attributes)
attributes
- the attributesATTRIBUTE_BACKUP_DATABASE
,
ATTRIBUTE_BUNDLE
,
ATTRIBUTE_COPY_PREVENTION
,
ATTRIBUTE_DIRTY_APPLICATION_INFO_AREA
,
ATTRIBUTE_HIDDEN
,
ATTRIBUTE_LAUNCHABLE_DATA
,
ATTRIBUTE_OK_TO_INSTALL_NEWER
,
ATTRIBUTE_OPEN
,
ATTRIBUTE_READ_ONLY
,
ATTRIBUTE_RECYCLABLE
,
ATTRIBUTE_RESET_DEVICE_AFTER_INSTALL
,
ATTRIBUTE_RESOURCE_DATABASE
,
ATTRIBUTE_STREAM
public void addAttribute(net.sourceforge.juint.UInt16 attribute)
attribute
- the attributeATTRIBUTE_BACKUP_DATABASE
,
ATTRIBUTE_BUNDLE
,
ATTRIBUTE_COPY_PREVENTION
,
ATTRIBUTE_DIRTY_APPLICATION_INFO_AREA
,
ATTRIBUTE_HIDDEN
,
ATTRIBUTE_LAUNCHABLE_DATA
,
ATTRIBUTE_OK_TO_INSTALL_NEWER
,
ATTRIBUTE_OPEN
,
ATTRIBUTE_READ_ONLY
,
ATTRIBUTE_RECYCLABLE
,
ATTRIBUTE_RESET_DEVICE_AFTER_INSTALL
,
ATTRIBUTE_RESOURCE_DATABASE
,
ATTRIBUTE_STREAM
public void removeAttribute(net.sourceforge.juint.UInt16 attribute)
attribute
- the attributeATTRIBUTE_BACKUP_DATABASE
,
ATTRIBUTE_BUNDLE
,
ATTRIBUTE_COPY_PREVENTION
,
ATTRIBUTE_DIRTY_APPLICATION_INFO_AREA
,
ATTRIBUTE_HIDDEN
,
ATTRIBUTE_LAUNCHABLE_DATA
,
ATTRIBUTE_OK_TO_INSTALL_NEWER
,
ATTRIBUTE_OPEN
,
ATTRIBUTE_READ_ONLY
,
ATTRIBUTE_RECYCLABLE
,
ATTRIBUTE_RESET_DEVICE_AFTER_INSTALL
,
ATTRIBUTE_RESOURCE_DATABASE
,
ATTRIBUTE_STREAM
public Date getCreationDate()
public void setCreationDate(Date creationDate)
creationDate
- the creation datepublic java.lang.String getCreator()
public void setCreator(java.lang.String creator)
CREATOR_LENGTH
characters.
creator
- the creatorpublic Date getLastBackupDate()
public void setLastBackupDate(Date lastBackupDate)
lastBackupDate
- the last backup datepublic Date getModificationDate()
public void setModificationDate(Date modificationDate)
modificationDate
- the modification datepublic net.sourceforge.juint.UInt32 getModificationNumber()
public void setModificationNumber(net.sourceforge.juint.UInt32 modificationNumber)
modificationNumber
- the modification numberpublic java.lang.String getName()
public void setName(java.lang.String name)
name
- the namepublic net.sourceforge.juint.UInt32 getNextRecordListOffset()
public void setNextRecordListOffset(net.sourceforge.juint.UInt32 nextRecordListOffset)
nextRecordListOffset
- the offsetpublic net.sourceforge.juint.UInt16 getNumberOfRecords()
public void setNumberOfRecords(net.sourceforge.juint.UInt16 numberOfRecords)
numberOfRecords
- the number of recordspublic net.sourceforge.juint.UInt32 getSortInfoOffset()
public void setSortInfoOffset(net.sourceforge.juint.UInt32 sortInfoOffset)
sortInfoOffset
- the offsetpublic java.lang.String getType()
public void setType(java.lang.String type)
type
- the typepublic net.sourceforge.juint.UInt32 getUniqueIdSeed()
public void setUniqueIdSeed(net.sourceforge.juint.UInt32 uniqueIdSeed)
uniqueIdSeed
- the unique id seedpublic net.sourceforge.juint.UInt16 getVersion()
public void setVersion(net.sourceforge.juint.UInt16 version)
version
- the versionpublic void deserialize(byte[] data)
DataBlock
byte
array.
deserialize
in class DataBlock
data
- the byte
arraypublic byte[] serialize()
DataBlock
byte
array of the class properties.
serialize
in class DataBlock
byte
arraypublic boolean equals(java.lang.Object object)
equals
in class DataBlock
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |