include/hiker/exgmgr2_handlers.h File Reference


Detailed Description

Public headers for exchange handlers.

#include <hiker/exgmgr2.h>

Go to the source code of this file.

Capture image or video

This verb is based on ALP_EXG2_GET_ACTIONCLASS. This service launches an application to capture a media file. The subject must be set to the type of the media you want to capture. This will typically be "image/jpeg" or some video type.

It is optionally possible to specify a filename where to store the captured file by passing a path in ALP_EXG2_AUDIO_FILEPATH_STRING_PARAM. If this parameter exists, its value is the path to store the recorded file. On output, the value is updated to be the full path to the recorded filename. This is useful when the requester just needs a reference to the file and not the actual data.

#define ALP_EXG2_AUDIO_FILEPATH_STRING_PARAM   "filePath"
 String parameter (optional) : path where to store recorded file.
#define ALP_EXG2_GET_CAPTURE_VERB   ALP_EXG2_GET_ACTIONCLASS"/capture"
 VERB: capture image or video file.

Open a URL in browser

This handler will start the browser application and open an url in browser. The subject must be set to ALP_EXG2_URLSTRING_SUBJECT.

The url string must be passed in the ALP_EXG2_GENERIC_STRING_PARAM string param.

#define ALP_EXG2_BROWSER_OPEN_URL_VERB   "Open"
 VERB: Open a URL in browser.

Displays events

This verb is based on ALP_EXG2_VIEW_ACTIONCLASS. The service can display events that are already in Calendar's database, or are in vCalendar file format.

The default behavior is to expect vCal data in a data object.

Optionally, the vCal data can be stored in a file whose name is passed in a ALP_EXGMGR_FILENAME_PARAM string parameter.

Optionally, the app can request that the displayed event be editable or not by setting a value in ALP_EXG2_EDITABLE_INT_PARAM. Default value is not editable.

#define ALP_EXG2_CALENDAR_VIEW_VERB   ALP_EXG2_VIEW_ACTIONCLASS"/calendar"
 VERB: Display an event in Calendar.

Displays contacts and vcards

This verb is based on ALP_EXG2_VIEW_ACTIONCLASS.

The default action is to display the data object as a contact information view. It will not be editable nor persistently stored.

If no input contact selection parameters then put up UI to allow user to pick.

The ALP_EXG2_CONTACTS_BECOME_PRIMARY_INT_PARAM is used to cause Contacts to relaunch itself as the primary app after returning from the exchange request.

It is also possible to select which contact you want to display:

  • ALP_EXG2_IDENTIFIER_STRING_PARAM [in] (optional) [char*] If present, and non-NULL, the string representation (unsigned) of local ID of the user whose info we want. Overrides any "fd_data".

  • ALP_EXG2_EDITABLE_INT_PARAM [in] (optional) [char*] If present, and non-zero, the user will be allowed to edit the contact. Defaults to 1 unless fd_data is given.


#define ALP_EXG2_CONTACTS_BECOME_PRIMARY_INT_PARAM   "becomePrimary"
 Int parameter (optional) : 0 = exit when finished handling request (default), 1 = relaunch as primary after handling request.
#define ALP_EXG2_CONTACTS_BECOME_PRIMARY_INT_PARAM   "becomePrimary"
 Int parameter (optional) : 0 = exit when finished handling request (default), 1 = relaunch as primary after handling request.
#define ALP_EXG2_CONTACTS_VIEW_VERB   ALP_EXG2_VIEW_ACTIONCLASS"/contacts"
 VERB: Displays contacts and vcards.

Get objects from storage : Contacts options

This describes the options available for ALP_EXG2_GET_FROMSTORAGE_VERB when you invoke it with the ALP_EXG2_CONTACTS_SUBJECT subject to use the Contacts services.

Here are all the options you can use to customize a get contact request:

  • ALP_EXG2_CONTACTS_CONTACT_TYPE_STRING_PARAM : [in,out] (optional) If present, used to limit the info returned to the desired contact type value and friendly name (returned in ALP_EXGMGR_FILENAME_PARAM.) Also restricts the picker to show only contacts that have data of this type. On output it will contain the value. Note where multiple values are present, only the first one will be returned. You can use the ALP_EXG2_PHONESTRING_SUBJECT if you want to get any phone number. Use kDistributionContactTypeMessaging (in contacts_dml.h) if you want any phone number and/or email

  • ALP_EXG2_CONTACTS_CATEGORY_OK_INT_PARAM : [in] (optional) If present, and non-zero, then the user will be allowed to select an entire category. Defaults to 0.

  • ALP_EXG2_CONTACTS_CONTACT_LUID_INT_PARAM : [out] If ALP_EXG2_CONTACTS_CONTACT_TYPE_STRING_PARAM specified, this is the Luid of the selected contact. 0 on errors or if user cancels selection.

  • ALP_EXG2_CONTACTS_FRIENDLY_NAME_STRING_PARAM : [out] If contactType specified, this is the friendly name of the selected contact.

  • ALP_EXG2_CONTACTS_CATEGORY_WAS_SELECTED_INT_PARAM : [out] If ALP_EXG2_CONTACTS_CATEGORY_OK_INT_PARAM, this will tell you if a category was selected. 0 = No, 1 = Yes.

  • ALP_EXG2_CONTACTS_CATEGORY_SELECTED_INT_PARAM : [out] If ALP_EXG2_CONTACTS_CATEGORY_OK_INT_PARAM and ALP_EXG2_CONTACTS_CATEGORY_WAS_SELECTED_INT_PARAM is 1, this will contain the category the user selected. 0 = All, -1 = Unfiled, otherwise the category ID.

  • ALP_EXG2_CONTACTS_DISTRIBUTION_OK_INT_PARAM : [in] (optional) If present, and non-zero, then the user will be allowed to select a distribution group. Defaults to ALP_EXG2_CONTACTS_DISTRIBUTION_OK_INT_PARAM. If ALP_EXG2_CONTACTS_DISTRIBUTION_OK_INT_PARAM_VALUE_ONLY then only distribution groups can be selected.

  • ALP_EXG2_CONTACTS_DISTRIBUTION_CONTACT_TYPE_STRING_PARAM : [in] (optional) If present, used to limit the info returned to the desired distribution type. See contacts_dml.h for valid values.

  • ALP_EXG2_CONTACTS_DISTRIBUTION_WAS_SELECTED_INT_PARAM : [out] If ALP_EXG2_CONTACTS_CATEGORY_OK_INT_PARAM, this will tell you if a distribution group was selected. 0 = No, 1 = Yes.

  • ALP_EXG2_CONTACTS_DISTRIBUTION_SELECTED_INT_PARAM : [out] [int] If ALP_EXG2_CONTACTS_DISTRIBUTION_OK_INT_PARAM is non-zero and ALP_EXG2_CONTACTS_DISTRIBUTION_WAS_SELECTED_INT_PARAM is 1, this will contain the the distribution ID selected.

  • ALP_EXG2_IDENTIFIER_STRING_PARAM : Used to identify specify an existing item to act on.

  • ALP_EXG2_EDITABLE_INT_PARAM : Used to specify whether a displayed data item should be editable. The parameter should be an zero or nonzero.


#define ALP_EXG2_CONTACTS_CATEGORY_OK_INT_PARAM   "categoryOK"
 Int parameter (optional) : set to non-zero to allow the user to select an entire category.
#define ALP_EXG2_CONTACTS_CATEGORY_SELECTED_INT_PARAM   "categorySelected"
 Int parameter (returned) : category the user selected (0 = All, -1 = Unfiled, otherwise the category ID).
#define ALP_EXG2_CONTACTS_CATEGORY_WAS_SELECTED_INT_PARAM   "categoryWasSelected"
 Int parameter (returned) : If ALP_EXG2_CONTACTS_CATEGORY_OK_INT_PARAM, this will tell you if a category was selected. 0 = No, 1 = Yes.
#define ALP_EXG2_CONTACTS_CONTACT_LUID_INT_PARAM   "contactLuid"
 Int parameter (returned) : this is the Luid of the selected contact. 0 on errors or user cancel.
#define ALP_EXG2_CONTACTS_CONTACT_TYPE_STRING_PARAM   "contactType"
 String parameter (optional / returned) : restrict picker to show this type of contact.
#define ALP_EXG2_CONTACTS_DISTRIBUTION_CONTACT_TYPE_STRING_PARAM   "distributionType"
 String parameter (optional) : If present, used to limit the info returned to the desired distribution type. See contacts_dml.h for valid values.
#define ALP_EXG2_CONTACTS_DISTRIBUTION_OK_INT_PARAM   "distributionOK"
 Int parameter (optional) : if non zero, allow the user to select a distribution group.
#define ALP_EXG2_CONTACTS_DISTRIBUTION_OK_INT_PARAM_VALUE_NO   0
#define ALP_EXG2_CONTACTS_DISTRIBUTION_OK_INT_PARAM_VALUE_ONLY   2
#define ALP_EXG2_CONTACTS_DISTRIBUTION_OK_INT_PARAM_VALUE_YES   1
#define ALP_EXG2_CONTACTS_DISTRIBUTION_SELECTED_INT_PARAM   "distributionSelected"
 Int parameter (returned) : If ALP_EXG2_CONTACTS_DISTRIBUTION_OK_INT_PARAM is non-zero and ALP_EXG2_CONTACTS_DISTRIBUTION_WAS_SELECTED_INT_PARAM is 1, this will contain the distribution ID selected.
#define ALP_EXG2_CONTACTS_DISTRIBUTION_WAS_SELECTED_INT_PARAM   "distributionWasSelected"
 Int parameter (returned) : If ALP_EXG2_CONTACTS_CATEGORY_OK_INT_PARAM, this will tell you if a distribution group was selected. 0 = No, 1 = Yes.
#define ALP_EXG2_CONTACTS_FRIENDLY_NAME_STRING_PARAM   "friendlyName"
 String parameter (optional) : If contactType specified, this is the friendly name of the selected contact.
#define ALP_EXG2_CONTACTS_SUBJECT   "application/vcf"
 SUBJECT: Get data from the Contacts database.
#define ALP_EXG2_EDITABLE_INT_PARAM   "editable"
 Used to specify whether a displayed data item should be editable. The parameter should be an zero or nonzero.
#define ALP_EXG2_IDENTIFIER_STRING_PARAM   "identifier"
 Used to identify specify an existing item to act on.

Store objects to storage : Contacts options

This describes the options available for ALP_EXG2_SEND_TOSTORAGE_VERB when you invoke it with one of the following subjects : "text/x-vcard", ".vcf".

The data object may contain one or several vcard data. The content of the data object will be saved into one or several new contacts. The user will be prompted before the store proceeds.

Upon successful store, a string representation (unsigned) of the local user ID of the new created contact is returned in the ALP_EXG2_IDENTIFIER_STRING_PARAM string param. This is not present on error.

The ALP_EXG2_CONTACTS_SHOW_UI_INT_PARAM int param can be used to ask for display of the Contacts information view after it was created. Use the value zero to not display any UI. Use the value one to display UI. If the parameter does not exists, it defaults to one 'showUI'. If the data contains multiple vcards, then the list View is displayed instead of the information view.

The ALP_EXG2_CONTACTS_BECOME_PRIMARY_INT_PARAM is used to cause Contacts to relaunch itself as the primary app after returning from the exchange request.

Creating/Modifying a contact using a phone number or email address:

The following subjects will be treated specially:

  • ALP_EXG2_PHONESTRING_SUBJECT : create a new contact from a phone number passed in ALP_EXG2_GENERIC_STRING_PARAM. You can define the phone type to use by passing a value in the optional ALP_EXGMGR_CONTACTS_CONTACT_TYPE_PARAM string param. The value must be one of one of kContactType ContactItem ContactType values or ALP_EXGMGR_CONTACTS_USER_PROMPT_CONTACT_TYPE.
  • ALP_EXG2_EMAILSTRING_SUBJECT : create a new contact from an email string passed in ALP_EXG2_GENERIC_STRING_PARAM
  • ALP_EXG2_CONTACTS_EMPTY_SUBJECT : put up an empty contact for editing

It is possible to modify an existing contact instead of creating a new one. You can do this by passing the userID of the existing contact you want to modify in the ALP_EXG2_IDENTIFIER_STRING_PARAM string param.

Upon successful store, a string representation (unsigned) of the local user ID of the new/modified contact is returned in the ALP_EXG2_IDENTIFIER_STRING_PARAM. Not present on error.

#define ALP_EXG2_CONTACTS_EMPTY_SUBJECT   "empty_contact"
 SUBJECT: subject to display an empty contact for editing.
#define ALP_EXG2_CONTACTS_SHOW_UI_INT_PARAM   "showUI"
 Int parameter (optional) : 0 = don't show UI, 1 = show UI (default).
#define ALP_EXGMGR_CONTACTS_CONTACT_TYPE_PARAM   "contactType"
 String parameter (optional) : one of kContactType values, or ALP_EXGMGR_CONTACTS_USER_PROMPT_CONTACT_TYPE.
#define ALP_EXGMGR_CONTACTS_USER_PROMPT_CONTACT_TYPE   "userPrompt"
 Value for ALP_EXGMGR_CONTACTS_CONTACT_TYPE_PARAM that will prompt the user to select the contact type.

Dial the emergency service

The service will dial the emergency service.

#define ALP_EXG2_DIAL_EMERGENCY_SUBJECT   "dial_emergency"
 SUBJECT: Dial the emergency service.
#define ALP_EXG2_DIAL_EMERGENCY_VERB   "dialEmergency"
 VERB: Dial the emergency service.

Dials the phone for a video call

This verb is based on ALP_EXG2_DIAL_ACTIONCLASS. The service will dial the number to establish a video call.

#define ALP_EXG2_DIAL_VIDEOCALL_VERB   ALP_EXG2_DIAL_ACTIONCLASS"/videoCall"
 VERB: Dial a video call.

Dials the phone for a voice call

This verb is based on ALP_EXG2_DIAL_ACTIONCLASS. The service will dial the number to establish a voice call.

#define ALP_EXG2_DIAL_VOICECALL_VERB   ALP_EXG2_DIAL_ACTIONCLASS"/voiceCall"
 VERB: Dial a voice call.

Dial the voicemail service

The service will dial the voicemail service.

#define ALP_EXG2_DIAL_VOICEMAIL_SUBJECT   "dial_voicemail"
 SUBJECT: Dial the voicemail service.
#define ALP_EXG2_DIAL_VOICEMAIL_VERB   "dialVoicemail"
 VERB: Dial the voicemail service.

Displays excel, powerpoint, pdf and files

This verb is based on ALP_EXG2_VIEW_ACTIONCLASS. The data object is displayed in doc viewer. The supported mimetypes are : "application/vnd.ms-excel", "application/vnd.ms-powerpoint", "application/pdf", "text/plain".

#define ALP_EXG2_DOC_VIEW_VERB   ALP_EXG2_VIEW_ACTIONCLASS"/docviewer"
 VERB: Displays doc files.

Download the content of a URL in download mgr

This handler will start the download mgr application and download the content of an url in download mgr. The subject must be set to ALP_EXG2_URLSTRING_SUBJECT.

The url string must be passed in the ALP_EXG2_GENERIC_STRING_PARAM string param.

#define ALP_EXG2_DOWNLOAD_URL_VERB   "alp_download"
 VERB: Download the content of a URL in download mgr.

View email attention item

This handler will start the email application and jump to the Inbox of the account for which the attn item was generated for The subject must be set to ALP_EXG2_EMAIL_ATTENTION_SUBJECT.

#define ALP_EXG2_EMAIL_ATTENTION_ACCOUNT_ID_INT_PARAM   "email_attention_account_id"
 PARAM: Email attention item accountId.
#define ALP_EXG2_EMAIL_ATTENTION_SERVICE_ID_INT_PARAM   "email_attention_service_id"
 PARAM: Email attention item serviceId.
#define ALP_EXG2_EMAIL_ATTENTION_SUBJECT   "email_attention_subject"
 SUBJECT: Email attention item subject.
#define ALP_EXG2_EMAIL_VIEW_ATTENTION_VERB   "email_attention_verb"
 VERB: View email attention item.

Send objects as email attachments

This verb is based on ALP_EXG2_SEND_ACTIONCLASS. The service will send all the data objects included in the request as Email attachments. You can use this service to send any kind of files (vobject, image, sound, video, etc) to other devices using one of the user's pre-configured email accounts. The objects names and mimetypes are embedded within each object added to the request.

An optional string parameter ALP_EXG2_EMAIL_MAILTO_PARAM can be included in the request. If found, the handler will parse out a mailto URL from this parameter and use it to populate the destinee field of the email.

#define ALP_EXG2_EMAIL_MAILTO_PARAM   "mailto_url"
 String parameter (optional) : email address (a string representing a text/rfc2368 address).
#define ALP_EXG2_SEND_AS_EMAIL_ATTACHMENT_VERB   ALP_EXG2_SEND_ACTIONCLASS"/asEmailAttach"
 VERB: send using Email.

Export to file

This verb is based on ALP_EXG2_EXPORT_ACTIONCLASS. This service will save the data objects to the Filesystem.

One application should register for the wildcard type ("*"). This application would receive all exported objects that have no owner, and it would be responsible to decide what to do with them.

#define ALP_EXG2_EXPORT_TOFILE_VERB   ALP_EXG2_EXPORT_ACTIONCLASS"/file"
 VERB: Export to file.

Generic string parameter used by various verbs

This parameter is used by various handlers. See exact meaning in each handler definition.

#define ALP_EXG2_GENERIC_STRING_PARAM   "stringParam"
 Generic string parameter.

Get objects from storage : General

This verb is based on ALP_EXG2_GET_ACTIONCLASS. This service will show the necessary UI to let the user select data (from a database, file system, hardware...) of the type requested by the subject.

The data is then returned as a data object.

#define ALP_EXG2_GET_FROMSTORAGE_VERB   ALP_EXG2_GET_ACTIONCLASS"/storage"
 VERB: get from storage.

Start a Chat

This handler will start the IM application. The subject must be set to ALP_EXG2_EMAILSTRING_SUBJECT.

The Chat will be started with the buddy whose email is passed in the ALP_EXG2_GENERIC_STRING_PARAM string param.

#define ALP_EXG2_IM_START_CHAT_VERB   "Chat"
 VERB: Start a Chat.

Import from a file

This verb is based on ALP_EXG2_IMPORT_ACTIONCLASS. This service will show UI to let the user select objects from a file on internal or external storage. The selected files are returned as data objects.

#define ALP_EXG2_IMPORT_FROMFILE_VERB   ALP_EXG2_IMPORT_ACTIONCLASS"/file"
 VERB: Import from file.

Displays memos, vnote and text files

This verb is based on ALP_EXG2_VIEW_ACTIONCLASS. The data object is displayed as a new memo, but it is not recorded.

#define ALP_EXG2_MEMO_VIEW_VERB   ALP_EXG2_VIEW_ACTIONCLASS"/memo"
 VERB: Displays memos, vnote and text files.

Plays common audio files

This verb is based on ALP_EXG2_VIEW_ACTIONCLASS. It registers for the supported audio types. The data objects will start to play immediately.

#define ALP_EXG2_MUSICPLAYER_VIEW_VERB   ALP_EXG2_VIEW_ACTIONCLASS"/musicplayer"
 VERB: Plays common audio files.

Launch PictureViewer in Grid view mode

This handler will launch Picture Viewer with grid view mode. No input parameters are required and no return values as well.

#define ALP_EXG2_PHOTOS_LIST_VIEW_SUBJECT   "application/img"
 SUBJECT: Go to the grid view mode of all the images.
#define ALP_EXG2_PHOTOS_LIST_VIEW_VERB   "photos_view_list"
 VERB: Go to the grid view mode of all the images.

Displays images

This verb is based on ALP_EXG2_VIEW_ACTIONCLASS. It registers for the supported image types, and also for the collection type (the mimetype is "collection/x-ply").

#define ALP_EXG2_PHOTOS_VIEW_VERB   ALP_EXG2_VIEW_ACTIONCLASS"/photos"
 VERB: Displays a particular image.

Play stream content from a URL

This handler will start the PVPlayer application and play the content from an URL. The subject must be set to ALP_EXG2_RTSPURLSTRING_SUBJECT.

The url string must be passed in the ALP_EXG2_GENERIC_STRING_PARAM string param.

#define ALP_EXG2_PLAY_STREAM_FROM_URL_VERB   "play_stream_from_url"
 VERB: Play stream content from a URL.

Launch Prefpanel/Security to accept a certificate

This handler will start the Prefpanel/Security application and display install/accept cert dialog if a browser or email app hits a server with an expired or self-signed cert.

The supported subject are: "application/x-x509-ca-cert", "application/x-x509-user-cert", "application/pkcs12", "application/x-pkcs12", "application/x-x509-email-cert", ".p12", ".pfx", ".cer", ".pem", ".crt".

This handler has the same param than verb ALP_EXG2_SECU_CERT_STORE_VERB The certificate must be contained in a file whose filename is passed in a ALP_EXG2_SECU_CERT_FILENAME_STR_PARAM string parameter or must be contained as binary data which is passed in a ALP_EXG2_SECU_CERT_DATA_BLOB_PARAM blob parameter.

The handler will return the result state in the ALP_EXG2_SECU_RESULT_INT_PARAM int parameter:

  • 0 - Reject or fail to accept/save.
  • 1 - Accept Once Successfully.
  • 2 - Accept & Save Successfully.
  • 4 - Existed (the cerificate existed).


#define ALP_EXG2_SECU_CERT_ACCEPT_VERB   "accept"
 VERB: Display Prefpanel/Security certificate accept dialog.

Launch Prefpanel/Security to install a certificate

This handler will start the Prefpanel/Security application and display install cert dialog.

The supported subject are: "application/x-x509-ca-cert", "application/x-x509-user-cert", "application/pkcs12", "application/x-pkcs12", "application/x-x509-email-cert", ".p12", ".pfx", ".cer", ".pem", ".crt".

The certificate must be contained in a file whose filename is passed in a ALP_EXG2_SECU_CERT_FILENAME_STR_PARAM string parameter or must be contained as binary data which is passed in a ALP_EXG2_SECU_CERT_DATA_BLOB_PARAM blob parameter.

The handler will return the result state in the ALP_EXG2_SECU_RESULT_INT_PARAM int parameter.

  • 0 - Cancel or fail to install.
  • 1 - installed Successfully.


#define ALP_EXG2_SECU_CERT_APPNAME_STR_PARAM   "appname"
 String send parameter : appname(which application lanuch the verb).
#define ALP_EXG2_SECU_CERT_DATA_BLOB_PARAM   "data"
 Blob send parameter : data(it is contained all certicate binary data).
#define ALP_EXG2_SECU_CERT_FILENAME_STR_PARAM   "filename"
 String send parameter : filename(certificate filename with path).
#define ALP_EXG2_SECU_CERT_RESULT_INT_PARAM   "mode"
 Mandatory send int parameter : mode(0: blocking - receive data and show install/accept dialog 1:unblocking - only receive data then return).
#define ALP_EXG2_SECU_CERT_STORE_VERB   "store"
 VERB: Display Prefpanel/Security certificate install dialog.

Verify DeviceLock state and unlock with password or enter into Emergency Call

This handler will verify if device is locked. If it is locked, it will ask the required password to the user or enter into Emergency Call.

The subject must be set to ALP_EXG2_SECU_VERIFY_SUBJECT.

The handler will return the result state in the ALP_EXG2_SECU_RESULT_INT_PARAM int parameter.

  • 0 - password verified successfully;
  • 1 - Entered into Emergency Call;
  • 2 - Cancel the verify dialog;


#define ALP_EXG2_SECU_RESULT_INT_PARAM   "result"
 returned int parameter : result
#define ALP_EXG2_SECU_VERIFY_SUBJECT   "application/x-text"
 SUBJECT: Display Prefpanel/Security subject.
#define ALP_EXG2_SECU_VERIFY_VERB   "verify"
 VERB: Display Prefpanel/Security Password verify dialog.

View Prefpanel/Security Certificates dialog

This handler will display Certificates dialog when it is launched by browser.

The subject must be set to ALP_EXG2_SECU_VERIFY_SUBJECT.

#define ALP_EXG2_SECU_VIEW_VERB   "view"
 VERB: Display Prefpanel/Security Certificate page.

Send objects using SMS or MMS

This verb is based on ALP_EXG2_SEND_ACTIONCLASS. The service will send all the data objects included in the request as SMS or MMS content or attachment. You can use this service to send any kind of files (vobject, image, sound, video, etc) to other devices. The objects names and mimetypes are embedded within each object added to the request.

The exact send method is determined by the service depending on the type of the data objects:

  • If the data is "text/plain", it will be sent as SMS content.
  • If the data is a media file (image, audio, video), it will be be sent as MMS content.
  • Any other data type will be sent as MMS attachment.


#define ALP_EXG2_SEND_BY_SMS_MMS_VERB   ALP_EXG2_SEND_ACTIONCLASS"/bySMS+"
 VERB: send using SMS or MMS.

Store objects to storage (or install applications) : General

This verb is based on ALP_EXG2_SEND_ACTIONCLASS. This service is intended to store the data objects using any application that can write them to storage. The exact action will depend on the object types. For a vObject, it will be to insert the data into the corresponding database. For a multimedia file, it will be to store the files in the media directory. For a bundle, prc or Java app, it will be to install the application.

Note that than sending data to storage is different from Exporting. When sending data to storage, the handler decides where it saves the data, whereas when exporting, it always saves to the file system.

Each application responsible to store data of some type should register a handler for this verb and a subject equal to the mimetype of the data they handle. One application should register for the wildcard type ("*"). This application would receive all objects that have no owner, and it would be responsible to decide what to do with them (ask the user, save for later or discard).

This service will typically be invoked to store files received on the device through any mean (OBEX, download, SMS, MMS, email attachments...).

#define ALP_EXG2_SEND_TOSTORAGE_VERB   ALP_EXG2_SEND_ACTIONCLASS"/storage"
 VERB: save to storage / install.

Send objects using OBEX Bluetooth

This verb is based on ALP_EXG2_SEND_ACTIONCLASS. The service will send all the data objects included in the request using Bluetooth OBEX. You can use this service to send any kind of files (vobject, image, sound, video, etc) to other devices of any kind (provided the remote device can understand the files). The objects will be sent with the name and mimetype embedded within each object added to the request.

By default, the service will automatically display a bluetooth discovery dialog to acquire the address of the destination device. However, you can add a string parameter (tag = ALP_EXG2_SEND_USINGBLUETOOTH_SPARAM_ADDR) whose value is the destination address to use (in the form xx:xx:xx:xx:xx:xx). If this parameter exists, no discovery is done and the connection to this device is immediately established.

This service is implemented by an invisible application (com.access.exchange.obexsendapp). The service registers for all subjects.

#define ALP_EXG2_SEND_USINGBLUETOOTH_SPARAM_ADDR   "btobexdestaddr"
 String parameter (optional) : Destination address (a string representing a bluetooth address).
#define ALP_EXG2_SEND_USINGBLUETOOTH_VERB   ALP_EXG2_SEND_ACTIONCLASS"/bluetooth"
 VERB: send using bluetooth OBEX.

Launch SMS/MMS to compose a message

This handler will start the SMS+ application to compose message. The subject must be set to ALP_EXG2_PHONESTRING_SUBJECT.

If the ALP_EXG2_GENERIC_STRING_PARAM string param exists and is not empty, the message destination number will be pre-filled with the value of this parameter (should be a phone number).

If the ALP_EXG2_SMS_MMS_BODYTEXT_STRING_PARAM string param exists and is not empty, the message body text will be pre-filled with this string.

If the ALP_EXG2_SMS_MMS_SERVICEID_INT_PARAM int param exists, its value tells which type of message must be composed:

  • The value ALP_POSTAL_SERVICE_ID_MMS will select to compose an MMS.
  • The value ALP_POSTAL_SERVICE_ID_SMS will select to compose an SMS (default if parameter not given).

NOTE: If ALP_EXG2_SMS_MMS_SERVICEID_INT_PARAM set as ALP_POSTAL_SERVICE_ID_SMS, ALP_EXG2_SMS_MMS_PHONENUM_STRING_PARAM exists and is not empty, the string defined by ALP_EXG2_SMS_MMS_BODYTEXT_STRING_PARAM will send as SMS directly without SMS+ compose window shown.

#define ALP_EXG2_SMS_MMS_BODYTEXT_STRING_PARAM   "smsBodyText"
 Optional string parameter : the text of sms or the text in first page of mms.
#define ALP_EXG2_SMS_MMS_COMPOSE_VERB   "compose_sms+"
 VERB: Compose SMS/MMS.
#define ALP_EXG2_SMS_MMS_SERVICEID_INT_PARAM   "smsServiceId"
 Optional int parameter : if value is ALP_POSTAL_SERVICE_ID_SMS, an SMS compose form is displayed. If the value is ALP_POSTAL_SERVICE_ID_MMS. an MMS compose form is displayed.

Display SMS/MMS using a record id

This handler will start the messaging application and display an SMS or MMS from the database. The subject must be set to ALP_EXG2_SMS_MMS_VIEWBYLUID_SUBJECT.

The record id must be passed in the ALP_EXG2_SMS_MMS_LUID_INT_PARAM int param.

#define ALP_EXG2_SMS_MMS_LUID_INT_PARAM   "smsMmsLuid"
 Mandatory int parameter : record id.
#define ALP_EXG2_SMS_MMS_VIEWBYLUID_SUBJECT   "ps_reference_sms"
 SUBJECT: Display SMS/MMS using a record id.
#define ALP_EXG2_SMS_MMS_VIEWBYLUID_VERB   "view_by_luid_SMS+"
 VERB: Display SMS/MMS using a record id.

Displays tasks, and vtodo files

This verb is based on ALP_EXG2_VIEW_ACTIONCLASS. The data object is displayed as a task.

#define ALP_EXG2_TASKS_VIEW_VERB   ALP_EXG2_VIEW_ACTIONCLASS"/tasks"
 VERB: Displays tasks, and vtodo files.

Displays videos

This verb is based on ALP_EXG2_VIEW_ACTIONCLASS. It registers for the supported video types. The data object is played.

#define ALP_EXG2_VIDEO_VIEW_VERB   ALP_EXG2_VIEW_ACTIONCLASS"/videoplayer"
 VERB: Displays images.

stop and quit the voice recorder application by the caller

Apps will generally stop recording and quit the voice recorder, eg. when the phone call ends, the phone recorder should be stopped.

#define ALP_EXG2_VOICERECORDER_STOP_VERB   "voicerecorder_stop"
 VERB: quit the voice recorder.

verbDescription

This verb is based on ALP_EXG2_XXXX_ACTIONCLASS. This service will xxxxxxxxx.

#define ALP_EXG2_XXXX_TOFILE_VERB   ALP_EXG2_XXXX_ACTIONCLASS"/xxxxxx"
 VERB: verbDescription.

Defines

#define ALP_EXG2_FILENAME_STRING_PARAM   "fileName"
 String Parameter : Complete file path to a readable DRM file.


Generated on Wed Jul 30 07:06:40 2008 by Doxygen 1.4.6 for ALP SDK + Hiker Documentation

Copyright © 1999-2008 ACCESS CO., LTD. All rights reserved.