Chapter 11. Getting Started with Conduits

It is time to discuss conduits—what they do, how to create them, what’s involved in getting a minimal conduit working. It would also help if you understood (codewise) what happens when a Palm device is plopped into a cradle and the user pushes the HotSync button.

Note

This is useful if you want a detailed understanding of what happens when your conduit code is called, and how it interacts with the Sync Manager to perform its tasks.

We take a brief detour to discuss the types of applications that can profitably use the Backup conduit (a conduit that simply archives application data on the desktop). We also show you the code changes required to do this. Last, we create an actual conduit. As you might imagine, we build a conduit for the Sales application using Visual C++. This conduit doesn’t do much; it just writes a message to the log file. However, it’s still quite useful. You can see very easily what is involved in creating a minimal conduit and what it takes to get to the point where syncing is ready to begin.

Overview of Conduits

A conduit can be simple or complex, depending on the job it has to do. Regardless of its complexity, you create it in the same way—a conduit is a desktop plug-in made in a desktop development environment. This isn’t code that runs on the Palm handheld, but an executable library that runs during the HotSync synchronization.

What Does a Conduit Do?

A conduit is responsible for the application’s data during a synchronization ...

Get Palm Programming: The Developer's Guide now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.