C H A P T E R 2 2
Using the Transport Interface
the routing slip is not closed. If
, then the
transport is changed and operations continue normally.
You can use the function
to determine the name of the
current (last-used for sending by the user) transport in a group. Note that when you
install a grouped transport, it becomes the current transport for that group.
Transports that are part of a group are individually selectable on the Send, Receive,
and Preferences pickers in the In/Out Box.
The Out Box sends the
message to your transport when data needs
to be sent. If your transport supports sending data, you must define this method to
actually send the data. For a complete description of the
see "SendRequest" (page 19-33) in Newton Programmer's Reference.
The Out Box puts its own query information in the request frame argument to
method must pass this frame to the
message to get the item (or next item) to send. In your
method, keep calling
until it returns
signalling no more items to send. For a complete description of the
method, see "ItemRequest" (page 19-26) in Newton Programmer's Reference.
slot of an item originally contained an alias, the alias is automatically
. That is, items returned by
slot that is not an alias.
Note that you can save entry aliases to items returned by
, if you
want. Later, when using them, make sure that
value, and that the item
slot is set as expected.
You can choose to comply with or ignore any request to send, depending on the
communication resources available and their status. If you choose to comply, your
method must obtain one or more items from the Out Box by using
method, and send them by whatever means the transport uses
to communicate. For example, most transports use the Endpoint interface to
establish and operate a connection.
, the item is queued in the Out Box for later sending,
but the Out Box still notifies the transport by sending it this
message so that the transport knows there are items waiting to be sent. Typically, a
transport doesn't need to take any immediate action on items where request.
, so you can use code like this to simply return:
If request.cause = 'submit then return nil;
slot contains a Boolean value indicating if the user chose to
send the item now (
) or later (