NCS_Register

Registers your application with the cluster SDK.

Syntax

 #include <ncssdk.h> 
  
 NCS_RETURN NCS_Register (
   UINT32                    (*Callback) (NCS_MAPI, 
                                   NCS_RESOURCE *,  
                                   void * cxt), 
   UINT8                      *Name,
   NCS_EPOCH_CHANGE_CALLBACK   EpochCallback, 
   void                       *reserved1,  
   void                       *reserved2,
   NCS_HANDLE                 *ncssdkHandle);
 

Parameters

callback

(IN) Points to the resource control callback function.

Name

(IN) Points to the name of your application.

EpochCallback

(IN) Specifies the callback for node joins/leaves.

reserved1

(IN) Reserved.

reserved2

(IN) REserved.

ncssdkHandle

(OUT) Points to the NCS supplied handle.

Return Values

Name

Description

SUCCESS

NCS_SUCCESS.

NCS_ALLOC_ERROR

Insufficient memory to perform the operation.

NCS_BAD_PARAMETER

See NDS Error Codes.

NCS_NOT_SUPPORTED

Message returned when NCS_ClusterIPAddress is called in a cluster running on a platform version less than NetWare 6.

NCS_UNKNOWN

Unspecified error.

Remarks

Call this function first. If you do not use the EpochCallback, just provide a resource event callback. The handle is returned in NCS_Handle. If you do not specify resource event callback, pass in NULL.The Name parameter is used only for the epoch callback, not for the resource callback.