Mobile SDK for Windows Apps2.0
Transforming Windows apps into Mobile apps
C/C++ API

These functions form the core of what is possible from C/C++ with SDK. The functions are broken up into three different listings.

Notes on the different sections in the function descriptions:

Context

Local or Remote
The API call is either considered to be run locally or remotely. Operations that only happen on the server are labelled as Local. Requests that are going to the client are marked as Remote. The further the request goes, the more likely it will be delayed by the network. Labelling the requests as local or remote only helps to know how much the call is going to "cost" in time and bandwidth usage.

Execution

Async or Sync
Sync means that the call is synchronous and will complete before returning to the caller. Async means asynchronous and the call will only start the operation and not wait for confirmation that it is complete. Typically an event will be sent to the caller when the request is done.

Foreground Required

Yes or No
Some functions can only be called when the application is in the foreground. If the application calls these foreground-based applications when it in the background, it will return an error. In some cases it is okay to disable the foreground check with CMPSetSessionOptionBool with the CMP_SESSION_OPTION_IGNORE_FOREGROUND_CHECK option set to FALSE. This makes it possible to make CMP calls marked with foreground execution in the background as well.

Include

includefile
The API needs an include file to be included in the program. For C/C++ programs this means including cmp.h.

Introduced

version
This field shows when the function was first added to the API. Currently this version field is always V1.0.

Library

libraryname
The program will need to link to the library to get access to the API. The library name will be either cpmapi.lib (32-bit) or cmpapi64.lib (64-bit) for C/C++. The library files are included with the SDK distribution.

Parameters

paramnames
For most functions there are parameters. These parameters typically include hCMP along with the optional function arguments.

Related Capability

capabilityname
If the function is related to a capability, it will have the "Related Capability" field. The capability is often required to be present on both the server and client before the function will work successfully.

Related Event

eventname
If there are any events related to this function, they are described by this field. In some cases, the event is fired based on this function being called.

Related Function

functionnames
These functions are closely related to the current function. It is useful to know all the possible operations for a given topic area. Typically these functions are for the same resource grouping.

Requires

function
Before this function can run, it needs another function to have been run before. Typically these functions initialize the environment for the current function to work. CMPInitialize, CMPOpen, and CMPOpenSession are the most common required functions.

Result Data Cached

Yes or No
If "Yes", the data from the function will be cached for the next request. This helps to reduce the amount of traffic to the client. Data is updated based on get requests and events. Set requests reset the cache for that item.

Returns

returnname
The result of the operation is mentioned with this field. The most common return value is CMPRESULT.

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Events Defines