Newton Connection Developer Information


NCX uses plugins to perform translation of desktop <-> Newton formats for its import and export functions. A plugin is a bundle containing an Objective-C executable, and an Info.plist file that describes the plugin’s capabilities. The plist names classes in the Objective-C code that conform to NCX’s import, export and item selection protocols.

For example, here is the Info.plist for the Notes plugin:

Here’s what those keys mean.

Standard Keys

These keys must be present for any plugin.

CFBundleExecutable

CFBundleIdentifier

CFBundleInfoDictionaryVersion

CFBundlePackageType

CFBundleSignature

CFBundleVersion

NCX Keys

NCApplication

This string is the user-visible name of the Newton application whose data this plugin imports or exports.

NCFileTypes

This dictionary maps file extensions to user-visible text. Each key is a file extension and its corresponding object is a short string describing that file type.
NOTE
The keys must be all lowercase.

Export Keys

These keys should only be present if the plugin performs export (Newton -> desktop) translation.

NCExportSoups

This array maps the classes of entries in a Newton soup to Objective-C classes in the plugin that perform export translation. Elements in the array are paired: the first item is a string naming the soup that is to be exported, and the second is a dictionary mapping Newton -> plugin classes; each key in the dictionary is the class of a soup entry and its corresponding object is the name of the Objective-C class in the bundle that handles its export (which must be derived from NCXTranslator).
NOTE
The keys must be all lowercase.

NCExportFormat

This string is a comma-delimited list of desktop file types (extensions) the plugin can generate. For example, the Works plugin can export text documents to RTF and drawings to TIFF. This implies that each soup entry generates a separate document on the desktop. Entering a single file type implies that the plugin rolls all soup entries into one document (like the Dates -> ICS plugin). Entering a single file type followed by a comma tells NCX that the plugin generates multiple documents but of only one type.

NCExportChooser

If the plugin allows selection of items to be exported, this string identifies the Objective-C class that performs selection. This class must be derived from NCXEntryChooser.

Import Keys

This key should only be present if the plugin performs import (desktop -> Newton) translation.

NCImportFormats

This dictionary maps desktop file extensions to code that performs translation of a file with that extension into Newton frames. Each key is a file extension and each object is a dictionary with the following key/object pairs:

soup		the name of the soup to be imported.
importer	the name of the Objective-C class that performs import
		(which must be derived from NCXTranslator).

The built-in plugins are located in the PlugIns folder of the NCX app bundle. NCX also looks for plugins in its support folders – this is where third-party plugins should be placed.

For the current user:
 ~/Library/Application Support/Newton Connection/PlugIns/
or for all users:
 /Library/Application Support/Newton Connection/PlugIns/