Summary: Isode provides a number of APIs which allow integrators and product developers to build components that access the Isode Messaging server products or other products supporting the same protocols.
checkaddress.h
Go to the documentation of this file.
1 /* Copyright (c) 2004-2009, Isode Limited, London, England.
2  * All rights reserved.
3  *
4  * Acquisition and use of this software and related materials for any
5  * purpose requires a written licence agreement from Isode Limited,
6  * or a written licence from an organisation licenced by Isode Limited
7  * to grant such a licence.
8  *
9  */
10 
11 #ifndef _SOM_CHECKADDRESS_H
12 #define _SOM_CHECKADDRESS_H
13 
14 #include "session.h"
15 
27 #define SOM_FACILITY_CHECKADDRESS (16)
34 #define SOM_CKADR_ATT_X400ADDRESS 1
35 #define SOM_CKADR_ATT_RFC822ADDRESS 2
36 #define SOM_CKADR_ATT_DELIVERED_MTA 3
37 #define SOM_CKADR_ATT_DELIVERED_CHANNEL 4
38 #define SOM_CKADR_ATT_DELIVERED_CHANNEL_WEIGHT 5
39 #define SOM_CKADR_ATT_AUTH 6
40 #define SOM_CKADR_ATT_REDIRECTED_ADDRESS 7
41 #define SOM_CKADR_ATT_REDIRECTED_DN 8
42 #define SOM_CKADR_ATT_REDIRECTED_TIME 9
43 #define SOM_CKADR_ATT_REDIRECTED_REASON 10
44 #define SOM_CKADR_ATT_LOCAL_DELIVERY_UID 11
45 #define SOM_CKADR_ATT_LOCAL_DELIVERY_GID 12
46 #define SOM_CKADR_ATT_LOCAL_DELIVERY_USERNAME 13
47 #define SOM_CKADR_ATT_LOCAL_DELIVERY_DIRECTORY 14
48 #define SOM_CKADR_ATT_LOCAL_DELIVERY_MAILBOX 15
49 #define SOM_CKADR_ATT_LOCAL_DELIVERY_SHELL 16
50 #define SOM_CKADR_ATT_LOCAL_DELIVERY_HOME 17
51 #define SOM_CKADR_ATT_LOCAL_DELIVERY_FORMAT 18
52 #define SOM_CKADR_ATT_LOCAL_DELIVERY_RESTRICTED 19
53 #define SOM_CKADR_ATT_LOCAL_DELIVERY_MAILFILTER 20
54 #define SOM_CKADR_ATT_LOCAL_DELIVERY_SYSMAILFILTER 21
55 #define SOM_CKADR_ATT_LOCAL_DELIVERY_PATH 22
56 #define SOM_CKADR_ATT_LOCAL_DELIVERY_OPTIONS 23
57 #define SOM_CKADR_ATT_LOCAL_DOMAIN 24
61 /* \} */
62 
63 
64 /* Object types */
65 
66 struct SOMCheckResults;
67 
84 typedef void SOMCheckAddressCallback (struct SOMSession *session,
85  void *ophandle,
86  void *clientdata,
87  struct SOMCheckResults *data,
88  int status,
89  const char *errstring);
105 SOMAPI_CDECL int SOMCheckAddressSetCallback (struct SOMSession *session,
106  SOMCheckAddressCallback *callback,
107  SOMCheckAddressCallback **oldvalue);
108 
109 /* \} */
110 
128 SOMAPI_CDECL int SOMCheckAddressGetStrParam (struct SOMCheckResults *res,
129  int paramtype,
130  char *buffer,
131  size_t buflen,
132  size_t *paramlenp);
133 
134 
142 SOMAPI_CDECL int SOMCheckAddressGetIntParam (struct SOMCheckResults *res,
143  int paramtype,
144  int *valp);
145 
146 /* \} */
147 
158 #define SOM_CKADR_ORIGINATOR (1)
159 #define SOM_CKADR_RFC822 (1<<1)
160 #define SOM_CKADR_X400 (1<<2)
161 #define SOM_CKADR_DN (1<<3)
162 #define SOM_CKADR_NORMALIZE_ALL (1<<4)
163 #define SOM_CKADR_NO_RESPONSIBILITY (1<<5)
164 #define SOM_CKADR_NO_REDIRECTION (1<<6)
165 #define SOM_CKADR_PARSE_X400 (1<<7)
166 #define SOM_CKADR_PARSE_RFC822 (1<<8)
167 #define SOM_CKADR_PARSE (1<<9)
168 #define SOM_CKADR_DOMAIN (1<<10)
169 
183 SOMAPI_CDECL int SOMCheckAddress (struct SOMSession *session,
184  const char *address,
185  const char *sender_name,
186  const char *inmta_name,
187  const char *inchannel_name,
188  const int flags,
189  void *ophandle,
190  int async);
191 /* \} */
192 
193 #endif /* _SOM_CHECKADDRESS_H */
int SOMCheckAddressSetCallback(struct SOMSession *session, SOMCheckAddressCallback *callback, SOMCheckAddressCallback **oldvalue)
Set the Address Check callback function for this session.
int SOMCheckAddressGetStrParam(struct SOMCheckResults *res, int paramtype, char *buffer, size_t buflen, size_t *paramlenp)
Return an string-valued parameter from the check results.
Switch Operation Management Interface.
int SOMCheckAddressGetIntParam(struct SOMCheckResults *res, int paramtype, int *valp)
Return an integer-valued parameter from the check results.
Opaque session data.
void SOMCheckAddressCallback(struct SOMSession *session, void *ophandle, void *clientdata, struct SOMCheckResults *data, int status, const char *errstring)
Prototype for callback for check address completion.
Definition: checkaddress.h:84
int SOMCheckAddress(struct SOMSession *session, const char *address, const char *sender_name, const char *inmta_name, const char *inchannel_name, const int flags, void *ophandle, int async)
Perform an address check.