The second part of the Palm application is the desktop connection. Because a Palm device acts as an extension of the desktop, it is crucial that information be easily exchanged. Conduits are the mechanisms for doing this (see Figure 2-1).
A conduit is code on the desktop that is called during a HotSync to manage the flow of information between databases on the handheld and the desktop. Conduits register the database or databases for which they are responsible. Note that each database should have only one conduit responsible for it. Conduits are created using the Conduit Development Kit (CDK) for Windows or Mac OS.
Applications that do not have a conduit portion use a system-provided one instead. This conduit is used for backups and is part of HotSync. This backup conduit copies the application data or database from the device and stores it as a file. You specify that you’d like a database to be backed up when you create a database. Think of this as the “If you can’t afford an attorney, one will be appointed for you at no charge” conduit—the last resort.
During a HotSync session, the backup conduit is called for databases that have been marked as needing backup. At this point, it copies each record from the database and copies database header information into a file. This file can then be used to restore the ...