ocpf_server.c File Reference

ocpf public API for server side. More...

#include "libocpf/ocpf.h"

Functions

_PUBLIC_ enum MAPISTATUS ocpf_server_add_SPropValue (uint32_t context_id, struct SPropValue *lpProps)
 
_PUBLIC_ enum MAPISTATUS ocpf_server_set_SPropValue (TALLOC_CTX *mem_ctx, uint32_t context_id)
 
enum MAPISTATUS ocpf_server_set_type (uint32_t context_id, const char *type)
 
_PUBLIC_ enum MAPISTATUS ocpf_server_sync (uint32_t context_id)
 

Detailed Description

ocpf public API for server side.

Do not perform any libmapi calls and trust incoming data. Most of these functions have equivalent in ocpf_public.c or ocpf_api.c

Function Documentation

_PUBLIC_ enum MAPISTATUS ocpf_server_add_SPropValue ( uint32_t  context_id,
struct SPropValue *  lpProps 
)

Add a SPropValue structure to the context

This functions adds a SPropValue to the ocpf context. This property must be part of the known property namespace. If the property already exists in the list, it is automatically replaced with the new one.

Parameters
context_ididentifier of the ocpf context
lpPropspointer to the SPropValue structure to add to the context
Returns
MAPI_E_SUCCESS on success, otheriwse MAPI/OCPF error
See Also
ocpf_server_add_named_SPropValue

References ctx, ocpf, and ocpf_context_search_by_context_id().

_PUBLIC_ enum MAPISTATUS ocpf_server_set_SPropValue ( TALLOC_CTX *  mem_ctx,
uint32_t  context_id 
)

Build a SPropValue array from ocpf context

This function builds a SPropValue array from the ocpf context and information stored.

Parameters
mem_ctxpointer to the memory context to use for memory allocation
context_ididentifier of the context to build a SPropValue array for
Note
This function is a server-side convenient function only. It doesn't handle named properties and its scope is much more limited than ocpf_set_SpropValue. Developers working on a client-side software/library must use ocpf_set_SPropValue instead.
Returns
MAPI_E_SUCCESS on success, otherwise MAPI/OCPF error
See Also
ocpf_get_SPropValue

References ctx, ocpf, ocpf_context_search_by_context_id(), and ocpf_server_set_type().

enum MAPISTATUS ocpf_server_set_type ( uint32_t  context_id,
const char *  type 
)

Set the message class (type) associated to an OCPF file.

Parameters
context_ididentifier of the context to set type for
typepointer to the type's string to set
Returns
MAPI_E_SUCCESS on success, otherwise MAPI/OCPF error

References ctx, ocpf, and ocpf_context_search_by_context_id().

Referenced by ocpf_server_set_SPropValue().

_PUBLIC_ enum MAPISTATUS ocpf_server_sync ( uint32_t  context_id)

Synchronize data on filesystem

Parameters
context_ididentifier of the ocpf context
Returns
MAPI_E_SUCCESS on success, otherwise otheriwse MAPI/OCPF error

References ctx, ocpf, and ocpf_context_search_by_context_id().


Creative Commons License
Creative Commons Attribution icon Creative Commons Share Alike icon
This content is licensed under the Creative Commons
Attribution ShareAlike License v. 3.0:
http://creativecommons.org/licenses/by-sa/3.0/