词条 | PDB (Palm OS) | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
释义 |
Structure of PDB fileA PDB file contains a PDB header, PDB record headers and records.[3][4]
PDB HeaderThe PDB header is located at the beginning of the file and contains meta-information on the file:[3]
PDB Record HeaderFor every record, there is an eight byte record header, containing:[3]
PDB RecordsNow the records themselves follow. The usual order is AppInfoArea, SortInfoArea and records, sequentially.[4] PDB DatetimesMany PDB format files used times counting in seconds from 1904-01-01T00:00:00. This is the base time used by the original Macintosh (up to Mac OS 9). It may be noted that there were close links between Palm OS and Mac OS during early development. Using an unsigned 32-bit integer and the 1904 epoch, integer overflow will overflow will occur sometime in 2040. Others may be observed to be counting from 1970-01-01T00:00:00 (the Unix epoch base time), and uses a signed 32-bit integer which will overflow sometime in 2038. For either system, overflow will occur in around 30 years time. Palm OS Protein C/C++ Compiler Language & Library Reference, Copyright 2004 Palm Source calls the dates calculated from 1904 "old Palm epoch", and the dates calculated from 1970 "UNIX epoch". Protein C also provides functions (palm_seconds_to_time_t(), and time_t_to_palm_seconds() ) for converting between the two. Some sources even suggest some very old files may use times counting from 1900 (which would be consistent with the Excel epoch). This conflict between old Palm (Mac OS 9) epoch and UNIX epoch is unfortunate, the following heuristic may be useful when examining a file copied from a Palm OS device:
This is based on the idea that, otherwise the time would be before 1972 or before 1970 (depending on the interpretation) and the PDB format wasn't around then. The [https://www.fourmilab.ch/palm/palmdump/ palmdump] utility and other software uses this rule-of-thumb when reading files. See also
References1. ^N. Rhodes, J. McKeehan. Palm OS Programming, Second Edition, O'Reilly, 2001, {{ISBN|1-56592-856-3}} 2. ^MobileRead Wiki: Specification of the PalmDOC format 3. ^1 2 Paul J. Lucas (1998) PDB (Pilot Database) file format. Accessed on 20090308 4. ^1 Microfirst Software. The Pilot Record Database Format {{webarchive|url=https://web.archive.org/web/20090315213538/http://membres.lycos.fr/microfirst/palm/pdb.html |date=2009-03-15 }} Accessed on 20090308 2 : Computer file formats|Palm OS |
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
随便看 |
|
开放百科全书收录14589846条英语、德语、日语等多语种百科知识,基本涵盖了大多数领域的百科知识,是一部内容自由、开放的电子版国际百科全书。