sntl_licensing_transfer
Library Information
>This API belongs to the Sentinel RMS licensing library.
>The corresponding header is licensing.h.
Description
Use this API for:
>Transferring a license authorization from the License Manager. Use the commute () action tag for transferring a license authorization from the License Manager.
>Generating the acknowledgment string for returning the commuter authorization code. Use returnCommuter ( ) action tag for generating the acknowledgment string.
>Synchronization between the licensed application \ License Manager and SCC. Use the sync () action for enforcing synchronization.
>Canceling an active lease to SCC so that it is available for other end users to use. Use the cancelLease () action.
>Resuming the canceled lease and request SCC for a new lease. Use the resumeLease () action.
>Marking the usage file containing usage data as completed. Use the readyUsageForUpload () action.
See Also: Implementing Cancel Lease, Resume Lease, and Force Sync (C, Java, .NET)
Syntax
SNTL_DECLARE(sntl_status_t) sntl_licensing_transfer(sntl_licensing_app_context_t *app_context,
const char *action,
const char *scope,
const sntl_licensing_attr_t *attr,
const char *recipient,
char **info);
Parameters
Parameter | Description | ||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|
app_context [in] |
Pointer to the application context object. | ||||||||||||
action [in] |
Type of transfer action as shown here. |
||||||||||||
Commute action
|
|||||||||||||
Return commuter action
|
|||||||||||||
Force synchronization action
|
|||||||||||||
Cancel Lease action
NOTE Standalone persistence must be initialized before performing the cancel and resume lease operations. |
|||||||||||||
Resume Lease action
NOTE Standalone persistence must be initialized before performing the cancel and resume lease operations. |
|||||||||||||
Ready Usage for Upload action
|
|||||||||||||
scope [in] |
Reserved for future use. Use NULL as the value for this argument. |
||||||||||||
|
The attribute object.
The attribute object contains attributes for Commute action type only:
|
||||||||||||
recipient [in] |
Recipient information of the machine for which the commuter authorization is requested. Use the recipientInfo query type of the sntl_licensing_get_info API to retrieve the recipient information of the machine for which commuter authorization is required. If this attribute is not used (or NULL is provided as the value for this parameter), the commuter code will be fetched for the local machine. NOTE This is applicable to the commute action type only. |
||||||||||||
info[out] |
Pointer to the data received such as a commuter authorization string. NOTE This is applicable to commute and return commuter action types only. |
NOTE You may instead use the macros (which are wrappers to the sntl_licensing_transfer API) for setting the transfer attributes. For example, 'sntl_licensing_attr_set_transfer_units_required' is the macro for setting the license units for transfer. You can find more macros for setting attributes in the licensing.h header file.
Returns
The status code SNTL_SUCCESS is returned, if successful. Otherwise, an error code is returned indicating the reason for failure.
For the complete list of error codes, refer to Licensing Library Error and Result Codes.