OpenChange Property Files 2.0 API Documentation

- Main Page
- Files
- Examples

- File List
- Globals

Functions
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_id | identifier of the ocpf context
  lpProps | pointer 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 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_ctx | pointer to the memory context to use for memory allocation
  context_id | identifier 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 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_id | identifier of the context to set type for
  type | pointer to the type's string to set

Returns
  MAPI_E_SUCCESS on success, otherwise MAPI/OCPF error

References 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_id | identifier of the ocpf context

Returns
  MAPI_E_SUCCESS on success, otherwise otheriwse MAPI/OCPF error

References ocpf_context_search_by_context_id().

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