Sun Java System Directory Server Enterprise Edition 6.2 Developer's Guide

slapi_add_entry_internal_set_pb()

Prepares a parameter block for an internal add operation involving a Slapi_Entry structure.

Syntax

#include "slapi-plugin.h"
int slapi_add_entry_internal_set_pb(Slapi_PBlock *pb,
    Slapi_Entry *e, LDAPControl **controls,
    Slapi_ComponentId *plugin_identity, int operation_flags);

Parameters

This function takes the following parameters:

pb

Parameter block for the internal add operation

e

Entry to add

controls

Array of controls to request for the add operation; NULL if no controls

plugin_identity

Plug-in identifier obtained from SLAPI_PLUGIN_IDENTITY during plug-in initialization

operation_flags

NULL or SLAPI_OP_FLAG_NEVER_CHAIN

Returns

This function returns 0 if successful. Otherwise it returns an LDAP error code.

Description

This function prepares a parameter block for use with slapi_add_internal_pb() using the entry.

Memory Concerns

Allocate the parameter block using slapi_pblock_new() before calling this function.

The entry is consumed during the call to slapi_add_internal_pb() . The LDAPControls are not consumed.

Free the parameter block after calling slapi_add_internal_pb() .

See Also

slapi_add_internal_pb()

slapi_add_internal_set_pb()

slapi_pblock_new()