#include <stdio.h>
#include <stdlib.h>
#include <stdint.h>
#include <stdbool.h>
#include <unistd.h>
#include <fcntl.h>
#include <errno.h>
#include <string.h>
#include <stdarg.h>
#include <netdb.h>
#include <netinet/in.h>
#include <arpa/inet.h>
#include <net/if.h>
#include <talloc.h>
#include <dcerpc.h>
#include <util/debug.h>
#include <param.h>
#include <dlinklist.h>
#include <gen_ndr/exchange.h>
#include <gen_ndr/property.h>
#include "libmapi/version.h"
#include "libmapi/nspi.h"
#include "libmapi/emsmdb.h"
#include "libmapi/mapi_context.h"
#include "libmapi/mapi_provider.h"
#include "libmapi/mapi_object.h"
#include "libmapi/mapi_id_array.h"
#include "libmapi/mapi_notification.h"
#include "libmapi/mapi_profile.h"
#include "libmapi/mapidefs.h"
#include "libmapi/mapicode.h"
#include "libmapi/socket/netif.h"
#include "libmapi/idset.h"
#include "libmapi/property_tags.h"
#include "libmapi/property_altnames.h"
Macros | |
#define | __BEGIN_DECLS |
#define | __END_DECLS |
#define | _GNU_SOURCE 1 |
#define | _PRINTF_ATTRIBUTE(a1, a2) PRINTF_ATTRIBUTE(a1, a2) |
#define | _PRINTF_ATTRIBUTE(a1, a2) |
#define | SIZE_DFLT_APPOINTMENTRECURRENCEPATTERN 26 |
#define | SIZE_DFLT_EXCEPTIONINFO 22 |
#define | SIZE_DFLT_EXTENDEDEXCEPTION 0 |
#define | SIZE_DFLT_RECURRENCEPATTERN 50 |
Typedefs | |
typedef enum MAPISTATUS(* | fxparser_delprop_callback_t )(uint32_t, void *) |
typedef enum MAPISTATUS(* | fxparser_marker_callback_t )(uint32_t, void *) |
typedef enum MAPISTATUS(* | fxparser_namedprop_callback_t )(uint32_t, struct MAPINAMEID, void *) |
typedef enum MAPISTATUS(* | fxparser_property_callback_t )(struct SPropValue, void *) |
Functions | |
enum MAPISTATUS | Abort (mapi_object_t *, uint8_t *) |
enum MAPISTATUS | AbortSubmit (mapi_object_t *, mapi_object_t *, mapi_object_t *) |
struct mapi_SPropValue * | add_mapi_SPropValue (TALLOC_CTX *, struct mapi_SPropValue *, uint16_t *, uint32_t, const void *) |
struct SPropValue * | add_SPropValue (TALLOC_CTX *, struct SPropValue *, uint32_t *, enum MAPITAGS, const void *) |
enum MAPISTATUS | AddressTypes (mapi_object_t *, uint16_t *, struct mapi_LPSTR **) |
enum MAPISTATUS | AddUserPermission (mapi_object_t *, const char *, enum ACLRIGHTS) |
uint32_t | calculateCRC (uint8_t *, uint32_t, uint32_t) |
uint32_t | cast_mapi_SPropValue (TALLOC_CTX *, struct mapi_SPropValue *, struct SPropValue *) |
void | cast_PropertyRow_to_SRow (TALLOC_CTX *, struct PropertyRow_r *, struct SRow *) |
void | cast_PropertyRowSet_to_SRowSet (TALLOC_CTX *, struct PropertyRowSet_r *, struct SRowSet *) |
void | cast_PropertyValue_to_SPropValue (struct PropertyValue_r *, struct SPropValue *) |
uint32_t | cast_SPropValue (TALLOC_CTX *, struct mapi_SPropValue *, struct SPropValue *) |
enum MAPISTATUS | ChangeProfilePassword (struct mapi_context *, const char *, const char *, const char *) |
enum MAPISTATUS | CloneStream (mapi_object_t *, mapi_object_t *) |
enum MAPISTATUS | CollapseRow (mapi_object_t *, uint64_t, uint32_t *) |
enum MAPISTATUS | CommitStream (mapi_object_t *) |
enum MAPISTATUS | compress_rtf (TALLOC_CTX *, const char *, const size_t, uint8_t **, size_t *) |
enum MAPISTATUS | CopyFolder (mapi_object_t *, mapi_object_t *, mapi_object_t *, char *, bool, bool) |
enum MAPISTATUS | CopyProfile (struct mapi_context *, const char *, const char *) |
enum MAPISTATUS | CopyProps (mapi_object_t *, mapi_object_t *, struct SPropTagArray *, uint8_t, uint16_t *, struct PropertyProblem **) |
enum MAPISTATUS | CopyTo (mapi_object_t *, mapi_object_t *, struct SPropTagArray *, uint8_t, uint16_t *, struct PropertyProblem **) |
enum MAPISTATUS | CopyToStream (mapi_object_t *, mapi_object_t *, uint64_t, uint64_t *, uint64_t *) |
enum MAPISTATUS | CreateAttach (mapi_object_t *, mapi_object_t *) |
enum MAPISTATUS | CreateBookmark (mapi_object_t *, uint32_t *) |
enum MAPISTATUS | CreateFolder (mapi_object_t *, enum FOLDER_TYPE, const char *, const char *, uint32_t, mapi_object_t *) |
enum MAPISTATUS | CreateMessage (mapi_object_t *, mapi_object_t *) |
enum MAPISTATUS | CreateProfile (struct mapi_context *, const char *, const char *, const char *, uint32_t) |
enum MAPISTATUS | CreateProfileStore (const char *, const char *) |
enum MAPISTATUS | DeleteAttach (mapi_object_t *, uint32_t) |
enum MAPISTATUS | DeleteFolder (mapi_object_t *, mapi_id_t, uint8_t, bool *) |
enum MAPISTATUS | DeleteMessage (mapi_object_t *, mapi_id_t *, uint32_t) |
enum MAPISTATUS | DeleteProfile (struct mapi_context *, const char *) |
enum MAPISTATUS | DeletePropertiesNoReplicate (mapi_object_t *, struct SPropTagArray *) |
enum MAPISTATUS | DeleteProps (mapi_object_t *, struct SPropTagArray *) |
enum MAPISTATUS | DispatchNotifications (struct mapi_session *) |
enum MAPISTATUS | DuplicateProfile (struct mapi_context *, const char *, const char *, const char *) |
enum MAPISTATUS | EmptyFolder (mapi_object_t *) |
struct emsmdb_info * | emsmdb_get_info (struct mapi_session *) |
void | emsmdb_get_SRowSet (TALLOC_CTX *, struct SRowSet *, struct SPropTagArray *, DATA_BLOB *) |
NTSTATUS | emsmdb_transaction (struct emsmdb_context *, TALLOC_CTX *, struct mapi_request *, struct mapi_response **) |
NTSTATUS | emsmdb_transaction_ext2 (struct emsmdb_context *, TALLOC_CTX *, struct mapi_request *, struct mapi_response **) |
NTSTATUS | emsmdb_transaction_null (struct emsmdb_context *, struct mapi_response **) |
NTSTATUS | emsmdb_transaction_wrapper (struct mapi_session *, TALLOC_CTX *, struct mapi_request *, struct mapi_response **) |
enum MAPISTATUS | EntryIDFromSourceIDForMessage (TALLOC_CTX *, mapi_object_t *, mapi_object_t *, mapi_object_t *, struct SBinary_short *) |
uint64_t | exchange_globcnt (uint64_t) |
enum MAPISTATUS | ExpandRow (mapi_object_t *, uint64_t, uint16_t, struct SRowSet *, uint32_t *) |
const void * | find_mapi_SPropValue_data (struct mapi_SPropValue_array *, uint32_t) |
const void * | find_PropertyValue_data (struct PropertyRow_r *, uint32_t) |
const void * | find_SPropValue_data (struct SRow *, uint32_t) |
enum MAPISTATUS | FindProfileAttr (struct mapi_profile *, const char *, const char *) |
enum MAPISTATUS | FindRow (mapi_object_t *, struct mapi_SRestriction *, enum BOOKMARK, enum FindRow_ulFlags, struct SRowSet *) |
enum MAPISTATUS | FreeBookmark (mapi_object_t *, uint32_t) |
enum MAPISTATUS | FXCopyFolder (mapi_object_t *, uint8_t, uint8_t, mapi_object_t *) |
enum MAPISTATUS | FXCopyMessages (mapi_object_t *, mapi_id_array_t *, uint8_t, uint8_t, mapi_object_t *) |
enum MAPISTATUS | FXCopyProperties (mapi_object_t *, uint8_t, uint32_t, uint8_t, struct SPropTagArray *, mapi_object_t *) |
enum MAPISTATUS | FXCopyTo (mapi_object_t *, uint8_t, uint32_t, uint8_t, struct SPropTagArray *, mapi_object_t *) |
enum MAPISTATUS | FXDestConfigure (mapi_object_t *, enum FastTransferDestConfig_SourceOperation, mapi_object_t *) |
enum MAPISTATUS | FXGetBuffer (mapi_object_t *obj_source_context, uint16_t maxSize, enum TransferStatus *, uint16_t *, uint16_t *, DATA_BLOB *) |
Get data from source fast transfer object. More... | |
struct fx_parser_context * | fxparser_init (TALLOC_CTX *, void *) |
enum MAPISTATUS | fxparser_parse (struct fx_parser_context *, DATA_BLOB *) |
void | fxparser_set_delprop_callback (struct fx_parser_context *, fxparser_delprop_callback_t) |
void | fxparser_set_marker_callback (struct fx_parser_context *, fxparser_marker_callback_t) |
void | fxparser_set_namedprop_callback (struct fx_parser_context *, fxparser_namedprop_callback_t) |
void | fxparser_set_property_callback (struct fx_parser_context *, fxparser_property_callback_t) |
enum MAPISTATUS | FXPutBuffer (mapi_object_t *obj_dest_context, DATA_BLOB *blob, uint16_t *usedSize) |
Send data to a destination fast transfer object. More... | |
struct Binary_r * | generate_recipient_entryid (TALLOC_CTX *, const char *) |
struct AddressBookEntryId * | get_AddressBookEntryId (TALLOC_CTX *, struct Binary_r *) |
struct AppointmentRecurrencePattern * | get_AppointmentRecurrencePattern (TALLOC_CTX *mem_ctx, struct Binary_r *) |
struct FolderEntryId * | get_FolderEntryId (TALLOC_CTX *, struct Binary_r *) |
struct GlobalObjectId * | get_GlobalObjectId (TALLOC_CTX *, struct Binary_r *) |
const char * | get_importance (uint32_t) |
int | get_interfaces_oc (struct iface_struct *, int) |
uint32_t | get_mapi_property_size (struct mapi_SPropValue *) |
enum MAPISTATUS | get_mapi_SPropValue_array_date_timeval (struct timeval *, struct mapi_SPropValue_array *, uint32_t) |
const void * | get_mapi_SPropValue_data (struct mapi_SPropValue *) |
enum MAPISTATUS | get_mapi_SPropValue_date_timeval (struct timeval *t, struct SPropValue) |
struct MessageEntryId * | get_MessageEntryId (TALLOC_CTX *, struct Binary_r *) |
const char * | get_namedid_name (uint32_t proptag) |
uint16_t | get_namedid_type (uint16_t untypedtag) |
uint32_t | get_namedid_value (const char *propname) |
uint16_t | get_property_type (uint16_t untypedtag) |
const void * | get_PropertyValue (struct PropertyValue_r *, enum MAPITAGS) |
const void * | get_PropertyValue_data (struct PropertyValue_r *) |
struct PropertyValue_r * | get_PropertyValue_PropertyRow (struct PropertyRow_r *, enum MAPITAGS) |
struct PropertyValue_r * | get_PropertyValue_PropertyRowSet (struct PropertyRowSet_r *, enum MAPITAGS) |
const void * | get_PropertyValue_PropertyRowSet_data (struct PropertyRowSet_r *, uint32_t) |
const char * | get_proptag_name (uint32_t) |
uint32_t | get_proptag_value (const char *) |
struct PtypServerId * | get_PtypServerId (TALLOC_CTX *, struct Binary_r *) |
struct RecurrencePattern * | get_RecurrencePattern (TALLOC_CTX *, struct Binary_r *) |
const void * | get_SPropValue (struct SPropValue *, enum MAPITAGS) |
const void * | get_SPropValue_data (struct SPropValue *) |
struct SPropValue * | get_SPropValue_SRow (struct SRow *, uint32_t) |
const void * | get_SPropValue_SRow_data (struct SRow *, uint32_t) |
struct SPropValue * | get_SPropValue_SRowSet (struct SRowSet *, uint32_t) |
const void * | get_SPropValue_SRowSet_data (struct SRowSet *, uint32_t) |
const char * | get_task_status (uint32_t) |
struct TimeZoneStruct * | get_TimeZoneStruct (TALLOC_CTX *, struct Binary_r *) |
const char * | get_TypedString (struct TypedString *) |
enum MAPISTATUS | GetABRecipientInfo (struct mapi_session *, const char *, struct SPropTagArray *, struct PropertyRowSet_r **) |
enum MAPISTATUS | GetAttachmentTable (mapi_object_t *, mapi_object_t *) |
enum MAPISTATUS | GetBestBody (mapi_object_t *, uint8_t *) |
enum MAPISTATUS | GetCollapseState (mapi_object_t *, uint64_t, uint32_t, struct SBinary_short *) |
enum MAPISTATUS | GetContentsTable (mapi_object_t *, mapi_object_t *, uint8_t, uint32_t *) |
enum MAPISTATUS | GetDefaultFolder (mapi_object_t *, uint64_t *, const uint32_t) |
enum MAPISTATUS | GetDefaultProfile (struct mapi_context *, char **) |
enum MAPISTATUS | GetDefaultPublicFolder (mapi_object_t *, uint64_t *, const uint32_t) |
enum MAPISTATUS | GetFIDFromEntryID (uint16_t, uint8_t *, uint64_t, uint64_t *) |
enum MAPISTATUS | GetFolderItemsCount (mapi_object_t *, uint32_t *, uint32_t *) |
int | GetFreeBusyYear (const uint32_t *) |
enum MAPISTATUS | GetGALTable (struct mapi_session *, struct SPropTagArray *, struct PropertyRowSet_r **, uint32_t, uint8_t) |
enum MAPISTATUS | GetGALTableCount (struct mapi_session *, uint32_t *) |
enum MAPISTATUS | GetHierarchyTable (mapi_object_t *, mapi_object_t *, uint8_t, uint32_t *) |
enum MAPISTATUS | GetIdFromLongTermId (mapi_object_t *, struct LongTermId, mapi_id_t *) |
enum MAPISTATUS | GetIDsFromNames (mapi_object_t *, uint16_t, struct MAPINAMEID *, uint32_t, struct SPropTagArray **) |
enum MAPISTATUS | GetLastError (void) |
enum MAPISTATUS | GetLoadparmContext (struct mapi_context *, struct loadparm_context **) |
enum MAPISTATUS | GetLocalReplicaIds (mapi_object_t *, uint32_t, struct GUID *, uint8_t[6]) |
enum MAPISTATUS | GetLongTermIdFromId (mapi_object_t *, mapi_id_t, struct LongTermId *) |
enum MAPISTATUS | GetMessageStatus (mapi_object_t *, mapi_id_t, uint32_t *) |
enum MAPISTATUS | GetNamesFromIDs (mapi_object_t *, enum MAPITAGS, uint16_t *, struct MAPINAMEID **) |
enum MAPISTATUS | GetOutboxFolder (mapi_object_t *, mapi_id_t *) |
enum MAPISTATUS | GetOwningServers (mapi_object_t *, mapi_object_t *, uint16_t *, uint16_t *, char **) |
enum MAPISTATUS | GetPermissionsTable (mapi_object_t *, uint8_t, mapi_object_t *) |
enum MAPISTATUS | GetProfileAttr (struct mapi_profile *, const char *, unsigned int *, char ***) |
enum MAPISTATUS | GetProfileTable (struct mapi_context *, struct SRowSet *) |
enum MAPISTATUS | GetPropList (mapi_object_t *, struct SPropTagArray *) |
enum MAPISTATUS | GetProps (mapi_object_t *, uint32_t, struct SPropTagArray *, struct SPropValue **, uint32_t *) |
enum MAPISTATUS | GetPropsAll (mapi_object_t *, uint32_t, struct mapi_SPropValue_array *) |
enum MAPISTATUS | GetReceiveFolder (mapi_object_t *, mapi_id_t *, const char *) |
enum MAPISTATUS | GetReceiveFolderTable (mapi_object_t *, struct SRowSet *) |
enum MAPISTATUS | GetRecipientTable (mapi_object_t *, struct SRowSet *, struct SPropTagArray *) |
enum MAPISTATUS | GetRulesTable (mapi_object_t *, mapi_object_t *, uint8_t) |
enum MAPISTATUS | GetSearchCriteria (mapi_object_t *, struct mapi_SRestriction *, uint32_t *, uint16_t *, uint64_t **) |
enum MAPISTATUS | GetStatus (mapi_object_t *, uint8_t *) |
enum MAPISTATUS | GetStoreState (mapi_object_t *, uint32_t *) |
enum MAPISTATUS | GetStreamSize (mapi_object_t *, uint32_t *) |
enum MAPISTATUS | GetTransportFolder (mapi_object_t *, mapi_id_t *) |
enum MAPISTATUS | GetUserFreeBusyData (mapi_object_t *, const char *, struct SRow *) |
enum MAPISTATUS | GetValidAttach (mapi_object_t *, uint16_t *, uint32_t **) |
struct globset_range * | GLOBSET_parse (TALLOC_CTX *, DATA_BLOB, uint32_t *, uint32_t *) |
char * | guid_delete_dash (TALLOC_CTX *, const char *) |
enum MAPISTATUS | HardDeleteMessage (mapi_object_t *, mapi_id_t *, uint16_t) |
enum MAPISTATUS | HardDeleteMessagesAndSubfolders (mapi_object_t *) |
enum MAPISTATUS | ICSSyncConfigure (mapi_object_t *, enum SynchronizationType, uint8_t, uint16_t, uint32_t, DATA_BLOB, struct SPropTagArray *, mapi_object_t *) |
enum MAPISTATUS | ICSSyncGetTransferState (mapi_object_t *, mapi_object_t *) |
enum MAPISTATUS | ICSSyncOpenCollector (mapi_object_t *, bool, mapi_object_t *) |
enum MAPISTATUS | ICSSyncUploadStateBegin (mapi_object_t *, enum StateProperty, uint32_t) |
Initialize an ICS Initial State upload. More... | |
enum MAPISTATUS | ICSSyncUploadStateContinue (mapi_object_t *, DATA_BLOB) |
Send data for an ICS Initial State upload. More... | |
enum MAPISTATUS | ICSSyncUploadStateEnd (mapi_object_t *) |
Signal completion of an ICS Initial State upload. More... | |
void | IDSET_dump (const struct idset *, const char *) |
bool | IDSET_includes_eid (const struct idset *, uint64_t) |
bool | IDSET_includes_guid_glob (const struct idset *, struct GUID *, uint64_t) |
struct idset * | IDSET_merge_idsets (TALLOC_CTX *mem_ctx, const struct idset *, const struct idset *) |
struct idset * | IDSET_parse (TALLOC_CTX *, DATA_BLOB, bool) |
void | IDSET_remove_rawidset (struct idset *, const struct rawidset *) |
struct Binary_r * | IDSET_serialize (TALLOC_CTX *, const struct idset *) |
enum MAPISTATUS | IsFreeBusyConflict (mapi_object_t *, struct FILETIME *, bool *) |
bool | IsMailboxFolder (mapi_object_t *, uint64_t, uint32_t *) |
enum MAPISTATUS | LoadProfile (struct mapi_context *, struct mapi_profile *) |
enum MAPISTATUS | LockRegionStream (mapi_object_t *, uint64_t, uint64_t, uint32_t) |
enum MAPISTATUS | Logoff (mapi_object_t *) |
void | mapi_copy_spropvalues (TALLOC_CTX *, struct SPropValue *, struct SPropValue *, uint32_t) |
void | mapi_errstr (const char *, enum MAPISTATUS) |
uint32_t | mapi_get_cpid_from_language (const char *) |
uint32_t | mapi_get_cpid_from_lcid (uint32_t) |
uint32_t | mapi_get_cpid_from_locale (const char *) |
const char * | mapi_get_errstr (enum MAPISTATUS) |
char ** | mapi_get_language_from_group (TALLOC_CTX *, uint32_t) |
const char * | mapi_get_language_from_lcid (uint32_t) |
const char * | mapi_get_language_from_locale (const char *) |
uint32_t | mapi_get_lcid_from_language (const char *) |
uint32_t | mapi_get_lcid_from_locale (const char *) |
const char * | mapi_get_locale_from_language (const char *) |
const char * | mapi_get_locale_from_lcid (uint32_t) |
char * | mapi_get_system_locale (void) |
enum MAPISTATUS | mapi_id_array_add_id (mapi_id_array_t *, mapi_id_t) |
enum MAPISTATUS | mapi_id_array_add_obj (mapi_id_array_t *, mapi_object_t *) |
enum MAPISTATUS | mapi_id_array_del_id (mapi_id_array_t *, mapi_id_t) |
enum MAPISTATUS | mapi_id_array_del_obj (mapi_id_array_t *, mapi_object_t *) |
enum MAPISTATUS | mapi_id_array_get (TALLOC_CTX *, mapi_id_array_t *, mapi_id_t **) |
enum MAPISTATUS | mapi_id_array_init (TALLOC_CTX *, mapi_id_array_t *) |
enum MAPISTATUS | mapi_id_array_release (mapi_id_array_t *) |
enum MAPISTATUS | mapi_nameid_canonical_add (struct mapi_nameid *, uint32_t) |
enum MAPISTATUS | mapi_nameid_custom_lid_add (struct mapi_nameid *, uint16_t, uint16_t, const char *) |
enum MAPISTATUS | mapi_nameid_custom_string_add (struct mapi_nameid *, const char *, uint16_t, const char *) |
enum MAPISTATUS | mapi_nameid_GetIDsFromNames (struct mapi_nameid *, mapi_object_t *, struct SPropTagArray *) |
enum MAPISTATUS | mapi_nameid_lid_add (struct mapi_nameid *, uint16_t, const char *) |
enum MAPISTATUS | mapi_nameid_lid_lookup (uint16_t, const char *, uint16_t *) |
enum MAPISTATUS | mapi_nameid_lid_lookup_canonical (uint16_t, const char *, uint32_t *) |
enum MAPISTATUS | mapi_nameid_lookup_SPropTagArray (struct mapi_nameid *, struct SPropTagArray *) |
enum MAPISTATUS | mapi_nameid_lookup_SPropValue (struct mapi_nameid *, struct SPropValue *, unsigned long) |
enum MAPISTATUS | mapi_nameid_map_SPropTagArray (struct mapi_nameid *, struct SPropTagArray *, struct SPropTagArray *) |
enum MAPISTATUS | mapi_nameid_map_SPropValue (struct mapi_nameid *, struct SPropValue *, uint32_t, struct SPropTagArray *) |
struct mapi_nameid * | mapi_nameid_new (TALLOC_CTX *) |
enum MAPISTATUS | mapi_nameid_OOM_add (struct mapi_nameid *, const char *, const char *) |
enum MAPISTATUS | mapi_nameid_OOM_lookup (const char *, const char *, uint16_t *) |
enum MAPISTATUS | mapi_nameid_property_lookup (uint32_t) |
enum MAPISTATUS | mapi_nameid_SPropTagArray (struct mapi_nameid *, struct SPropTagArray *) |
enum MAPISTATUS | mapi_nameid_string_add (struct mapi_nameid *, const char *, const char *) |
enum MAPISTATUS | mapi_nameid_string_lookup (const char *, const char *, uint16_t *) |
enum MAPISTATUS | mapi_nameid_string_lookup_canonical (const char *, const char *, uint32_t *) |
enum MAPISTATUS | mapi_nameid_unmap_SPropTagArray (struct mapi_nameid *, struct SPropTagArray *) |
enum MAPISTATUS | mapi_nameid_unmap_SPropValue (struct mapi_nameid *, struct SPropValue *, uint32_t) |
enum MAPISTATUS | mapi_object_bookmark_debug (mapi_object_t *) |
enum MAPISTATUS | mapi_object_bookmark_get_count (mapi_object_t *, uint32_t *) |
enum MAPISTATUS | mapi_object_copy (mapi_object_t *, mapi_object_t *) |
void | mapi_object_debug (mapi_object_t *) |
mapi_id_t | mapi_object_get_id (mapi_object_t *) |
enum MAPISTATUS | mapi_object_get_logon_id (mapi_object_t *, uint8_t *) |
struct mapi_session * | mapi_object_get_session (mapi_object_t *) |
enum MAPISTATUS | mapi_object_init (mapi_object_t *) |
void | mapi_object_release (mapi_object_t *) |
void | mapi_object_set_logon_id (mapi_object_t *, uint8_t) |
void | mapi_object_set_logon_store (mapi_object_t *) |
void | mapi_object_set_session (mapi_object_t *, struct mapi_session *) |
enum MAPISTATUS | mapi_profile_add_string_attr (struct mapi_context *, const char *, const char *, const char *) |
enum MAPISTATUS | mapi_profile_delete_string_attr (struct mapi_context *, const char *, const char *, const char *) |
const char * | mapi_profile_get_ldif_path (void) |
enum MAPISTATUS | mapi_profile_modify_string_attr (struct mapi_context *, const char *, const char *, const char *) |
void | mapi_SPropValue_array_named (mapi_object_t *, struct mapi_SPropValue_array *) |
bool | mapi_verify_cpid (uint32_t) |
enum MAPISTATUS | MAPIAllocateBuffer (struct mapi_context *, uint32_t, void **) |
void | mapidump_appointment (struct mapi_SPropValue_array *, const char *) |
void | mapidump_contact (struct mapi_SPropValue_array *, const char *) |
void | mapidump_date (struct mapi_SPropValue_array *, uint32_t, const char *) |
void | mapidump_date_SPropValue (struct SPropValue, const char *, const char *) |
void | mapidump_foldercopied (struct FolderMoveCopyNotification *, const char *) |
void | mapidump_foldercreated (struct FolderCreatedNotification *, const char *) |
void | mapidump_folderdeleted (struct FolderDeletedNotification *, const char *) |
void | mapidump_foldermoved (struct FolderMoveCopyNotification *, const char *) |
void | mapidump_freebusy_date (uint32_t, const char *) |
void | mapidump_freebusy_event (struct Binary_r *, uint32_t, uint32_t, const char *) |
const char * | mapidump_freebusy_month (uint32_t, uint32_t) |
uint32_t | mapidump_freebusy_year (uint32_t, uint32_t) |
void | mapidump_languages_list (void) |
void | mapidump_message (struct mapi_SPropValue_array *, const char *, mapi_object_t *) |
void | mapidump_message_summary (mapi_object_t *) |
void | mapidump_messagecopied (struct MessageMoveCopyNotification *, const char *) |
void | mapidump_messagecreated (struct MessageCreatedNotification *, const char *) |
void | mapidump_messagedeleted (struct MessageDeletedNotification *, const char *) |
void | mapidump_messagemodified (struct MessageModifiedNotification *, const char *) |
void | mapidump_messagemoved (struct MessageMoveCopyNotification *, const char *) |
void | mapidump_msgflags (uint32_t, const char *) |
void | mapidump_newmail (struct NewMailNotification *, const char *) |
void | mapidump_note (struct mapi_SPropValue_array *, const char *) |
void | mapidump_PAB_entry (struct PropertyRow_r *) |
Output a row of the public address book. More... | |
void | mapidump_Recipients (const char **, struct SRowSet *, struct PropertyTagArray_r *flaglist) |
void | mapidump_SPropTagArray (struct SPropTagArray *) |
void | mapidump_SPropValue (struct SPropValue, const char *) |
Output one property tag and value. More... | |
void | mapidump_SRow (struct SRow *, const char *) |
void | mapidump_SRowSet (struct SRowSet *, const char *) |
void | mapidump_tags (enum MAPITAGS *, uint16_t, const char *) |
void | mapidump_task (struct mapi_SPropValue_array *, const char *) |
enum MAPISTATUS | MAPIFreeBuffer (void *) |
enum MAPISTATUS | MAPIInitialize (struct mapi_context **, const char *) |
enum MAPISTATUS | MapiLogonEx (struct mapi_context *, struct mapi_session **, const char *, const char *) |
enum MAPISTATUS | MapiLogonProvider (struct mapi_context *, struct mapi_session **, const char *, const char *, enum PROVIDER_ID) |
void | MAPIUninitialize (struct mapi_context *) |
enum MAPISTATUS | ModifyPermissions (mapi_object_t *, uint8_t, struct mapi_PermissionsData *) |
enum MAPISTATUS | ModifyRecipients (mapi_object_t *, struct SRowSet *) |
enum MAPISTATUS | ModifyUserPermission (mapi_object_t *, const char *, enum ACLRIGHTS) |
enum MAPISTATUS | MonitorNotification (struct mapi_session *, void *, struct mapi_notify_continue_callback_data *) |
enum MAPISTATUS | MoveCopyMessages (mapi_object_t *, mapi_object_t *, mapi_id_array_t *, bool) |
enum MAPISTATUS | MoveFolder (mapi_object_t *, mapi_object_t *, mapi_object_t *, char *, bool) |
void | ndr_push_idset (struct ndr_push *, struct idset *) |
__BEGIN_DECLS struct nspi_context * | nspi_bind (TALLOC_CTX *, struct dcerpc_pipe *, struct cli_credentials *, uint32_t, uint32_t, uint32_t) |
enum MAPISTATUS | nspi_CompareMIds (struct nspi_context *, TALLOC_CTX *, uint32_t, uint32_t, uint32_t *) |
enum MAPISTATUS | nspi_DNToMId (struct nspi_context *, TALLOC_CTX *, struct StringsArray_r *, struct PropertyTagArray_r **ppMIds) |
enum MAPISTATUS | nspi_GetIDsFromNames (struct nspi_context *, TALLOC_CTX *, bool, uint32_t, struct PropertyName_r *, struct SPropTagArray **) |
enum MAPISTATUS | nspi_GetMatches (struct nspi_context *, TALLOC_CTX *, struct SPropTagArray *, struct Restriction_r *, uint32_t ulRequested, struct PropertyRowSet_r **, struct PropertyTagArray_r **ppOutMIds) |
enum MAPISTATUS | nspi_GetNamesFromIDs (struct nspi_context *, TALLOC_CTX *, struct FlatUID_r *, struct SPropTagArray *, struct SPropTagArray **, struct PropertyNameSet_r **) |
enum MAPISTATUS | nspi_GetPropList (struct nspi_context *, TALLOC_CTX *, bool, uint32_t, struct SPropTagArray **) |
enum MAPISTATUS | nspi_GetProps (struct nspi_context *, TALLOC_CTX *, struct SPropTagArray *, struct PropertyTagArray_r *MId, struct PropertyRowSet_r **) |
enum MAPISTATUS | nspi_GetSpecialTable (struct nspi_context *, TALLOC_CTX *, uint32_t, struct PropertyRowSet_r **) |
enum MAPISTATUS | nspi_GetTemplateInfo (struct nspi_context *, TALLOC_CTX *, uint32_t, uint32_t, char *, struct PropertyRow_r **) |
enum MAPISTATUS | nspi_ModLinkAtt (struct nspi_context *, bool, uint32_t, uint32_t, struct BinaryArray_r *) |
enum MAPISTATUS | nspi_ModProps (struct nspi_context *, TALLOC_CTX *, uint32_t, struct SPropTagArray *, struct PropertyRow_r *) |
enum MAPISTATUS | nspi_QueryColumns (struct nspi_context *, TALLOC_CTX *, bool, struct SPropTagArray **) |
enum MAPISTATUS | nspi_QueryRows (struct nspi_context *, TALLOC_CTX *, struct SPropTagArray *, struct PropertyTagArray_r *MIds, uint32_t, struct PropertyRowSet_r **) |
enum MAPISTATUS | nspi_ResolveNames (struct nspi_context *, TALLOC_CTX *, const char **, struct SPropTagArray *, struct PropertyRowSet_r ***, struct PropertyTagArray_r ***) |
enum MAPISTATUS | nspi_ResolveNamesW (struct nspi_context *, TALLOC_CTX *, const char **, struct SPropTagArray *, struct PropertyRowSet_r ***, struct PropertyTagArray_r ***) |
enum MAPISTATUS | nspi_ResortRestriction (struct nspi_context *, TALLOC_CTX *, enum TableSortOrders, struct PropertyTagArray_r *pInMIds, struct PropertyTagArray_r **ppMIds) |
enum MAPISTATUS | nspi_SeekEntries (struct nspi_context *, TALLOC_CTX *, enum TableSortOrders, struct PropertyValue_r *, struct SPropTagArray *, struct PropertyTagArray_r *pMIds, struct PropertyRowSet_r **) |
enum MAPISTATUS | nspi_unbind (struct nspi_context *) |
enum MAPISTATUS | nspi_UpdateStat (struct nspi_context *, TALLOC_CTX *, uint32_t *) |
enum MAPISTATUS | OpenAttach (mapi_object_t *, uint32_t, mapi_object_t *) |
enum MAPISTATUS | OpenEmbeddedMessage (mapi_object_t *, mapi_object_t *, enum OpenEmbeddedMessage_OpenModeFlags) |
enum MAPISTATUS | OpenFolder (mapi_object_t *, mapi_id_t, mapi_object_t *) |
enum MAPISTATUS | OpenMessage (mapi_object_t *, mapi_id_t, mapi_id_t, mapi_object_t *, uint8_t) |
enum MAPISTATUS | OpenMsgStore (struct mapi_session *, mapi_object_t *) |
enum MAPISTATUS | OpenProfile (struct mapi_context *, struct mapi_profile *, const char *, const char *) |
enum MAPISTATUS | OpenPublicFolder (struct mapi_session *, mapi_object_t *) |
enum MAPISTATUS | OpenPublicFolderByName (mapi_object_t *, mapi_object_t *, const char *) |
enum MAPISTATUS | OpenStream (mapi_object_t *, enum MAPITAGS, enum OpenStream_OpenModeFlags, mapi_object_t *) |
enum MAPISTATUS | OpenUserMailbox (struct mapi_session *, const char *, mapi_object_t *) |
enum MAPISTATUS | OptionsData (mapi_object_t *, const char *, uint8_t **, uint16_t *, uint8_t **, uint16_t *, const char **) |
enum MAPISTATUS | ProcessNetworkProfile (struct mapi_session *, const char *, mapi_profile_callback_t, const void *) |
enum MAPISTATUS | PropertyRow_addprop (struct PropertyRow_r *, struct PropertyValue_r) |
uint32_t | PropertyRowSet_propcpy (TALLOC_CTX *, struct PropertyRowSet_r *, struct PropertyValue_r) |
enum MAPISTATUS | PublicFolderIsGhosted (mapi_object_t *, mapi_object_t *, bool *) |
enum MAPISTATUS | QueryColumns (mapi_object_t *, struct SPropTagArray *) |
enum MAPISTATUS | QueryNamedProperties (mapi_object_t *, uint8_t, struct GUID *, uint16_t *, uint16_t **, struct MAPINAMEID **) |
enum MAPISTATUS | QueryPosition (mapi_object_t *, uint32_t *, uint32_t *) |
enum MAPISTATUS | QueryRows (mapi_object_t *, uint16_t, enum QueryRowsFlags, struct SRowSet *) |
struct idset * | RAWIDSET_convert_to_idset (TALLOC_CTX *, const struct rawidset *) |
struct rawidset * | RAWIDSET_make (TALLOC_CTX *, bool, bool) |
void | RAWIDSET_push_eid (struct rawidset *, uint64_t) |
void | RAWIDSET_push_guid_glob (struct rawidset *, const struct GUID *, uint64_t) |
enum MAPISTATUS | ReadRecipients (mapi_object_t *, uint32_t, uint8_t *, struct ReadRecipientRow **) |
enum MAPISTATUS | ReadStream (mapi_object_t *, unsigned char *, uint16_t, uint16_t *) |
enum MAPISTATUS | RegisterAsyncNotification (struct mapi_session *, uint32_t *) |
enum MAPISTATUS | RegisterNotification (struct mapi_session *) |
enum MAPISTATUS | Release (mapi_object_t *) |
enum MAPISTATUS | ReloadCachedInformation (mapi_object_t *) |
enum MAPISTATUS | RemoveAllRecipients (mapi_object_t *) |
enum MAPISTATUS | RemoveUserPermission (mapi_object_t *, const char *) |
enum MAPISTATUS | RenameProfile (struct mapi_context *, const char *, const char *) |
enum MAPISTATUS | Reset (mapi_object_t *) |
enum MAPISTATUS | ResolveNames (struct mapi_session *, const char **, struct SPropTagArray *, struct PropertyRowSet_r **, struct PropertyTagArray_r **, uint32_t) |
enum MAPISTATUS | Restrict (mapi_object_t *, struct mapi_SRestriction *, uint8_t *) |
enum MAPISTATUS | RfrGetFQDNFromLegacyDN (struct mapi_context *, struct mapi_session *, const char **) |
enum MAPISTATUS | RfrGetNewDSA (struct mapi_context *, struct mapi_session *, const char *, const char *, char **) |
enum MAPISTATUS | SaveChangesAttachment (mapi_object_t *, mapi_object_t *, enum SaveFlags) |
enum MAPISTATUS | SaveChangesMessage (mapi_object_t *, mapi_object_t *, uint8_t) |
enum MAPISTATUS | SeekRow (mapi_object_t *, enum BOOKMARK, int32_t, uint32_t *) |
enum MAPISTATUS | SeekRowApprox (mapi_object_t *, uint32_t, uint32_t) |
enum MAPISTATUS | SeekRowBookmark (mapi_object_t *, uint32_t, uint32_t, uint32_t *) |
enum MAPISTATUS | SeekStream (mapi_object_t *, uint8_t, uint64_t, uint64_t *) |
struct Binary_r * | set_AppointmentRecurrencePattern (TALLOC_CTX *mem_ctx, const struct AppointmentRecurrencePattern *) |
size_t | set_AppointmentRecurrencePattern_size (const struct AppointmentRecurrencePattern *) |
enum MAPISTATUS | set_default_error_SPropValue_SRow (struct SRow *, enum MAPITAGS, void *) |
size_t | set_ExceptionInfo_size (const struct ExceptionInfo *) |
size_t | set_ExtendedException_size (uint32_t, enum OverrideFlags, const struct ExtendedException *) |
bool | set_mapi_SPropValue (TALLOC_CTX *, struct mapi_SPropValue *, const void *) |
bool | set_mapi_SPropValue_proptag (TALLOC_CTX *, struct mapi_SPropValue *, uint32_t, const void *) |
bool | set_PropertyValue (struct PropertyValue_r *, const void *) |
struct Binary_r * | set_RecurrencePattern (TALLOC_CTX *, const struct RecurrencePattern *) |
size_t | set_RecurrencePattern_size (const struct RecurrencePattern *) |
struct SPropTagArray * | set_SPropTagArray (TALLOC_CTX *, uint32_t,...) |
bool | set_SPropValue (struct SPropValue *, const void *) |
bool | set_SPropValue_proptag (struct SPropValue *, enum MAPITAGS, const void *) |
bool | set_SPropValue_proptag_date_timeval (struct SPropValue *, enum MAPITAGS, const struct timeval *) |
struct Binary_r * | set_TimeZoneDefinition (TALLOC_CTX *, const struct TimeZoneDefinition *) |
struct Binary_r * | set_TimeZoneStruct (TALLOC_CTX *, const struct TimeZoneStruct *) |
enum MAPISTATUS | SetCollapseState (mapi_object_t *, struct SBinary_short *) |
enum MAPISTATUS | SetColumns (mapi_object_t *, struct SPropTagArray *) |
enum MAPISTATUS | SetDefaultProfile (struct mapi_context *, const char *) |
enum MAPISTATUS | SetLocalReplicaMidsetDeleted (mapi_object_t *, const struct GUID, const uint8_t GlobalCountLow[6], const uint8_t GlobalCountHigh[6]) |
enum MAPISTATUS | SetMAPIDebugLevel (struct mapi_context *, uint32_t) |
enum MAPISTATUS | SetMAPIDumpData (struct mapi_context *, bool) |
enum MAPISTATUS | SetMessageReadFlag (mapi_object_t *, mapi_object_t *, uint8_t) |
enum MAPISTATUS | SetMessageStatus (mapi_object_t *, mapi_id_t, uint32_t, uint32_t, uint32_t *) |
enum MAPISTATUS | SetPropertiesNoReplicate (mapi_object_t *, uint32_t, struct SPropValue *, unsigned long) |
enum MAPISTATUS | SetProps (mapi_object_t *, uint32_t, struct SPropValue *, unsigned long) |
enum MAPISTATUS | SetReadFlags (mapi_object_t *, uint8_t, uint16_t, uint64_t *) |
enum MAPISTATUS | SetReceiveFolder (mapi_object_t *, mapi_object_t *, const char *) |
enum MAPISTATUS | SetRecipientType (struct SRow *, enum ulRecipClass) |
enum MAPISTATUS | SetSearchCriteria (mapi_object_t *, struct mapi_SRestriction *, uint32_t, mapi_id_array_t *) |
enum MAPISTATUS | SetSpooler (mapi_object_t *) |
enum MAPISTATUS | SetStreamSize (mapi_object_t *, uint64_t) |
enum MAPISTATUS | SetSyncNotificationGuid (mapi_object_t *, const struct GUID) |
enum MAPISTATUS | ShutDown (struct mapi_profile *) |
enum MAPISTATUS | SortTable (mapi_object_t *, struct SSortOrderSet *) |
enum MAPISTATUS | SpoolerLockMessage (mapi_object_t *, mapi_object_t *, enum LockState) |
enum MAPISTATUS | SPropTagArray_add (TALLOC_CTX *, struct SPropTagArray *, enum MAPITAGS) |
enum MAPISTATUS | SPropTagArray_delete (TALLOC_CTX *, struct SPropTagArray *, uint32_t) |
enum MAPISTATUS | SPropTagArray_find (struct SPropTagArray, enum MAPITAGS, uint32_t *) |
enum MAPISTATUS | SRow_addprop (struct SRow *, struct SPropValue) |
uint32_t | SRowSet_propcpy (TALLOC_CTX *, struct SRowSet *, struct SPropValue) |
enum MAPISTATUS | SubmitMessage (mapi_object_t *) |
enum MAPISTATUS | Subscribe (mapi_object_t *, uint32_t *, uint16_t, bool, mapi_notify_callback_t, void *) |
enum MAPISTATUS | SyncOpenAdvisor (mapi_object_t *, mapi_object_t *) |
enum MAPISTATUS | TellVersion (mapi_object_t *, uint16_t version[3]) |
enum MAPISTATUS | TransportNewMail (mapi_object_t *, mapi_object_t *, mapi_object_t *, const char *, uint32_t) |
enum MAPISTATUS | TransportSend (mapi_object_t *, struct mapi_SPropValue_array *) |
enum MAPISTATUS | uncompress_rtf (TALLOC_CTX *, uint8_t *, uint32_t, DATA_BLOB *) |
enum MAPISTATUS | UnlockRegionStream (mapi_object_t *, uint64_t, uint64_t, uint32_t) |
enum MAPISTATUS | Unsubscribe (struct mapi_session *, uint32_t) |
enum MAPISTATUS | WrapCompressedRTFStream (mapi_object_t *, DATA_BLOB *) |
enum MAPISTATUS | WriteAndCommitStream (mapi_object_t *, DATA_BLOB *, uint16_t *) |
enum MAPISTATUS | WriteStream (mapi_object_t *, DATA_BLOB *, uint16_t *) |
char * | x500_get_dn_element (TALLOC_CTX *, const char *, const char *) |
char * | x500_get_servername (const char *) |
Retrieve the servername from a string We should definitively find a better way to handle this. More... | |
char * | x500_truncate_dn_last_elements (TALLOC_CTX *, const char *, uint32_t) |
#define __BEGIN_DECLS |
#define __END_DECLS |
#define _GNU_SOURCE 1 |
#define _PRINTF_ATTRIBUTE | ( | a1, | |
a2 | |||
) | PRINTF_ATTRIBUTE(a1, a2) |
struct ExtendedException has fixed response size for:
#define _PRINTF_ATTRIBUTE | ( | a1, | |
a2 | |||
) |
struct ExtendedException has fixed response size for:
#define SIZE_DFLT_APPOINTMENTRECURRENCEPATTERN 26 |
struct AppointmentRecurrencePattern has fixed response size for:
Referenced by set_AppointmentRecurrencePattern_size().
#define SIZE_DFLT_EXCEPTIONINFO 22 |
struct ExceptionInfo has fixed response size for:
Referenced by set_ExceptionInfo_size().
#define SIZE_DFLT_EXTENDEDEXCEPTION 0 |
struct ExceptionInfo has not fixed response size
Referenced by set_ExtendedException_size().
#define SIZE_DFLT_RECURRENCEPATTERN 50 |
struct RecurrencePattern has fixed response size for:
Referenced by set_RecurrencePattern_size().
typedef enum MAPISTATUS(* fxparser_delprop_callback_t)(uint32_t, void *) |
typedef enum MAPISTATUS(* fxparser_marker_callback_t)(uint32_t, void *) |
typedef enum MAPISTATUS(* fxparser_namedprop_callback_t)(uint32_t, struct MAPINAMEID, void *) |
typedef enum MAPISTATUS(* fxparser_property_callback_t)(struct SPropValue, void *) |
enum MAPISTATUS Abort | ( | mapi_object_t * | obj_table, |
uint8_t * | TableStatus | ||
) |
Aborts an asynchronous table operation in progress
obj_table | the table object where we want to abort an asynchronous operation |
TableStatus | pointer on the table status returned by the operation |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS AbortSubmit | ( | mapi_object_t * | obj_store, |
mapi_object_t * | obj_folder, | ||
mapi_object_t * | obj_message | ||
) |
Aborts a previous message submission.
obj_store | the store object |
obj_folder | the folder object where the message has been submitted |
obj_message | the submitted message object |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_id(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
struct mapi_SPropValue* add_mapi_SPropValue | ( | TALLOC_CTX * | , |
struct mapi_SPropValue * | , | ||
uint16_t * | , | ||
uint32_t | , | ||
const void * | |||
) |
References set_mapi_SPropValue_proptag().
struct SPropValue* add_SPropValue | ( | TALLOC_CTX * | , |
struct SPropValue * | , | ||
uint32_t * | , | ||
enum | MAPITAGS, | ||
const void * | |||
) |
References set_SPropValue_proptag().
enum MAPISTATUS AddressTypes | ( | mapi_object_t * | obj_store, |
uint16_t * | lpcAdrType, | ||
struct mapi_LPSTR ** | lpAdrTypeArray | ||
) |
Returns the types of recipients that the transport provider handles.
obj_store | the object to get recipients types from |
lpcAdrType | the count of recipients types returned |
lpAdrTypeArray | pointer on pointer of returned transport provider types |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS AddUserPermission | ( | mapi_object_t * | obj_folder, |
const char * | username, | ||
enum ACLRIGHTS | role | ||
) |
Adds permissions for a user on a given folder
obj_folder | the folder we add permission for |
username | the Exchange username we add permissions for |
role | the permission mask value |
The following permissions and rights are supported:
References get_PropertyValue_data(), mapi_object_get_session(), MAPI_RESOLVED, MAPIFreeBuffer(), ModifyPermissions(), OPENCHANGE_RETVAL_IF, PR_DISPLAY_NAME, PR_ENTRYID, PR_MEMBER_RIGHTS, ResolveNames(), set_mapi_SPropValue(), and set_SPropTagArray().
uint32_t calculateCRC | ( | uint8_t * | , |
uint32_t | , | ||
uint32_t | |||
) |
Referenced by compress_rtf().
uint32_t cast_mapi_SPropValue | ( | TALLOC_CTX * | mem_ctx, |
struct mapi_SPropValue * | mapi_sprop, | ||
struct SPropValue * | sprop | ||
) |
Convenience function to convert a SPropValue structure into a mapi_SPropValue structure and return the associated size.
mem_ctx | pointer to the memory context to use for allocation |
mapi_sprop | pointer to the MAPI SPropValue structure to copy data to |
sprop | pointer to the SPropValue structure to copy data from |
References get_utf8_utf16_conv_length(), PT_BINARY, PT_BOOLEAN, PT_CLSID, PT_DOUBLE, PT_ERROR, PT_I2, PT_I8, PT_LONG, PT_MV_BINARY, PT_MV_CLSID, PT_MV_LONG, PT_MV_STRING8, PT_MV_UNICODE, PT_STRING8, PT_SVREID, PT_SYSTIME, and PT_UNICODE.
Referenced by ModifyRecipients(), SetPropertiesNoReplicate(), and SetProps().
void cast_PropertyRow_to_SRow | ( | TALLOC_CTX * | mem_ctx, |
struct PropertyRow_r * | proprow, | ||
struct SRow * | srow | ||
) |
Convenience function to convert a PropertyRow_r structure into a SRow structure.
mem_ctx | pointer to the allocation context for structure members |
proprow | pointer to the PropertyRow_r structure to copy data to |
srow | pointer to the SRow structure to copy data from |
References cast_PropertyValue_to_SPropValue().
Referenced by cast_PropertyRowSet_to_SRowSet().
void cast_PropertyRowSet_to_SRowSet | ( | TALLOC_CTX * | mem_ctx, |
struct PropertyRowSet_r * | prowset, | ||
struct SRowSet * | srowset | ||
) |
Convenience function to convert a PropertyRowSet_r structure into a SRowSet structure.
mem_ctx | pointer to the allocation context for structure members |
prowset | pointer to the PropertyRowSet_r structure to copy data to |
setrowset | pointer to the SRowSet structure to copy data from |
References cast_PropertyRow_to_SRow().
void cast_PropertyValue_to_SPropValue | ( | struct PropertyValue_r * | propvalue, |
struct SPropValue * | spropvalue | ||
) |
Convenience function to convert a PropertyValue_r structure into a SPropValue structure.
propvalue | pointer to the PropertyValue_r structure to copy data to |
spropvalue | pointer to the SPropValue structure to copy data from |
References PT_BINARY, PT_BOOLEAN, PT_CLSID, PT_ERROR, PT_I2, PT_LONG, PT_MV_BINARY, PT_MV_CLSID, PT_MV_LONG, PT_MV_STRING8, PT_MV_UNICODE, PT_STRING8, PT_SVREID, PT_SYSTIME, and PT_UNICODE.
Referenced by cast_PropertyRow_to_SRow().
uint32_t cast_SPropValue | ( | TALLOC_CTX * | mem_ctx, |
struct mapi_SPropValue * | mapi_sprop, | ||
struct SPropValue * | sprop | ||
) |
Convenience function to convert a mapi_SPropValue structure into a SPropValue structure and return the associated size
mem_ctx | pointer to the memory context to use for allocation |
mapi_sprop | pointer to the MAPI SPropValue structure to copy data from |
sprop | pointer to the SPropValue structure to copy data to |
References get_utf8_utf16_conv_length(), PT_BINARY, PT_BOOLEAN, PT_CLSID, PT_DOUBLE, PT_ERROR, PT_I2, PT_I8, PT_LONG, PT_MV_BINARY, PT_MV_CLSID, PT_MV_LONG, PT_MV_STRING8, PT_MV_UNICODE, PT_STRING8, PT_SVREID, PT_SYSTIME, and PT_UNICODE.
enum MAPISTATUS ChangeProfilePassword | ( | struct mapi_context * | mapi_ctx, |
const char * | profile, | ||
const char * | old_password, | ||
const char * | password | ||
) |
Change the profile password of an existing MAPI profile
mapi_ctx | pointer to the MAPI context |
profile | the name of the profile to have its password changed |
old_password | the old password |
password | the new password |
References mapi_profile_modify_string_attr(), mapi_context::mem_ctx, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS CloneStream | ( | mapi_object_t * | obj_src, |
mapi_object_t * | obj_dst | ||
) |
Clone a source stream to another stream
obj_src | the source stream object |
obj_dst | the destination stream object |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), mapi_object_set_handle(), mapi_object_set_logon_id(), mapi_object_set_session(), and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS CollapseRow | ( | mapi_object_t * | obj_table, |
uint64_t | categoryId, | ||
uint32_t * | rowCount | ||
) |
Collapse an expanded row in a table
After a contents table has been sorted and categorized using SortTable, rows can be expanded and collapsed (using ExpandRow and CollapseRow repectively).
obj_table | the table we are collapsing the category in. |
categoryId | the row identification for the heading row for the category being collapsed. |
rowCount | (result) the number of rows that were removed from the table when the row was collapsed. |
You obtain the categoryId argument from the PR_INST_ID property of the heading row for the category that is being collapsed.
If you pass rowCount as null, the number of rows will not be returned.
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS CommitStream | ( | mapi_object_t * | obj_stream) |
Commits stream operations
obj_stream | the stream object to commit |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS compress_rtf | ( | TALLOC_CTX * | , |
const char * | , | ||
const size_t | , | ||
uint8_t ** | , | ||
size_t * | |||
) |
References calculateCRC(), LZFU_COMPRESSED, LZFU_DICTLENGTH, LZFU_INITDICT, and LZFU_INITLENGTH.
enum MAPISTATUS CopyFolder | ( | mapi_object_t * | obj_folder, |
mapi_object_t * | obj_src, | ||
mapi_object_t * | obj_dst, | ||
char * | NewFolderName, | ||
bool | UseUnicode, | ||
bool | WantRecursive | ||
) |
Copy a folder
obj_folder | the folder to copy |
obj_src | source object where the folder to copy is stored |
obj_dst | destination object where the folder will be copied |
NewFolderName | the new folder name in the destination folder |
UseUnicode | whether the folder name is unicode encoded or not |
WantRecursive | whether we should copy folder's subdirectories or not |
References emsmdb_transaction_wrapper(), get_utf8_utf16_conv_length(), mapi_object_get_handle(), mapi_object_get_id(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS CopyProfile | ( | struct mapi_context * | mapi_ctx, |
const char * | profile_src, | ||
const char * | profile_dst | ||
) |
Copy a profile
mapi_ctx | pointer to the MAPI context |
profile_src | the source profile to copy from |
profile_dst | the destination profile to copy to |
References mapi_context::ldb_ctx, mapi_context::mem_ctx, and OPENCHANGE_RETVAL_IF.
Referenced by DuplicateProfile().
enum MAPISTATUS CopyProps | ( | mapi_object_t * | obj_src, |
mapi_object_t * | obj_dst, | ||
struct SPropTagArray * | tags, | ||
uint8_t | copyFlags, | ||
uint16_t * | problemCount, | ||
struct PropertyProblem ** | problems | ||
) |
Copy properties from one object to another
This function copies (or moves) specified properties from one object to another.
obj_src | the object to copy properties from |
obj_dst | the object to set properties on |
copyFlags | flags to determine whether to copy or move, and whether to overwrite existing properties. |
tags | the list of properties to copy |
problemCount | (return value) number of entries in the problems array |
problems | (return value) array of problemCount entries. |
The caller is responsible for freeing the problems array using MAPIFreeBuffer(). If the problemCount pointer is NULL, then the problems array will not be returned.
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS CopyTo | ( | mapi_object_t * | obj_src, |
mapi_object_t * | obj_dst, | ||
struct SPropTagArray * | excludeTags, | ||
uint8_t | copyFlags, | ||
uint16_t * | problemCount, | ||
struct PropertyProblem ** | problems | ||
) |
Copy multiple properties from one object to another
This function copies (or moves) properties from one object to another. Unlike CopyProperties, this function copies all properties except those identified.
obj_src | the object to copy properties from |
obj_dst | the object to set properties on |
excludeTags | the list of properties to not copy |
copyFlags | flags to determine whether to copy or move, and whether to overwrite existing properties. |
problemCount | (return value) number of entries in the problems array |
problems | (return value) array of problemCount entries. |
The caller is responsible for freeing the problems array using MAPIFreeBuffer(). If the problemCount pointer is NULL, then the problems array will not be returned.
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS CopyToStream | ( | mapi_object_t * | obj_src, |
mapi_object_t * | obj_dst, | ||
uint64_t | ByteCount, | ||
uint64_t * | ReadByteCount, | ||
uint64_t * | WrittenByteCount | ||
) |
Copy a number of bytes from a source stream to another stream
obj_src | the source stream object |
obj_dst | the destination stream object |
ByteCount | the number of bytes to copy |
ReadByteCount | pointer on the number of bytes read from the source object |
WrittenByteCount | pointer on the number of bytes written to the destination object |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS CreateAttach | ( | mapi_object_t * | obj_message, |
mapi_object_t * | obj_attach | ||
) |
Create a new attachment
This function creates a new attachment to an existing message.
obj_message | the message to attach to |
obj_attach | the attachment |
Both objects need to exist before you call this message. obj_message should be a valid message on the server. obj_attach needs to be initialised.
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), mapi_object_set_handle(), mapi_object_set_logon_id(), mapi_object_set_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS CreateBookmark | ( | mapi_object_t * | obj_table, |
uint32_t * | lpbkPosition | ||
) |
Marks the table current position
obj_table | the table we are creating a bookmark in |
lpbkPosition | pointer to the bookmark value. This bookmark can be passed in a call to the SeekRowBookmark method |
References mapi_obj_bookmark::bin, mapi_obj_table::bk_last, mapi_obj_table::bookmark, emsmdb_transaction_wrapper(), mapi_obj_bookmark::index, mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, OPENCHANGE_RETVAL_IF, and mapi_object::private_data.
enum MAPISTATUS CreateFolder | ( | mapi_object_t * | obj_parent, |
enum FOLDER_TYPE | ulFolderType, | ||
const char * | name, | ||
const char * | comment, | ||
uint32_t | ulFlags, | ||
mapi_object_t * | obj_child | ||
) |
Create a folder
The function creates a folder (defined with its name, comment and type) within a specified folder.
obj_parent | the folder to create the new folder in |
ulFolderType | the type of the folder |
name | the name of the new folder |
comment | the comment associated with the new folder |
ulFlags | flags associated with folder creation |
obj_child | pointer to the newly created folder |
ulFlags possible values:
ulFolderType possible values:
References emsmdb_transaction_wrapper(), get_utf8_utf16_conv_length(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), mapi_object_init(), mapi_object_set_handle(), mapi_object_set_id(), mapi_object_set_logon_id(), mapi_object_set_session(), MAPI_UNICODE, OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS CreateMessage | ( | mapi_object_t * | obj_folder, |
mapi_object_t * | obj_message | ||
) |
The function creates a message in the specified folder, and returns a pointer on this message.
obj_folder | the folder to create the message in. |
obj_message | pointer to the newly created message. |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_id(), mapi_object_get_logon_id(), mapi_object_get_session(), mapi_object_set_handle(), mapi_object_set_logon_id(), mapi_object_set_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS CreateProfile | ( | struct mapi_context * | mapi_ctx, |
const char * | profile, | ||
const char * | username, | ||
const char * | password, | ||
uint32_t | flag | ||
) |
Create a profile in the MAPI profile database
This function creates a profile named profile in the MAPI profile database and sets the specified username in that profile.
This function may also set the password. If the flags include OC_PROFILE_NOPASSWORD then the password will not be set. Otherwise, the specified password argument will also be saved to the profile.
mapi_ctx | pointer to the MAPI context |
profile | the name of the profile |
username | the username of the profile |
password | the password for the profile (if used) |
flag | the union of the flags. |
References mapi_context::ldb_ctx, mapi_profile_add_string_attr(), mapi_context::mem_ctx, OC_PROFILE_NOPASSWORD, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS CreateProfileStore | ( | const char * | profiledb, |
const char * | ldif_path | ||
) |
Create a profile database
This function creates a new profile database, including doing an initial setup.
profiledb | the absolute path to the profile database intended to be created |
ldif_path | the absolute path to the LDIF information to use for initial setup. |
References OPENCHANGE_RETVAL_ERR, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS DeleteAttach | ( | mapi_object_t * | obj_message, |
uint32_t | AttachmentID | ||
) |
Delete an attachment from a message
This function deletes one attachment from a message. The attachment to be deleted is specified by its PR_ATTACH_NUM
obj_message | the message to operate on |
AttachmentID | the attachment number |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS DeleteFolder | ( | mapi_object_t * | obj_parent, |
mapi_id_t | FolderId, | ||
uint8_t | DeleteFolderFlags, | ||
bool * | PartialCompletion | ||
) |
Delete a folder
The function deletes a specified folder.
obj_parent | the folder containing the folder to be deleted |
FolderId | the ID of the folder to delete |
DeleteFolderFlags | control DeleteFolder operation behavior |
PartialCompletion | pointer on a boolean value which specify whether the operation was partially completed or not |
Possible values for DeleteFolderFlags are:
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS DeleteMessage | ( | mapi_object_t * | obj_folder, |
mapi_id_t * | id_messages, | ||
uint32_t | cn_messages | ||
) |
Delete one or more messages
This function deletes one or more messages based on their ids from a specified folder.
obj_folder | the folder to delete messages from |
id_messages | the list of ids |
cn_messages | the number of messages in the id list. |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS DeleteProfile | ( | struct mapi_context * | mapi_ctx, |
const char * | profile | ||
) |
Delete a profile from the MAPI profile database
mapi_ctx | pointer to the MAPI context |
profile | the name of the profile to delete |
References mapi_context::ldb_ctx, mapi_context::mem_ctx, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS DeletePropertiesNoReplicate | ( | mapi_object_t * | obj, |
struct SPropTagArray * | proptags | ||
) |
Deletes property values from an object without invoking replication.
obj | the object to remove properties from |
proptags | the properties to remove from the given object |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS DeleteProps | ( | mapi_object_t * | obj, |
struct SPropTagArray * | proptags | ||
) |
Delete one or more properties from an object
obj | the object to remove properties from |
proptags | the properties to remove from the given object |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS DispatchNotifications | ( | struct mapi_session * | session) |
Force notification of pending events
This function force the server to send any pending notificaion and process them. These MAPI notifications are next compared to the registered ones and the callback specified in Subscribe() called if it matches.
References mapi_provider::ctx, mapi_session::emsmdb, emsmdb_transaction_null(), mapi_session::notify_ctx, OPENCHANGE_RETVAL_IF, and ProcessNotification().
enum MAPISTATUS DuplicateProfile | ( | struct mapi_context * | mapi_ctx, |
const char * | profile_src, | ||
const char * | profile_dst, | ||
const char * | username | ||
) |
Duplicate an existing profile.
The username specified in parameter is used to customize the new profile. This function should only be used in environments where users are within the same administrative group, storage group, server etc. Otherwise this will create an invalid profile and may cause unpredictable results.
mapi_ctx | pointer to the MAPI context |
profile_src | the source profile to duplicate from |
profile_dst | the destination profile to duplicate to |
username | the username to replace within the destination profile |
References CopyProfile(), mapi_provider::ctx, GetLastError(), GetProfileAttr(), mapi_session::mapi_ctx, mapi_errstr(), mapi_profile_delete_string_attr(), mapi_profile_modify_string_attr(), MAPIFreeBuffer(), MapiLogonProvider(), mapi_context::mem_ctx, mapi_session::nspi, nspi_GetMatches(), nspi_GetSpecialTable(), OPENCHANGE_RETVAL_IF, OpenProfile(), PR_ANR_UNICODE, PR_EMAIL_ADDRESS, PROVIDER_ID_NSPI, RES_PROPERTY, mapi_context::session, and set_SPropTagArray().
enum MAPISTATUS EmptyFolder | ( | mapi_object_t * | obj_folder) |
Empty the contents of a folder
This function empties (clears) the contents of a specified folder.
obj_folder | the folder to empty |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
struct emsmdb_info* emsmdb_get_info | ( | struct mapi_session * | session) |
Retrieves the EMSMDB context server information structure
session | pointer to the MAPI session context |
References mapi_provider::ctx, and mapi_session::emsmdb.
void emsmdb_get_SRowSet | ( | TALLOC_CTX * | mem_ctx, |
struct SRowSet * | rowset, | ||
struct SPropTagArray * | proptags, | ||
DATA_BLOB * | content | ||
) |
Get a SRowSet from a DATA blob
mem_ctx | pointer on the memory context |
rowset | pointer on the returned SRowSe |
proptags | pointer on a list of property tags to lookup |
content | pointer on the DATA blob content |
References free_emsmdb_property(), PT_ERROR, pull_emsmdb_property(), and set_SPropValue().
Referenced by ExpandRow(), FindRow(), and QueryRows().
NTSTATUS emsmdb_transaction | ( | struct emsmdb_context * | emsmdb_ctx, |
TALLOC_CTX * | mem_ctx, | ||
struct mapi_request * | req, | ||
struct mapi_response ** | repl | ||
) |
Make a EMSMDB transaction.
emsmdb_ctx | pointer to the EMSMDB connection context |
mem_ctx | pointer to the memory context |
req | pointer to the MAPI request to send |
repl | pointer on pointer to the MAPI reply returned by the server |
References emsmdb_context::cache_count, emsmdb_context::cache_requests, emsmdb_context::cache_size, emsmdb_context::handle, emsmdb_context::max_data, emsmdb_context::mem_ctx, emsmdb_context::rpc_connection, and emsmdb_context::setup.
Referenced by emsmdb_transaction_wrapper().
NTSTATUS emsmdb_transaction_ext2 | ( | struct emsmdb_context * | emsmdb_ctx, |
TALLOC_CTX * | mem_ctx, | ||
struct mapi_request * | req, | ||
struct mapi_response ** | repl | ||
) |
Make a EMSMDB EXT2 transaction.
emsmdb_ctx | pointer to the EMSMDB connection context |
mem_ctx | pointer to the memory context |
req | pointer to the MAPI request to send |
repl | pointer on pointer to the MAPI reply returned by the server |
References emsmdb_context::handle, and emsmdb_context::rpc_connection.
Referenced by emsmdb_transaction_wrapper().
NTSTATUS emsmdb_transaction_null | ( | struct emsmdb_context * | emsmdb_ctx, |
struct mapi_response ** | res | ||
) |
Send an empty MAPI packet - useful to keep connection up or force notifications.
emsmdb_ctx | pointer to the EMSMDB connection context |
res | pointer on pointer to a MAPI response structure |
References emsmdb_context::handle, MAPI_STATUS_IS_OK, emsmdb_context::max_data, emsmdb_context::mem_ctx, and emsmdb_context::rpc_connection.
Referenced by DispatchNotifications(), and MonitorNotification().
NTSTATUS emsmdb_transaction_wrapper | ( | struct mapi_session * | , |
TALLOC_CTX * | , | ||
struct mapi_request * | , | ||
struct mapi_response ** | |||
) |
References mapi_provider::ctx, mapi_session::emsmdb, emsmdb_transaction(), emsmdb_transaction_ext2(), mapi_profile::exchange_version, and mapi_session::profile.
Referenced by Abort(), AbortSubmit(), AddressTypes(), CloneStream(), CollapseRow(), CommitStream(), CopyFolder(), CopyProps(), CopyTo(), CopyToStream(), CreateAttach(), CreateBookmark(), CreateFolder(), CreateMessage(), DeleteAttach(), DeleteFolder(), DeleteMessage(), DeletePropertiesNoReplicate(), DeleteProps(), EmptyFolder(), ExpandRow(), FindRow(), FreeBookmark(), FXCopyFolder(), FXCopyMessages(), FXCopyProperties(), FXCopyTo(), FXDestConfigure(), FXGetBuffer(), FXPutBuffer(), GetAttachmentTable(), GetCollapseState(), GetContentsTable(), GetHierarchyTable(), GetIdFromLongTermId(), GetIDsFromNames(), GetLocalReplicaIds(), GetLongTermIdFromId(), GetMessageStatus(), GetNamesFromIDs(), GetOwningServers(), GetPermissionsTable(), GetPropList(), GetProps(), GetPropsAll(), GetReceiveFolder(), GetReceiveFolderTable(), GetRulesTable(), GetSearchCriteria(), GetStatus(), GetStoreState(), GetStreamSize(), GetTransportFolder(), GetValidAttach(), HardDeleteMessage(), HardDeleteMessagesAndSubfolders(), ICSSyncConfigure(), ICSSyncGetTransferState(), ICSSyncOpenCollector(), ICSSyncUploadStateBegin(), ICSSyncUploadStateContinue(), ICSSyncUploadStateEnd(), LockRegionStream(), ModifyPermissions(), ModifyRecipients(), MoveCopyMessages(), MoveFolder(), OpenAttach(), OpenEmbeddedMessage(), OpenFolder(), OpenMessage(), OpenPublicFolder(), OpenPublicFolderByName(), OpenStream(), OpenUserMailbox(), OptionsData(), PublicFolderIsGhosted(), QueryColumns(), QueryNamedProperties(), QueryPosition(), QueryRows(), ReadRecipients(), ReadStream(), Release(), ReloadCachedInformation(), RemoveAllRecipients(), Reset(), Restrict(), SaveChangesAttachment(), SaveChangesMessage(), SeekRow(), SeekRowApprox(), SeekRowBookmark(), SeekStream(), SetCollapseState(), SetColumns(), SetLocalReplicaMidsetDeleted(), SetMessageReadFlag(), SetMessageStatus(), SetPropertiesNoReplicate(), SetProps(), SetReadFlags(), SetReceiveFolder(), SetSearchCriteria(), SetSpooler(), SetStreamSize(), SetSyncNotificationGuid(), SortTable(), SpoolerLockMessage(), SubmitMessage(), Subscribe(), SyncOpenAdvisor(), TellVersion(), TransportNewMail(), TransportSend(), UnlockRegionStream(), WriteAndCommitStream(), and WriteStream().
enum MAPISTATUS EntryIDFromSourceIDForMessage | ( | TALLOC_CTX * | mem_ctx, |
mapi_object_t * | obj_store, | ||
mapi_object_t * | obj_folder, | ||
mapi_object_t * | obj_message, | ||
struct SBinary_short * | entryID | ||
) |
Build an EntryID for message from folder and message source ID
References get_SPropValue(), GetProps(), mapi_obj_store::guid, MAPIFreeBuffer(), OPENCHANGE_RETVAL_IF, PidTagSourceKey, mapi_object::private_data, PublicFolder, set_SPropTagArray(), and mapi_obj_store::store_type.
uint64_t exchange_globcnt | ( | uint64_t | globcnt) |
Inverts the bytes of a globcnt, such as for the ids returned by Exchange
Referenced by IDSET_dump(), IDSET_includes_eid(), and IDSET_includes_guid_glob().
enum MAPISTATUS ExpandRow | ( | mapi_object_t * | obj_table, |
uint64_t | categoryId, | ||
uint16_t | maxRows, | ||
struct SRowSet * | rowData, | ||
uint32_t * | expandedRowCount | ||
) |
Expand a collapsed row in a table
After a contents table has been sorted and categorized using SortTable, rows can be expanded and collapsed (using ExpandRow and CollapseRow repectively).
obj_table | the table we are collapsing the category in. |
categoryId | the row identification for the heading row for the category being expanded. |
maxRows | the maximum number of rows to retrieve (can be zero) |
rowData | (result) the data rows under this category heading |
expandedRowCount | (result) the number of rows that were added to the table when the row was expanded |
You obtain the categoryId argument from the PR_INST_ID property of the heading row for the category that is being collapsed.
The maxRows argument specifies the upper limit on how many rows to return (as rowData) when the category is expanded. The expandedRowCount argument returns the number of rows that were added to the table. As an example, consider a collapsed category with 8 entries. If you set maxRows to 3, then rowData will contain the data for the first three rows, and expandedRowCount will be set to 8. If you now use QueryRows(), you can read the 5 additional rows. If you'd specified maxRows as 8 (or more), rowData would have contained all 8 rows and expandedRowCount still would have been 8.
References emsmdb_get_SRowSet(), emsmdb_transaction_wrapper(), mapi_session::mapi_ctx, mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, OPENCHANGE_RETVAL_IF, mapi_object::private_data, and mapi_obj_table::proptags.
const void* find_mapi_SPropValue_data | ( | struct mapi_SPropValue_array * | , |
uint32_t | |||
) |
References get_mapi_SPropValue_data().
Referenced by get_mapi_SPropValue_array_date_timeval(), mapidump_appointment(), mapidump_contact(), mapidump_date(), mapidump_message(), mapidump_note(), and mapidump_task().
const void* find_PropertyValue_data | ( | struct PropertyRow_r * | , |
uint32_t | |||
) |
References get_PropertyValue_data().
Referenced by mapidump_PAB_entry(), ModifyUserPermission(), and RemoveUserPermission().
const void* find_SPropValue_data | ( | struct SRow * | , |
uint32_t | |||
) |
References get_SPropValue_data().
Referenced by GetBestBody(), IsFreeBusyConflict(), mapidump_message_summary(), and ModifyRecipients().
enum MAPISTATUS FindProfileAttr | ( | struct mapi_profile * | profile, |
const char * | attribute, | ||
const char * | value | ||
) |
Search the value of an attribute within a given profile
profile | pointer to the MAPI profile |
attribute | pointer to the attribute name |
value | pointer to the attribute value |
References mapi_context::ldb_ctx, mapi_profile::mapi_ctx, OPENCHANGE_RETVAL_IF, and mapi_profile::profname.
enum MAPISTATUS FindRow | ( | mapi_object_t * | obj_table, |
struct mapi_SRestriction * | res, | ||
enum BOOKMARK | bkOrigin, | ||
enum FindRow_ulFlags | ulFlags, | ||
struct SRowSet * | SRowSet | ||
) |
Find the next row in a table that matches specific search criteria
obj_table | the table we are searching in |
res | pointer on search criterias |
bkOrigin | bookmark identifying the row where FindRow should begin |
ulFlags | controls the direction of the search |
SRowSet | the resulting row |
bkOrigin can either take the value of a bookmark created with CreateBookmark or any of the default values:
ulFlags can be set either to DIR_FORWARD (0x0) or DIR_BACKWARD (0x1).
References emsmdb_get_SRowSet(), emsmdb_transaction_wrapper(), get_mapi_SRestriction_size(), mapi_session::mapi_ctx, mapi_object_bookmark_find(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, OPENCHANGE_RETVAL_IF, mapi_object::private_data, and mapi_obj_table::proptags.
Referenced by GetUserFreeBusyData().
enum MAPISTATUS FreeBookmark | ( | mapi_object_t * | obj_table, |
uint32_t | bkPosition | ||
) |
Release the resources associated with a bookmark
obj_table | the table the bookmark is associated to |
bkPosition | the bookmark to be freed |
References mapi_obj_bookmark::bin, mapi_obj_table::bk_last, mapi_obj_table::bookmark, emsmdb_transaction_wrapper(), mapi_obj_bookmark::index, mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), MAPIFreeBuffer(), mapi_obj_bookmark::next, OPENCHANGE_CHECK_NOTIFICATION, OPENCHANGE_RETVAL_IF, and mapi_object::private_data.
enum MAPISTATUS FXCopyFolder | ( | mapi_object_t * | obj, |
uint8_t | copyFlags, | ||
uint8_t | sendOptions, | ||
mapi_object_t * | obj_source_context | ||
) |
Prepare a server for Fast Transfer transmission of a folder hierachy
This function is used to configure a server for a fast-transfer folder hierachy send operation. This could be the origin server in a server->client->server copy, or for a server to client download.
This operation copies the folder object, and any sub-objects (including folder properties and messages). It can optionally copy sub-folders, depending on copyFlags.
obj | the source object for the operation (folder) |
copyFlags | flags that change the copy behaviour (see below) |
sendOptions | flags that change the format of the transfer (see FXCopyMessages) |
obj_source_context | the fast transfer source context for future ROPs |
copyflags can be zero or more of the following:
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), mapi_object_set_handle(), mapi_object_set_logon_id(), mapi_object_set_session(), and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS FXCopyMessages | ( | mapi_object_t * | obj, |
mapi_id_array_t * | message_ids, | ||
uint8_t | copyFlags, | ||
uint8_t | sendOptions, | ||
mapi_object_t * | obj_source_context | ||
) |
Prepare a server for Fast Transfer transmission of a list of messages
This function is used to configure a server for a fast-transfer message send operation. This could be the origin server in a server->client->server copy, or for a server to client download.
This operation copies the message objects, and any sub-objects (including attachments and embedded messages).
obj | the source object for the operation (folder) |
message_ids | the message IDs for the messages to copy. |
copyFlags | flags that change the copy behaviour (see below) |
sendOptions | flags that change the format of the transfer (see below) |
obj_source_context | the fast transfer source context for future ROPs |
copyflags can be zero or more of the following:
sendOptions can be zero or more of the following:
If the FastTransfer_ForUpload is set, the next call must be TellVersion()
References mapi_id_array::count, emsmdb_transaction_wrapper(), mapi_id_array_get(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), mapi_object_set_handle(), mapi_object_set_logon_id(), mapi_object_set_session(), and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS FXCopyProperties | ( | mapi_object_t * | obj, |
uint8_t | level, | ||
uint32_t | copyFlags, | ||
uint8_t | sendOptions, | ||
struct SPropTagArray * | properties, | ||
mapi_object_t * | obj_source_context | ||
) |
Prepare a server for Fast Transfer transmission of the properties of a folder, message or attachment
This function is used to configure a server for a fast-transfer download of properties. This could be the origin server in a server->client->server copy, or for a server to client download.
This operation copies the specified properties of the source object. It can optionally copy properties of sub-objects, depending on Level.
obj | the source object for the operation (folder, message or attachment) |
level | whether to copy properties of sub-objects of folders or messages (set to 0) or not (set to any other value) |
copyFlags | flags that change the copy behaviour (see below) |
sendOptions | flags that change the format of the transfer (see FXCopyMessages) |
properties | the list of properties to transfer |
obj_source_context | the fast transfer source context for future ROPs |
copyflags may be the following:
Be careful in setting level to something other than zero. In particular, if level is non-zero for a message, then the list of recipients, and any attachments or embedded messages, will not be transferred.
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), mapi_object_set_handle(), mapi_object_set_logon_id(), mapi_object_set_session(), and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS FXCopyTo | ( | mapi_object_t * | obj, |
uint8_t | level, | ||
uint32_t | copyFlags, | ||
uint8_t | sendOptions, | ||
struct SPropTagArray * | excludes, | ||
mapi_object_t * | obj_source_context | ||
) |
Prepare a server for Fast Transfer transmission of a folder, message or attachment
This function is used to configure a server for a fast-transfer download of a folder, message or attachment. This could be the origin server in a server->client->server copy, or for a server to client download.
This operation copies the source object, potentially omitting some properties. It can optionally copy sub-objects, depending on Level.
obj | the source object for the operation (folder, message or attachment) |
level | whether to copy sub-objects of folders or messages (set to 0) or not (set to any other value) |
copyFlags | flags that change the copy behaviour (see below) |
sendOptions | flags that change the format of the transfer (see FXCopyMessages) |
excludes | the list of properties to exclude from the transfer |
obj_source_context | the fast transfer source context for future ROPs |
copyflags can be zero or more of the following:
Be careful in setting level to something other than zero. In particular, if level is non-zero for a message, then the list of recipients, and any attachments or embedded messages, will not be transferred.
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), mapi_object_set_handle(), mapi_object_set_logon_id(), mapi_object_set_session(), and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS FXDestConfigure | ( | mapi_object_t * | obj, |
enum FastTransferDestConfig_SourceOperation | sourceOperation, | ||
mapi_object_t * | obj_destination_context | ||
) |
Prepare a server for Fast Transfer receive
This function is used to configure a server for fast-transfer receive operation. This could be the target server in a server->client->server copy, or for a client->server upload.
obj | the target object for the upload (folder, message or attachment) |
sourceOperation | the type of transfer (one of FastTransferDest_CopyTo, FastTransferDest_CopyProperties,FastTransferDest_CopyMessages or FastTransferDest_CopyFolder) |
obj_destination_context | the fast transfer context for future ROPs. |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), mapi_object_set_handle(), mapi_object_set_logon_id(), mapi_object_set_session(), and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS FXGetBuffer | ( | mapi_object_t * | obj_source_context, |
uint16_t | maxSize, | ||
enum TransferStatus * | transferStatus, | ||
uint16_t * | progressStepCount, | ||
uint16_t * | totalStepCount, | ||
DATA_BLOB * | blob | ||
) |
Get data from source fast transfer object.
Fast transfers are done in blocks, each block transfered over a call to FXGetBuffer. If the block is small, it will fit into a single call, and the transferStatus will indicate completion. However larger transfers will require multiple calls.
obj_source_context | the source object (from FXCopyTo, FXCopyProperties, FXCopyFolder or FXCopyMessages) |
maxSize | the maximum size (pass 0 to indicate maximum available size) |
transferStatus | result of the transfer |
progressStepCount | the approximate number of steps (of totalStepCount) completed |
totalStepCount | the approximate number of steps (total) |
blob | this part of the transfer |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), and OPENCHANGE_RETVAL_IF.
struct fx_parser_context* fxparser_init | ( | TALLOC_CTX * | mem_ctx, |
void * | priv | ||
) |
initialise a fast transfer parser
References fx_parser_context::data, fx_parser_context::idx, fx_parser_context::lpProp, fx_parser_context::mem_ctx, ParserState_Entry, fx_parser_context::priv, and fx_parser_context::state.
enum MAPISTATUS fxparser_parse | ( | struct fx_parser_context * | parser, |
DATA_BLOB * | fxbuf | ||
) |
parse a fast transfer buffer
References fx_parser_context::data, fx_parser_context::enough_data, fx_parser_context::idx, fx_parser_context::lpProp, fx_parser_context::mem_ctx, fx_parser_context::op_delprop, fx_parser_context::op_marker, fx_parser_context::op_property, ParserState_Entry, ParserState_HavePropTag, ParserState_HaveTag, PidTagEndAttach, PidTagEndEmbed, PidTagEndFolder, PidTagEndMessage, PidTagEndToRecip, PidTagFXDelProp, PidTagNewAttach, PidTagStartEmbed, PidTagStartFAIMsg, PidTagStartMessage, PidTagStartRecip, PidTagStartSubFld, PidTagStartTopFld, fx_parser_context::priv, fx_parser_context::state, and fx_parser_context::tag.
void fxparser_set_delprop_callback | ( | struct fx_parser_context * | parser, |
fxparser_delprop_callback_t | delprop_callback | ||
) |
set a callback function for delete properties output
References fx_parser_context::op_delprop.
void fxparser_set_marker_callback | ( | struct fx_parser_context * | parser, |
fxparser_marker_callback_t | marker_callback | ||
) |
set a callback function for marker output
References fx_parser_context::op_marker.
void fxparser_set_namedprop_callback | ( | struct fx_parser_context * | parser, |
fxparser_namedprop_callback_t | namedprop_callback | ||
) |
set a callback function for named properties output
References fx_parser_context::op_namedprop.
void fxparser_set_property_callback | ( | struct fx_parser_context * | parser, |
fxparser_property_callback_t | property_callback | ||
) |
set a callback function for property output
References fx_parser_context::op_property.
enum MAPISTATUS FXPutBuffer | ( | mapi_object_t * | obj_dest_context, |
DATA_BLOB * | blob, | ||
uint16_t * | usedSize | ||
) |
Send data to a destination fast transfer object.
Fast transfers are done in blocks, each block transfered over a call to FXGetBuffer. If the block is small, it will fit into a single call, and the transferStatus will indicate completion. However larger transfers will require multiple calls.
obj_dest_context | the destination object (from FXDestConfigure) |
blob | this part of the transfer |
usedSize | how many bytes of this part of the transfer that were used (only less than the total if an error occurred) |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), and OPENCHANGE_RETVAL_IF.
struct Binary_r* generate_recipient_entryid | ( | TALLOC_CTX * | , |
const char * | |||
) |
References guid_delete_dash().
struct AddressBookEntryId* get_AddressBookEntryId | ( | TALLOC_CTX * | mem_ctx, |
struct Binary_r * | bin | ||
) |
Retrieve a AddressBookEntryId structure from a binary blob
mem_ctx | pointer to the memory context |
bin | pointer to the Binary_r structure with raw AddressBookEntryId data |
struct AppointmentRecurrencePattern* get_AppointmentRecurrencePattern | ( | TALLOC_CTX * | mem_ctx, |
struct Binary_r * | |||
) |
struct FolderEntryId* get_FolderEntryId | ( | TALLOC_CTX * | mem_ctx, |
struct Binary_r * | bin | ||
) |
Retrieve a FolderEntryId structure from a binary blob
mem_ctx | pointer to the memory context |
bin | pointer to the Binary_r structure with raw FolderEntryId data |
struct GlobalObjectId* get_GlobalObjectId | ( | TALLOC_CTX * | mem_ctx, |
struct Binary_r * | bin | ||
) |
Retrieve a GlobalObjectId structure from a binary blob
mem_ctx | pointer to the memory context |
bin | pointer to the Binary_r structure with raw GlobalObjectId data |
const char* get_importance | ( | uint32_t | ) |
References IMPORTANCE_HIGH, IMPORTANCE_LOW, and IMPORTANCE_NORMAL.
Referenced by mapidump_task().
int get_interfaces_oc | ( | struct iface_struct * | , |
int | |||
) |
uint32_t get_mapi_property_size | ( | struct mapi_SPropValue * | ) |
References get_utf8_utf16_conv_length(), PT_BINARY, PT_BOOLEAN, PT_DOUBLE, PT_ERROR, PT_I2, PT_I8, PT_LONG, PT_STRING8, PT_SYSTIME, and PT_UNICODE.
Referenced by get_mapi_SRestriction_size(), and ModifyPermissions().
enum MAPISTATUS get_mapi_SPropValue_array_date_timeval | ( | struct timeval * | , |
struct mapi_SPropValue_array * | , | ||
uint32_t | |||
) |
References find_mapi_SPropValue_data().
const void* get_mapi_SPropValue_data | ( | struct mapi_SPropValue * | ) |
References PT_BINARY, PT_BOOLEAN, PT_DOUBLE, PT_ERROR, PT_I2, PT_I8, PT_LONG, PT_MV_BINARY, PT_MV_LONG, PT_MV_STRING8, PT_MV_UNICODE, PT_STRING8, PT_SYSTIME, and PT_UNICODE.
Referenced by find_mapi_SPropValue_data().
enum MAPISTATUS get_mapi_SPropValue_date_timeval | ( | struct timeval * | t, |
struct SPropValue | |||
) |
References get_SPropValue_data().
struct MessageEntryId* get_MessageEntryId | ( | TALLOC_CTX * | mem_ctx, |
struct Binary_r * | bin | ||
) |
Retrieve a MessageEntryId structure from a binary blob
mem_ctx | pointer to the memory context |
bin | pointer to the Binary_r structure with raw MessageEntryId data |
const char* get_namedid_name | ( | uint32_t | proptag) |
References mapi_nameid_names::propname, mapi_nameid_names::proptag, PT_MV_STRING8, and PT_STRING8.
uint16_t get_namedid_type | ( | uint16_t | untypedtag) |
References mapi_nameid_names::proptag, PT_ERROR, and PT_STRING8.
uint32_t get_namedid_value | ( | const char * | propname) |
References mapi_nameid_names::proptag.
uint16_t get_property_type | ( | uint16_t | untypedtag) |
References PT_ERROR, and PT_STRING8.
const void* get_PropertyValue | ( | struct PropertyValue_r * | , |
enum | MAPITAGS | ||
) |
References get_PropertyValue_data().
Referenced by get_PropertyValue_PropertyRowSet_data().
const void* get_PropertyValue_data | ( | struct PropertyValue_r * | ) |
References PT_BINARY, PT_BOOLEAN, PT_CLSID, PT_ERROR, PT_LONG, PT_MV_BINARY, PT_MV_LONG, PT_MV_SHORT, PT_MV_STRING8, PT_MV_SYSTIME, PT_MV_UNICODE, PT_NULL, PT_SHORT, PT_STRING8, PT_SVREID, PT_SYSTIME, and PT_UNICODE.
Referenced by AddUserPermission(), find_PropertyValue_data(), get_PropertyValue(), and PropertyRow_addprop().
struct PropertyValue_r* get_PropertyValue_PropertyRow | ( | struct PropertyRow_r * | , |
enum | MAPITAGS | ||
) |
struct PropertyValue_r* get_PropertyValue_PropertyRowSet | ( | struct PropertyRowSet_r * | , |
enum | MAPITAGS | ||
) |
Referenced by get_PropertyValue_PropertyRowSet_data(), and ProcessNetworkProfile().
const void* get_PropertyValue_PropertyRowSet_data | ( | struct PropertyRowSet_r * | , |
uint32_t | |||
) |
References get_PropertyValue(), and get_PropertyValue_PropertyRowSet().
Referenced by GetABRecipientInfo(), and GetUserFreeBusyData().
const char* get_proptag_name | ( | uint32_t | ) |
References PT_MV_STRING8, and PT_STRING8.
Referenced by mapidump_SPropTagArray(), mapidump_SPropValue(), and mapidump_tags().
uint32_t get_proptag_value | ( | const char * | ) |
struct PtypServerId* get_PtypServerId | ( | TALLOC_CTX * | mem_ctx, |
struct Binary_r * | bin | ||
) |
Retrieve a PtypServerId structure from a binary blob
mem_ctx | pointer to the memory context |
bin | pointer to the Binary_r structure with raw PtypServerId data |
struct RecurrencePattern* get_RecurrencePattern | ( | TALLOC_CTX * | mem_ctx, |
struct Binary_r * | bin | ||
) |
Retrieve a RecurrencePattern structure from a binary blob
mem_ctx | pointer to the memory context |
bin | pointer to the Binary_r structure with non-mapped reccurrence data |
const void* get_SPropValue | ( | struct SPropValue * | , |
enum | MAPITAGS | ||
) |
References get_SPropValue_data().
Referenced by EntryIDFromSourceIDForMessage(), get_SPropValue_SRow_data(), and get_SPropValue_SRowSet_data().
const void* get_SPropValue_data | ( | struct SPropValue * | ) |
References PT_BINARY, PT_BOOLEAN, PT_CLSID, PT_DOUBLE, PT_ERROR, PT_I8, PT_LONG, PT_MV_BINARY, PT_MV_LONG, PT_MV_SHORT, PT_MV_STRING8, PT_MV_SYSTIME, PT_MV_UNICODE, PT_NULL, PT_OBJECT, PT_SHORT, PT_STRING8, PT_SVREID, PT_SYSTIME, and PT_UNICODE.
Referenced by find_SPropValue_data(), get_mapi_SPropValue_date_timeval(), get_SPropValue(), mapidump_date_SPropValue(), mapidump_SPropValue(), and SRow_addprop().
struct SPropValue* get_SPropValue_SRow | ( | struct SRow * | , |
uint32_t | |||
) |
const void* get_SPropValue_SRow_data | ( | struct SRow * | , |
uint32_t | |||
) |
References get_SPropValue(), and get_SPropValue_SRow().
struct SPropValue* get_SPropValue_SRowSet | ( | struct SRowSet * | , |
uint32_t | |||
) |
Referenced by get_SPropValue_SRowSet_data().
const void* get_SPropValue_SRowSet_data | ( | struct SRowSet * | , |
uint32_t | |||
) |
References get_SPropValue(), and get_SPropValue_SRowSet().
Referenced by GetUserFreeBusyData().
const char* get_task_status | ( | uint32_t | ) |
References olTaskComplete, olTaskDeferred, olTaskInProgress, olTaskNotStarted, and olTaskWaiting.
Referenced by mapidump_appointment(), and mapidump_task().
struct TimeZoneStruct* get_TimeZoneStruct | ( | TALLOC_CTX * | mem_ctx, |
struct Binary_r * | bin | ||
) |
Retrieve a TimeZoneStruct structure from a binary blob
mem_ctx | pointer to the memory context |
bin | pointer to the Binary_r structure with raw TimeZoneStruct data |
const char* get_TypedString | ( | struct TypedString * | tstring) |
Return the effective value used in a TypedString structure.
tstring | pointer to TypedString structure |
Referenced by OpenMessage().
enum MAPISTATUS GetABRecipientInfo | ( | struct mapi_session * | session, |
const char * | username, | ||
struct SPropTagArray * | pPropTags, | ||
struct PropertyRowSet_r ** | ppRowSet | ||
) |
Retrieve Address Book information for a given recipient
session | pointer to the MAPI session context |
username | pointer to the username to retrieve information from |
pPropTags | pointer to the property tags array to lookup |
ppRowSet | pointer on pointer to the results |
Note that if pPropTags is NULL, then GetABNameInfo will fetch the following default property tags:
References mapi_provider::ctx, get_PropertyValue_PropertyRowSet_data(), MAPI_RESOLVED, MAPI_UNICODE, MAPIFreeBuffer(), nspi_context::mem_ctx, mapi_session::nspi, nspi_DNToMId(), nspi_GetProps(), OPENCHANGE_RETVAL_IF, PR_7BIT_DISPLAY_NAME_UNICODE, PR_ADDRTYPE_UNICODE, PR_DISPLAY_NAME_UNICODE, PR_DISPLAY_TYPE, PR_EMAIL_ADDRESS_UNICODE, PR_ENTRYID, PR_OBJECT_TYPE, PR_SEARCH_KEY, PR_SEND_INTERNET_ENCODING, PR_SEND_RICH_INFO, PR_SMTP_ADDRESS_UNICODE, PR_TRANSMITTABLE_DISPLAY_NAME_UNICODE, mapi_session::profile, ResolveNames(), and set_SPropTagArray().
Referenced by GetUserFreeBusyData().
enum MAPISTATUS GetAttachmentTable | ( | mapi_object_t * | obj_message, |
mapi_object_t * | obj_table | ||
) |
Retrieve the attachment table for a message
obj_message | the message |
obj_table | the attachment table for the message |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), mapi_object_set_handle(), mapi_object_set_logon_id(), mapi_object_set_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS GetBestBody | ( | mapi_object_t * | obj_message, |
uint8_t * | format | ||
) |
Implement the BestBody algorithm and return the best body content type for a given message.
obj_message | the message we find the best body for |
format | the format - see below. |
References find_SPropValue_data(), GetProps(), mapi_session::mapi_ctx, mapi_object_get_session(), MAPIFreeBuffer(), mapi_context::mem_ctx, olEditorHTML, olEditorRTF, olEditorText, OPENCHANGE_RETVAL_ERR, OPENCHANGE_RETVAL_IF, PR_BODY_ERROR, PR_BODY_HTML_ERROR, PR_BODY_UNICODE, PR_HTML, PR_RTF_COMPRESSED, PR_RTF_COMPRESSED_ERROR, PR_RTF_IN_SYNC, and set_SPropTagArray().
enum MAPISTATUS GetCollapseState | ( | mapi_object_t * | obj_table, |
uint64_t | rowId, | ||
uint32_t | rowInstanceNumber, | ||
struct SBinary_short * | CollapseState | ||
) |
Get the Collapse State of a Table
After a contents table has been sorted and categorized using SortTable, rows can be expanded and collapsed (using ExpandRow() and CollapseRow() repectively). You can save the state of the table using this function, and restore it using SetCollapseState.
obj_table | the table we are retrieving the state from |
rowId | the row number for the cursor |
rowInstanceNumber | the instance number for the cursor |
CollapseState | (result) the returned table Collapse State |
You obtain the row number and row instance number arguments from the PR_INST_ID and PR_INST_NUM properties of the row you want to use as the cursor.
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS GetContentsTable | ( | mapi_object_t * | obj_container, |
mapi_object_t * | obj_table, | ||
uint8_t | TableFlags, | ||
uint32_t * | RowCount | ||
) |
Returns a pointer to a container's table object
This function takes a pointer to a container object and returns a pointer to its associated contents
obj_container | the object to get the contents of |
obj_table | the resulting table containing the container's contents. |
TableFlags | flags controlling the type of table |
RowCount | the number of rows in the hierarchy table |
TableFlags possible values:
Developers can either set RowCount to a valid pointer on uint32_t or set it to NULL. In this last case, GetHierarchyTable won't return any value to the calling function.
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), mapi_object_set_handle(), mapi_object_set_logon_id(), mapi_object_set_session(), mapi_object_table_init(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
Referenced by GetUserFreeBusyData().
enum MAPISTATUS GetDefaultFolder | ( | mapi_object_t * | obj_store, |
uint64_t * | folder, | ||
const uint32_t | id | ||
) |
Retrieves the folder id for the specified default folder in a mailbox store
obj_store | the store to search |
id | the type of folder to search for |
folder | the resulting folder reference |
The following types of folders are supported:
Note that this function will cache FID values for common accessed folders such as calendar, contact, journal, note, task and drafts until the store object got released.
References mapi_obj_store::fid_calendar, mapi_obj_store::fid_common_views, mapi_obj_store::fid_contact, mapi_obj_store::fid_deleted_items, mapi_obj_store::fid_drafts, mapi_obj_store::fid_inbox, mapi_obj_store::fid_journal, mapi_obj_store::fid_mailbox_root, mapi_obj_store::fid_note, mapi_obj_store::fid_outbox, mapi_obj_store::fid_search, mapi_obj_store::fid_sent_items, mapi_obj_store::fid_task, mapi_obj_store::fid_top_information_store, olFolderCalendar, olFolderCommonView, olFolderContacts, olFolderDeletedItems, olFolderDrafts, olFolderFinder, olFolderInbox, olFolderJournal, olFolderMailboxRoot, olFolderNotes, olFolderOutbox, olFolderSentMail, olFolderTasks, olFolderTopInformationStore, OPENCHANGE_RETVAL_ERR, OPENCHANGE_RETVAL_IF, mapi_object::private_data, PrivateFolderWithoutCachedFids, and mapi_obj_store::store_type.
enum MAPISTATUS GetDefaultProfile | ( | struct mapi_context * | mapi_ctx, |
char ** | profname | ||
) |
Get the default profile from the database
mapi_ctx | pointer to the MAPI context |
profname | the result of the function (name of the default profile) |
References get_SPropValue_SRow(), GetProfileTable(), mapi_context::mem_ctx, OPENCHANGE_RETVAL_ERR, OPENCHANGE_RETVAL_IF, PR_DEFAULT_PROFILE, and PR_DISPLAY_NAME.
enum MAPISTATUS GetDefaultPublicFolder | ( | mapi_object_t * | obj_store, |
uint64_t * | folder, | ||
const uint32_t | id | ||
) |
Retrieve the folder id for the specified default folder in a public folder store
obj_store | the store to search |
id | the type of folder to search for |
folder | the resulting folder reference |
The following types of folders are supported:
References olFolderPublicEFormsRegistry, olFolderPublicEFormsRoot, olFolderPublicFreeBusyRoot, olFolderPublicIPMSubtree, olFolderPublicLocalFreeBusy, olFolderPublicLocalOfflineAB, olFolderPublicNNTPArticle, olFolderPublicNonIPMSubtree, olFolderPublicOfflineAB, olFolderPublicRoot, OPENCHANGE_RETVAL_ERR, OPENCHANGE_RETVAL_IF, and mapi_object::private_data.
Referenced by GetUserFreeBusyData().
enum MAPISTATUS GetFIDFromEntryID | ( | uint16_t | cb, |
uint8_t * | lpb, | ||
uint64_t | parent_fid, | ||
uint64_t * | fid | ||
) |
Create a FID from an EntryID
cb | count of lpb bytes |
lpb | pointer on an array of bytes |
parent_fid | the parent folder identifier |
fid | pointer to the returned fid |
References OPENCHANGE_RETVAL_IF.
enum MAPISTATUS GetFolderItemsCount | ( | mapi_object_t * | obj_folder, |
uint32_t * | unread, | ||
uint32_t * | total | ||
) |
Retrieves the total and unread number of items for a specified folder.
obj_folder | the folder to get item counts for |
unread | the number of items in the folder (result) |
total | the number of items in the folder, including unread items (result) |
References GetProps(), mapi_object_get_session(), MAPIFreeBuffer(), OPENCHANGE_RETVAL_IF, PR_CONTENT_COUNT, PR_CONTENT_UNREAD, and set_SPropTagArray().
int GetFreeBusyYear | ( | const uint32_t * | publish_start) |
Return the year associated with the FreeBusy start range
publish_start | pointer to the publish start integer |
Referenced by IsFreeBusyConflict().
enum MAPISTATUS GetGALTable | ( | struct mapi_session * | session, |
struct SPropTagArray * | SPropTagArray, | ||
struct PropertyRowSet_r ** | rowsetp, | ||
uint32_t | count, | ||
uint8_t | ulFlags | ||
) |
Retrieve the global address list
The Global Address List is the full list of email addresses (and other account-type things, such as "rooms" and distribution lists) accessible on the server. A user will usually have access to both a personal address book, and to the Global Address List. Public Address Book is another name for Global Address List.
You access the Global Address List by setting the list of things that you want to retrieve from the Global Address List as property names in the SPropTagArray argument, and then calling this function. The results are returned in SRowSet.
You can get a convenient output of the results using mapidump_PAB_entry() for each row returned.
session | pointer to the MAPI session context |
SPropTagArray | pointer to an array of MAPI properties we want to fetch |
SRowSet | pointer to the rows of the table returned |
count | the number of rows we want to fetch |
ulFlags | specify the table cursor location |
Possible value for ulFlags:
The Global Address List may be quite large (tens of thousands of entries in a large deployment), so you usually call this function with ulFlags set to TABLE_START the first time, and then subsequent calls will be made with TABLE_CUR to progress through the table.
References mapi_provider::ctx, nspi_context::mem_ctx, mapi_session::nspi, nspi_QueryRows(), OPENCHANGE_RETVAL_IF, nspi_context::pStat, and TABLE_START.
enum MAPISTATUS GetGALTableCount | ( | struct mapi_session * | session, |
uint32_t * | totalRecs | ||
) |
Retrieve the total number of records in the global address list
The Global Address List is the full list of email addresses (and other account-type things, such as "rooms" and distribution lists) accessible on the server. A user will usually have access to both a personal address book, and to the Global Address List. Public Address Book is another name for Global Address List.
session | pointer to the MAPI session context |
totalRecs | pointers to the total number of records in the global address list returned |
References mapi_provider::ctx, nspi_context::mem_ctx, mapi_session::nspi, nspi_QueryRows(), OPENCHANGE_RETVAL_IF, and nspi_context::pStat.
enum MAPISTATUS GetHierarchyTable | ( | mapi_object_t * | obj_container, |
mapi_object_t * | obj_table, | ||
uint8_t | TableFlags, | ||
uint32_t * | RowCount | ||
) |
Returns a pointer to a container's table object
This function takes a pointer to a container object and returns a pointer to its associated hierarchy table
obj_container | the object to get the contents of |
obj_table | the resulting table containing the container's hierarchy |
TableFlags | flags controlling the type of table |
RowCount | the number of rows in the hierarchy table |
TableFlags possible values:
Developers can either set RowCount to a valid pointer on uint32_t or set it to NULL. In this last case, GetHierarchyTable won't return any value to the calling function.
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), mapi_object_set_handle(), mapi_object_set_logon_id(), mapi_object_set_session(), mapi_object_table_init(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
Referenced by GetUserFreeBusyData().
enum MAPISTATUS GetIdFromLongTermId | ( | mapi_object_t * | obj, |
struct LongTermId | long_term_id, | ||
mapi_id_t * | id | ||
) |
Convert an Long Term Id into an Id
The function looks up the Id for a specified Long Term Id value.
obj | the object to look up on |
long_term_id | the id to look up |
id | the id returned by the server |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS GetIDsFromNames | ( | mapi_object_t * | obj, |
uint16_t | count, | ||
struct MAPINAMEID * | nameid, | ||
uint32_t | ulFlags, | ||
struct SPropTagArray ** | proptags | ||
) |
Provides the property identifiers that correspond to one or more property names.
obj | the object we are retrieving the identifiers from |
count | count of property names pointed to by the nameid parameter. |
nameid | pointer to an array of property names |
ulFlags | indicates how the property identifiers should be returned |
proptags | pointer to a pointer to an array of property tags containing existing or newly assigned property identifiers. Property types in this array are set to PT_NULL. |
ulFlags can be set to:
References emsmdb_transaction_wrapper(), get_utf8_utf16_conv_length(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, OPENCHANGE_RETVAL_IF, and PT_UNSPECIFIED.
Referenced by GetProps(), mapi_nameid_GetIDsFromNames(), SetPropertiesNoReplicate(), and SetProps().
enum MAPISTATUS GetLastError | ( | void | ) |
Returns the latest error code.
This function returns the error code set by a previous function call.
Referenced by DuplicateProfile(), mapi_nameid_GetIDsFromNames(), OpenMsgStore(), and WrapCompressedRTFStream().
enum MAPISTATUS GetLoadparmContext | ( | struct mapi_context * | mapi_ctx, |
struct loadparm_context ** | lp_ctx | ||
) |
Retrieve the MAPI loadparm context for specified MAPI context
mapi_ctx | pointer to the MAPI context |
lp_ctx | pointer to a pointer to the loadparm context that the function returns |
References mapi_context::lp_ctx, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS GetLocalReplicaIds | ( | mapi_object_t * | obj_store, |
uint32_t | IdCount, | ||
struct GUID * | ReplGuid, | ||
uint8_t | GlobalCount[6] | ||
) |
Reserves a range of IDs to be used by a local replica
obj_store | pointer on the store MAPI object |
IdCount | ID range length to reserve |
ReplGuid | pointer to the GUID structure returned by the server |
GlobalCount | byte array that specifies the first allocated field |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS GetLongTermIdFromId | ( | mapi_object_t * | obj, |
mapi_id_t | id, | ||
struct LongTermId * | long_term_id | ||
) |
Convert an ID to a Long Term Id
The function looks up the Long Term Id for a specified ID value.
obj | the object to look up on |
id | the id to look up |
long_term_id | the long term ID returned from the server |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS GetMessageStatus | ( | mapi_object_t * | obj_folder, |
mapi_id_t | msgid, | ||
uint32_t * | ulStatus | ||
) |
Obtain the status associated with a message
This function obtains the status associated with a message in the given folder.
obj_folder | the folder where the message is located |
msgid | the message ID |
ulStatus | the message status |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS GetNamesFromIDs | ( | mapi_object_t * | obj, |
enum MAPITAGS | ulPropTag, | ||
uint16_t * | count, | ||
struct MAPINAMEID ** | nameid | ||
) |
Provides the property names that correspond to one or more property identifiers.
obj | the object we are retrieving the names from |
ulPropTag | the mapped property tag |
count | count of property names pointed to by the nameid parameter returned by the server |
nameid | pointer to a pointer to property names returned by the server |
ulPropTag must be a property with type set to PT_NULL
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
Referenced by mapi_SPropValue_array_named().
enum MAPISTATUS GetOutboxFolder | ( | mapi_object_t * | obj_store, |
mapi_id_t * | outbox_id | ||
) |
Retrieves the sending folder (OUTBOX) for a given store
This function obtains the folder that was established as the destination for outgoing messages of a specified message class.
This function does not result in any network traffic.
obj_store | the store to get the outbox folder for |
outbox_id | the resulting folder identification |
References OPENCHANGE_RETVAL_IF, and mapi_object::private_data.
enum MAPISTATUS GetOwningServers | ( | mapi_object_t * | obj_store, |
mapi_object_t * | obj_folder, | ||
uint16_t * | OwningServersCount, | ||
uint16_t * | CheapServersCount, | ||
char ** | OwningServers | ||
) |
Get the list of servers that host replicas of a given public folder.
obj_store | the public folder store object |
obj_folder | the folder object we search replica for |
OwningServersCount | number of OwningServers |
CheapServersCount | number of low-cost servers |
OwningServers | pointer on the list of NULL terminated ASCII string representing replica servers |
Developers may also call GetLastError() to retrieve the last MAPI error code. Possible MAPI error codes are:
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_id(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS GetPermissionsTable | ( | mapi_object_t * | obj_container, |
uint8_t | flags, | ||
mapi_object_t * | obj_table | ||
) |
Returns a pointer to the permission's table object.
This function takes a pointer to a container object and returns a pointer to its associated permission table
obj_container | the object to get the contents of |
flags | any special flags to pass |
obj_table | the resulting table containing the container's permissions |
The only meaningful value for flags is IncludeFreeBusy (0x02). This should be set when getting permissions on the Calendar folder when using Exchange 2007 and later. It should not be set in other situations.
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), mapi_object_set_handle(), mapi_object_set_logon_id(), mapi_object_set_session(), mapi_object_table_init(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
Referenced by ModifyUserPermission(), and RemoveUserPermission().
enum MAPISTATUS GetProfileAttr | ( | struct mapi_profile * | profile, |
const char * | attribute, | ||
unsigned int * | count, | ||
char *** | value | ||
) |
Retrieve attribute values from a profile
This function retrieves all the attribute values from the given profile. The number of results is stored in count and values are stored in an allocated string array in the value parameter that needs to be free'd using MAPIFreeBuffer().
profile | the name of the profile to retrieve attributes from |
attribute | the attribute(s) to search for |
count | the number of results |
value | the resulting values |
References mapi_context::ldb_ctx, mapi_profile::mapi_ctx, OPENCHANGE_RETVAL_IF, and mapi_profile::profname.
Referenced by DuplicateProfile().
enum MAPISTATUS GetProfileTable | ( | struct mapi_context * | mapi_ctx, |
struct SRowSet * | proftable | ||
) |
Retrieve the profile table
This function retrieves the profile table. Two fields are returned:
mapi_ctx | pointer to the MAPI context |
proftable | the result of the call |
References mapi_context::ldb_ctx, mapi_context::mem_ctx, OPENCHANGE_RETVAL_IF, PR_DEFAULT_PROFILE, and PR_DISPLAY_NAME.
Referenced by GetDefaultProfile(), and RenameProfile().
enum MAPISTATUS GetPropList | ( | mapi_object_t * | obj, |
struct SPropTagArray * | proptags | ||
) |
Retrieve all the properties associated with a given object
obj | the object to retrieve properties for |
proptags | the resulting list of properties associated with the object |
MAPI_E_CALL_FAILED: A network problem was encountered during the transaction
The developer MUST provide an allocated SPropTagArray structure to the function.
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS GetProps | ( | mapi_object_t * | obj, |
uint32_t | flags, | ||
struct SPropTagArray * | SPropTagArray, | ||
struct SPropValue ** | lpProps, | ||
uint32_t * | PropCount | ||
) |
Returns values of one or more properties for an object
The function takes a pointer on the object obj, a MAPITAGS array specified in mapitags, and the count of properties. The function returns associated values within the SPropValue values pointer.
The array of MAPI property tags can be filled with both known and named properties.
obj | the object to get properties on |
flags | Flags for behaviour; can be bit-OR of MAPI_UNICODE and MAPI_PROPS_SKIP_NAMEDID_CHECK constants |
SPropTagArray | an array of MAPI property tags |
lpProps | the result of the query |
PropCount | the count of property tags |
References mapi_nameid::count, emsmdb_get_SPropValue(), emsmdb_transaction_wrapper(), GetIDsFromNames(), mapi_session::mapi_ctx, mapi_nameid_lookup_SPropTagArray(), mapi_nameid_map_SPropTagArray(), mapi_nameid_new(), mapi_nameid_unmap_SPropTagArray(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), MAPI_PROPS_SKIP_NAMEDID_CHECK, MAPI_UNICODE, MAPIFreeBuffer(), mapi_nameid::nameid, OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
Referenced by EntryIDFromSourceIDForMessage(), GetBestBody(), GetFolderItemsCount(), and GetUserFreeBusyData().
enum MAPISTATUS GetPropsAll | ( | mapi_object_t * | obj, |
uint32_t | flags, | ||
struct mapi_SPropValue_array * | properties | ||
) |
Retrieve all properties and values associated with an object
This function returns all the properties and and associated values for a given object.
obj | the object to get the properties for |
flags | Flags for behaviour; can be a MAPI_UNICODE constant |
properties | the properties / values for the object |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), MAPI_UNICODE, OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS GetReceiveFolder | ( | mapi_object_t * | obj_store, |
mapi_id_t * | id_folder, | ||
const char * | MessageClass | ||
) |
Gets the receive folder for incoming messages of a particular message class.
This function obtains the folder that was established as the destination for incoming messages of a specified message class, or the default receive folder for the message store.
obj_store | the store to get the receiver folder for |
id_folder | the resulting folder identification |
MessageClass | which message class to find the receivefolder for |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS GetReceiveFolderTable | ( | mapi_object_t * | obj_store, |
struct SRowSet * | SRowSet | ||
) |
Retrieve the receive folder table which includes all the information about the receive folders for the message store
obj_store | the message store object |
SRowSet | pointer on a SRowSet structure with GetReceiveFolderTable results. |
Developers are required to call MAPIFreeBuffer(SRowSet.aRow) when they don't need the folder table data anymore.
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, OPENCHANGE_RETVAL_IF, PR_FID, PR_LAST_MODIFICATION_TIME, and PR_MESSAGE_CLASS.
enum MAPISTATUS GetRecipientTable | ( | mapi_object_t * | obj_message, |
struct SRowSet * | SRowSet, | ||
struct SPropTagArray * | SPropTagArray | ||
) |
Returns the message recipient table
obj_message | the message to receive recipients from |
SRowSet | pointer to the recipient table |
SPropTagArray | pointer to the array of properties listed in the recipient table |
References OPENCHANGE_RETVAL_IF, mapi_object::private_data, mapi_obj_message::SPropTagArray, and mapi_obj_message::SRowSet.
enum MAPISTATUS GetRulesTable | ( | mapi_object_t * | obj_folder, |
mapi_object_t * | obj_table, | ||
uint8_t | TableFlags | ||
) |
Gets the rules table of a folder
obj_folder | the folder we want to retrieve the rules table from |
obj_table | the rules table |
TableFlags | bitmask associated to the rules table |
Possible values for TableFlags:
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), mapi_object_set_handle(), mapi_object_set_logon_id(), mapi_object_set_session(), mapi_object_table_init(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS GetSearchCriteria | ( | mapi_object_t * | obj_container, |
struct mapi_SRestriction * | res, | ||
uint32_t * | SearchFlags, | ||
uint16_t * | FolderIdCount, | ||
uint64_t ** | FolderIds | ||
) |
Obtains the search criteria for a container
obj_container | the object we retrieve search criteria from |
res | pointer to a mapi_SRestriction structure defining the search criteria |
SearchFlags | bitmask of flags that controls how the search is performed |
FolderIdCount | number of FolderIds entries |
FolderIds | pointer to a list of identifiers representing containers included in the search |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS GetStatus | ( | mapi_object_t * | obj_table, |
uint8_t * | TableStatus | ||
) |
Get the status of a table
obj_table | the table we are retrieving the status from |
TableStatus | the table status result |
TableStatus can either hold:
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS GetStoreState | ( | mapi_object_t * | obj_store, |
uint32_t * | StoreState | ||
) |
Gets the current store state for the logged in user
This operation must be performed against a user store (not against a Public Folder store). The StoreState will have the STORE_HAS_SEARCHES flag set if there are any active search folders. There are (currently) no other flags in the StoreState.
obj_store | the store object |
StoreState | pointer to the store state returned by the server |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS GetStreamSize | ( | mapi_object_t * | obj_stream, |
uint32_t * | StreamSize | ||
) |
Gets the size of a stream
obj_stream | the stream object we retrieve size from |
StreamSize | pointer on the stream size |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS GetTransportFolder | ( | mapi_object_t * | obj_store, |
mapi_id_t * | FolderId | ||
) |
Retrieves the folder ID of the temporary transport folder.
obj_store | the server object |
FolderId | pointer on the returning Folder identifier |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS GetUserFreeBusyData | ( | mapi_object_t * | obj_store, |
const char * | recipient, | ||
struct SRow * | pSRow | ||
) |
Retrieve FreeBusy data associated with the specified recipient
obj_store | pointer to the public folder MAPI object |
recipient | name of the recipient to fetch freebusy data |
pSRow | pointer to the returned properties |
References FindRow(), FREEBUSY_FOLDER, FREEBUSY_USER, get_PropertyValue_PropertyRowSet_data(), get_SPropValue_SRowSet_data(), GetABRecipientInfo(), GetContentsTable(), GetDefaultPublicFolder(), GetHierarchyTable(), GetProps(), mapi_object_get_session(), mapi_object_init(), mapi_object_release(), MAPIFreeBuffer(), olFolderPublicFreeBusyRoot, OPENCHANGE_RETVAL_IF, OpenFolder(), OpenMessage(), ORG, ORG_UNIT, PR_ADDRBOOK_MID, PR_DISPLAY_NAME, PR_EMAIL_ADDRESS_UNICODE, PR_FID, PR_FREEBUSY_PUBLISH_END, PR_FREEBUSY_PUBLISH_START, PR_FREEBUSY_RANGE_TIMESTAMP, PR_INSTANCE_NUM, PR_MID, PR_NORMALIZED_SUBJECT, PR_SCHDINFO_FREEBUSY_BUSY, PR_SCHDINFO_FREEBUSY_MERGED, PR_SCHDINFO_FREEBUSY_OOF, PR_SCHDINFO_FREEBUSY_TENTATIVE, PR_SCHDINFO_MONTHS_BUSY, PR_SCHDINFO_MONTHS_MERGED, PR_SCHDINFO_MONTHS_OOF, PR_SCHDINFO_MONTHS_TENTATIVE, RES_PROPERTY, set_SPropTagArray(), SetColumns(), SortTable(), and x500_get_dn_element().
Referenced by IsFreeBusyConflict().
enum MAPISTATUS GetValidAttach | ( | mapi_object_t * | obj_message, |
uint16_t * | NumAttachments, | ||
uint32_t ** | AttachmentIds | ||
) |
Get the valid attachment IDs for a message
This function returns the list of valid attachment IDs for a message. You can then use these IDs with the OpenAttach and DeleteAttach functions.
obj_message | the message to operate on |
NumAttachments | the number of attachments for the message |
AttachmentIds | array of attachment Ids |
The AttachmentIds array has NumAttachments elements.
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
struct globset_range* GLOBSET_parse | ( | TALLOC_CTX * | mem_ctx, |
DATA_BLOB | buffer, | ||
uint32_t * | countP, | ||
uint32_t * | byte_countP | ||
) |
deserialize a GLOBSET following the format described in [OXCFXICS - 2.2.2.5]
References globset_range::next.
Referenced by IDSET_parse().
char* guid_delete_dash | ( | TALLOC_CTX * | , |
const char * | |||
) |
Referenced by generate_recipient_entryid().
enum MAPISTATUS HardDeleteMessage | ( | mapi_object_t * | obj_folder, |
mapi_id_t * | id_messages, | ||
uint16_t | cn_messages | ||
) |
Hard delete one or more messages
This function hard deletes one or more messages based on their ids from a specified folder.
obj_folder | the folder to hard delete messages from |
id_messages | the list of ids |
cn_messages | the number of messages in the id list. |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS HardDeleteMessagesAndSubfolders | ( | mapi_object_t * | obj_folder) |
Hard delete the contents of a folder, including subfolders
This function empties (clears) the contents of a specified folder.
obj_folder | the folder to empty |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS ICSSyncConfigure | ( | mapi_object_t * | obj, |
enum SynchronizationType | sync_type, | ||
uint8_t | send_options, | ||
uint16_t | sync_flags, | ||
uint32_t | sync_extraflags, | ||
DATA_BLOB | restriction, | ||
struct SPropTagArray * | property_tags, | ||
mapi_object_t * | obj_sync_context | ||
) |
Prepare a server for ICS download
This function is used to configure a server for ICS (Incremental Change Synchronization) download. You use the synchronization context handle for other ICS and Fast Transfer operations.
obj | the target object for the upload (folder) |
sync_type | the type of synchronization that will be performed (just folder contents, or whole folder hierachy) |
send_options | flags that change the format of the transfer (see FXCopyMessages) |
sync_flags | flags that change the behavior of the transfer (see below) |
sync_extraflags | additional flags that change the behavior of the transfer (see below) |
restriction | a Restriction structure to limit downloads (only for sync_type == SynchronizationType_Content) |
property_tags | the properties to exclude (or include, if SynchronizationFlag_OnlySpecifiedProperties flag is set) in the download |
obj_sync_context | the resulting synchronization context handle |
sync_flags can be zero or more of the following:
sync_extraflags can be zero or more of the following:
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), mapi_object_set_handle(), mapi_object_set_logon_id(), mapi_object_set_session(), and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS ICSSyncGetTransferState | ( | mapi_object_t * | obj, |
mapi_object_t * | obj_sync_context | ||
) |
obtain an object to get the sync transfer state
obj | the source object |
obj_sync_context | the synchronization transfer state object |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), mapi_object_set_handle(), mapi_object_set_logon_id(), mapi_object_set_session(), and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS ICSSyncOpenCollector | ( | mapi_object_t * | folder, |
bool | isContentsCollector, | ||
mapi_object_t * | obj_collector | ||
) |
Prepare a folder for ICS upload
folder | the folder for the collector creation |
isContentsCollector | true for contents collector, false for hierachy collector |
obj_collector | pointer to the resulting ICS collector |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), mapi_object_set_handle(), mapi_object_set_logon_id(), mapi_object_set_session(), and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS ICSSyncUploadStateBegin | ( | mapi_object_t * | obj_sync_context, |
enum StateProperty | state_property, | ||
uint32_t | length | ||
) |
Initialize an ICS Initial State upload.
This is one of three operations (along with ICSSyncUploadStateContinue and ICSSyncUploadStateEnd) used to send the initial state for an ICS download to the server.
obj_sync_context | the synchronization context (from ICSSyncConfigure) |
state_property | the type of ICS state that will be uploaded (see below) |
length | the length (in bytes) of the ICS state that will be uploaded |
state_property can be one of the following:
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS ICSSyncUploadStateContinue | ( | mapi_object_t * | obj_sync_context, |
DATA_BLOB | state | ||
) |
Send data for an ICS Initial State upload.
This is one of three operations (along with ICSSyncUploadStateBegin and ICSSyncUploadStateEnd) used to send the initial state for an ICS download to the server.
obj_sync_context | the synchronization context (from ICSSyncConfigure) |
state | the state data for this part of the upload |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS ICSSyncUploadStateEnd | ( | mapi_object_t * | obj_sync_context) |
Signal completion of an ICS Initial State upload.
This is one of three operations (along with ICSSyncUploadStateBegin and ICSSyncUploadStateContinue) used to send the initial state for an ICS download to the server.
obj_sync_context | the synchronization context (from ICSSyncConfigure) |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), and OPENCHANGE_RETVAL_IF.
void IDSET_dump | ( | const struct idset * | idset, |
const char * | label | ||
) |
dump an idset structure
References exchange_globcnt(), idset::guid, globset_range::high, idset::id, idset::idbased, globset_range::low, idset::next, globset_range::next, idset::range_count, idset::ranges, and idset::repl.
Referenced by IDSET_parse().
bool IDSET_includes_eid | ( | const struct idset * | idset, |
uint64_t | eid | ||
) |
tests the presence of a specific id in the ranges of a ReplID-based idset structure
References exchange_globcnt(), globset_range::high, idset::id, idset::idbased, globset_range::low, idset::next, globset_range::next, idset::ranges, and idset::repl.
bool IDSET_includes_guid_glob | ( | const struct idset * | idset, |
struct GUID * | replica_guid, | ||
uint64_t | id | ||
) |
tests the presence of a specific id in the ranges of a ReplGUID-based idset structure
References exchange_globcnt(), idset::guid, globset_range::high, idset::idbased, globset_range::low, idset::next, globset_range::next, idset::ranges, and idset::repl.
struct idset* IDSET_merge_idsets | ( | TALLOC_CTX * | mem_ctx, |
const struct idset * | left, | ||
const struct idset * | right | ||
) |
merge two idsets structures into a third one
References idset::guid, idset::id, idset::idbased, idset::next, globset_range::next, globset_range::prev, idset::range_count, idset::ranges, and idset::repl.
struct idset* IDSET_parse | ( | TALLOC_CTX * | mem_ctx, |
DATA_BLOB | buffer, | ||
bool | idbased | ||
) |
deserialize an IDSET following the format described in [OXCFXICS - 2.2.2.4]
References GLOBSET_parse(), idset::guid, idset::id, IDSET_dump(), idset::next, idset::range_count, idset::ranges, and idset::repl.
struct Binary_r* IDSET_serialize | ( | TALLOC_CTX * | mem_ctx, |
const struct idset * | idset | ||
) |
serialize an idset structure in a struct SBinary_r
References idset::guid, idset::id, idset::idbased, idset::next, globset_range::next, idset::ranges, and idset::repl.
Referenced by ndr_push_idset().
enum MAPISTATUS IsFreeBusyConflict | ( | mapi_object_t * | obj_store, |
struct FILETIME * | date, | ||
bool * | conflict | ||
) |
Check if a date conflicts with existing FreeBusy Busy/Out Of Office events
obj_store | pointer to the public folder MAPI object |
date | pointer to the date to check |
conflict | pointer to the returned boolean value |
References find_SPropValue_data(), GetFreeBusyYear(), GetUserFreeBusyData(), mapi_object_get_session(), OPENCHANGE_RETVAL_IF, PR_FREEBUSY_PUBLISH_START, PR_SCHDINFO_FREEBUSY_MERGED, PR_SCHDINFO_MONTHS_MERGED, mapi_session::profile, and mapi_profile::username.
bool IsMailboxFolder | ( | mapi_object_t * | obj_store, |
uint64_t | fid, | ||
uint32_t * | olFolder | ||
) |
Check if a given folder identifier matches with a system/default one and optionally returns the olFolder type
obj_store | pointer to the store object |
fid | reference to the folder identifier to check |
olFolder | pointer to the returned olFolder |
References mapi_obj_store::fid_calendar, mapi_obj_store::fid_common_views, mapi_obj_store::fid_contact, mapi_obj_store::fid_deleted_items, mapi_obj_store::fid_drafts, mapi_obj_store::fid_inbox, mapi_obj_store::fid_journal, mapi_obj_store::fid_note, mapi_obj_store::fid_outbox, mapi_obj_store::fid_pf_EFormsRegistry, mapi_obj_store::fid_pf_EFormsRegistryRoot, mapi_obj_store::fid_pf_FreeBusyRoot, mapi_obj_store::fid_pf_ipm_subtree, mapi_obj_store::fid_pf_LocalSiteFreeBusy, mapi_obj_store::fid_pf_LocalSiteOfflineAB, mapi_obj_store::fid_pf_NNTPArticle, mapi_obj_store::fid_pf_non_ipm_subtree, mapi_obj_store::fid_pf_OfflineAB, mapi_obj_store::fid_pf_public_root, mapi_obj_store::fid_search, mapi_obj_store::fid_sent_items, mapi_obj_store::fid_task, mapi_obj_store::fid_top_information_store, olFolderCalendar, olFolderCommonView, olFolderContacts, olFolderDeletedItems, olFolderDrafts, olFolderFinder, olFolderInbox, olFolderJournal, olFolderNotes, olFolderOutbox, olFolderPublicEFormsRegistry, olFolderPublicEFormsRoot, olFolderPublicFreeBusyRoot, olFolderPublicIPMSubtree, olFolderPublicLocalFreeBusy, olFolderPublicLocalOfflineAB, olFolderPublicNNTPArticle, olFolderPublicNonIPMSubtree, olFolderPublicOfflineAB, olFolderPublicRoot, olFolderSentMail, olFolderTasks, olFolderTopInformationStore, mapi_object::private_data, PrivateFolderWithoutCachedFids, and mapi_obj_store::store_type.
enum MAPISTATUS LoadProfile | ( | struct mapi_context * | mapi_ctx, |
struct mapi_profile * | profile | ||
) |
Load a MAPI Profile and sets its credentials
This function loads a named MAPI profile and sets the MAPI session credentials.
mapi_ctx | pointer to the MAPI context |
profile | pointer to the MAPI profile |
References mapi_profile::credentials, mapi_profile::domain, mapi_profile::kerberos, mapi_context::lp_ctx, OPENCHANGE_RETVAL_IF, mapi_profile::password, mapi_profile::realm, mapi_context::session, mapi_profile::username, and mapi_profile::workstation.
Referenced by MapiLogonProvider().
enum MAPISTATUS LockRegionStream | ( | mapi_object_t * | obj_stream, |
uint64_t | RegionOffset, | ||
uint64_t | RegionSize, | ||
uint32_t | LockFlags | ||
) |
Lock a range of bytes within the stream
obj_stream | the stream object |
RegionOffset | starting point for the range |
RegionSize | length of the range |
LockFlags | type of locking to apply |
Setting LockFlags to 0x00000001 will provide a write lock (i.e. one writer, any number of readers). Setting LockFlags to any other value will provide a read-write lock (one reader/writer, no other readers or writers).
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS Logoff | ( | mapi_object_t * | obj_store) |
Logoff an Exchange store
This function uninitializes the MAPI session associated to the object.
obj_store | pointer to the store object |
References mapi_session::mapi_ctx, mapi_object_get_session(), mapi_object_release(), MAPIFreeBuffer(), mapi_session::next, OPENCHANGE_RETVAL_IF, and mapi_context::session.
void mapi_copy_spropvalues | ( | TALLOC_CTX * | mem_ctx, |
struct SPropValue * | source_values, | ||
struct SPropValue * | dest_values, | ||
uint32_t | count | ||
) |
Convenience function to copy an array of struct SPropValue or a part thereof into another array, by duplicating and properly parenting pointer data. The destination array is considered to be preallocated.
References MV_FLAG, PT_BINARY, PT_STRING8, and PT_UNICODE.
void mapi_errstr | ( | const char * | , |
enum | MAPISTATUS | ||
) |
Referenced by DuplicateProfile(), emsmdb_connect(), and emsmdb_connect_ex().
uint32_t mapi_get_cpid_from_language | ( | const char * | language) |
Return codepage associated to specified language
language | The language string to lookup |
uint32_t mapi_get_cpid_from_lcid | ( | uint32_t | lcid) |
Returns codepage for a given LCID (Locale ID)
lcid | the locale ID to lookup |
uint32_t mapi_get_cpid_from_locale | ( | const char * | locale) |
Return codepage associated to specified locale
locale | The locale string to lookup |
const char* mapi_get_errstr | ( | enum | MAPISTATUS) |
char** mapi_get_language_from_group | ( | TALLOC_CTX * | mem_ctx, |
uint32_t | group | ||
) |
Returns List of languages for a given Language Group
mem_ctx | pointer to the memory context |
group | the locale group to lookup |
const char* mapi_get_language_from_lcid | ( | uint32_t | lcid) |
Returns Language for a given Locale ID
lcid | the locale ID to lookup |
const char* mapi_get_language_from_locale | ( | const char * | locale) |
Returns Language for a given Locale
locale | the language string to lookup |
uint32_t mapi_get_lcid_from_language | ( | const char * | language) |
Returns LCID (Locale ID) for a given language
language | the language string to lookup |
uint32_t mapi_get_lcid_from_locale | ( | const char * | locale) |
Returns LCID (Locale ID) for a given locale
locale | the locale string to lookup |
const char* mapi_get_locale_from_language | ( | const char * | language) |
Returns Locale for a given language
language | the language string to lookup |
const char* mapi_get_locale_from_lcid | ( | uint32_t | lcid) |
Returns Locale for a given Locale ID
lcid | the locale ID to lookup |
char* mapi_get_system_locale | ( | void | ) |
Returns current locale used by the system
enum MAPISTATUS mapi_id_array_add_id | ( | mapi_id_array_t * | id, |
mapi_id_t | fid | ||
) |
Add a container ID to the list given its container ID
id | pointer to a mapi_id_array structure |
fid | the container ID |
References mapi_container_list::id, mapi_id_array::lpContainerList, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS mapi_id_array_add_obj | ( | mapi_id_array_t * | id, |
mapi_object_t * | obj | ||
) |
Add a container ID to the list given its mapi_object_t
id | pointer to a mapi_id_array structure |
obj | pointer on the mapi object we retrieve the container ID from |
References mapi_container_list::id, mapi_id_array::lpContainerList, mapi_object_get_id(), and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS mapi_id_array_del_id | ( | mapi_id_array_t * | id, |
mapi_id_t | fid | ||
) |
Delete a container ID from the list given its container ID
id | pointer to a mapi_id_array structure |
fid | the container ID |
References mapi_id_array::count, mapi_container_list::id, mapi_id_array::lpContainerList, mapi_container_list::next, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS mapi_id_array_del_obj | ( | mapi_id_array_t * | id, |
mapi_object_t * | obj | ||
) |
Delete a container ID from the list given its mapi_object_t
id | pointer to a mapi_id_array structure |
obj | pointer on the mapi object we retrieve the container ID from |
References mapi_id_array::count, mapi_container_list::id, mapi_id_array::lpContainerList, mapi_object_get_id(), mapi_container_list::next, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS mapi_id_array_get | ( | TALLOC_CTX * | mem_ctx, |
mapi_id_array_t * | id, | ||
mapi_id_t ** | ContainerList | ||
) |
Retrieve the ContainerList and store it within a uint64_t array.
mem_ctx | allocated talloc pointer |
id | pointer to a mapi_id_array structure |
ContainerList | pointer on a pointer of uint64_t values |
References mapi_id_array::count, mapi_container_list::id, mapi_id_array::lpContainerList, mapi_container_list::next, and OPENCHANGE_RETVAL_IF.
Referenced by FXCopyMessages(), MoveCopyMessages(), and SetSearchCriteria().
enum MAPISTATUS mapi_id_array_init | ( | TALLOC_CTX * | mem_ctx, |
mapi_id_array_t * | id | ||
) |
Initialize a mapi_id_array structure
mem_ctx | pointer to the talloc context |
id | pointer to a mapi_id_array structure |
References OPENCHANGE_RETVAL_IF.
enum MAPISTATUS mapi_id_array_release | ( | mapi_id_array_t * | id) |
Uninitialize a mapi_id_array structure
id | pointer to a mapi_id_array structure |
References mapi_id_array::lpContainerList, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS mapi_nameid_canonical_add | ( | struct mapi_nameid * | mapi_nameid, |
uint32_t | proptag | ||
) |
Add a mapi_nameid entry given its canonical property tag
mapi_nameid | the structure where results are stored |
proptag | the canonical property tag we are searching |
References mapi_nameid::count, mapi_nameid::entries, get_utf8_utf16_conv_length(), mapi_nameid_tags::lid, mapi_nameid_tags::Name, mapi_nameid::nameid, mapi_nameid_tags::OLEGUID, and OPENCHANGE_RETVAL_IF.
Referenced by mapi_nameid_lookup_SPropTagArray(), and mapi_nameid_lookup_SPropValue().
enum MAPISTATUS mapi_nameid_custom_lid_add | ( | struct mapi_nameid * | mapi_nameid, |
uint16_t | lid, | ||
uint16_t | propType, | ||
const char * | OLEGUID | ||
) |
Register and add a custom MNID_ID named property given its lid, proptype and OLEGUID.
mapi_nameid | the structure where results are stored |
lid | the light ID of the name property (used by MNID_ID named props only) |
propType | the named property type |
OLEGUID | the property set this entry belongs to |
References mapi_nameid::count, mapi_nameid::entries, mapi_nameid_tags::lid, mapi_nameid::nameid, mapi_nameid_tags::OLEGUID, OPENCHANGE_RETVAL_IF, mapi_nameid_tags::propType, and mapi_nameid_tags::ulKind.
enum MAPISTATUS mapi_nameid_custom_string_add | ( | struct mapi_nameid * | mapi_nameid, |
const char * | Name, | ||
uint16_t | propType, | ||
const char * | OLEGUID | ||
) |
Register and add a custom MNID_STRING named property given its string, proptype and OLEGUID.
mapi_nameid | the structure where results are stored |
Name | the property name (used by MNID_STRING named props only) |
propType | the named property type |
OLEGUID | the property set this entry belongs to |
References mapi_nameid::count, mapi_nameid::entries, get_utf8_utf16_conv_length(), mapi_nameid_tags::Name, mapi_nameid::nameid, mapi_nameid_tags::OLEGUID, OPENCHANGE_RETVAL_IF, mapi_nameid_tags::propType, and mapi_nameid_tags::ulKind.
enum MAPISTATUS mapi_nameid_GetIDsFromNames | ( | struct mapi_nameid * | mapi_nameid, |
mapi_object_t * | obj, | ||
struct SPropTagArray * | SPropTagArray | ||
) |
Lookup named properties (MNID_STRING) and return their mapped proptags
This convenient function calls GetIDsFromNames() and returns property tags with their real property type.
References mapi_nameid::count, mapi_nameid::entries, GetIDsFromNames(), GetLastError(), mapi_nameid::nameid, OPENCHANGE_RETVAL_IF, and mapi_nameid_tags::propType.
enum MAPISTATUS mapi_nameid_lid_add | ( | struct mapi_nameid * | mapi_nameid, |
uint16_t | lid, | ||
const char * | OLEGUID | ||
) |
Add a mapi_nameid entry given its lid and OLEGUID (MNID_ID)
mapi_nameid | the structure where results are stored |
lid | the light ID of the name property (used by MNID_ID named props only) |
OLEGUID | the property set this entry belongs to |
References mapi_nameid::count, mapi_nameid::entries, get_utf8_utf16_conv_length(), mapi_nameid_tags::lid, mapi_nameid_tags::Name, mapi_nameid::nameid, mapi_nameid_tags::OLEGUID, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS mapi_nameid_lid_lookup | ( | uint16_t | lid, |
const char * | OLEGUID, | ||
uint16_t * | propType | ||
) |
Search for a given lid,OLEGUID couple and return the associated propType.
lid | the named property light ID |
OLEGUID | the named property GUID for this entry |
propType | pointer on returned named property type |
References mapi_nameid_tags::OLEGUID, OPENCHANGE_RETVAL_ERR, OPENCHANGE_RETVAL_IF, and mapi_nameid_tags::propType.
enum MAPISTATUS mapi_nameid_lid_lookup_canonical | ( | uint16_t | lid, |
const char * | OLEGUID, | ||
uint32_t * | propTag | ||
) |
Search for a given lid,OLEGUID couple and return the associated canonical propTag.
lid | the named property light ID |
OLEGUID | the named property GUID for this entry |
propTag | pointer on returned named canonical property tag |
References mapi_nameid_tags::OLEGUID, OPENCHANGE_RETVAL_ERR, OPENCHANGE_RETVAL_IF, and mapi_nameid_tags::proptag.
enum MAPISTATUS mapi_nameid_lookup_SPropTagArray | ( | struct mapi_nameid * | nameid, |
struct SPropTagArray * | SPropTagArray | ||
) |
Loop over SPropTagArray and look for canonical named property tags we can add to the nameid structure.
nameid | the structure where results are stored |
SPropTagArray | the array of property tags where to look for canonical named property tags. |
References mapi_nameid_canonical_add(), mapi_nameid_property_lookup(), and OPENCHANGE_RETVAL_IF.
Referenced by GetProps().
enum MAPISTATUS mapi_nameid_lookup_SPropValue | ( | struct mapi_nameid * | mapi_nameid, |
struct SPropValue * | lpProps, | ||
unsigned long | PropCount | ||
) |
Loop over lpProps and look for canonical named property tags we can add to the nameid structure.
mapi_nameid | the structure where results are stored |
lpProps | pointer on a SPropValue structure with the property tags where to look for canonical named property tags |
PropCount | count of lpProps elemense |
References mapi_nameid_canonical_add(), and OPENCHANGE_RETVAL_IF.
Referenced by SetPropertiesNoReplicate(), and SetProps().
enum MAPISTATUS mapi_nameid_map_SPropTagArray | ( | struct mapi_nameid * | mapi_nameid, |
struct SPropTagArray * | SPropTagArray, | ||
struct SPropTagArray * | SPropTagArray2 | ||
) |
Replace named property tags in SPropTagArray with the property ID Exchange expects and stored in SPropTagArray2.
mapi_nameid | the structure where results are stored |
SPropTagArray | the array of property tags with original property tags |
SPropTagArray2 | the array of named property tags resolved with GetIDsFromNames |
References mapi_nameid::count, mapi_nameid::entries, OPENCHANGE_RETVAL_IF, mapi_nameid_tags::position, mapi_nameid_tags::proptag, and mapi_nameid_tags::propType.
Referenced by GetProps().
enum MAPISTATUS mapi_nameid_map_SPropValue | ( | struct mapi_nameid * | mapi_nameid, |
struct SPropValue * | lpProps, | ||
uint32_t | PropCount, | ||
struct SPropTagArray * | SPropTagArray | ||
) |
Replace named property tags in the SPropValue array with the property ID Exchange expects and stored in SPropTagArray.
mapi_nameid | the structure where results are stored |
lpProps | pointer on a SPropValue structure with property tags and values |
PropCount | count of lpProps elements |
SPropTagArray | the array of named property tags resolved with GetIDsFromNames |
References mapi_nameid::count, mapi_nameid::entries, OPENCHANGE_RETVAL_IF, mapi_nameid_tags::position, mapi_nameid_tags::proptag, and mapi_nameid_tags::propType.
Referenced by SetPropertiesNoReplicate(), and SetProps().
struct mapi_nameid* mapi_nameid_new | ( | TALLOC_CTX * | mem_ctx) |
Create a new mapi_nameid structure
mem_ctx | memory context to use for allocation |
References mapi_nameid::count, mapi_nameid::entries, and mapi_nameid::nameid.
Referenced by GetProps(), SetPropertiesNoReplicate(), and SetProps().
enum MAPISTATUS mapi_nameid_OOM_add | ( | struct mapi_nameid * | mapi_nameid, |
const char * | OOM, | ||
const char * | OLEGUID | ||
) |
Add a mapi_nameid entry given its OOM and OLEGUID (MNID_ID|MNID_STRING)
mapi_nameid | the structure where results are stored |
OOM | the Outlook Object Model matching string |
OLEGUID | the property set this entry belongs to |
References mapi_nameid::count, mapi_nameid::entries, get_utf8_utf16_conv_length(), mapi_nameid_tags::lid, mapi_nameid_tags::Name, mapi_nameid::nameid, mapi_nameid_tags::OLEGUID, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS mapi_nameid_OOM_lookup | ( | const char * | OOM, |
const char * | OLEGUID, | ||
uint16_t * | propType | ||
) |
Search for a given OOM,OLEGUID couple and return the associated propType.
OOM | The Outlook Object Model |
OLEGUID | the named property GUID for this entry |
propType | pointer on returned named property type |
References mapi_nameid_tags::OLEGUID, OPENCHANGE_RETVAL_ERR, OPENCHANGE_RETVAL_IF, and mapi_nameid_tags::propType.
enum MAPISTATUS mapi_nameid_property_lookup | ( | uint32_t | proptag) |
Search for a given referenced unmapped named property and return whether it was found or not.
proptag | the unmapped property tag to lookup |
References mapi_nameid_tags::proptag.
Referenced by mapi_nameid_lookup_SPropTagArray().
enum MAPISTATUS mapi_nameid_SPropTagArray | ( | struct mapi_nameid * | mapi_nameid, |
struct SPropTagArray * | SPropTagArray | ||
) |
set SPropTagArray ulPropTag property types from mapi_nameid returned by GetIDsFromNames()
mapi_nameid | the structure where results are stored |
SPropTagArray | the array of property tags returned by previous call to GetIDsFromNames() |
References mapi_nameid::count, mapi_nameid::entries, OPENCHANGE_RETVAL_IF, and mapi_nameid_tags::propType.
enum MAPISTATUS mapi_nameid_string_add | ( | struct mapi_nameid * | mapi_nameid, |
const char * | Name, | ||
const char * | OLEGUID | ||
) |
Add a mapi_nameid entry given its Name and OLEGUID (MNID_STRING)
mapi_nameid | the structure where results are stored |
Name | the property name (used by MNID_STRING named props only) |
OLEGUID | the property set this entry belongs to |
References mapi_nameid::count, mapi_nameid::entries, get_utf8_utf16_conv_length(), mapi_nameid_tags::lid, mapi_nameid_tags::Name, mapi_nameid::nameid, mapi_nameid_tags::OLEGUID, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS mapi_nameid_string_lookup | ( | const char * | Name, |
const char * | OLEGUID, | ||
uint16_t * | propType | ||
) |
Search for a given Name,OLEGUID couple and return the associated propType.
Name | the named property name |
OLEGUID | the named property GUID for this entry |
propType | pointer on returned named property type |
References mapi_nameid_tags::OLEGUID, OPENCHANGE_RETVAL_ERR, OPENCHANGE_RETVAL_IF, and mapi_nameid_tags::propType.
enum MAPISTATUS mapi_nameid_string_lookup_canonical | ( | const char * | Name, |
const char * | OLEGUID, | ||
uint32_t * | propTag | ||
) |
Search for a given Name,OLEGUID couple and return the associated canonical propTag.
Name | the named property name |
OLEGUID | the named property GUID for this entry |
propTag | pointer on returned named canonical property tag |
References mapi_nameid_tags::OLEGUID, OPENCHANGE_RETVAL_ERR, OPENCHANGE_RETVAL_IF, and mapi_nameid_tags::proptag.
enum MAPISTATUS mapi_nameid_unmap_SPropTagArray | ( | struct mapi_nameid * | mapi_nameid, |
struct SPropTagArray * | SPropTagArray | ||
) |
Restore the original SPropTagArray array with the property tags saved in the mapi_nameid structure.
mapi_nameid | the structure where results are stored |
SPropTagArray | the array of property tags with original property tags |
References mapi_nameid::count, mapi_nameid::entries, OPENCHANGE_RETVAL_IF, mapi_nameid_tags::position, and mapi_nameid_tags::proptag.
Referenced by GetProps().
enum MAPISTATUS mapi_nameid_unmap_SPropValue | ( | struct mapi_nameid * | mapi_nameid, |
struct SPropValue * | lpProps, | ||
uint32_t | PropCount | ||
) |
Restore the original SPropValue array with the property tags saved in the mapi_nameid structure.
mapi_nameid | the structure where results are stored |
lpProps | the array of SPropValue structures with original property tags |
PropCount | count of lpProps elements |
References mapi_nameid::count, mapi_nameid::entries, OPENCHANGE_RETVAL_IF, mapi_nameid_tags::position, and mapi_nameid_tags::proptag.
Referenced by SetPropertiesNoReplicate(), and SetProps().
enum MAPISTATUS mapi_object_bookmark_debug | ( | mapi_object_t * | obj_table) |
Dump bookmarks associated to a MAPI object table
obj_table | pointer on the MAPI object table |
References mapi_obj_bookmark::bin, mapi_obj_table::bookmark, mapi_obj_bookmark::index, mapi_obj_bookmark::next, OPENCHANGE_RETVAL_IF, and mapi_object::private_data.
enum MAPISTATUS mapi_object_bookmark_get_count | ( | mapi_object_t * | obj_table, |
uint32_t * | count | ||
) |
Retrieve the number of bookmarks stored in a MAPI object table
obj_table | pointer to the MAPI object table |
count | pointer to the number of bookmarks to return |
References mapi_obj_table::bk_last, OPENCHANGE_RETVAL_IF, and mapi_object::private_data.
enum MAPISTATUS mapi_object_copy | ( | mapi_object_t * | dst, |
mapi_object_t * | src | ||
) |
Copy MAPI object
This function copies mapi_object data from source to destination.
dst | pointer on the destination MAPI object |
src | pointer on the source MAPI object |
References mapi_object::handle, mapi_object::id, mapi_object::logon_id, OPENCHANGE_RETVAL_IF, mapi_object::private_data, and mapi_object::session.
void mapi_object_debug | ( | mapi_object_t * | obj) |
Dump a MAPI object (for debugging)
obj | pointer on the MAPI object to dump out |
References mapi_object::handle, and mapi_object::id.
mapi_id_t mapi_object_get_id | ( | mapi_object_t * | obj) |
Retrieve an object ID for a given MAPI object
obj | pointer on the MAPI object to get the ID for |
References mapi_object::id.
Referenced by AbortSubmit(), CopyFolder(), CreateMessage(), GetOwningServers(), mapi_id_array_add_obj(), mapi_id_array_del_obj(), MoveFolder(), PublicFolderIsGhosted(), SetReceiveFolder(), SpoolerLockMessage(), Subscribe(), and TransportNewMail().
enum MAPISTATUS mapi_object_get_logon_id | ( | mapi_object_t * | obj, |
uint8_t * | logon_id | ||
) |
Retrieve the logon id for a given MAPI object
obj | pointer to the object to retrieve the logon id from |
logon_id | pointer to a variable to store the logon id |
References mapi_object::logon_id.
Referenced by Abort(), AbortSubmit(), AddressTypes(), CloneStream(), CollapseRow(), CommitStream(), CopyFolder(), CopyProps(), CopyTo(), CopyToStream(), CreateAttach(), CreateBookmark(), CreateFolder(), CreateMessage(), DeleteAttach(), DeleteFolder(), DeleteMessage(), DeletePropertiesNoReplicate(), DeleteProps(), EmptyFolder(), ExpandRow(), FindRow(), FreeBookmark(), FXCopyFolder(), FXCopyMessages(), FXCopyProperties(), FXCopyTo(), FXDestConfigure(), FXGetBuffer(), FXPutBuffer(), GetAttachmentTable(), GetCollapseState(), GetContentsTable(), GetHierarchyTable(), GetIdFromLongTermId(), GetIDsFromNames(), GetLocalReplicaIds(), GetLongTermIdFromId(), GetMessageStatus(), GetNamesFromIDs(), GetOwningServers(), GetPermissionsTable(), GetPropList(), GetProps(), GetPropsAll(), GetReceiveFolder(), GetReceiveFolderTable(), GetRulesTable(), GetSearchCriteria(), GetStatus(), GetStoreState(), GetStreamSize(), GetTransportFolder(), GetValidAttach(), HardDeleteMessage(), HardDeleteMessagesAndSubfolders(), ICSSyncConfigure(), ICSSyncGetTransferState(), ICSSyncOpenCollector(), ICSSyncUploadStateBegin(), ICSSyncUploadStateContinue(), ICSSyncUploadStateEnd(), LockRegionStream(), ModifyPermissions(), ModifyRecipients(), MoveCopyMessages(), MoveFolder(), OpenAttach(), OpenEmbeddedMessage(), OpenFolder(), OpenMessage(), OpenPublicFolderByName(), OpenStream(), OptionsData(), PublicFolderIsGhosted(), QueryColumns(), QueryNamedProperties(), QueryPosition(), QueryRows(), ReadRecipients(), ReadStream(), Release(), ReloadCachedInformation(), RemoveAllRecipients(), Reset(), Restrict(), SaveChangesAttachment(), SaveChangesMessage(), SeekRow(), SeekRowApprox(), SeekRowBookmark(), SeekStream(), SetCollapseState(), SetColumns(), SetLocalReplicaMidsetDeleted(), SetMessageReadFlag(), SetMessageStatus(), SetPropertiesNoReplicate(), SetProps(), SetReadFlags(), SetReceiveFolder(), SetSearchCriteria(), SetSpooler(), SetStreamSize(), SetSyncNotificationGuid(), SortTable(), SpoolerLockMessage(), SubmitMessage(), Subscribe(), SyncOpenAdvisor(), TellVersion(), TransportNewMail(), TransportSend(), UnlockRegionStream(), WriteAndCommitStream(), and WriteStream().
struct mapi_session* mapi_object_get_session | ( | mapi_object_t * | obj) |
Retrieve the session associated to the MAPI object
obj | the object to get the session for |
References mapi_object::session.
Referenced by Abort(), AbortSubmit(), AddressTypes(), AddUserPermission(), CloneStream(), CollapseRow(), CommitStream(), CopyFolder(), CopyProps(), CopyTo(), CopyToStream(), CreateAttach(), CreateBookmark(), CreateFolder(), CreateMessage(), DeleteAttach(), DeleteFolder(), DeleteMessage(), DeletePropertiesNoReplicate(), DeleteProps(), EmptyFolder(), ExpandRow(), FindRow(), FreeBookmark(), FXCopyFolder(), FXCopyMessages(), FXCopyProperties(), FXCopyTo(), FXDestConfigure(), FXGetBuffer(), FXPutBuffer(), GetAttachmentTable(), GetBestBody(), GetCollapseState(), GetContentsTable(), GetFolderItemsCount(), GetHierarchyTable(), GetIdFromLongTermId(), GetIDsFromNames(), GetLocalReplicaIds(), GetLongTermIdFromId(), GetMessageStatus(), GetNamesFromIDs(), GetOwningServers(), GetPermissionsTable(), GetPropList(), GetProps(), GetPropsAll(), GetReceiveFolder(), GetReceiveFolderTable(), GetRulesTable(), GetSearchCriteria(), GetStatus(), GetStoreState(), GetStreamSize(), GetTransportFolder(), GetUserFreeBusyData(), GetValidAttach(), HardDeleteMessage(), HardDeleteMessagesAndSubfolders(), ICSSyncConfigure(), ICSSyncGetTransferState(), ICSSyncOpenCollector(), ICSSyncUploadStateBegin(), ICSSyncUploadStateContinue(), ICSSyncUploadStateEnd(), IsFreeBusyConflict(), LockRegionStream(), Logoff(), mapi_SPropValue_array_named(), ModifyPermissions(), ModifyRecipients(), ModifyUserPermission(), MoveCopyMessages(), MoveFolder(), OpenAttach(), OpenEmbeddedMessage(), OpenFolder(), OpenMessage(), OpenPublicFolderByName(), OpenStream(), OptionsData(), PublicFolderIsGhosted(), QueryColumns(), QueryNamedProperties(), QueryPosition(), QueryRows(), ReadRecipients(), ReadStream(), Release(), ReloadCachedInformation(), RemoveAllRecipients(), RemoveUserPermission(), Reset(), Restrict(), SaveChangesAttachment(), SaveChangesMessage(), SeekRow(), SeekRowApprox(), SeekRowBookmark(), SeekStream(), SetCollapseState(), SetColumns(), SetLocalReplicaMidsetDeleted(), SetMessageReadFlag(), SetMessageStatus(), SetPropertiesNoReplicate(), SetProps(), SetReadFlags(), SetReceiveFolder(), SetSearchCriteria(), SetSpooler(), SetStreamSize(), SetSyncNotificationGuid(), SortTable(), SpoolerLockMessage(), SubmitMessage(), Subscribe(), SyncOpenAdvisor(), TellVersion(), TransportNewMail(), TransportSend(), UnlockRegionStream(), WrapCompressedRTFStream(), WriteAndCommitStream(), and WriteStream().
enum MAPISTATUS mapi_object_init | ( | mapi_object_t * | obj) |
Initialize MAPI object
This function is required to be called before any manipulation of this MAPI object.
obj | the object to initialize |
Referenced by CreateFolder(), GetUserFreeBusyData(), ModifyUserPermission(), RemoveUserPermission(), and Subscribe().
void mapi_object_release | ( | mapi_object_t * | obj) |
Release MAPI object
This function is required to be called when this MAPI object is no longer required.
obj | pointer on the MAPI object to release |
References mapi_object::handle, INVALID_HANDLE_VALUE, mapi_object::logon_id, mapi_session::logon_ids, mapi_object::private_data, Release(), mapi_object::session, and mapi_object::store.
Referenced by GetUserFreeBusyData(), Logoff(), ModifyUserPermission(), and RemoveUserPermission().
void mapi_object_set_logon_id | ( | mapi_object_t * | obj, |
uint8_t | logon_id | ||
) |
Set the logon id for a given MAPI object
obj | pointer to the object to set the logon id for |
logon_id | the logon identifier to associate to the MAPI object |
References mapi_object::logon_id.
Referenced by CloneStream(), CreateAttach(), CreateFolder(), CreateMessage(), FXCopyFolder(), FXCopyMessages(), FXCopyProperties(), FXCopyTo(), FXDestConfigure(), GetAttachmentTable(), GetContentsTable(), GetHierarchyTable(), GetPermissionsTable(), GetRulesTable(), ICSSyncConfigure(), ICSSyncGetTransferState(), ICSSyncOpenCollector(), OpenAttach(), OpenEmbeddedMessage(), OpenFolder(), OpenMessage(), OpenPublicFolder(), OpenPublicFolderByName(), OpenStream(), OpenUserMailbox(), and SyncOpenAdvisor().
void mapi_object_set_logon_store | ( | mapi_object_t * | obj) |
Mark a MAPI object as a store object
obj | pointer to the object to set the store boolean for |
References mapi_object::store.
Referenced by OpenPublicFolder(), and OpenUserMailbox().
void mapi_object_set_session | ( | mapi_object_t * | obj, |
struct mapi_session * | session | ||
) |
Set the session for a given MAPI object
obj | pointer on the object to set the session for |
session | pointer on the MAPI session to associate to the MAPI object |
References mapi_object::session.
Referenced by CloneStream(), CreateAttach(), CreateFolder(), CreateMessage(), FXCopyFolder(), FXCopyMessages(), FXCopyProperties(), FXCopyTo(), FXDestConfigure(), GetAttachmentTable(), GetContentsTable(), GetHierarchyTable(), GetPermissionsTable(), GetRulesTable(), ICSSyncConfigure(), ICSSyncGetTransferState(), ICSSyncOpenCollector(), OpenAttach(), OpenEmbeddedMessage(), OpenFolder(), OpenMessage(), OpenPublicFolder(), OpenPublicFolderByName(), OpenStream(), OpenUserMailbox(), Subscribe(), and SyncOpenAdvisor().
enum MAPISTATUS mapi_profile_add_string_attr | ( | struct mapi_context * | mapi_ctx, |
const char * | profile, | ||
const char * | attr, | ||
const char * | value | ||
) |
Add an attribute to the profile
mapi_ctx | pointer to the MAPI context |
profile | pointer to the profile name |
attr | the name of the atribute |
value | the value of the attribute |
References mapi_context::ldb_ctx, mapi_context::mem_ctx, and OPENCHANGE_RETVAL_IF.
Referenced by CreateProfile(), and ProcessNetworkProfile().
enum MAPISTATUS mapi_profile_delete_string_attr | ( | struct mapi_context * | mapi_ctx, |
const char * | profname, | ||
const char * | attr, | ||
const char * | value | ||
) |
Delete an attribute
mapi_ctx | pointer to the MAPI context |
profname | the name of the profile |
attr | the name of the attribute |
value | the value of the attribute |
References mapi_context::ldb_ctx, mapi_context::mem_ctx, and OPENCHANGE_RETVAL_IF.
Referenced by DuplicateProfile().
const char* mapi_profile_get_ldif_path | ( | void | ) |
Get default ldif_path
This function returns the path for the default LDIF files.
enum MAPISTATUS mapi_profile_modify_string_attr | ( | struct mapi_context * | mapi_ctx, |
const char * | profname, | ||
const char * | attr, | ||
const char * | value | ||
) |
Modify an attribute
mapi_ctx | pointer to the MAPI context |
profname | the name of the profile |
attr | the name of the attribute |
value | the value of the attribute |
References mapi_context::ldb_ctx, mapi_context::mem_ctx, and OPENCHANGE_RETVAL_IF.
Referenced by ChangeProfilePassword(), DuplicateProfile(), and SetDefaultProfile().
void mapi_SPropValue_array_named | ( | mapi_object_t * | , |
struct mapi_SPropValue_array * | |||
) |
References GetNamesFromIDs(), mapi_object_get_session(), and PT_NULL.
bool mapi_verify_cpid | ( | uint32_t | cpid) |
Verify if the specified codepage is valid
cpid | the codepage to lookup |
enum MAPISTATUS MAPIAllocateBuffer | ( | struct mapi_context * | mapi_ctx, |
uint32_t | size, | ||
void ** | ptr | ||
) |
Allocate memory using the MAPI memory context
mapi_ctx | pointer to the MAPI context |
size | the number of bytes to allocate |
ptr | pointer to the allocated byte region |
References mapi_context::mem_ctx, and OPENCHANGE_RETVAL_IF.
void mapidump_appointment | ( | struct mapi_SPropValue_array * | properties, |
const char * | id | ||
) |
This function dumps the properties relating to an appointment to standard output
The expected way to obtain the properties array is to use OpenMessage() to obtain the appointment object, then to use GetPropsAll() to obtain all the properties.
properties | array of appointment properties |
id | identification to display for the appointment (can be NULL) |
References find_mapi_SPropValue_data(), get_task_status(), mapidump_date(), PidLidBusyStatus, PidLidContacts, PidLidLocation, PidLidPrivate, PidLidTimeZoneDescription, PR_CONVERSATION_TOPIC, PR_END_DATE, and PR_START_DATE.
void mapidump_contact | ( | struct mapi_SPropValue_array * | properties, |
const char * | id | ||
) |
This function dumps the properties relating to a contact (address book entry) to standard output
The expected way to obtain the properties array is to use OpenMessage() to obtain the contact object, then to use GetPropsAll() to obtain all the properties.
properties | array of contact properties |
id | identification to display for the contact (can be NULL) |
References find_mapi_SPropValue_data(), PidLidEmail1OriginalDisplayName, PidLidFileUnder, PR_BUSINESS_FAX_NUMBER, PR_BUSINESS_HOME_PAGE, PR_COMPANY_NAME, PR_CONVERSATION_TOPIC, PR_COUNTRY, PR_DEPARTMENT_NAME, PR_DISPLAY_NAME, PR_GIVEN_NAME, PR_HOME_TELEPHONE_NUMBER, PR_LOCALITY, PR_MOBILE_TELEPHONE_NUMBER, PR_OFFICE_TELEPHONE_NUMBER, PR_POSTAL_ADDRESS, PR_STATE_OR_PROVINCE, PR_STREET_ADDRESS, PR_SURNAME, and PR_TITLE.
void mapidump_date | ( | struct mapi_SPropValue_array * | , |
uint32_t | , | ||
const char * | |||
) |
References find_mapi_SPropValue_data().
Referenced by mapidump_appointment(), mapidump_note(), and mapidump_task().
void mapidump_date_SPropValue | ( | struct SPropValue | lpProp, |
const char * | label, | ||
const char * | sep | ||
) |
This function dumps a property containing a date / time to standard output
If the property does not contain a PT_SYSTIME type value, then no output will occur.
lpProp | the property to dump |
label | the label to display prior to the time (e.g. the property tag) |
sep | a separator / spacer to insert in front of the label |
References get_SPropValue_data().
Referenced by mapidump_SPropValue().
void mapidump_foldercopied | ( | struct FolderMoveCopyNotification * | , |
const char * | |||
) |
References mapidump_foldermoved().
void mapidump_foldercreated | ( | struct FolderCreatedNotification * | , |
const char * | |||
) |
References mapidump_tags().
void mapidump_folderdeleted | ( | struct FolderDeletedNotification * | , |
const char * | |||
) |
void mapidump_foldermoved | ( | struct FolderMoveCopyNotification * | , |
const char * | |||
) |
Referenced by mapidump_foldercopied().
void mapidump_freebusy_date | ( | uint32_t | , |
const char * | |||
) |
void mapidump_freebusy_event | ( | struct Binary_r * | , |
uint32_t | , | ||
uint32_t | , | ||
const char * | |||
) |
References mapidump_freebusy_month(), and mapidump_freebusy_year().
const char* mapidump_freebusy_month | ( | uint32_t | , |
uint32_t | |||
) |
Referenced by mapidump_freebusy_event().
uint32_t mapidump_freebusy_year | ( | uint32_t | , |
uint32_t | |||
) |
Referenced by mapidump_freebusy_event().
void mapidump_languages_list | ( | void | ) |
print the list of languages OpenChange supports
References mapi_get_language_list().
void mapidump_message | ( | struct mapi_SPropValue_array * | properties, |
const char * | id, | ||
mapi_object_t * | obj_msg | ||
) |
This function dumps the properties relating to an email message to standard output
The expected way to obtain the properties array is to use OpenMessage() to obtain the message object, then to use GetPropsAll() to obtain all the properties.
properties | array of message properties |
id | identification to display for the message (can be NULL) |
obj_msg | pointer to the message MAPI object (can be NULL) |
References find_mapi_SPropValue_data(), mapidump_message_summary(), PR_BODY, PR_BODY_UNICODE, PR_CONVERSATION_TOPIC, PR_CONVERSATION_TOPIC_UNICODE, PR_DISPLAY_BCC, PR_DISPLAY_BCC_UNICODE, PR_DISPLAY_CC, PR_DISPLAY_CC_UNICODE, PR_DISPLAY_TO, PR_DISPLAY_TO_UNICODE, PR_HASATTACH, PR_HTML, PR_INTERNET_MESSAGE_ID, PR_INTERNET_MESSAGE_ID_UNICODE, PR_MESSAGE_CODEPAGE, PR_SENT_REPRESENTING_NAME, and PR_SENT_REPRESENTING_NAME_UNICODE.
void mapidump_message_summary | ( | mapi_object_t * | obj_message) |
This function dumps message information retrieved from OpenMessage call. It provides a quick method to print message summaries with information such as subject and recipients.
obj_message | pointer to the MAPI message object to use |
References find_SPropValue_data(), mapi_obj_message::NormalizedSubject, PR_RECIPIENT_TYPE, PR_SMTP_ADDRESS, PR_SMTP_ADDRESS_UNICODE, mapi_object::private_data, mapi_obj_message::SRowSet, and mapi_obj_message::SubjectPrefix.
Referenced by mapidump_message().
void mapidump_messagecopied | ( | struct MessageMoveCopyNotification * | , |
const char * | |||
) |
References mapidump_messagemoved().
void mapidump_messagecreated | ( | struct MessageCreatedNotification * | , |
const char * | |||
) |
References mapidump_tags().
Referenced by mapidump_messagemodified().
void mapidump_messagedeleted | ( | struct MessageDeletedNotification * | , |
const char * | |||
) |
void mapidump_messagemodified | ( | struct MessageModifiedNotification * | , |
const char * | |||
) |
References mapidump_messagecreated().
void mapidump_messagemoved | ( | struct MessageMoveCopyNotification * | , |
const char * | |||
) |
Referenced by mapidump_messagecopied().
void mapidump_msgflags | ( | uint32_t | , |
const char * | |||
) |
References mdump_msgflags::flag.
Referenced by mapidump_newmail().
void mapidump_newmail | ( | struct NewMailNotification * | , |
const char * | |||
) |
References mapidump_msgflags().
void mapidump_note | ( | struct mapi_SPropValue_array * | properties, |
const char * | id | ||
) |
This function dumps the properties relating to a note to standard output
The expected way to obtain the properties array is to use OpenMessage() to obtain the note object, then to use GetPropsAll() to obtain all the properties.
properties | array of note properties |
id | identification to display for the note (can be NULL) |
References find_mapi_SPropValue_data(), mapidump_date(), PR_BODY, PR_BODY_HTML, PR_CLIENT_SUBMIT_TIME, and PR_CONVERSATION_TOPIC.
void mapidump_PAB_entry | ( | struct PropertyRow_r * | aRow) |
Output a row of the public address book.
aRow | one row of the public address book (Global Address List) |
This function is usually used with GetGALTable, which can obtain several rows at once - you'll need to iterate over the rows.
The SRow is assumed to contain entries for PR_ADDRTYPE_UNICODE, PR_DISPLAY_NAME_UNICODE, PR_EMAIL_ADDRESS_UNICODE and PR_ACCOUNT_UNICODE.
References find_PropertyValue_data(), PR_ACCOUNT_UNICODE, PR_ADDRTYPE_UNICODE, PR_DISPLAY_NAME_UNICODE, and PR_EMAIL_ADDRESS_UNICODE.
void mapidump_Recipients | ( | const char ** | , |
struct SRowSet * | , | ||
struct PropertyTagArray_r * | flaglist | ||
) |
References MAPI_AMBIGUOUS, MAPI_RESOLVED, MAPI_UNRESOLVED, and mapidump_SRow().
void mapidump_SPropTagArray | ( | struct SPropTagArray * | ) |
References get_proptag_name().
void mapidump_SPropValue | ( | struct SPropValue | lpProp, |
const char * | sep | ||
) |
Output one property tag and value.
lpProp | the property to print |
sep | a separator / spacer to insert in front of the label |
References get_proptag_name(), get_SPropValue_data(), mapidump_date_SPropValue(), OC_ASSERT, PT_BINARY, PT_BOOLEAN, PT_CLSID, PT_DOUBLE, PT_ERROR, PT_I8, PT_LONG, PT_MV_BINARY, PT_MV_LONG, PT_MV_STRING8, PT_MV_UNICODE, PT_OBJECT, PT_SHORT, PT_STRING8, PT_SVREID, PT_SYSTIME, and PT_UNICODE.
Referenced by mapidump_SRow().
void mapidump_SRow | ( | struct SRow * | , |
const char * | |||
) |
References mapidump_SPropValue().
Referenced by mapidump_Recipients(), and mapidump_SRowSet().
void mapidump_SRowSet | ( | struct SRowSet * | , |
const char * | |||
) |
References mapidump_SRow().
void mapidump_tags | ( | enum MAPITAGS * | , |
uint16_t | , | ||
const char * | |||
) |
References get_proptag_name().
Referenced by mapidump_foldercreated(), and mapidump_messagecreated().
void mapidump_task | ( | struct mapi_SPropValue_array * | properties, |
const char * | id | ||
) |
This function dumps the properties relating to a task (to-do list entry) to standard output
The expected way to obtain the properties array is to use OpenMessage() to obtain the task object, then to use GetPropsAll() to obtain all the properties.
properties | array of task properties |
id | identification to display for the task (can be NULL) |
References find_mapi_SPropValue_data(), get_importance(), get_task_status(), mapidump_date(), olTaskComplete, PidLidContacts, PidLidPercentComplete, PidLidPrivate, PidLidTaskDateCompleted, PidLidTaskDueDate, PidLidTaskStartDate, PidLidTaskStatus, PR_BODY, PR_CONVERSATION_TOPIC, and PR_IMPORTANCE.
enum MAPISTATUS MAPIFreeBuffer | ( | void * | ptr) |
Free allocated memory
This function frees memory previously allocated with MAPIAllocateBuffer.
ptr | memory region to free |
References OPENCHANGE_RETVAL_IF.
Referenced by AddUserPermission(), DuplicateProfile(), EntryIDFromSourceIDForMessage(), FreeBookmark(), GetABRecipientInfo(), GetBestBody(), GetFolderItemsCount(), GetProps(), GetUserFreeBusyData(), Logoff(), ModifyUserPermission(), ProcessNetworkProfile(), RemoveUserPermission(), SetPropertiesNoReplicate(), and SetProps().
enum MAPISTATUS MAPIInitialize | ( | struct mapi_context ** | _mapi_ctx, |
const char * | profiledb | ||
) |
Initialize mapi context structure
This function inititalizes the MAPI subsystem and open the profile database pointed by profiledb .
_mapi_ctx | pointer to the MAPI context |
profiledb | profile database path |
References mapi_context::dumpdata, mapi_context::ldb_ctx, mapi_context::lp_ctx, mapi_context::mem_ctx, OPENCHANGE_RETVAL_IF, OpenProfileStore(), and mapi_context::session.
enum MAPISTATUS MapiLogonEx | ( | struct mapi_context * | mapi_ctx, |
struct mapi_session ** | session, | ||
const char * | profname, | ||
const char * | password | ||
) |
Create a full MAPI session
Open providers stored in the profile and return a pointer on a IMAPISession object.
mapi_ctx | pointer to the MAPI context |
session | pointer to a pointer to a MAPI session object |
profname | profile name to use |
password | password to use for the profile |
password should be set to NULL if the password has been stored in the profile.
References MapiLogonProvider(), PROVIDER_ID_EMSMDB, and PROVIDER_ID_NSPI.
enum MAPISTATUS MapiLogonProvider | ( | struct mapi_context * | mapi_ctx, |
struct mapi_session ** | session, | ||
const char * | profname, | ||
const char * | password, | ||
enum PROVIDER_ID | provider | ||
) |
Initialize a session on the specified provider
mapi_ctx | pointer to the MAPI context |
session | pointer to a pointer to a MAPI session object |
profname | profile name |
password | profile password |
provider | provider we want to establish a connection on |
password should be set to NULL if the password has been stored in the profile.
Supported providers are:
References mapi_session::emsmdb, emsmdb_disconnect_dtor(), LoadProfile(), Logon(), mapi_session::logon_ids, mapi_session::mapi_ctx, mapi_context::mem_ctx, mapi_session::next, mapi_session::nspi, nspi_disconnect_dtor(), OPENCHANGE_RETVAL_IF, OpenProfile(), mapi_session::profile, PROVIDER_ID_EMSMDB, PROVIDER_ID_NSPI, and mapi_context::session.
Referenced by DuplicateProfile(), and MapiLogonEx().
void MAPIUninitialize | ( | struct mapi_context * | mapi_ctx) |
Uninitialize MAPI subsystem
mapi_ctx | pointer to the MAPI context |
This function uninitializes the MAPI context and destroy recursively the whole mapi session and associated objects hierarchy
References mapi_notify_ctx::fd, mapi_context::mem_ctx, mapi_session::notify_ctx, and mapi_context::session.
enum MAPISTATUS ModifyPermissions | ( | mapi_object_t * | obj_table, |
uint8_t | flags, | ||
struct mapi_PermissionsData * | permsdata | ||
) |
Modify the entries of a permission table
This function takes a pointer to a table object, a list of entries to modify and alter the permission table of its associated container. This function can be used to add, modify or remove permissions.
obj_table | the table containing the container's permissions |
flags | any special flags to use |
permsdata | the list of permissions table entries to modify |
Possible values for flags:
References emsmdb_transaction_wrapper(), get_mapi_property_size(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
Referenced by AddUserPermission(), ModifyUserPermission(), and RemoveUserPermission().
enum MAPISTATUS ModifyRecipients | ( | mapi_object_t * | obj_message, |
struct SRowSet * | SRowSet | ||
) |
Adds, deletes or modifies message recipients
obj_message | the message to change the recipients for |
SRowSet | the recipients to add |
When using this function, take care to ensure that the properties that are present on the first row in the rowset are also present in all the following rows. If any are missing, this function will suffer NDR errors. This includes making sure that any string properties are present in the same encoding (e.g. if you use PR_SMTP_ADDRESS_UNICODE on the first row, don't provide PR_SMTP_ADDRESS on subsequent rows).
References cast_mapi_SPropValue(), emsmdb_transaction_wrapper(), find_SPropValue_data(), get_MAPITAGS_SRow(), get_utf8_utf16_conv_length(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), mapi_recipients_RecipientFlags(), MAPITAGS_delete_entries(), OPENCHANGE_CHECK_NOTIFICATION, OPENCHANGE_RETVAL_IF, PR_7BIT_DISPLAY_NAME, PR_7BIT_DISPLAY_NAME_UNICODE, PR_ADDRTYPE, PR_ADDRTYPE_ERROR, PR_ADDRTYPE_UNICODE, PR_DISPLAY_NAME, PR_DISPLAY_NAME_ERROR, PR_DISPLAY_NAME_UNICODE, PR_EMAIL_ADDRESS, PR_EMAIL_ADDRESS_UNICODE, PR_ENTRYID, PR_GIVEN_NAME, PR_GIVEN_NAME_ERROR, PR_GIVEN_NAME_UNICODE, PR_RECIPIENT_TYPE, PR_SEND_INTERNET_ENCODING, PR_SEND_INTERNET_ENCODING_ERROR, PR_SEND_RICH_INFO, PR_SEND_RICH_INFO_ERROR, PR_SMTP_ADDRESS, PR_SMTP_ADDRESS_UNICODE, PR_TRANSMITTABLE_DISPLAY_NAME, and PR_TRANSMITTABLE_DISPLAY_NAME_UNICODE.
enum MAPISTATUS ModifyUserPermission | ( | mapi_object_t * | obj_folder, |
const char * | username, | ||
enum ACLRIGHTS | role | ||
) |
Modify permissions for a user on a given folder
obj_folder | the folder to modify permissions for |
username | the Exchange username to modify permissions for |
role | the permission mask value (see AddUserPermission) |
References find_PropertyValue_data(), get_SPropValue_SRow(), GetPermissionsTable(), mapi_object_get_session(), mapi_object_init(), mapi_object_release(), MAPI_RESOLVED, MAPIFreeBuffer(), ModifyPermissions(), OPENCHANGE_RETVAL_IF, PR_DISPLAY_NAME, PR_ENTRYID, PR_MEMBER_ID, PR_MEMBER_NAME, PR_MEMBER_RIGHTS, QueryPosition(), QueryRows(), ResolveNames(), set_SPropTagArray(), and SetColumns().
enum MAPISTATUS MonitorNotification | ( | struct mapi_session * | session, |
void * | private_data, | ||
struct mapi_notify_continue_callback_data * | cb_data | ||
) |
Wait for notifications and process them
This function waits for notifications on the UDP port and generates the traffic needed to receive MAPI notifications. These MAPI notifications are next compared to the registered ones and the callback specified in Subscribe() called if it matches.
The function takes a callback in cb_data to check if it should continue to process notifications. Timeval in cb_data can be used to control the behavior of select.
References mapi_notify_continue_callback_data::callback, mapi_provider::ctx, mapi_notify_continue_callback_data::data, mapi_session::emsmdb, emsmdb_transaction_null(), mapi_notify_ctx::fd, mapi_session::notify_ctx, OPENCHANGE_RETVAL_IF, ProcessNotification(), and mapi_notify_continue_callback_data::tv.
enum MAPISTATUS MoveCopyMessages | ( | mapi_object_t * | obj_src, |
mapi_object_t * | obj_dst, | ||
mapi_id_array_t * | message_id, | ||
bool | WantCopy | ||
) |
Copy or Move a message from a folder to another
obj_src | The source folder |
obj_dst | The destination folder |
message_id | pointer to container object for message ids. |
WantCopy | boolean value, defines whether the operation is a copy or a move |
Possible values for WantCopy:
References mapi_id_array::count, emsmdb_transaction_wrapper(), mapi_id_array_get(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS MoveFolder | ( | mapi_object_t * | obj_folder, |
mapi_object_t * | obj_src, | ||
mapi_object_t * | obj_dst, | ||
char * | NewFolderName, | ||
bool | UseUnicode | ||
) |
Moves a folder
obj_folder | the folder to move |
obj_src | source object where the folder to move is stored |
obj_dst | destination object where the folder will be moved |
NewFolderName | the new folder name in the destination folder |
UseUnicode | whether the folder name is unicode encoded or not |
References emsmdb_transaction_wrapper(), get_utf8_utf16_conv_length(), mapi_object_get_handle(), mapi_object_get_id(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
void ndr_push_idset | ( | struct ndr_push * | ndr, |
struct idset * | idset | ||
) |
push an idset on an ndr stream
References IDSET_serialize().
__BEGIN_DECLS struct nspi_context* nspi_bind | ( | TALLOC_CTX * | parent_ctx, |
struct dcerpc_pipe * | p, | ||
struct cli_credentials * | cred, | ||
uint32_t | codepage, | ||
uint32_t | language, | ||
uint32_t | method | ||
) |
Initiates a session between a client and the NSPI server.
parent_ctx | pointer to the memory context |
p | pointer to the DCERPC pipe |
cred | pointer to the user credentials |
codepage | the code to set in the STAT structure |
language | the language to set in the STAT structure |
method | the method to set in the STAT structure |
References nspi_context::cred, nspi_context::handle, nspi_context::mem_ctx, nspi_context::pStat, nspi_context::rpc_connection, and nspi_context::version.
Referenced by Logon().
enum MAPISTATUS nspi_CompareMIds | ( | struct nspi_context * | nspi_ctx, |
TALLOC_CTX * | mem_ctx, | ||
uint32_t | MId1, | ||
uint32_t | MId2, | ||
uint32_t * | plResult | ||
) |
Compares the position in an address book container of two objects identified by MId and returns the value of the comparison
nspi_ctx | pointer to the NSPI connection context |
mem_ctx | pointer to the memory context |
MId1 | the first MId to compare |
MId2 | the second MId to compare |
plResult | pointer to the value of the comparison |
References nspi_context::handle, OPENCHANGE_RETVAL_IF, nspi_context::pStat, and nspi_context::rpc_connection.
enum MAPISTATUS nspi_DNToMId | ( | struct nspi_context * | nspi_ctx, |
TALLOC_CTX * | mem_ctx, | ||
struct StringsArray_r * | pNames, | ||
struct PropertyTagArray_r ** | ppMIds | ||
) |
Maps a set of DN to a set of MId
nspi_ctx | pointer to the NSPI connection context |
mem_ctx | pointer to the memory context |
pNames | pointer to a StringsArray_r structure with the DN to map |
ppMIds | pointer on pointer to the returned list of MIds |
References nspi_context::handle, OPENCHANGE_RETVAL_IF, and nspi_context::rpc_connection.
Referenced by GetABRecipientInfo(), and ProcessNetworkProfile().
enum MAPISTATUS nspi_GetIDsFromNames | ( | struct nspi_context * | nspi_ctx, |
TALLOC_CTX * | mem_ctx, | ||
bool | VerifyNames, | ||
uint32_t | cNames, | ||
struct PropertyName_r * | ppNames, | ||
struct SPropTagArray ** | ppPropTags | ||
) |
Retrieve the Property IDs associated with property names from the NSPI server.
nspi_ctx | pointer on the NSPI connection context |
mem_ctx | pointer to the memoty context |
VerifyNames | boolean value defining whether the NSPI server must verify that all client specified names are recognized by the server |
cNames | count of PropertyName_r entries |
ppNames | pointer to a PropertyName_r structure with the list of property tags supplied by the client |
ppPropTags | pointer on pointer to the list of proptags returned by the server |
References nspi_context::handle, OPENCHANGE_RETVAL_IF, and nspi_context::rpc_connection.
enum MAPISTATUS nspi_GetMatches | ( | struct nspi_context * | nspi_ctx, |
TALLOC_CTX * | mem_ctx, | ||
struct SPropTagArray * | pPropTags, | ||
struct Restriction_r * | Filter, | ||
uint32_t | ulRequested, | ||
struct PropertyRowSet_r ** | ppRows, | ||
struct PropertyTagArray_r ** | ppOutMIds | ||
) |
Returns an explicit table.
nspi_ctx | pointer to the NSPI connection context |
mem_ctx | pointer to the memory context |
pPropTags | pointer to an array of property tags of columns |
Filter | pointer to the Restriction to apply to the table |
ulRequested | The upper limit for returned rows |
ppRows | pointer to pointer to a SRowSet structure holding the rows returned by the server |
ppOutMIds | pointer to pointer to a list of MId that comprise a restricted address book container |
References nspi_context::handle, OPENCHANGE_RETVAL_IF, nspi_context::pStat, and nspi_context::rpc_connection.
Referenced by DuplicateProfile(), and ProcessNetworkProfile().
enum MAPISTATUS nspi_GetNamesFromIDs | ( | struct nspi_context * | nspi_ctx, |
TALLOC_CTX * | mem_ctx, | ||
struct FlatUID_r * | lpGuid, | ||
struct SPropTagArray * | pPropTags, | ||
struct SPropTagArray ** | ppReturnedPropTags, | ||
struct PropertyNameSet_r ** | ppNames | ||
) |
Returns a list of property names for a set of proptags
nspi_ctx | pointer on the NSPI connection text |
mem_ctx | pointer to the memory context |
lpGuid | the property set about which the client is requesting information |
pPropTags | pointer to the proptags list |
ppReturnedPropTags | pointer on pointer to the list of all the proptags in the property set specified in lpGuid |
ppNames | pointer on pointer to the list of property names returned by the server |
References nspi_context::handle, OPENCHANGE_RETVAL_IF, and nspi_context::rpc_connection.
enum MAPISTATUS nspi_GetPropList | ( | struct nspi_context * | nspi_ctx, |
TALLOC_CTX * | mem_ctx, | ||
bool | WantObject, | ||
uint32_t | dwMId, | ||
struct SPropTagArray ** | ppPropTags | ||
) |
Returns a list of all the properties that have values on the specified object
nspi_ctx | pointer to the NSPI connection context |
mem_ctx | pointer to the memory context |
WantObject | boolean value defining whether we want the server to include properties with the type set to PT_OBJECT |
dwMId | the MId of the specified object |
ppPropTags | pointer on pointer to the list of property tags associated to the object. |
References nspi_context::handle, OPENCHANGE_RETVAL_IF, nspi_context::pStat, and nspi_context::rpc_connection.
enum MAPISTATUS nspi_GetProps | ( | struct nspi_context * | nspi_ctx, |
TALLOC_CTX * | mem_ctx, | ||
struct SPropTagArray * | pPropTags, | ||
struct PropertyTagArray_r * | MId, | ||
struct PropertyRowSet_r ** | SRowSet | ||
) |
Returns an address book row containing a set of the properties and values that exists on an object
nspi_ctx | pointer to the NSPI connection context |
mem_ctx | pointer to the memory context |
pPropTags | pointer to the list of property tags that the client wants to be returned |
MId | pointer to the MId of the record |
SRowSet | pointer on pointer to the row returned by the server |
References nspi_context::handle, OPENCHANGE_RETVAL_IF, nspi_context::pStat, and nspi_context::rpc_connection.
Referenced by GetABRecipientInfo(), and ProcessNetworkProfile().
enum MAPISTATUS nspi_GetSpecialTable | ( | struct nspi_context * | nspi_ctx, |
TALLOC_CTX * | mem_ctx, | ||
uint32_t | Type, | ||
struct PropertyRowSet_r ** | ppRows | ||
) |
Returns the rows of a special table to the client. The special table can be a Hierarchy Table or an Address Creation Table
nspi_ctx | pointer to the NSPI connection context |
mem_ctx | pointer to the memory context |
Type | bitmap of flags defining the type of the special table |
ppRows | pointer on pointer to the rows returned by the server |
Possible values for Type:
If NspiAddressCreationTemplates is not set, then NspiGetSpecialTable will automatically fetch the Hierarchy Table.
If NspiAddressCreationTemplates is set, then NspiUnicodeStrings is ignored.
References nspi_context::handle, OPENCHANGE_RETVAL_IF, nspi_context::pStat, nspi_context::rpc_connection, and nspi_context::version.
Referenced by DuplicateProfile(), and ProcessNetworkProfile().
enum MAPISTATUS nspi_GetTemplateInfo | ( | struct nspi_context * | nspi_ctx, |
TALLOC_CTX * | mem_ctx, | ||
uint32_t | dwFlags, | ||
uint32_t | ulType, | ||
char * | pDN, | ||
struct PropertyRow_r ** | ppData | ||
) |
Returns information about template objects in the address book.
nspi_ctx | pointer to the NSPI memory context |
mem_ctx | pointer to the memory context |
dwFlags | set of bit flags |
ulType | specifies the display type of the template |
pDN | the DN of the template requested |
ppData | pointer on pointer to the data requested |
Possible values for dwFlags:
References nspi_context::handle, OPENCHANGE_RETVAL_IF, nspi_context::pStat, and nspi_context::rpc_connection.
enum MAPISTATUS nspi_ModLinkAtt | ( | struct nspi_context * | nspi_ctx, |
bool | Delete, | ||
uint32_t | ulPropTag, | ||
uint32_t | MId, | ||
struct BinaryArray_r * | lpEntryIds | ||
) |
Modifies the values of a specific property of a specific row in the address book. This function only applies only to rows that support the PT_OBJECT Property Type.
nspi_ctx | pointer to the NSPI connection context |
Delete | boolean value defining whether the server must remove all values specified by the input parameter lpEntryIDs from the property specified by ulPropTag |
ulPropTag | property tag of the property the client wishes to modify |
MId | the MId of the address book object |
lpEntryIds | array of BinaryArray_r structures intended to be modified or deleted |
References nspi_context::handle, nspi_context::mem_ctx, OPENCHANGE_RETVAL_IF, PT_OBJECT, and nspi_context::rpc_connection.
enum MAPISTATUS nspi_ModProps | ( | struct nspi_context * | nspi_ctx, |
TALLOC_CTX * | mem_ctx, | ||
uint32_t | MId, | ||
struct SPropTagArray * | pPropTags, | ||
struct PropertyRow_r * | pRow | ||
) |
Modify the properties of an object in the address book
nspi_ctx | pointer to the NSPI connection context |
mem_ctx | pointer to the memory context |
MId | the MId of the address book object |
pPropTags | pointer to the list of properties to be modified on the object |
pRow | Contains an address book row |
References nspi_context::handle, OPENCHANGE_RETVAL_IF, nspi_context::pStat, and nspi_context::rpc_connection.
enum MAPISTATUS nspi_QueryColumns | ( | struct nspi_context * | nspi_ctx, |
TALLOC_CTX * | mem_ctx, | ||
bool | WantUnicode, | ||
struct SPropTagArray ** | ppColumns | ||
) |
Returns a list of all the properties the NSPI server is aware off.
nspi_ctx | pointer to the NSPI connection context |
mem_ctx | pointer to the memory context |
WantUnicode | whether we want UNICODE properties or not |
ppColumns | pointer on pointer to a property tag array |
References nspi_context::handle, OPENCHANGE_RETVAL_IF, and nspi_context::rpc_connection.
enum MAPISTATUS nspi_QueryRows | ( | struct nspi_context * | nspi_ctx, |
TALLOC_CTX * | mem_ctx, | ||
struct SPropTagArray * | pPropTags, | ||
struct PropertyTagArray_r * | MIds, | ||
uint32_t | count, | ||
struct PropertyRowSet_r ** | ppRows | ||
) |
Returns a number of Rows from a specified table.
nspi_ctx | pointer to the NSPI connection context |
mem_ctx | pointer to the memory context |
pPropTags | pointer to the list of proptags that the client requires to be returned for each row. |
MIds | pointer to a list of values representing an Explicit table |
count | the number of rows requested |
ppRows | pointer on pointer to the the rows returned by the server |
References nspi_context::handle, OPENCHANGE_RETVAL_IF, nspi_context::pStat, and nspi_context::rpc_connection.
Referenced by GetGALTable(), GetGALTableCount(), and ProcessNetworkProfile().
enum MAPISTATUS nspi_ResolveNames | ( | struct nspi_context * | nspi_ctx, |
TALLOC_CTX * | mem_ctx, | ||
const char ** | usernames, | ||
struct SPropTagArray * | pPropTags, | ||
struct PropertyRowSet_r *** | pppRows, | ||
struct PropertyTagArray_r *** | pppMIds | ||
) |
Takes a set of string values in an 8-bit character set and performs ANR on those strings
nspi_ctx | pointer on the NSPI connection context |
mem_ctx | pointer to the memory context |
usernames | pointer on pointer to the list of values we want to perform ANR on |
pPropTags | pointer on the property tags list we want for each row returned |
pppRows | pointer on pointer on pointer to the rows returned by the server |
pppMIds | pointer on pointer on pointer to the MIds matching the array of strings |
References nspi_context::handle, OPENCHANGE_RETVAL_IF, nspi_context::pStat, and nspi_context::rpc_connection.
Referenced by ResolveNames().
enum MAPISTATUS nspi_ResolveNamesW | ( | struct nspi_context * | nspi_ctx, |
TALLOC_CTX * | mem_ctx, | ||
const char ** | usernames, | ||
struct SPropTagArray * | pPropTags, | ||
struct PropertyRowSet_r *** | pppRows, | ||
struct PropertyTagArray_r *** | pppMIds | ||
) |
Takes a set of string values in the Unicode character set and performs ambiguous name resolution (ANR) on those strings
nspi_ctx | pointer on the NSPI connection context |
mem_ctx | pointer to the memory context |
usernames | pointer on pointer to the list of values we want to perform ANR on |
pPropTags | pointer on the property tags list we want for each row returned |
pppRows | pointer on pointer on pointer to the rows returned by the server |
pppMIds | pointer on pointer on pointer to the MIds matching the array of strings |
References nspi_context::handle, OPENCHANGE_RETVAL_IF, nspi_context::pStat, and nspi_context::rpc_connection.
Referenced by ResolveNames().
enum MAPISTATUS nspi_ResortRestriction | ( | struct nspi_context * | nspi_ctx, |
TALLOC_CTX * | mem_ctx, | ||
enum TableSortOrders | SortType, | ||
struct PropertyTagArray_r * | pInMIds, | ||
struct PropertyTagArray_r ** | ppMIds | ||
) |
Applies a sort order to the objects in a restricted address book container
nspi_ctx | pointer to the NSPI connection context |
mem_ctx | pointer to the memory context |
SortType | the table sort order to use |
pInMIds | pointer on a list of MIds that comprise a restricted address book container |
ppMIds | pointer on pointer to the returned list of MIds that comprise a restricted address book container. |
SortType can take the following values:
References nspi_context::handle, OPENCHANGE_RETVAL_IF, nspi_context::pStat, and nspi_context::rpc_connection.
enum MAPISTATUS nspi_SeekEntries | ( | struct nspi_context * | nspi_ctx, |
TALLOC_CTX * | mem_ctx, | ||
enum TableSortOrders | SortType, | ||
struct PropertyValue_r * | pTarget, | ||
struct SPropTagArray * | pPropTags, | ||
struct PropertyTagArray_r * | pMIds, | ||
struct PropertyRowSet_r ** | pRows | ||
) |
Searches for and sets the logical position in a specific table to the first entry greater than or equal to a specified value. Optionally, it might also return information about rows in the table.
nspi_ctx | pointer to the NSPI connection context |
mem_ctx | pointer to the memory context |
SortType | the table sort order to use |
pTarget | PropertyValue_r struct holding the value being sought |
pPropTags | pointer to an array of property tags of columns that the client wants to be returned for each row returned. |
pMIds | pointer to a list of Mid that comprise a restricted address book container |
pRows | pointer to pointer to a SRowSet structure holding the rows returned by the server |
SortType can take the following values:
If pTarget property tag is not set accordingly to SortType, the function returns MAPI_E_INVALID_PARAMETER. Possible values are:
References nspi_context::handle, OPENCHANGE_RETVAL_IF, PR_DISPLAY_NAME, PR_DISPLAY_NAME_UNICODE, PR_EMS_AB_PHONETIC_DISPLAY_NAME, PR_EMS_AB_PHONETIC_DISPLAY_NAME_UNICODE, nspi_context::pStat, and nspi_context::rpc_connection.
enum MAPISTATUS nspi_unbind | ( | struct nspi_context * | nspi_ctx) |
Destroys the context handle
nspi_ctx | pointer to the NSPI connection context |
References nspi_context::handle, MAPI_STATUS_IS_OK, nspi_context::mem_ctx, OPENCHANGE_RETVAL_IF, and nspi_context::rpc_connection.
Referenced by nspi_disconnect_dtor().
enum MAPISTATUS nspi_UpdateStat | ( | struct nspi_context * | nspi_ctx, |
TALLOC_CTX * | mem_ctx, | ||
uint32_t * | plDelta | ||
) |
Updates the STAT block representing position in a table to reflect positioning changes requested by the client.
nspi_ctx | pointer to the NSPI connection context |
mem_ctx | pointer to the memory context |
plDelta | pointer to an unsigned long indicating movement within the address book container specified by the input parameter pStat. |
References nspi_context::handle, OPENCHANGE_RETVAL_IF, nspi_context::pStat, and nspi_context::rpc_connection.
enum MAPISTATUS OpenAttach | ( | mapi_object_t * | obj_message, |
uint32_t | AttachmentID, | ||
mapi_object_t * | obj_attach | ||
) |
Open an attachment to a message
This function opens one attachment from a message. The attachment to be opened is specified by its PR_ATTACH_NUM.
obj_message | the message to operate on |
AttachmentID | the attachment number |
obj_attach | the resulting attachment object |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), mapi_object_set_handle(), mapi_object_set_logon_id(), mapi_object_set_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS OpenEmbeddedMessage | ( | mapi_object_t * | obj_attach, |
mapi_object_t * | obj_embeddedmsg, | ||
enum OpenEmbeddedMessage_OpenModeFlags | ulFlags | ||
) |
Opens an embedded message object and retrieves a MAPI object that can be used to get or set properties on the embedded message.
This function essentially takes an attachment and gives you back a message.
obj_attach | the attachment object |
obj_embeddedmsg | the embedded message |
ulFlags | access rights on the embedded message |
Possible ulFlags values:
References mapi_obj_message::cValues, emsmdb_get_SRow(), emsmdb_transaction_wrapper(), mapi_session::mapi_ctx, mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), mapi_object_set_handle(), mapi_object_set_logon_id(), mapi_object_set_session(), OPENCHANGE_CHECK_NOTIFICATION, OPENCHANGE_RETVAL_IF, PR_INTERNET_CPID, PR_RECIPIENT_TYPE, mapi_object::private_data, mapi_obj_message::SPropTagArray, SPropTagArray_add(), SRow_addprop(), and mapi_obj_message::SRowSet.
enum MAPISTATUS OpenFolder | ( | mapi_object_t * | obj_store, |
mapi_id_t | id_folder, | ||
mapi_object_t * | obj_folder | ||
) |
Open a folder from the store
obj_store | the store to open a folder in (i.e. the parent) |
id_folder | the folder identifier |
obj_folder | the resulting open folder |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), mapi_object_set_handle(), mapi_object_set_id(), mapi_object_set_logon_id(), mapi_object_set_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
Referenced by GetUserFreeBusyData().
enum MAPISTATUS OpenMessage | ( | mapi_object_t * | obj_store, |
mapi_id_t | id_folder, | ||
mapi_id_t | id_message, | ||
mapi_object_t * | obj_message, | ||
uint8_t | ulFlags | ||
) |
Opens a specific message and retrieves a MAPI object that can be used to get or set message properties.
This function opens a specific message defined by a combination of object store, folder ID, and message ID and which read/write access is defined by ulFlags.
obj_store | the store to read from |
id_folder | the folder ID |
id_message | the message ID |
obj_message | the resulting message object |
ulFlags | Possible ulFlags values:
|
References mapi_obj_message::cValues, emsmdb_get_SRow(), emsmdb_transaction_wrapper(), get_TypedString(), mapi_session::mapi_ctx, mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), mapi_object_set_handle(), mapi_object_set_logon_id(), mapi_object_set_session(), mapi_obj_message::NormalizedSubject, OPENCHANGE_CHECK_NOTIFICATION, OPENCHANGE_RETVAL_IF, PR_INTERNET_CPID, PR_RECIPIENT_TYPE, mapi_object::private_data, mapi_obj_message::SPropTagArray, SPropTagArray_add(), SRow_addprop(), mapi_obj_message::SRowSet, and mapi_obj_message::SubjectPrefix.
Referenced by GetUserFreeBusyData().
enum MAPISTATUS OpenMsgStore | ( | struct mapi_session * | session, |
mapi_object_t * | obj_store | ||
) |
Open the Message Store
This function opens the main message store. This allows access to the normal user folders.
session | pointer to the MAPI session context |
obj_store | the result of opening the store |
References GetLastError(), OPENCHANGE_RETVAL_IF, OpenUserMailbox(), mapi_session::profile, and mapi_profile::username.
enum MAPISTATUS OpenProfile | ( | struct mapi_context * | mapi_ctx, |
struct mapi_profile * | profile, | ||
const char * | profname, | ||
const char * | password | ||
) |
Load a profile from the database
This function opens a named profile from the database, and fills the mapi_profile structure with common profile information.
mapi_ctx | pointer to the MAPI context |
profile | the resulting profile |
profname | the name of the profile to open |
password | the password to use with the profile |
References mapi_context::ldb_ctx, mapi_profile::mapi_ctx, and OPENCHANGE_RETVAL_IF.
Referenced by DuplicateProfile(), and MapiLogonProvider().
enum MAPISTATUS OpenPublicFolder | ( | struct mapi_session * | session, |
mapi_object_t * | obj_store | ||
) |
Open the Public Folder store
This function opens the public folder store. This allows access to the public folders.
obj_store | the result of opening the store |
session | pointer to the MAPI session context |
References emsmdb_transaction_wrapper(), mapi_obj_store::fid_pf_EFormsRegistry, mapi_obj_store::fid_pf_EFormsRegistryRoot, mapi_obj_store::fid_pf_FreeBusyRoot, mapi_obj_store::fid_pf_ipm_subtree, mapi_obj_store::fid_pf_LocalSiteFreeBusy, mapi_obj_store::fid_pf_LocalSiteOfflineAB, mapi_obj_store::fid_pf_NNTPArticle, mapi_obj_store::fid_pf_non_ipm_subtree, mapi_obj_store::fid_pf_OfflineAB, mapi_obj_store::fid_pf_public_root, GetNewLogonId(), mapi_obj_store::guid, mapi_object_set_handle(), mapi_object_set_logon_id(), mapi_object_set_logon_store(), mapi_object_set_session(), OPENCHANGE_CHECK_NOTIFICATION, OPENCHANGE_RETVAL_IF, mapi_object::private_data, mapi_session::profile, PublicFolder, and mapi_obj_store::store_type.
enum MAPISTATUS OpenPublicFolderByName | ( | mapi_object_t * | obj_folder, |
mapi_object_t * | obj_child, | ||
const char * | name | ||
) |
Open a NNTP Public Folder given its name
obj_folder | the parent folder |
obj_child | the resulting open folder |
name | the folder name |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), mapi_object_set_handle(), mapi_object_set_logon_id(), mapi_object_set_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS OpenStream | ( | mapi_object_t * | obj_related, |
enum MAPITAGS | PropertyTag, | ||
enum OpenStream_OpenModeFlags | OpenModeFlags, | ||
mapi_object_t * | obj_stream | ||
) |
Open a stream
This function opens a stream on the property prop set in obj_related with access flags set to access_flags and returns an object obj_stream.
obj_related | the object to open. |
PropertyTag | the property name for the object to create a stream for. |
OpenModeFlags | sets the access mode for the stream and is one of the following values: 0x0: ReadOnly 0x1: ReadWrite 0x2: Create 0x3: BestAccess |
obj_stream | the resulting stream object. |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), mapi_object_set_handle(), mapi_object_set_logon_id(), mapi_object_set_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS OpenUserMailbox | ( | struct mapi_session * | session, |
const char * | username, | ||
mapi_object_t * | obj_store | ||
) |
Open another user mailbox
This function opens the main message store. This allows access to the normal user folders.
session | pointer to the MAPI session context |
username | name of the user's mailbox to open |
obj_store | the result of opening the store |
References emsmdb_transaction_wrapper(), mapi_obj_store::fid_common_views, mapi_obj_store::fid_deferred_actions, mapi_obj_store::fid_deleted_items, mapi_obj_store::fid_inbox, mapi_obj_store::fid_mailbox_root, mapi_obj_store::fid_outbox, mapi_obj_store::fid_schedule, mapi_obj_store::fid_search, mapi_obj_store::fid_sent_items, mapi_obj_store::fid_shortcuts, mapi_obj_store::fid_spooler_queue, mapi_obj_store::fid_top_information_store, mapi_obj_store::fid_views, GetNewLogonId(), mapi_obj_store::guid, mapi_profile::mailbox, mapi_object_set_handle(), mapi_object_set_logon_id(), mapi_object_set_logon_store(), mapi_object_set_session(), OPENCHANGE_CHECK_NOTIFICATION, OPENCHANGE_RETVAL_CALL_IF, OPENCHANGE_RETVAL_IF, mapi_profile::org, mapi_profile::ou, mapi_object::private_data, PrivateFolderWithoutCachedFids, mapi_session::profile, and mapi_obj_store::store_type.
Referenced by OpenMsgStore().
enum MAPISTATUS OptionsData | ( | mapi_object_t * | obj_store, |
const char * | addrtype, | ||
uint8_t ** | OptionsData, | ||
uint16_t * | OptionsLength, | ||
uint8_t ** | HelpFile, | ||
uint16_t * | HelpFileLength, | ||
const char ** | HelpFileName | ||
) |
Returns options information for the types of recipients that the transport provider handles.
[in] | obj_store | the object to get recipients types from |
[in] | addrtype | string name of the address type to get options for |
[out] | OptionsData | the options data for this addrtype |
[out] | OptionsLength | length of the OptionsData array |
[out] | HelpFile | the help file data for this addrtype (often empty) |
[out] | HelpFileLength | length of the HelpFile array |
[out] | HelpFileName | the name of the help file (often null) |
The caller is responsible for talloc_free()ing the OptionsData array.
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS ProcessNetworkProfile | ( | struct mapi_session * | session, |
const char * | username, | ||
mapi_profile_callback_t | callback, | ||
const void * | private_data | ||
) |
Process a full and automated MAPI profile creation
This function process a full and automated MAPI profile creation using the username pattern passed as a parameter. The functions takes a callback parameter which will be called when the username checked matches several usernames. Private data needed by the callback can be supplied using the private_data pointer.
The callback returns the SRow element index within the SRowSet structure. If the user cancels the operation the callback return value should be SRowSet->cRows or more.
session | the session context |
username | the username for the network profile |
callback | function pointer callback function |
private_data | context data that will be provided to the callback |
References nspi_context::cred, mapi_provider::ctx, get_PropertyValue_PropertyRowSet(), mapi_session::mapi_ctx, mapi_profile_add_string_attr(), MAPIFreeBuffer(), mapi_session::nspi, nspi_DNToMId(), nspi_GetMatches(), nspi_GetProps(), nspi_GetSpecialTable(), nspi_QueryRows(), OPENCHANGE_RETVAL_IF, nspi_context::org, ORG, nspi_context::org_unit, ORG_UNIT, PR_ACCOUNT, PR_ADDRTYPE, PR_ANR_UNICODE, PR_ATTACH_NUM, PR_COMPANY_NAME, PR_DISPLAY_NAME, PR_DISPLAY_TYPE, PR_EMAIL_ADDRESS, PR_EMS_AB_HOME_MDB, PR_EMS_AB_NETWORK_ADDRESS, PR_EMS_AB_PROXY_ADDRESSES, PR_ENTRYID, PR_INSTANCE_KEY, PR_OBJECT_TYPE, PR_OFFICE_LOCATION, PR_OFFICE_TELEPHONE_NUMBER, PR_PROFILE_HOME_SERVER_ADDRS, PR_TITLE, mapi_session::profile, mapi_profile::profname, nspi_context::pStat, RES_PROPERTY, SERVER_DN, nspi_context::servername, set_SPropTagArray(), x500_get_dn_element(), and x500_get_servername().
enum MAPISTATUS PropertyRow_addprop | ( | struct PropertyRow_r * | aRow, |
struct PropertyValue_r | propValue | ||
) |
add a PropertyValue_r structure to a PropertyRow_r array
aRow | pointer to the PropertyRow_r array where propValue should be appended |
propValue | the PropertyValue_r structure to add to aRow |
References get_PropertyValue_data(), OPENCHANGE_RETVAL_IF, and set_PropertyValue().
uint32_t PropertyRowSet_propcpy | ( | TALLOC_CTX * | mem_ctx, |
struct PropertyRowSet_r * | RowSet, | ||
struct PropertyValue_r | value | ||
) |
Append a PropertyValue_r structure to given PropertyRowSet_r
mem_ctx | pointer to the memory context |
RowSet | pointer to the PropertyRowSet_r array to update |
value | the PropertyValue_r to append within SRowSet |
References set_PropertyValue().
enum MAPISTATUS PublicFolderIsGhosted | ( | mapi_object_t * | obj_store, |
mapi_object_t * | obj_folder, | ||
bool * | IsGhosted | ||
) |
Determine if a public folder is ghosted.
This function returns whether a public folder is ghosted or not.
obj_store | the store of the public folder |
obj_folder | the folder we are querying for ghost |
IsGhosted | pointer on the boolean value returned |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_id(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS QueryColumns | ( | mapi_object_t * | obj_table, |
struct SPropTagArray * | cols | ||
) |
Retrieves the set of columns defined in the current table view
obj_table | the table we are retrieving columns from |
cols | pointer to an array of property tags |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, OPENCHANGE_RETVAL_IF, and mapi_object::private_data.
enum MAPISTATUS QueryNamedProperties | ( | mapi_object_t * | obj, |
uint8_t | queryFlags, | ||
struct GUID * | guid, | ||
uint16_t * | count, | ||
uint16_t ** | propID, | ||
struct MAPINAMEID ** | nameid | ||
) |
Provides the property names that correspond to one or more property identifiers.
obj | the object to obtain the properties for |
queryFlags | A set of flags that can restrict the type of properties |
guid | a pointer to the GUID for the property set to fetch (null for all property sets. |
count | count of property names pointed to by the nameid and propID parameters returned by the server |
propID | pointer to an array of property IDs returned by the server |
nameid | pointer to an array of property names returned by the server |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS QueryPosition | ( | mapi_object_t * | obj_table, |
uint32_t * | Numerator, | ||
uint32_t * | Denominator | ||
) |
Returns the approximate cursor position
obj_table | pointer to the table's object |
Numerator | pointer to the numerator of the fraction identifying the table position |
Denominator | pointer to the denominator of the fraction identifying the table position |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
Referenced by ModifyUserPermission(), and RemoveUserPermission().
enum MAPISTATUS QueryRows | ( | mapi_object_t * | obj_table, |
uint16_t | row_count, | ||
enum QueryRowsFlags | flags, | ||
struct SRowSet * | rowSet | ||
) |
Returns a RowSet with the properties returned by the server
obj_table | the table we are requesting properties from |
row_count | the maximum number of rows to retrieve |
flags | flags to use for the query |
rowSet | the results |
flags possible values:
References emsmdb_get_SRowSet(), emsmdb_transaction_wrapper(), mapi_session::mapi_ctx, mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, OPENCHANGE_RETVAL_IF, mapi_object::private_data, and mapi_obj_table::proptags.
Referenced by ModifyUserPermission(), and RemoveUserPermission().
struct rawidset* RAWIDSET_make | ( | TALLOC_CTX * | , |
bool | , | ||
bool | |||
) |
References rawidset::count, rawidset::globcnts, rawidset::idbased, rawidset::max_count, rawidset::mem_ctx, rawidset::next, and rawidset::single.
Referenced by RAWIDSET_push_eid(), and RAWIDSET_push_guid_glob().
void RAWIDSET_push_eid | ( | struct rawidset * | , |
uint64_t | |||
) |
void RAWIDSET_push_guid_glob | ( | struct rawidset * | , |
const struct GUID * | , | ||
uint64_t | |||
) |
enum MAPISTATUS ReadRecipients | ( | mapi_object_t * | obj_message, |
uint32_t | RowId, | ||
uint8_t * | RowCount, | ||
struct ReadRecipientRow ** | RecipientRows | ||
) |
Read Recipients from a message
obj_message | the message we want to read recipients from |
RowId | the row index we start reading recipients from |
RowCount | pointer on the number of recipients |
RecipientRows | pointer on the recipients array |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS ReadStream | ( | mapi_object_t * | obj_stream, |
unsigned char * | buf_data, | ||
uint16_t | ByteCount, | ||
uint16_t * | ByteRead | ||
) |
Read buffer from a stream
This function reads from an open data stream. It will read up to ByteCount bytes from the stream, and return the data in data_buf. ByteRead is set to the number of bytes actually read.
obj_stream | the opened stream object |
buf_data | the buffer where data read from the stream will be stored |
ByteCount | the number of bytes requested to be read from the stream |
ByteRead | the number of bytes read from the stream |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
Referenced by WrapCompressedRTFStream().
enum MAPISTATUS RegisterAsyncNotification | ( | struct mapi_session * | session, |
uint32_t * | resultFlag | ||
) |
Create an asynchronous notification
This function initializes the notification subsystem and configures the server to send notifications. Note that this call will block.
session | the session context to register for notifications on. |
resultFlag | the result of the operation (true if there was anything returned) |
References mapi_provider::ctx, mapi_session::emsmdb, emsmdb_async_waitex(), emsmdb_context::mem_ctx, notifications::next, mapi_notify_ctx::notifications, mapi_session::notify_ctx, OPENCHANGE_RETVAL_IF, and notifications::prev.
enum MAPISTATUS RegisterNotification | ( | struct mapi_session * | session) |
Initialize the notification subsystem
This function initializes the notification subsystem, binds a local UDP port to receive Exchange (server side) notifications and configures the server to send notifications on this port.
session | the session context to register for notifications on. |
References mapi_provider::ctx, mapi_session::emsmdb, emsmdb_bind_notification(), emsmdb_register_notification(), mapi_session::mapi_ctx, emsmdb_context::mem_ctx, mapi_session::notify_ctx, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS Release | ( | mapi_object_t * | obj) |
Release an object on the server
The function releases the object obj on the server.
obj | the object to release |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
Referenced by mapi_object_release(), and Unsubscribe().
enum MAPISTATUS ReloadCachedInformation | ( | mapi_object_t * | obj_message) |
Retrieve the message properties for an already open message.
This function is very similar to OpenMessage, but works on an already open message object.
obj_message | the message object to retrieve the properties for. |
References mapi_obj_message::cValues, emsmdb_get_SRow(), emsmdb_transaction_wrapper(), mapi_session::mapi_ctx, mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, OPENCHANGE_RETVAL_IF, PR_INTERNET_CPID, PR_RECIPIENT_TYPE, mapi_object::private_data, mapi_obj_message::SPropTagArray, SPropTagArray_add(), SRow_addprop(), and mapi_obj_message::SRowSet.
enum MAPISTATUS RemoveAllRecipients | ( | mapi_object_t * | obj_message) |
Deletes all recipients from a message
obj_message | the message we want to remove all recipients from |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS RemoveUserPermission | ( | mapi_object_t * | obj_folder, |
const char * | username | ||
) |
Remove permissions for a user on a given folder
obj_folder | the folder to remove permission from |
username | the Exchange username to remove permissions for |
References find_PropertyValue_data(), get_SPropValue_SRow(), GetPermissionsTable(), mapi_object_get_session(), mapi_object_init(), mapi_object_release(), MAPI_RESOLVED, MAPIFreeBuffer(), ModifyPermissions(), OPENCHANGE_RETVAL_IF, PR_DISPLAY_NAME, PR_ENTRYID, PR_MEMBER_ID, PR_MEMBER_NAME, PR_MEMBER_RIGHTS, QueryPosition(), QueryRows(), ResolveNames(), set_SPropTagArray(), and SetColumns().
enum MAPISTATUS RenameProfile | ( | struct mapi_context * | mapi_ctx, |
const char * | old_profile, | ||
const char * | profile | ||
) |
Rename a profile
mapi_ctx | pointer to the MAPI context |
old_profile | old profile name |
profile | new profile name |
References get_SPropValue_SRow(), GetProfileTable(), mapi_context::ldb_ctx, nspi_context::mem_ctx, mapi_context::mem_ctx, OPENCHANGE_RETVAL_IF, and PR_DISPLAY_NAME.
enum MAPISTATUS Reset | ( | mapi_object_t * | obj_table) |
Removes all filters that are currently on a table
obj_table | the table object to reset |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS ResolveNames | ( | struct mapi_session * | session, |
const char ** | usernames, | ||
struct SPropTagArray * | props, | ||
struct PropertyRowSet_r ** | rowset, | ||
struct PropertyTagArray_r ** | flaglist, | ||
uint32_t | flags | ||
) |
Resolve user names against the Windows Address Book Provider
session | pointer to the MAPI session context |
usernames | list of user names to resolve |
rowset | resulting list of user details |
props | resulting list of resolved names |
flaglist | resulting list of resolution status (see below) |
flags | if set to MAPI_UNICODE then UNICODE MAPITAGS can be used, otherwise only UTF8 encoded fields may be returned. |
Possible flaglist values are:
MAPI_E_CALL_FAILED: A network problem was encountered during the transaction
It is the developer responsibility to call MAPIFreeBuffer on rowset and flaglist once they have finished to use them.
References mapi_provider::ctx, MAPI_UNICODE, nspi_context::mem_ctx, mapi_session::nspi, nspi_ResolveNames(), nspi_ResolveNamesW(), and OPENCHANGE_RETVAL_IF.
Referenced by AddUserPermission(), GetABRecipientInfo(), ModifyUserPermission(), and RemoveUserPermission().
enum MAPISTATUS Restrict | ( | mapi_object_t * | obj_table, |
struct mapi_SRestriction * | res, | ||
uint8_t * | TableStatus | ||
) |
Applies a filter to a table, reducing the row set to only those rows matching the specified criteria.
obj_table | the object we are filtering |
res | the filters we want to apply |
TableStatus | the table status result |
TableStatus can either hold:
Unlike MAPI, you don't pass a null restriction argument to remove the current restrictions. Use Reset() instead.
TableStatus should be set to NULL if you don't want to retrieve the status of the table.
References emsmdb_transaction_wrapper(), get_mapi_SRestriction_size(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS RfrGetFQDNFromLegacyDN | ( | struct mapi_context * | mapi_ctx, |
struct mapi_session * | session, | ||
const char ** | serverFQDN | ||
) |
Returns the FQDN of the NSPI server corresponding to a DN
mapi_ctx | pointer to the MAPI context |
session | pointer to the MAPI session context |
serverFQDN | pointer to the server FQDN string (return value) |
References mapi_profile::credentials, mapi_profile::homemdb, mapi_context::lp_ctx, OPENCHANGE_RETVAL_IF, mapi_session::profile, RfrGetFQDNFromLegacyDN(), and mapi_profile::server.
Referenced by RfrGetFQDNFromLegacyDN().
enum MAPISTATUS RfrGetNewDSA | ( | struct mapi_context * | mapi_ctx, |
struct mapi_session * | session, | ||
const char * | server, | ||
const char * | userDN, | ||
char ** | dsa | ||
) |
Returns the name of an NSPI server
mapi_ctx | pointer to the MAPI context |
session | pointer to the MAPI session context |
server | the Exchange server address (IP or FQDN) |
userDN | optional user mailbox DN |
dsa | pointer to a new dsa (return value), containing a valid allocated string on success, otherwise NULL |
It is up to the developer to free the returned string when not needed anymore.
References mapi_profile::credentials, mapi_context::lp_ctx, mapi_session::profile, RfrGetNewDSA(), and mapi_context::session.
Referenced by Logon(), and RfrGetNewDSA().
enum MAPISTATUS SaveChangesAttachment | ( | mapi_object_t * | obj_parent, |
mapi_object_t * | obj_child, | ||
enum SaveFlags | flags | ||
) |
Makes permanent any changes made to an attachment since the last save operation.
obj_parent | the parent of the object to save changes for |
obj_child | the object to save changes for |
flags | the access flags to set on the saved object |
Possible flags:
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS SaveChangesMessage | ( | mapi_object_t * | parent, |
mapi_object_t * | obj_message, | ||
uint8_t | SaveFlags | ||
) |
Saves all changes to the message
parent | the parent object for the message |
obj_message | the message to save |
SaveFlags | specify how the save operation behaves |
Possible value for SaveFlags:
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), mapi_object_set_id(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS SeekRow | ( | mapi_object_t * | obj_table, |
enum BOOKMARK | origin, | ||
int32_t | offset, | ||
uint32_t * | row | ||
) |
Move the table cursor at a specific location
obj_table | the table we are moving cursor on |
origin | the table position where we start to seek |
offset | a particular offset in the table |
row | the position of the seeked row is returned in rows |
origin possible values:
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS SeekRowApprox | ( | mapi_object_t * | obj_table, |
uint32_t | ulNumerator, | ||
uint32_t | ulDenominator | ||
) |
Moves the cursor to an approximate fractional position in the table
obj_table | the table we are moving cursor on |
ulNumerator | numerator of the fraction representing the table position. |
ulDenominator | denominator of the fraction representing the table position
|
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS SeekRowBookmark | ( | mapi_object_t * | obj_table, |
uint32_t | lpbkPosition, | ||
uint32_t | RowCount, | ||
uint32_t * | row | ||
) |
Move the table cursor at a specific location given a bookmark
obj_table | the table we are moving cursor on |
lpbkPosition | the bookmarked position |
RowCount | a relative number of rows to the bookmark |
row | the position of the seeked row is returned in rows |
References emsmdb_transaction_wrapper(), mapi_object_bookmark_find(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS SeekStream | ( | mapi_object_t * | obj_stream, |
uint8_t | Origin, | ||
uint64_t | Offset, | ||
uint64_t * | NewPosition | ||
) |
Seek a specific position within the stream
obj_stream | the stream object |
Origin | origin location for the seek operation |
Offset | the seek offset |
NewPosition | pointer on the new position after the operation |
Origin can either take one of the following values:
0x0 The new seek pointer is an offset relative to the beginning of the stream. 0x1 The new seek pointer is an offset relative to the current seek pointer location. 0x2 The new seek pointer is an offset relative to the end of the stream.
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
struct Binary_r* set_AppointmentRecurrencePattern | ( | TALLOC_CTX * | mem_ctx, |
const struct AppointmentRecurrencePattern * | |||
) |
size_t set_AppointmentRecurrencePattern_size | ( | const struct AppointmentRecurrencePattern * | ) |
enum MAPISTATUS set_default_error_SPropValue_SRow | ( | struct SRow * | , |
enum | MAPITAGS, | ||
void * | |||
) |
References set_SPropValue_proptag().
size_t set_ExceptionInfo_size | ( | const struct ExceptionInfo * | ) |
References SIZE_DFLT_EXCEPTIONINFO.
Referenced by set_AppointmentRecurrencePattern_size().
size_t set_ExtendedException_size | ( | uint32_t | , |
enum | OverrideFlags, | ||
const struct ExtendedException * | |||
) |
References SIZE_DFLT_EXTENDEDEXCEPTION.
Referenced by set_AppointmentRecurrencePattern_size().
bool set_mapi_SPropValue | ( | TALLOC_CTX * | , |
struct mapi_SPropValue * | , | ||
const void * | |||
) |
References PT_BINARY, PT_BOOLEAN, PT_CLSID, PT_DOUBLE, PT_ERROR, PT_I8, PT_LONG, PT_MV_BINARY, PT_MV_CLSID, PT_MV_LONG, PT_MV_STRING8, PT_MV_UNICODE, PT_SHORT, PT_STRING8, PT_SYSTIME, and PT_UNICODE.
Referenced by AddUserPermission(), and set_mapi_SPropValue_proptag().
bool set_mapi_SPropValue_proptag | ( | TALLOC_CTX * | , |
struct mapi_SPropValue * | , | ||
uint32_t | , | ||
const void * | |||
) |
References set_mapi_SPropValue().
Referenced by add_mapi_SPropValue().
bool set_PropertyValue | ( | struct PropertyValue_r * | , |
const void * | |||
) |
References PT_BINARY, PT_BOOLEAN, PT_CLSID, PT_ERROR, PT_LONG, PT_MV_BINARY, PT_MV_CLSID, PT_MV_LONG, PT_MV_SHORT, PT_MV_STRING8, PT_MV_SYSTIME, PT_MV_UNICODE, PT_NULL, PT_SHORT, PT_STRING8, PT_SVREID, PT_SYSTIME, and PT_UNICODE.
Referenced by PropertyRow_addprop(), and PropertyRowSet_propcpy().
struct Binary_r* set_RecurrencePattern | ( | TALLOC_CTX * | , |
const struct RecurrencePattern * | |||
) |
References set_RecurrencePattern_size().
size_t set_RecurrencePattern_size | ( | const struct RecurrencePattern * | ) |
References SIZE_DFLT_RECURRENCEPATTERN.
Referenced by set_AppointmentRecurrencePattern_size(), and set_RecurrencePattern().
struct SPropTagArray* set_SPropTagArray | ( | TALLOC_CTX * | mem_ctx, |
uint32_t | PropCount, | ||
... | |||
) |
Create a property tag array
mem_ctx | talloc memory context to use for allocation |
PropCount | the number of properties in the array |
The varargs (the third and subsequent arguments) are the property tags to make up the array. So the normal way to use this to create an array of two tags is like:
Referenced by AddUserPermission(), DuplicateProfile(), EntryIDFromSourceIDForMessage(), GetABRecipientInfo(), GetBestBody(), GetFolderItemsCount(), GetUserFreeBusyData(), ModifyUserPermission(), ProcessNetworkProfile(), and RemoveUserPermission().
bool set_SPropValue | ( | struct SPropValue * | , |
const void * | |||
) |
References PT_BINARY, PT_BOOLEAN, PT_CLSID, PT_DOUBLE, PT_ERROR, PT_I8, PT_LONG, PT_MV_BINARY, PT_MV_CLSID, PT_MV_LONG, PT_MV_SHORT, PT_MV_STRING8, PT_MV_SYSTIME, PT_MV_UNICODE, PT_NULL, PT_OBJECT, PT_SHORT, PT_STRING8, PT_SVREID, PT_SYSTIME, and PT_UNICODE.
Referenced by emsmdb_get_SPropValue(), emsmdb_get_SRow(), emsmdb_get_SRowSet(), set_SPropValue_proptag(), SRow_addprop(), and SRowSet_propcpy().
bool set_SPropValue_proptag | ( | struct SPropValue * | , |
enum | MAPITAGS, | ||
const void * | |||
) |
References set_SPropValue().
Referenced by add_SPropValue(), set_default_error_SPropValue_SRow(), and set_SPropValue_proptag_date_timeval().
bool set_SPropValue_proptag_date_timeval | ( | struct SPropValue * | , |
enum | MAPITAGS, | ||
const struct timeval * | |||
) |
References set_SPropValue_proptag().
struct Binary_r* set_TimeZoneDefinition | ( | TALLOC_CTX * | , |
const struct TimeZoneDefinition * | |||
) |
struct Binary_r* set_TimeZoneStruct | ( | TALLOC_CTX * | , |
const struct TimeZoneStruct * | |||
) |
enum MAPISTATUS SetCollapseState | ( | mapi_object_t * | obj_table, |
struct SBinary_short * | CollapseState | ||
) |
Set the Collapse State of a Table
After a contents table has been sorted and categorized using SortTable, rows can be expanded and collapsed (using ExpandRow() and CollapseRow() repectively). You can save the state of the table using GetCollapseState, and restore it using this function.
obj_table | the table we are restoring the state for |
CollapseState | the Collapse State to restore |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, OPENCHANGE_RETVAL_IF, and mapi_object::private_data.
enum MAPISTATUS SetColumns | ( | mapi_object_t * | obj_table, |
struct SPropTagArray * | properties | ||
) |
Defines the particular properties and order of properties to appear as columns in the table.
obj_table | the table the function is setting columns for |
properties | the properties intended to be set |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, OPENCHANGE_RETVAL_IF, mapi_object::private_data, and mapi_obj_table::proptags.
Referenced by GetUserFreeBusyData(), ModifyUserPermission(), and RemoveUserPermission().
enum MAPISTATUS SetDefaultProfile | ( | struct mapi_context * | mapi_ctx, |
const char * | profname | ||
) |
Set a default profile for the database
mapi_ctx | pointer to the MAPI context |
profname | the name of the profile to make the default profile |
References mapi_context::ldb_ctx, mapi_profile_modify_string_attr(), mapi_context::mem_ctx, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS SetLocalReplicaMidsetDeleted | ( | mapi_object_t * | obj_folder, |
const struct GUID | ReplGuid, | ||
const uint8_t | GlobalCountLow[6], | ||
const uint8_t | GlobalCountHigh[6] | ||
) |
Mark a range of Message Ids as deleted / unused
This function allows the client to specify that a specific range of message identifiers will never be used on a particular folder. This allows the server to make optimisations for message identifier sets during incremental change synchronisation operations.
obj_folder | pointer to the folder MAPI object |
ReplGuid | the GUID for the MIDSET |
GlobalCountLow | lower end of the range to be marked as deleted |
GlobalCountHigh | upper end of the range to be marked as deleted |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS SetMAPIDebugLevel | ( | struct mapi_context * | mapi_ctx, |
uint32_t | level | ||
) |
Set MAPI debug level
mapi_ctx | pointer to the MAPI context |
level | the debug level to set |
References mapi_context::lp_ctx, mapi_context::mem_ctx, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS SetMAPIDumpData | ( | struct mapi_context * | mapi_ctx, |
bool | status | ||
) |
Enable MAPI network trace output
mapi_ctx | pointer to the MAPI context |
status | the status |
possible status values/behavior:
References mapi_context::dumpdata, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS SetMessageReadFlag | ( | mapi_object_t * | obj_folder, |
mapi_object_t * | obj_child, | ||
uint8_t | flags | ||
) |
Clear or set the MSGFLAG_READ flag for a given message
This function clears or sets the MSGFLAG_READ flag in the PR_MESSAGE_FLAGS property of a given message.
obj_folder | the folder to operate in |
obj_child | the message to set flags on |
flags | the new flags (MSGFLAG_READ) value |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS SetMessageStatus | ( | mapi_object_t * | obj_folder, |
mapi_id_t | msgid, | ||
uint32_t | ulNewStatus, | ||
uint32_t | ulNewStatusMask, | ||
uint32_t * | ulOldStatus | ||
) |
Set the status associated with a message
This function sets the status associated with a message in the given folder.
obj_folder | the folder where the message is located |
msgid | the message ID |
ulNewStatus | the new status to be assigned |
ulNewStatusMask | bitmask of flags hat is applied to the new status indicating the flags to be set |
ulOldStatus | pointer on the previous status of the message |
ulNewStatusMask possible values:
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS SetPropertiesNoReplicate | ( | mapi_object_t * | obj, |
uint32_t | flags, | ||
struct SPropValue * | lpProps, | ||
unsigned long | PropCount | ||
) |
Set one or more properties on a given object without invoking replication.
This function sets one or more properties on a specified object. It is the same as SetProps, except if the object is a folder, where this function does not result in folder properties being replicated.
obj | the object to set properties on |
flags | Flags for behaviour; can be MAPI_PROPS_SKIP_NAMEDID_CHECK |
lpProps | the list of properties to set |
PropCount | the number of properties |
References cast_mapi_SPropValue(), mapi_nameid::count, emsmdb_transaction_wrapper(), GetIDsFromNames(), mapi_nameid_lookup_SPropValue(), mapi_nameid_map_SPropValue(), mapi_nameid_new(), mapi_nameid_unmap_SPropValue(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), MAPI_PROPS_SKIP_NAMEDID_CHECK, MAPIFreeBuffer(), mapi_nameid::nameid, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS SetProps | ( | mapi_object_t * | obj, |
uint32_t | flags, | ||
struct SPropValue * | lpProps, | ||
unsigned long | PropCount | ||
) |
Set one or more properties on a given object
This function sets one or more properties on a specified object.
obj | the object to set properties on |
flags | Flags for behaviour; can be MAPI_PROPS_SKIP_NAMEDID_CHECK |
lpProps | the list of properties to set |
PropCount | the number of properties |
References cast_mapi_SPropValue(), mapi_nameid::count, emsmdb_transaction_wrapper(), GetIDsFromNames(), mapi_nameid_lookup_SPropValue(), mapi_nameid_map_SPropValue(), mapi_nameid_new(), mapi_nameid_unmap_SPropValue(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), MAPI_PROPS_SKIP_NAMEDID_CHECK, MAPIFreeBuffer(), mapi_nameid::nameid, OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS SetReadFlags | ( | mapi_object_t * | obj_folder, |
uint8_t | ReadFlags, | ||
uint16_t | MessageIdCount, | ||
uint64_t * | MessageIds | ||
) |
Set the Read Flags on one or more messages
obj_folder | the folder containing the messages to change |
ReadFlags | a bitmap of flags controlling the changes to PR_PROPERTY_FLAGS |
MessageIdCount | the number of messages in the MessageIds array |
MessageIds | an array of message ids to set Read flags for |
Note that the obj_folder argument is the object corresponding to the folder containing the messages (e.g. the result of CreateFolder() or OpenFolder(). It is not the content table of that folder (unlike SetMessageReadFlag().)
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS SetReceiveFolder | ( | mapi_object_t * | obj_store, |
mapi_object_t * | obj_folder, | ||
const char * | lpszMessageClass | ||
) |
Sets a folder as the destination for incoming messages of a particular message class.
obj_store | the store to set the receive folder for |
obj_folder | the destination folder |
lpszMessageClass | the message class the folder will receive |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_id(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS SetRecipientType | ( | struct SRow * | aRow, |
enum ulRecipClass | RecipClass | ||
) |
Set the type of a recipient
The function sets the recipient type (RecipClass) in the aRow parameter. ResolveNames should be used to fill the SRow structure.
aRow | the row to set |
RecipClass | the type of recipient to set on the specified row |
References OPENCHANGE_RETVAL_IF, PR_RECIPIENT_TYPE, and SRow_addprop().
enum MAPISTATUS SetSearchCriteria | ( | mapi_object_t * | obj_container, |
struct mapi_SRestriction * | res, | ||
uint32_t | SearchFlags, | ||
mapi_id_array_t * | lpContainerList | ||
) |
Establishes search criteria for the container
obj_container | the object we apply search criteria to |
res | pointer to a mapi_SRestriction structure defining the search criteria |
SearchFlags | bitmask of flags that controls how the search is performed |
lpContainerList | pointer to a list of identifiers representing containers to be included in the search |
SearchFlags can take the following values:
References mapi_id_array::count, emsmdb_transaction_wrapper(), get_mapi_SRestriction_size(), mapi_id_array_get(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS SetSpooler | ( | mapi_object_t * | obj_store) |
Informs the server that the client intends to act as a mail spooler.
obj_store,: | the object server store object |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS SetStreamSize | ( | mapi_object_t * | obj_stream, |
uint64_t | SizeStream | ||
) |
Set the stream size
obj_stream | the stream object |
SizeStream | the size of the stream |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS SetSyncNotificationGuid | ( | mapi_object_t * | obj_advisor, |
const struct GUID | Guid | ||
) |
Assign a notification GUID to an ICS Advisor object
This function allows the client to set a specific GUID to an ICS advistor object (as returned from SyncOpenAdvisor). This operation is not supported on Exchange 2010.
obj_advisor | pointer to the ICS Advisor object |
Guid | the GUID for the notification |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS ShutDown | ( | struct mapi_profile * | profile) |
Release a profile
This function releases the credentials associated with the profile.
profile | the profile to release. |
References mapi_profile::credentials, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS SortTable | ( | mapi_object_t * | obj_table, |
struct SSortOrderSet * | lpSortCriteria | ||
) |
Order the rows of the table based on a criteria
obj_table | the table we are ordering rows on |
lpSortCriteria | pointer on sort criterias to apply |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
Referenced by GetUserFreeBusyData().
enum MAPISTATUS SpoolerLockMessage | ( | mapi_object_t * | obj_store, |
mapi_object_t * | obj_message, | ||
enum LockState | lockstate | ||
) |
Locks the specified message for spooling.
obj_store | the store object |
obj_message | the message object we want to lock |
lockstate | the lock state |
Possible values for the lock state:
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_id(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS SPropTagArray_add | ( | TALLOC_CTX * | mem_ctx, |
struct SPropTagArray * | SPropTagArray, | ||
enum MAPITAGS | aulPropTag | ||
) |
Add a property tag to an existing properties array
mem_ctx | talloc memory context to use for allocation |
SPropTagArray | existing properties array to add to |
aulPropTag | the property tag to add |
References OPENCHANGE_RETVAL_IF.
Referenced by OpenEmbeddedMessage(), OpenMessage(), and ReloadCachedInformation().
enum MAPISTATUS SPropTagArray_delete | ( | TALLOC_CTX * | mem_ctx, |
struct SPropTagArray * | SPropTagArray, | ||
uint32_t | aulPropTag | ||
) |
Delete a property tag from an existing properties array
mem_ctx | talloc memory context to use for allocation |
SPropTagArray | existing properties array to remove from |
aulPropTag | the property tag to remove |
References OPENCHANGE_RETVAL_IF.
enum MAPISTATUS SPropTagArray_find | ( | struct SPropTagArray | , |
enum | MAPITAGS, | ||
uint32_t * | |||
) |
enum MAPISTATUS SRow_addprop | ( | struct SRow * | aRow, |
struct SPropValue | spropvalue | ||
) |
add a SPropValue structure to a SRow array
aRow | pointer to the SRow array where spropvalue should be appended |
spropvalue | reference to the SPropValue structure to add to aRow |
References get_SPropValue_data(), OPENCHANGE_RETVAL_IF, and set_SPropValue().
Referenced by OpenEmbeddedMessage(), OpenMessage(), ReloadCachedInformation(), and SetRecipientType().
uint32_t SRowSet_propcpy | ( | TALLOC_CTX * | mem_ctx, |
struct SRowSet * | SRowSet, | ||
struct SPropValue | spropvalue | ||
) |
Append a SPropValue structure to given SRowSet
mem_ctx | pointer to the memory context |
SRowSet | pointer to the SRowSet array to update |
spropvalue | the SPropValue to append within SRowSet |
References set_SPropValue().
enum MAPISTATUS SubmitMessage | ( | mapi_object_t * | obj_message) |
Saves all changes to the message and marks it as ready for sending.
This function saves all changes made to a message and marks it ready to be sent.
obj_message | the message to mark complete |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS Subscribe | ( | mapi_object_t * | obj, |
uint32_t * | connection, | ||
uint16_t | NotificationFlags, | ||
bool | WholeStore, | ||
mapi_notify_callback_t | notify_callback, | ||
void * | private_data | ||
) |
Register an object to receive notifications
This function registers notifications on the Exchange server for an object. The function holds the notifications intended to be monitored in as a bitmask.
obj | the object to get notifications for |
connection | connection identifier for callback function |
NotificationFlags | mask for events to provide notifications for (see below) |
WholeStore | whether the scope for this notification is whole database |
notify_callback | notification callback function. |
private_data | the data to be passed at the callback function when invoked |
The Notification Flags can take the following values:
References notifications::callback, emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_id(), mapi_object_get_logon_id(), mapi_object_get_session(), mapi_object_init(), mapi_object_set_handle(), mapi_object_set_session(), notifications::NotificationFlags, mapi_notify_ctx::notifications, mapi_session::notify_ctx, notifications::obj_notif, OPENCHANGE_RETVAL_IF, notifications::parentID, notifications::private_data, and notifications::ulConnection.
enum MAPISTATUS SyncOpenAdvisor | ( | mapi_object_t * | obj, |
mapi_object_t * | obj_notifier | ||
) |
Obtain an ICS notification object
This function is used to obtain a server object handle for an ICS notification operation (RegisterSyncNotifications or SetSyncNotificationGuid). This operation is not supported on Exchange 2010.
obj | the logon object for which notifications are desired |
obj_notifier | the notifier object for future ROPs. |
The caller should release the returned notifier object when it is no longer required, using the mapi_object_release function.
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), mapi_object_set_handle(), mapi_object_set_logon_id(), mapi_object_set_session(), and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS TellVersion | ( | mapi_object_t * | obj_store, |
uint16_t | version[3] | ||
) |
Advise a server of the "other server" version
This function is used to set up a fast server-client-server transfer.
obj_store | pointer to the store MAPI object |
version | the server version |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS TransportNewMail | ( | mapi_object_t * | obj_store, |
mapi_object_t * | obj_folder, | ||
mapi_object_t * | obj_msg, | ||
const char * | MessageClass, | ||
uint32_t | MessageFlags | ||
) |
Notify the store of a new message to be processed
obj_store | the store that the message is in (logon object) |
obj_folder | the folder that the message is in |
obj_msg | the message to be processed |
MessageClass | the message class of the message to be processed |
MessageFlags | the message flags on the message |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_id(), mapi_object_get_logon_id(), mapi_object_get_session(), and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS TransportSend | ( | mapi_object_t * | obj_message, |
struct mapi_SPropValue_array * | lpProps | ||
) |
Sends the specified Message object out for message delivery.
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS uncompress_rtf | ( | TALLOC_CTX * | , |
uint8_t * | , | ||
uint32_t | , | ||
DATA_BLOB * | |||
) |
References LZFU_UNCOMPRESSED, and OPENCHANGE_RETVAL_ERR.
Referenced by WrapCompressedRTFStream().
enum MAPISTATUS UnlockRegionStream | ( | mapi_object_t * | obj_stream, |
uint64_t | RegionOffset, | ||
uint64_t | RegionSize, | ||
uint32_t | LockFlags | ||
) |
Unlock a range of bytes within the stream
obj_stream | the stream object |
RegionOffset | starting point for the range |
RegionSize | length of the range |
LockFlags | type of locking |
LockFlags used in unlocking must match the LockFlags used in locking.
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS Unsubscribe | ( | struct mapi_session * | session, |
uint32_t | ulConnection | ||
) |
Unregister notifications on a given object.
Cancel any notification registrations associated with the notify object. This function unregisters notifications on the Exchange server for the object specified with its connection number ulConnection. The function will releases the notification on the Exchange server and remove the entry from the internal notifications list.
The function takes a callback to execute when such notification occurs and returns the ulConnection identifier we can use in further management.
References notifications::next, mapi_notify_ctx::notifications, mapi_session::notify_ctx, notifications::obj_notif, OPENCHANGE_RETVAL_IF, Release(), and notifications::ulConnection.
enum MAPISTATUS WrapCompressedRTFStream | ( | mapi_object_t * | obj_stream, |
DATA_BLOB * | rtf | ||
) |
creates a DATA_BLOB in uncompressed Rich Text Format (RTF) from the compressed format used in the PR_RTF_COMPRESSED property opened in the stream.
obj_stream | stream object with RTF stream content |
rtf | the output blob with uncompressed content |
References GetLastError(), mapi_session::mapi_ctx, mapi_object_get_session(), mapi_context::mem_ctx, OPENCHANGE_RETVAL_IF, ReadStream(), and uncompress_rtf().
enum MAPISTATUS WriteAndCommitStream | ( | mapi_object_t * | obj_stream, |
DATA_BLOB * | blob, | ||
uint16_t * | WrittenSize | ||
) |
Write and commit a buffer to the stream
This function writes and commits the contents of a DATA_BLOB to the stream obj_stream.
obj_stream | the opened stream object |
blob | the DATA_BLOB to write to the stream |
WrittenSize | the actual number of bytes written to the stream |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), and OPENCHANGE_RETVAL_IF.
enum MAPISTATUS WriteStream | ( | mapi_object_t * | obj_stream, |
DATA_BLOB * | blob, | ||
uint16_t * | WrittenSize | ||
) |
Write buffer to the stream
This function writes the stream specified as a DATA_BLOB in data to the stream obj_stream.
obj_stream | the opened stream object |
blob | the DATA_BLOB to write to the stream |
WrittenSize | the actual number of bytes written to the stream |
References emsmdb_transaction_wrapper(), mapi_object_get_handle(), mapi_object_get_logon_id(), mapi_object_get_session(), OPENCHANGE_CHECK_NOTIFICATION, and OPENCHANGE_RETVAL_IF.
char* x500_get_dn_element | ( | TALLOC_CTX * | mem_ctx, |
const char * | dn, | ||
const char * | element | ||
) |
Extract a DN element from a given DN
mem_ctx | pointer to the memory context |
dn | pointer to a valid DN |
element | pointer to the substring where extraction should start |
Referenced by GetUserFreeBusyData(), and ProcessNetworkProfile().
char* x500_get_servername | ( | const char * | ) |
Retrieve the servername from a string We should definitively find a better way to handle this.
References SERVERNAME.
Referenced by ProcessNetworkProfile().
char* x500_truncate_dn_last_elements | ( | TALLOC_CTX * | mem_ctx, |
const char * | dn, | ||
uint32_t | elcount | ||
) |
Truncate a DN element
mem_ctx | pointer to the memory context |
dn | pointer to a valid DN |
elcount | the number of elements to remove from the end of the DN |
![]() ![]() ![]() |
This content is licensed under the Creative Commons Attribution ShareAlike License v. 3.0: http://creativecommons.org/licenses/by-sa/3.0/ |