API's
[Id Management]


Functions

alp_status_t alp_hsim_allocate_referenceable_luid_for_guid (AlpHsIdMgrHandle hIdMgr, AlpGuidPtr pGuid, AlpLuidPtr pLuid)
 Allocates a new LUID for an input GUID.
alp_status_t alp_hsim_close (AlpHsIdMgrHandle)
 Close the IdMgr.
alp_status_t alp_hsim_compare_guids (AlpGuidPtr pGuid1, AlpGuidPtr pGuid2, bool *pResult)
 Returns true when the two input GUIDs are equal, and false otherwise.
alp_status_t alp_hsim_copy_guid (AlpGuidPtr pGuid, AlpGuidPtr *ppGuid)
 Makes an exact copy of an input guid.
alp_status_t alp_hsim_create_guid_from_bytes (const uint8_t *pBuf, AlpGuidPtr *pGuid)
 Creates a GUID from an input byte array.
alp_status_t alp_hsim_create_guid_from_utf8 (const uint8_t *pBuf, uint32_t size, AlpGuidPtr *pGuid)
 Creates a GUID from its system standard NULL-terminated string representation.
alp_status_t alp_hsim_create_guid_from_words (const uint32_t *pBuf, AlpGuidPtr *pGuid)
 Creates a GUID from an input word array.
alp_status_t alp_hsim_extend_guid (AlpGuidPtr pGuid, AlpGuidPtr pExtensionGuid)
 Extends the tail of an existing GUID.
alp_status_t alp_hsim_free_guidptr (AlpGuidPtr pGuid)
 Free the input GUID.
alp_status_t alp_hsim_get_conflicted_luids (AlpHsIdMgrHandle hIdMgr, uint32_t *pCount, AlpLuidPtr pLuidArray)
 Get the referenceable ids for conflicted objects in a datastore. Enumerate ids for conflicted objects.
alp_status_t alp_hsim_get_extended_luids (AlpHsIdMgrHandle hIdMgr, AlpLuid luid, uint32_t *pCount, AlpLuidPtr pLuidArray)
 Returns an array of referenceable LUIDs for the GUIDs in an extended GUID identified by its LUID.
alp_status_t alp_hsim_get_guid_bytes (AlpGuidPtr pGuid, uint8_t *pBuf)
 Get the zero based nth byte from a 128 bit GUID.
alp_status_t alp_hsim_get_guid_extension (AlpGuidPtr pGuid, AlpGuidPtr *pExtensionGuid)
 Get the tail of an extended GUID.
alp_status_t alp_hsim_get_guid_extension_depth (AlpGuidPtr pGuid, uint32_t *pDepth)
 Returns the zero-based depth of the input GUID.
alp_status_t alp_hsim_get_guid_utf8 (AlpGuidPtr pGuid, uint8_t *pBuf, uint32_t *size)
 Gets the NULL-terminated system standard string representation of a GUID.
alp_status_t alp_hsim_get_guid_word (AlpGuidPtr pGuid, unsigned int wordNum, uint32_t *pWord)
 Get the zero based nth word from a 128 bit GUID.
alp_status_t alp_hsim_get_luids_for_guid (AlpHsIdMgrHandle hIdMgr, AlpGuidPtr pGuid, uint32_t *pCount, AlpLuidPtr pLuidArray)
 Get the LUIDs associated with an input GUID.
alp_status_t alp_hsim_get_luids_for_luid (AlpHsIdMgrHandle hIdMgr, AlpLuid luid, uint32_t *pCount, AlpLuidPtr pLuidArray)
 Gets the LUIDs associated with an input LUID.
alp_status_t alp_hsim_get_referenceable_guid_for_luid (AlpHsIdMgrHandle hIdMgr, AlpLuid luid, AlpGuidPtr *ppGuid)
 Gets the GUID associated with a LUID.
alp_status_t alp_hsim_get_referenceable_luid_for_guid (AlpHsIdMgrHandle hIdMgr, AlpGuidPtr pGuid, AlpLuidPtr pLuid)
 Gets the referenceable LUID associated with a GUID.
alp_status_t alp_hsim_get_referenceable_luid_for_luid (AlpHsIdMgrHandle hIdMgr, AlpLuid luid, AlpLuidPtr pLuid)
 Gets the referenceable LUID associated with a LUID.
alp_status_t alp_hsim_int_compare_guids (AlpGuidPtr pGuid1, AlpGuidPtr pGuid2, int *pResult)
 Return 0 when the two input GUIDs are equal, -1 if the first GUID is less than the second and 1 otherwise.
alp_status_t alp_hsim_open (AlpHsIdMgrHandle *hIdMgr, _TCHAR *node, _TCHAR *locURI, uint32_t userId)
 Open the IdMgr for a specified datastore.


Function Documentation

alp_status_t alp_hsim_allocate_referenceable_luid_for_guid AlpHsIdMgrHandle  hIdMgr,
AlpGuidPtr  pGuid,
AlpLuidPtr  pLuid
 

Allocates a new LUID for an input GUID.

Parameters:
[in] hIdMgr Handle to an open IdMgr
[in] pGuid The object GUId
[out] pLuid The object's new LUID
Returns:
If successful returns ALP_STATUS_HOTSYNC_OK; otherwise returns an error.
Remarks:
Application developers should use the ChangeMgr to allocate ids for objects rather than calling this function.
See also:
alp_hscm_begin_modify().

alp_status_t alp_hsim_close AlpHsIdMgrHandle   ) 
 

Close the IdMgr.

Parameters:
[in] hIdMgr Handle to an open IdMgr
Returns:
If successful returns ALP_STATUS_HOTSYNC_OK; otherwise returns an error.
See also:
alp_hsim_open().

alp_status_t alp_hsim_compare_guids AlpGuidPtr  pGuid1,
AlpGuidPtr  pGuid2,
bool *  pResult
 

Returns true when the two input GUIDs are equal, and false otherwise.

Parameters:
[in] pGuid1 The first GUID
[in] pGuid2 The second GUID
[in] pResult The comparison result
Returns:
If successful returns ALP_STATUS_HOTSYNC_OK; otherwise returns an error.
See also:
alp_hsim_int_compare_guids().

alp_status_t alp_hsim_copy_guid AlpGuidPtr  pGuid,
AlpGuidPtr ppGuid
 

Makes an exact copy of an input guid.

Parameters:
[in] hIdMgr Handle to an open IdMgr
[in] pGuid The input GUId
[out] ppGuid Copy of the input GUID
Returns:
If successful returns ALP_STATUS_HOTSYNC_OK; otherwise returns an error.

alp_status_t alp_hsim_create_guid_from_bytes const uint8_t *  pBuf,
AlpGuidPtr pGuid
 

Creates a GUID from an input byte array.

This function creates a 128 bit globally unique id from an input array of 16 bytes.

Parameters:
[in] pBuf An array of 16 bytes.
[out] pGuid A globally unique id consisting of the 16 bytes from pBuf.
Returns:
If successful returns ALP_STATUS_HOTSYNC_OK; otherwise returns an error.
Remarks:
The caller is responsible for freeing the output GUID by passing it to alp_hsim_free_guidptr().

alp_status_t alp_hsim_create_guid_from_utf8 const uint8_t *  pBuf,
uint32_t  size,
AlpGuidPtr pGuid
 

Creates a GUID from its system standard NULL-terminated string representation.

Parameters:
[in] pBuf Buffer containing the GUID's standard string representation
[in] size Size of *pBuf
[out] pGuid The output GUID
Returns:
If successful returns ALP_STATUS_HOTSYNC_OK; otherwise returns an error.
Remarks:
The caller is responsible for freeing the output GUID by passing it to alp_hsim_free_guidptr().
See also:
alp_hsim_get_guid_utf8().

alp_status_t alp_hsim_create_guid_from_words const uint32_t *  pBuf,
AlpGuidPtr pGuid
 

Creates a GUID from an input word array.

This function creates a 128 bit globally unique id from an input array of 4 32 bit integers.

Parameters:
[in] pBuf An array of 4 32 bit integers.
[out] pGuid A globally unique id consisting of the 16 bytes from pBuf[0][0] through pBuf[3][3].
Returns:
If successful returns ALP_STATUS_HOTSYNC_OK; otherwise returns an error.
Remarks:
The caller is responsible for freeing the output GUID by passing it to alp_hsim_free_guidptr().

alp_status_t alp_hsim_extend_guid AlpGuidPtr  pGuid,
AlpGuidPtr  pExtensionGuid
 

Extends the tail of an existing GUID.

This function extends the tail of an existing GUID. For example, when pGUID is composed of two non-extended GUIDs, (pGUID1, pGUID2), it will be composed of (pGUID1, pGUID2, pExtensionGuid) after calling this function.

This function may be called repeatedly to arbitrarily extend a GUID.

Parameters:
[in,out] pGuid The GUID to be extended.
[in] pExtensionGuid The 128 bit GUID extension.
Returns:
If successful returns ALP_STATUS_HOTSYNC_OK; otherwise returns an error.
See also:
alp_hsim_get_guid_extension(), alp_hsim_get_extended_luids().

alp_status_t alp_hsim_free_guidptr AlpGuidPtr  pGuid  ) 
 

Free the input GUID.

Parameters:
[in] pGuid The GUId to free
Returns:
If successful returns ALP_STATUS_HOTSYNC_OK; otherwise returns an error.

alp_status_t alp_hsim_get_conflicted_luids AlpHsIdMgrHandle  hIdMgr,
uint32_t *  pCount,
AlpLuidPtr  pLuidArray
 

Get the referenceable ids for conflicted objects in a datastore. Enumerate ids for conflicted objects.

alp_status_t alp_hsim_get_extended_luids AlpHsIdMgrHandle  hIdMgr,
AlpLuid  luid,
uint32_t *  pCount,
AlpLuidPtr  pLuidArray
 

Returns an array of referenceable LUIDs for the GUIDs in an extended GUID identified by its LUID.

Parameters:
[in] hIdMgr Handle to an open IdMgr
[in] luid LUID for the extended GUID
[in,out] pCount On input, the size of pLuidArray; on output, the number of ids written to pLuidArray
[in,out] pLuidArray An array of LUIDs
Returns:
If successful returns ALP_STATUS_HOTSYNC_OK; otherwise returns an error.
Remarks:
The caller is responsible for allocating pLuidArray. The correct size can be found by calling this function with pLuidArray equal to zero.
See also:
alp_hsim_extend_guid().

alp_status_t alp_hsim_get_guid_bytes AlpGuidPtr  pGuid,
uint8_t *  pBuf
 

Get the zero based nth byte from a 128 bit GUID.

Parameters:
[in] pGuid A 128 bit global id.
[out] pBuf An 8 bit integer corresponding to the nth byte in pGuid.
Returns:
If successful returns ALP_STATUS_HOTSYNC_OK; otherwise returns an error.
See also:
alp_hsim_create_guid_from_bytes().

alp_status_t alp_hsim_get_guid_extension AlpGuidPtr  pGuid,
AlpGuidPtr pExtensionGuid
 

Get the tail of an extended GUID.

This function returns the tail of an extended GUID. For example, when the input extended GUID consists of 3 GUIDs, this function returns the extended GUID consisting of the last 2 GUIDs of the input GUID.

Parameters:
[in] hIdMgr Handle to an open IdMgr
Returns:
If successful returns ALP_STATUS_HOTSYNC_OK; otherwise returns an error.

alp_status_t alp_hsim_get_guid_extension_depth AlpGuidPtr  pGuid,
uint32_t *  pDepth
 

Returns the zero-based depth of the input GUID.

Parameters:
[in] pGuid The input GUId
[out] pDepth The GUID's extension depth
Returns:
If successful returns ALP_STATUS_HOTSYNC_OK; otherwise returns an error.

alp_status_t alp_hsim_get_guid_utf8 AlpGuidPtr  pGuid,
uint8_t *  pBuf,
uint32_t *  size
 

Gets the NULL-terminated system standard string representation of a GUID.

Parameters:
[in] pGuid The input GUID
[in,out] pBuf Buffer to hold the GUID's standard string representation
[in,out] size On input, the size of *pBuf; on output, the number of bytes written to *pBuf
Remarks:
The caller is responsible for allocating pBuf. The correct size can be found by calling this function with pBuf equal to zero.
Returns:
If successful returns ALP_STATUS_HOTSYNC_OK; otherwise returns an error.
See also:
alp_hsim_create_guid_from_utf8().

alp_status_t alp_hsim_get_guid_word AlpGuidPtr  pGuid,
unsigned int  wordNum,
uint32_t *  pWord
 

Get the zero based nth word from a 128 bit GUID.

Parameters:
[in] pGuid A 128 bit global id.
[in] wordNum An integer from 0 to 3.
[out] pWord The 32 bit integer corresponding to the nth word in pGuid.
Returns:
If successful returns ALP_STATUS_HOTSYNC_OK; otherwise returns an error.
See also:
alp_hsim_create_guid_from_words().

alp_status_t alp_hsim_get_luids_for_guid AlpHsIdMgrHandle  hIdMgr,
AlpGuidPtr  pGuid,
uint32_t *  pCount,
AlpLuidPtr  pLuidArray
 

Get the LUIDs associated with an input GUID.

This function returns the set of local ids associated with an input global id. When more than one id is returned, the relevant object has multiple conflicting content versions.

Parameters:
[in] hIdMgr Handle to an open IdMgr
[in] pGuid The object GUID
[in,out] pCount On input, the size of pLuidArray; on output, the number of ids written to pLuidArray
[in,out] pLuidArray An array of LUIDs
Returns:
If successful returns ALP_STATUS_HOTSYNC_OK; otherwise returns an error.
Remarks:
When pCount > 0 and pLuidArray is not null, pLuidArray[0] is the object's referenceable LUID.

The caller is responsible for allocating pLuidArray. The correct size can be found by calling this function with pLuidArray equal to zero.

alp_status_t alp_hsim_get_luids_for_luid AlpHsIdMgrHandle  hIdMgr,
AlpLuid  luid,
uint32_t *  pCount,
AlpLuidPtr  pLuidArray
 

Gets the LUIDs associated with an input LUID.

This function returns the set of local ids associated with an input local id. When more than one id is returned, the relevant object has multiple conflicting content versions.

Parameters:
[in] hIdMgr Handle to an open IdMgr
[in] luid The object LUID
[in,out] pCount On input, the size of pLuidArray; on output, the number of ids written to pLuidArray
[in,out] pLuidArray An array of LUIDs
Returns:
If successful returns ALP_STATUS_HOTSYNC_OK; otherwise returns an error.
Remarks:
When pCount > 0 and pLuidArray is not null, pLuidArray[0] is the object's referenceable LUID.

The caller is responsible for allocating pLuidArray. The correct size can be found by calling this function with pLuidArray equal to zero.

This function is equivalent to calling alp_hsim_get_referenceable_guid_for_luid() followed by alp_hsim_get_luids_for_guid().

alp_status_t alp_hsim_get_referenceable_guid_for_luid AlpHsIdMgrHandle  hIdMgr,
AlpLuid  luid,
AlpGuidPtr ppGuid
 

Gets the GUID associated with a LUID.

Parameters:
[in] hIdMgr Handle to an open IdMgr
[in] luid The object LUID
[out] ppGuid The return value
Returns:
If successful returns ALP_STATUS_HOTSYNC_OK; otherwise returns an error.
Remarks:
The caller is responsible for free-ing the output GUID by passing it to alp_hsim_free_guidptr().

alp_status_t alp_hsim_get_referenceable_luid_for_guid AlpHsIdMgrHandle  hIdMgr,
AlpGuidPtr  pGuid,
AlpLuidPtr  pLuid
 

Gets the referenceable LUID associated with a GUID.

Parameters:
[in] hIdMgr Handle to an open IdMgr
[in] pGuid The object's GUID
[out] pLuid The object's LUID
Returns:
If successful returns ALP_STATUS_HOTSYNC_OK; otherwise returns an error.

alp_status_t alp_hsim_get_referenceable_luid_for_luid AlpHsIdMgrHandle  hIdMgr,
AlpLuid  luid,
AlpLuidPtr  pLuid
 

Gets the referenceable LUID associated with a LUID.

Parameters:
[in] hIdMgr Handle to an open IdMgr
[in] luid The object's LUID
[out] pLuid The object's referenceable LUID
Returns:
If successful returns ALP_STATUS_HOTSYNC_OK; otherwise returns an error.
Remarks:
If *pLuid != luid after the call, the object has multiple conflicting content versions.
See also:
(OPTIONAL)

alp_status_t alp_hsim_int_compare_guids AlpGuidPtr  pGuid1,
AlpGuidPtr  pGuid2,
int *  pResult
 

Return 0 when the two input GUIDs are equal, -1 if the first GUID is less than the second and 1 otherwise.

The two input GUIDs are compared bytewise to determine their relation. When one or both GUIDs are extended, their component GUIDs are compared bytewise. If the first GUID is equal to a leading non-empty sub-sequence of the second, the first is said to be less than the second and the function returns -1.

Parameters:
[in] pGuid1 The first GUID
[in] pGuid2 The second GUID
[out] pResult The comparison result.
Returns:
If successful returns ALP_STATUS_HOTSYNC_OK; otherwise returns an error.
See also:
alp_hsim_compare_guids().

alp_status_t alp_hsim_open AlpHsIdMgrHandle hIdMgr,
_TCHAR *  node,
_TCHAR *  locURI,
uint32_t  userId
 

Open the IdMgr for a specified datastore.

Parameters:
[out] hIdMgr Handle to the IdMgr.
[in] node Desktop only. On ALP, this parameter must be set to ALP_HS_DEFAULT_NODE_NAME.
[in] locURI The datastore's locURI.
[out] userId Desktop only. For ALP this should be set to zero.
Returns:
If successful returns ALP_STATUS_HOTSYNC_OK; otherwise returns an error.
See also:
alp_hsim_close().


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

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