HP-UX Directory Server 8.1 plug-in reference

Table Of Contents
42.23 slapi_value_set_string()
Description This function sets the value of the Slapi_Value structure by duplicating the string
strVal.
Syntax
#include "slapi-plugin.h"
slapi_value_set_string(Slapi_Value *value, const char *strVal);
Parameters This function takes the following parameters:
Pointer to the Slapi_Value structure in which to set the value.value
The string containing the value to set.
strVal
Returns This function returns one of the following:
0 if value is set.
-1 if the pointer to the Slapi_Value is NULL.
Memory concerns If the pointer to the Slapi_Value is NULL, nothing is done, and the function
returns -1. If the Slapi_Value already contains a value, it is freed from memory before the new
one is set.
When you are no longer using the Slapi_Value structure, you should free it from memory by
calling “slapi_value_free()”.
See also “slapi_value_free()”
42.24 slapi_value_set_string_passin()
Description This function sets the value of Slapi_Value structure with the string strVal. If
the Slapi_Value structure already contains a value, it is freed from memory before the new
one is set. The string strVal must not be freed from memory.
Syntax
#include "slapi-plugin.h"
int slapi_value_set_string_passin ( Slapi_Value *value, char *strVal);
Parameters This function takes the following parameters:
Pointer to the Slapi_Value structure into which the value will be set.value
The string containing the value to set.
strVal
Returns This function returns one of the following values:
0 if the value is set.
-1 if the pointer to the Slapi_Value structure is NULL.
Memory concerns Use slapi_value_free() when you are finished working with the
structure to free it from memory.
42.25 slapi_value_set_value()
Description This function sets the value of the Slapi_Value structure. This value is duplicated
from the Slapi_Value structure vfrom. vfrom must not be NULL.
Syntax
#include "slapi-plugin.h"
slapi_value_set_value( Slapi_Value *value, const Slapi_Value *vfrom);
344 Functions for handling values