Ejemplo n.º 1
0
ANSC_HANDLE
AnscOcoCreate
    (
        ANSC_HANDLE                 hContainerContext,
        ANSC_HANDLE                 hOwnerContext,
        ANSC_HANDLE                 hAnscReserved
    )
{
    ANSC_STATUS                     returnStatus = ANSC_STATUS_SUCCESS;
    PANSC_COMPONENT_OBJECT          pBaseObject  = NULL;
    PANSC_OBJECT_CONTAINER_OBJECT   pMyObject    = NULL;

    /*
     * We create object by first allocating memory for holding the variables and member functions.
     */
    pMyObject = (PANSC_OBJECT_CONTAINER_OBJECT)AnscAllocateMemory(sizeof(ANSC_OBJECT_CONTAINER_OBJECT));

    if ( !pMyObject )
    {
        return  (ANSC_HANDLE)NULL;
    }
    else
    {
        pBaseObject = (PANSC_COMPONENT_OBJECT)pMyObject;
    }

    /*
     * Initialize the common variables and functions for a container object.
     */
    /* AnscCopyString(pBaseObject->Name, ANSC_OBJECT_CONTAINER_NAME); */

    pBaseObject->hContainerContext = hContainerContext;
    pBaseObject->hOwnerContext     = hOwnerContext;
    pBaseObject->Oid               = ANSC_OBJECT_CONTAINER_OID;
    pBaseObject->Create            = AnscOcoCreate;
    pBaseObject->Remove            = AnscOcoRemove;
    pBaseObject->EnrollObjects     = AnscOcoEnrollObjects;
    pBaseObject->Initialize        = AnscOcoInitialize;

    pBaseObject->EnrollObjects((ANSC_HANDLE)pBaseObject);
    pBaseObject->Initialize   ((ANSC_HANDLE)pBaseObject);

    return  (ANSC_HANDLE)pMyObject;
}
Ejemplo n.º 2
0
ANSC_HANDLE
HttpSmpoCreate
    (
        ANSC_HANDLE                 hContainerContext,
        ANSC_HANDLE                 hOwnerContext,
        ANSC_HANDLE                 hAnscReserved
    )
{
    ANSC_STATUS                     returnStatus = ANSC_STATUS_SUCCESS;
    PANSC_COMPONENT_OBJECT          pBaseObject  = NULL;
    PHTTP_SIMPLE_MSG_PARSER         pMyObject    = NULL;

    /*
     * We create object by first allocating memory for holding the variables and member functions.
     */
    pMyObject = (PHTTP_SIMPLE_MSG_PARSER)AnscAllocateMemory(sizeof(HTTP_SIMPLE_MSG_PARSER));

    if ( !pMyObject )
    {
        return  (ANSC_HANDLE)NULL;
    }
    else
    {
        pBaseObject = (PANSC_COMPONENT_OBJECT)pMyObject;
    }

    /*
     * Initialize the common variables and functions for a component object.
     */
    AnscCopyString(pBaseObject->Name, HTTP_SMPO_COMPONENT_NAME);

    pBaseObject->hContainerContext = hContainerContext;
    pBaseObject->hOwnerContext     = hOwnerContext;
    pBaseObject->Oid               = HTTP_SMPO_COMPONENT_OID;
    pBaseObject->Create            = HttpSmpoCreate;
    pBaseObject->Remove            = HttpSmpoRemove;
    pBaseObject->EnrollObjects     = HttpSmpoEnrollObjects;
    pBaseObject->Initialize        = HttpSmpoInitialize;

    pBaseObject->EnrollObjects((ANSC_HANDLE)pBaseObject);
    pBaseObject->Initialize   ((ANSC_HANDLE)pBaseObject);

    return  (ANSC_HANDLE)pMyObject;
}
Ejemplo n.º 3
0
ANSC_HANDLE
SysIroV2Create
    (
        ANSC_HANDLE                 hContainerContext,
        ANSC_HANDLE                 hOwnerContext,
        ANSC_HANDLE                 hAnscReserved
    )
{
    ANSC_STATUS                     returnStatus = ANSC_STATUS_SUCCESS;
    PANSC_COMPONENT_OBJECT          pBaseObject  = NULL;
    PSYS_IROV2_OBJECT               pMyObject    = NULL;

    /*
     * We create object by first allocating memory for holding the variables and member functions.
     */
    pMyObject = (PSYS_IROV2_OBJECT)AnscAllocateMemory(sizeof(SYS_IROV2_OBJECT));

    if ( !pMyObject )
    {
        return  (ANSC_HANDLE)NULL;
    }
    else
    {
        pBaseObject = (PANSC_COMPONENT_OBJECT)pMyObject;
    }

    /*
     * Initialize the common variables and functions for a container object.
     */
    AnscCopyString(pBaseObject->Name, SYS_INFO_REPOSITORY_NAME);

    pBaseObject->hContainerContext = hContainerContext;
    pBaseObject->hOwnerContext     = hOwnerContext;
    pBaseObject->Oid               = SYS_INFO_REPOSITORY_OID;
    pBaseObject->Create            = SysIroV2Create;
    pBaseObject->Remove            = SysIroV2Remove;
    pBaseObject->EnrollObjects     = SysIroV2EnrollObjects;
    pBaseObject->Initialize        = SysIroV2Initialize;

    pBaseObject->EnrollObjects((ANSC_HANDLE)pBaseObject);
    pBaseObject->Initialize   ((ANSC_HANDLE)pBaseObject);

    return  (ANSC_HANDLE)pMyObject;
}
ANSC_HANDLE
TlsHsoServerCreate
(
    ANSC_HANDLE                 hContainerContext,
    ANSC_HANDLE                 hOwnerContext,
    ANSC_HANDLE                 hAnscReserved
)
{
    PANSC_COMPONENT_OBJECT          pBaseObject  = NULL;
    PTLS_HSO_SERVER_OBJECT          pMyObject    = NULL;

    /*
     * We create object by first allocating memory for holding the variables and member functions.
     */
    pMyObject = (PTLS_HSO_SERVER_OBJECT)AnscAllocateMemory(sizeof(TLS_HSO_SERVER_OBJECT));

    if ( !pMyObject )
    {
        return  (ANSC_HANDLE)NULL;
    }
    else
    {
        pBaseObject = (PANSC_COMPONENT_OBJECT)pMyObject;
    }

    /*
     * Initialize the common variables and functions for a container object.
     */
    /* AnscCopyString(pBaseObject->Name, TLS_HSO_SERVER_NAME); */

    pBaseObject->hContainerContext = hContainerContext;
    pBaseObject->hOwnerContext     = hOwnerContext;
    pBaseObject->Oid               = TLS_HSO_SERVER_OID;
    pBaseObject->Create            = TlsHsoServerCreate;
    pBaseObject->Remove            = TlsHsoServerRemove;
    pBaseObject->EnrollObjects     = TlsHsoServerEnrollObjects;
    pBaseObject->Initialize        = TlsHsoServerInitialize;

    pBaseObject->EnrollObjects((ANSC_HANDLE)pBaseObject);
    pBaseObject->Initialize   ((ANSC_HANDLE)pBaseObject);

    return  (ANSC_HANDLE)pMyObject;
}