X400 Gateway API


Functions

const char * X400mtError (int error)
 Return string for error code.
int X400mtOpen (const char *credentials, struct X400mtSession **spp)
 Open a session to the MTA.
int X400mtClose (struct X400mtSession *sp)
 Close a X400 Session.
int X400mtSetIntDefault (struct X400mtSession *sp, int paramtype, int value)
 Set a default integer parameter value in a session.
int X400mtSetStrDefault (struct X400mtSession *sp, int paramtype, const char *value, size_t length)
 Set a default string parameter value in a session.
int X400mtMsgNew (struct X400mtSession *sp, int type, struct X400mtMessage **mpp)
 Creates new message.
int X400mtMsgCountRecip (struct X400mtMessage *mp, int type, int *cp)
 Returns count of addresses of given type in message object.
int X400mtMsgSend (struct X400mtMessage *mp)
 Send message object to MTA.
int X400mtMsgDelete (struct X400mtMessage *mp)
 Delete message object.
int X400mtMsgAddStrParam (struct X400mtMessage *mp, int paramtype, const char *value, size_t length)
 Add string-valued parameter to the message.
int X400mtMsgAddIntParam (struct X400mtMessage *mp, int paramtype, int value)
 Add integer-valued parameter to the message.
int X400mtMsgAddAttachment (struct X400mtMessage *mp, int type, const char *string, size_t length)
 Add an attachment to the message.
int X400mtMsgAddBodypart (struct X400mtMessage *mp, struct X400Bodypart *bp)
 Add a body part object to a message.
int X400mtMsgAddMessageBody (struct X400mtMessage *mp, struct X400Message *mbp)
int X400mtMsgAddMessageBodyWType (struct X400mtMessage *mp, struct X400Message *mbp, int type)
 Add a message body part object to a message.
int X400mtRecipNew (struct X400mtMessage *mp, int type, struct X400Recipient **rpp)
 Add new recipient to a message.
int X400mtRecipAddStrParam (struct X400Recipient *rp, int paramtype, const char *value, size_t length)
 Add string-valued parameter to the message.
int X400mtRecipAddIntParam (struct X400Recipient *rp, int paramtype, int value)
 Add integer-valued parameter to the message.
int X400mtWait (struct X400mtSession *sp, int seconds, int *count)
 Wait for messages to be transferred out.
int X400mtMsgGet (struct X400mtSession *sp, struct X400mtMessage **mpp, int *typep)
 Transfer message object out from MTA completely.
int X400mtMsgGetStart (struct X400mtSession *sp, struct X400mtMessage **mpp, int *typep)
 Get message object for transfer out from MTA.
int X400mtMsgGetFinish (struct X400mtMessage *mp, int status, int reason, int diag, char *info)
 Finish transfer-out of message from MTA, generate DR if required.
int X400mtMsgGetStrParam (struct X400mtMessage *mp, int paramtype, char *buffer, size_t buflen, size_t *paramlenp)
 Return a string-valued parameter from the message object.
int X400mtMsgGetIntParam (struct X400mtMessage *mp, int paramtype, int *valp)
 Return a integer-valued parameter from the message object.
int X400mtMsgGetAttachment (struct X400mtMessage *mp, int number, int *typep, char *buffer, size_t buflen, size_t *lengthp)
 Return a integer-valued parameter from the message object.
int X400mtMsgGetBodypart (struct X400mtMessage *mp, int number, int *typep, struct X400Bodypart **bpp)
 Return a pointer to a body part object.
int X400mtMsgGetMessageBody (struct X400mtMessage *mp, int number, struct X400Message **mpp)
 Return a pointer to a body part object.
int X400mtRecipGet (struct X400mtMessage *mp, int type, int number, struct X400Recipient **rpp)
 Get recipient object from message.
int X400mtRecipGetStrParam (struct X400Recipient *rp, int paramtype, char *buffer, size_t buflen, size_t *paramlenp)
 Return a string-valued parameter from the recipient object.
int X400mtRecipGetIntParam (struct X400Recipient *rp, int paramtype, int *valp)
 Return a integer-valued parameter from the recipient object.
int X400mtDLExpHistGet (struct X400mtMessage *mp, int entry, struct X400DLExpHist **hist)
 Create a new DL Expansion History object from the message object.
int X400mtDLExpHistNew (struct X400mtMessage *mp, struct X400DLExpHist **histp)
 Create a new DL Expansion History object, and associate it with the existing message.
int X400mtTraceInfoGet (struct X400mtMessage *mp, int entry, struct X400TraceInfo **info, int type)
 Get a Trace Info object for a message object.
int X400mtTraceInfoNew (struct X400mtMessage *mp, struct X400TraceInfo **info, int type)
 Create a new Trace Info object for a message object.
int X400mtInternalTraceInfoGet (struct X400mtMessage *mp, int entry, struct X400InternalTraceInfo **info)
 Get an Internal Trace Info object for a message object.
int X400mtInternalTraceInfoNew (struct X400mtMessage *mp, struct X400InternalTraceInfo **info)
 Create a new Internal Trace Info object for a message object.
int X400mtALINew (struct X400mtMessage *mp, struct X400ALI **ali)
 Create a new Address List Indicator object for a message object.
int X400mtALIGet (struct X400mtMessage *mp, int entry, struct X400ALI **ali)
 Get a new Address List Indicator object for a message object.
int X400mtPSSNew (struct X400mtMessage *mp, int type, struct X400PSS **pss)
 Create a new Printable String Syntax object for a message object.
int X400mtPSSGet (struct X400mtMessage *mp, int type, int entry, struct X400PSS **pss)
 Get a new Printable String Syntax object for a message object.
int X400mtDistFieldNew (struct X400mtMessage *mp, struct X400DistField **distfield)
 Create a new P772 Distribution Field object for a message object.
int X400mtDistFieldGet (struct X400mtMessage *mp, int entry, struct X400DistField **distfield)
 Get a new P772 Distribution Field object for a message object.
int X400mtOtherRecipNew (struct X400mtMessage *mp, struct X400OtherRecip **otherrecip)
 Create a new P772 Other Recipient object for a message object.
int X400mtOtherRecipGet (struct X400mtMessage *mp, int entry, struct X400OtherRecip **otherrecip)
 Get a new P772 Other Recipient object for a message object.
int X400mtRediHistGetEnv (struct X400mtMessage *msg, int entry, struct X400RediHist **hist)
 Get the Redirection History object from a message envelope this is represented by 8.3.1.2.1.5 in X.411.
int X400mtRediHistNewEnv (struct X400mtMessage *msg, struct X400RediHist **hist)
 Create a new Redirection History object for a message envelope this is represented by 8.3.1.2.1.5 in X.411.
int X400mtORandDLNew (struct X400mtMessage *msg, struct X400ORandDL **or_and_dl)
 Create new Originator and DL expansion history object.
int X400mtORandDLGet (struct X400mtMessage *msg, int entry, struct X400ORandDL **or_and_dl)
 Get Originator and DL expansion history object.

Detailed Description

These function calls provide the X.400 Gateway API.

Function Documentation

const char* X400mtError ( int  error  ) 

Return string for error code.

Parameters:
error [in] error code
Returns:
Pointer to NUL terminated string for error
Examples:
examples/x400_mtrcv.c, examples/x400_mtsend.c, examples/x400_mtsend_rep.c, and examples/x400_mttutorial.c.

int X400mtOpen ( const char *  credentials,
struct X400mtSession **  spp 
)

Open a session to the MTA.

Parameters:
credentials [in] String for the credentials for the session
spp [out] Pointer to receive pointer to opaque session data
Returns:
zero on success or non-zero error code
Opens a session for transfer in and transfer out. The credentials string should be formatted as "channelname[/mtaname]".

int X400mtClose ( struct X400mtSession *  sp  ) 

Close a X400 Session.

Parameters:
sp [in] Pointer to session data
Returns:
Zero on success or non-zero error code
Closes a session and deletes all resources associated with the session.
Examples:
examples/x400_mtrcv.c, examples/x400_mtsend.c, examples/x400_mtsend_rep.c, and examples/x400_mttutorial.c.

int X400mtSetIntDefault ( struct X400mtSession *  sp,
int  paramtype,
int  value 
)

Set a default integer parameter value in a session.

Parameters:
sp [in] Session handle returned from an X400mtOpen call
paramtype [in] Parameter type to set
value [in] Parameter value to set
Returns:
zero on success or non-zero error code
Sets a default integer parameter value in a session object. If this parameter has previously been set in the session, the existing value is replaced. When a message is sent, any attribute which is not present in the message being sent will be taken from the session's default set.

int X400mtSetStrDefault ( struct X400mtSession *  sp,
int  paramtype,
const char *  value,
size_t  length 
)

Set a default string parameter value in a session.

Parameters:
sp [in] Session handle returned from an X400mtOpen call
paramtype [in] Parameter type to set
value [in] Parameter value to set
length [in] Length of parameter value to set
Returns:
zero on success or non-zero error code
Sets a default string parameter value in a session object. If this parameter has previously been set in the session, the existing value is replaced. When a message is sent, any attribute which is not present in the message being sent will be taken from the session's default set.
Examples:
examples/x400_mtrcv.c, examples/x400_mtsend.c, and examples/x400_mttutorial.c.

int X400mtMsgNew ( struct X400mtSession *  sp,
int  type,
struct X400mtMessage **  mpp 
)

Creates new message.

Parameters:
sp [in] X400 session pointer
type [in] Type of message object
mpp [out] pointer to receive pointer to message object
Returns:
zero on success or non-zero error code
Message types are
  • X400_MSG_MESSAGE A Message object
  • X400_MSG_REPORT A Report object
  • X400_MSG_PROBE A Probe object
Examples:
examples/x400_mtsend.c, examples/x400_mtsend_rep.c, and examples/x400_mttutorial.c.

int X400mtMsgCountRecip ( struct X400mtMessage *  mp,
int  type,
int *  cp 
)

Returns count of addresses of given type in message object.

Parameters:
mp [in] X400 MT message
type [in] Type of address to count
cp [out] pointer integer to receive count of addresses
Returns:
zero on success or non-zero error code

int X400mtMsgSend ( struct X400mtMessage *  mp  ) 

Send message object to MTA.

Parameters:
mp [in] Message pointer
Returns:
Zero on success or non-zero error code
Examples:
examples/x400_mtsend.c, examples/x400_mtsend_rep.c, and examples/x400_mttutorial.c.

int X400mtMsgDelete ( struct X400mtMessage *  mp  ) 

Delete message object.

Parameters:
mp [in] Message pointer
Returns:
Zero on success or non-zero error code
This is called after submitting a message object or to abandon submission.
Examples:
examples/x400_mtrcv.c, examples/x400_mtsend.c, examples/x400_mtsend_rep.c, and examples/x400_mttutorial.c.

int X400mtMsgAddStrParam ( struct X400mtMessage *  mp,
int  paramtype,
const char *  value,
size_t  length 
)

Add string-valued parameter to the message.

Parameters:
mp [in] Message pointer
paramtype [in] Type of parameter
value [in] Value of parameter
length [in] Length of parameter, -1 if NUL terminated
Returns:
Zero on success or non-zero error code
Examples:
examples/x400_mtsend.c, examples/x400_mtsend_rep.c, and examples/x400_mttutorial.c.

int X400mtMsgAddIntParam ( struct X400mtMessage *  mp,
int  paramtype,
int  value 
)

Add integer-valued parameter to the message.

Parameters:
mp [in] Message pointer
paramtype [in] Type of parameter
value [in] Value of parameter
Returns:
Zero on success or non-zero error code
Examples:
examples/x400_mtsend.c, examples/x400_mtsend_rep.c, and examples/x400_mttutorial.c.

int X400mtMsgAddAttachment ( struct X400mtMessage *  mp,
int  type,
const char *  string,
size_t  length 
)

Add an attachment to the message.

Parameters:
mp [in] Message pointer
type [in] Type of attachment
string [in] String value for attachment
length [in] Length of string
Returns:
Zero on success or non-zero error code
Examples:
examples/x400_mtsend.c.

int X400mtMsgAddBodypart ( struct X400mtMessage *  mp,
struct X400Bodypart *  bp 
)

Add a body part object to a message.

Parameters:
mp [in] Message pointer
bp [in] Bodypart pointer
Returns:
Zero on success or non-zero error code
Examples:
examples/x400_mtsend.c.

int X400mtMsgAddMessageBody ( struct X400mtMessage *  mp,
struct X400Message *  mbp 
)

Deprecated:
Use X400mtMsgAddMessageBodyWtype instead.
Examples:
examples/x400_mtsend.c.

int X400mtMsgAddMessageBodyWType ( struct X400mtMessage *  mp,
struct X400Message *  mbp,
int  type 
)

Add a message body part object to a message.

Parameters:
mp [in] Message pointer
mbp [in] Message body part pointer
type [in] BodyPart type (E.G X400_T_MESSAGE)
Returns:
Zero on success or non-zero error code
The message body part must be a message delivery object for forwarded-message body part.

If the message object being created has an IPN content, then any envelope information is ignored.

Examples:
examples/x400_mtsend.c.

int X400mtRecipNew ( struct X400mtMessage *  mp,
int  type,
struct X400Recipient **  rpp 
)

Add new recipient to a message.

Parameters:
mp [in] Message pointer
type [in] type of recipient
rpp [out] Pointer to place for pointer to recipient information
Returns:
Zero on success or non-zero error code
Creates a recipient object associated with the message. There are several different types for recipient object. Normal recipients can be specified separately for the envelope (i.e. controlling where the message actually goes) and the header which is part of the content. They can also be specified together. A separate type of recipient is the reported recipient which appears in a report content.

  • X400_RECIP_PRIMARY Primary recipient in header
  • X400_RECIP_CC Carbon copy recipient in header
  • X400_RECIP_BCC Blind copy recipient in header
  • X400_RECIP_REPLY Reply-recipient in header
  • X400_RECIP_ENVELOPE Actual recipient in envelope
  • X400_RECIP_REPORT Reported recipient in report content
  • X400_RECIP_ORIGINAL Originally intended recipient in report content
  • X400_ORIGINATOR Originator address in IPM header
  • X400_AUTH_ORIG Authorizing originator address in IPM header

To set a given recipient in both envelope and header, add together the values, e.g. X400_RECIP_PRIMARY + X400_RECIP_ENVELOPE. The value X400_RECIP_STANDARD is a shorthand for this combination.

Examples:
examples/x400_mtsend.c, examples/x400_mtsend_rep.c, and examples/x400_mttutorial.c.

int X400mtRecipAddStrParam ( struct X400Recipient *  rp,
int  paramtype,
const char *  value,
size_t  length 
)

Add string-valued parameter to the message.

Parameters:
rp [in] Recipient pointer
paramtype [in] Type of parameter
value [in] Value of parameter
length [in] Length of parameter, -1 if NUL terminated
Returns:
Zero on success or non-zero error code
Examples:
examples/x400_mtsend.c, examples/x400_mtsend_rep.c, and examples/x400_mttutorial.c.

int X400mtRecipAddIntParam ( struct X400Recipient *  rp,
int  paramtype,
int  value 
)

Add integer-valued parameter to the message.

Parameters:
rp [in] Message pointer
paramtype [in] Type of parameter
value [in] Value of parameter
Returns:
Zero on success or non-zero error code
Examples:
examples/x400_mtsend.c, examples/x400_mtsend_rep.c, and examples/x400_mttutorial.c.

int X400mtWait ( struct X400mtSession *  sp,
int  seconds,
int *  count 
)

Wait for messages to be transferred out.

Parameters:
sp [in] Session pointer
seconds [in] Seconds to wait
count [out] pointer to receive number of messages
Returns:
Zero on success, non-zero on failure, including timeout.
If seconds is zero, then there is no delay. If seconds is negative, then the delay is indefinite.

int X400mtMsgGet ( struct X400mtSession *  sp,
struct X400mtMessage **  mpp,
int *  typep 
)

Transfer message object out from MTA completely.

Parameters:
sp [in] Session pointer
mpp [out] Pointer to receive message object pointer
typep [out] Pointer to receive message object type.
Returns:
Zero on success, non-zero on failure

int X400mtMsgGetStart ( struct X400mtSession *  sp,
struct X400mtMessage **  mpp,
int *  typep 
)

Get message object for transfer out from MTA.

Parameters:
sp [in] Session pointer
mpp [out] Pointer to receive message object pointer
typep [out] Pointer to receive message object type.
Returns:
Zero on success, non-zero on failure
Starts transfer-out of a message from the MTA. Returns a handle to a message, but does not aceept responsibilty for the message. Once the message has been processed by the gateway application, X400mtMsgGetFinish must be called to cause a delivery report to be generated if required, and to allow the MTA to release the message.
Examples:
examples/x400_mtrcv.c, and examples/x400_mttutorial.c.

int X400mtMsgGetFinish ( struct X400mtMessage *  mp,
int  status,
int  reason,
int  diag,
char *  info 
)

Finish transfer-out of message from MTA, generate DR if required.

Parameters:
mp [in] Message pointer
status [in] Status from gateway message handling.
reason [in] DR reason code. See standards for values
diag [in] DR diagnostic code. See standards for values
info [in] DR supplementary info.
Returns:
Zero on success, non-zero on failure
Signals that the gateway application has completed its handling of the specified message.

If the 'x400_reports' key of the x400tailor file is set to "1" and "status" is specified as X400_E_NOERROR, a positive delivery report will be generated. If an error status is passed in, the DR reason and diagnostic codes and supplementary information will be used to generate a DR.

Under normal circumstances, gateway applications should generate their own delivery reports, and not rely on the ones generated by this function, as for example, when there's more than one recipient in the message, it cannot set a different status for each recipient.

Examples:
examples/x400_mtrcv.c, and examples/x400_mttutorial.c.

int X400mtMsgGetStrParam ( struct X400mtMessage *  mp,
int  paramtype,
char *  buffer,
size_t  buflen,
size_t *  paramlenp 
)

Return a string-valued parameter from the message object.

Parameters:
mp [in] message object pointer
paramtype [in] type of parameter
buffer [in/out] address for result
buflen [in] length of buffer provided
paramlenp [out] Pointer to receive actual length
Returns:
Zero on success or non-zero error code
Examples:
examples/x400_mtrcv.c, and examples/x400_mttutorial.c.

int X400mtMsgGetIntParam ( struct X400mtMessage *  mp,
int  paramtype,
int *  valp 
)

Return a integer-valued parameter from the message object.

Parameters:
mp [in] message object pointer
paramtype [in] type of parameter
valp [out] Pointer to receive value
Returns:
Zero on success or non-zero error code
Examples:
examples/x400_mtrcv.c.

int X400mtMsgGetAttachment ( struct X400mtMessage *  mp,
int  number,
int *  typep,
char *  buffer,
size_t  buflen,
size_t *  lengthp 
)

Return a integer-valued parameter from the message object.

Parameters:
mp [in] message object pointer
number [in] Attachment number
typep [out] Pointer to receive attachment type
buffer [in] Buffer to receive data
buflen [in] Length of buffer
lengthp [out] Length of string
Returns:
Zero on success or non-zero error code
The string returned is allocated on the heap and should be freed using free().

int X400mtMsgGetBodypart ( struct X400mtMessage *  mp,
int  number,
int *  typep,
struct X400Bodypart **  bpp 
)

Return a pointer to a body part object.

int number, int *typep, struct X400Bodypart **bpp)

Parameters:
mp [in] message object pointer
number [in] Bodypart number
typep [out] Pointer to receive attachment type
bpp [out] Pointer to pointer to object
Returns:
Zero on success or non-zero error code
If the body part is a forwarded message body part or a returned IPM then the error X400_E_MESSAGE_BODY is returned.
Examples:
examples/x400_mtrcv.c.

int X400mtMsgGetMessageBody ( struct X400mtMessage *  mp,
int  number,
struct X400Message **  mpp 
)

Return a pointer to a body part object.

Parameters:
mp [in] message object pointer
number [in] Bodypart number
mpp [out] Pointer to pointer to object
Returns:
Zero on success or non-zero error code
Examples:
examples/x400_mtrcv.c.

int X400mtRecipGet ( struct X400mtMessage *  mp,
int  type,
int  number,
struct X400Recipient **  rpp 
)

Get recipient object from message.

Parameters:
mp [in] Message object pointer
type [in] Type of recipient
number [in] Ordinal number of recipient
rpp [out] Pointer to receive recipient object pointer
Returns:
Zero on success, non-zero on failure
Examples:
examples/x400_mtrcv.c, and examples/x400_mttutorial.c.

int X400mtRecipGetStrParam ( struct X400Recipient *  rp,
int  paramtype,
char *  buffer,
size_t  buflen,
size_t *  paramlenp 
)

Return a string-valued parameter from the recipient object.

Parameters:
rp [in] recipient object pointer
paramtype [in] type of parameter
buffer [in/out] address for result
buflen [in] length of buffer provided
paramlenp [out] Pointer to receive actual length
Returns:
Zero on success or non-zero error code
Examples:
examples/x400_mtrcv.c, and examples/x400_mttutorial.c.

int X400mtRecipGetIntParam ( struct X400Recipient *  rp,
int  paramtype,
int *  valp 
)

Return a integer-valued parameter from the recipient object.

Parameters:
rp [in] recipient object pointer
paramtype [in] type of parameter
valp [out] Pointer to receive value
Returns:
Zero on success or non-zero error code
Examples:
examples/x400_mtrcv.c.

int X400mtDLExpHistGet ( struct X400mtMessage *  mp,
int  entry,
struct X400DLExpHist **  hist 
)

Create a new DL Expansion History object from the message object.

Parameters:
mp [in] message object pointer
entry [in] DL expansion history element to fetch
hist [out] pointer to receive new DL Expansion History object
Returns:
Zero on success, or non-zero error code
Examples:
examples/x400_mtrcv.c.

int X400mtDLExpHistNew ( struct X400mtMessage *  mp,
struct X400DLExpHist **  histp 
)

Create a new DL Expansion History object, and associate it with the existing message.

Parameters:
mp [in] message pointer
histp [out] pointer to receive new DL Expansion History object
Returns:
Zero on success, or non-zero error code
Examples:
examples/x400_mtsend.c.

int X400mtTraceInfoGet ( struct X400mtMessage *  mp,
int  entry,
struct X400TraceInfo **  info,
int  type 
)

Get a Trace Info object for a message object.

Parameters:
mp [in] message pointer
entry [in] Trace Info object to use
info [out] pointer to receive new trace infomation object
type [in] type of trace info object to get
Returns:
Zero on success, or non-zero error code
Examples:
examples/x400_mtrcv.c.

int X400mtTraceInfoNew ( struct X400mtMessage *  mp,
struct X400TraceInfo **  info,
int  type 
)

Create a new Trace Info object for a message object.

Parameters:
mp [in] message pointer
info [out] pointer to receive new trace infomation object
type [in] type of trace info object to create
Returns:
Zero on success, or non-zero error code
Examples:
examples/x400_mtsend.c, and examples/x400_mtsend_rep.c.

int X400mtInternalTraceInfoGet ( struct X400mtMessage *  mp,
int  entry,
struct X400InternalTraceInfo **  info 
)

Get an Internal Trace Info object for a message object.

Parameters:
mp [in] message pointer
entry [in] Trace Info object to use
info [out] pointer to receive new trace infomation object
Returns:
Zero on success, or non-zero error code
Examples:
examples/x400_mtrcv.c.

int X400mtInternalTraceInfoNew ( struct X400mtMessage *  mp,
struct X400InternalTraceInfo **  info 
)

Create a new Internal Trace Info object for a message object.

Parameters:
mp [in] message pointer
info [out] pointer to receive new trace infomation object
Returns:
Zero on success, or non-zero error code
Examples:
examples/x400_mtsend.c.

int X400mtALINew ( struct X400mtMessage *  mp,
struct X400ALI **  ali 
)

Create a new Address List Indicator object for a message object.

Parameters:
mp [in] message pointer
ali [out] pointer to receive ALI object
Returns:
Zero on success, or non-zero error code
Examples:
examples/x400_mtsend.c.

int X400mtALIGet ( struct X400mtMessage *  mp,
int  entry,
struct X400ALI **  ali 
)

Get a new Address List Indicator object for a message object.

Parameters:
mp [in] message pointer
entry [in] ALI object being used.
ali [out] pointer to receive new ALI object
Returns:
Zero on success, or non-zero error code
Examples:
examples/x400_mtrcv.c.

int X400mtPSSNew ( struct X400mtMessage *  mp,
int  type,
struct X400PSS **  pss 
)

Create a new Printable String Syntax object for a message object.

Parameters:
mp [in] message pointer
type [in] type of PSS being used.
pss [out] pointer to receive pss object
Returns:
Zero on success, or non-zero error code
Examples:
examples/x400_mtsend.c.

int X400mtPSSGet ( struct X400mtMessage *  mp,
int  type,
int  entry,
struct X400PSS **  pss 
)

Get a new Printable String Syntax object for a message object.

Parameters:
mp [in] message pointer
type [in] type of PSS being used.
entry [in] PSS object being used.
pss [out] pointer to receive new PSS object
Returns:
Zero on success, or non-zero error code
Examples:
examples/x400_mtrcv.c.

int X400mtDistFieldNew ( struct X400mtMessage *  mp,
struct X400DistField **  distfield 
)

Create a new P772 Distribution Field object for a message object.

Parameters:
mp [in] message pointer
distfield [out] pointer to receive distfield object
Returns:
Zero on success, or non-zero error code
Examples:
examples/x400_mtsend.c.

int X400mtDistFieldGet ( struct X400mtMessage *  mp,
int  entry,
struct X400DistField **  distfield 
)

Get a new P772 Distribution Field object for a message object.

Parameters:
mp [in] message pointer
entry [in] distfield object being used.
distfield [out] pointer to receive new PSS object
Returns:
Zero on success, or non-zero error code
Examples:
examples/x400_mtrcv.c.

int X400mtOtherRecipNew ( struct X400mtMessage *  mp,
struct X400OtherRecip **  otherrecip 
)

Create a new P772 Other Recipient object for a message object.

Parameters:
mp [in] message pointer
otherrecip [out] pointer to receive other recipient object
Returns:
Zero on success, or non-zero error code
Examples:
examples/x400_mtsend.c.

int X400mtOtherRecipGet ( struct X400mtMessage *  mp,
int  entry,
struct X400OtherRecip **  otherrecip 
)

Get a new P772 Other Recipient object for a message object.

Parameters:
mp [in] message pointer
entry [in] Other Recip object being used.
otherrecip [out] pointer to receive new other recipient object
Returns:
Zero on success, or non-zero error code
Examples:
examples/x400_mtrcv.c.

int X400mtRediHistGetEnv ( struct X400mtMessage *  msg,
int  entry,
struct X400RediHist **  hist 
)

Get the Redirection History object from a message envelope this is represented by 8.3.1.2.1.5 in X.411.

Parameters:
msg [in] X.400 Message
entry [in] Redirection history object to use
hist [out] Pointer to redirection history object
Returns:
Zero on success or non-zero error code
Examples:
examples/x400_mtrcv.c.

int X400mtRediHistNewEnv ( struct X400mtMessage *  msg,
struct X400RediHist **  hist 
)

Create a new Redirection History object for a message envelope this is represented by 8.3.1.2.1.5 in X.411.

Parameters:
msg [in] X.400 Redirection history
hist [out] Pointer to redirection history object
Returns:
Zero on success or non-zero error code
Examples:
examples/x400_mtsend_rep.c.

int X400mtORandDLNew ( struct X400mtMessage *  msg,
struct X400ORandDL **  or_and_dl 
)

Create new Originator and DL expansion history object.

Parameters:
msg [in] X.400 Originator and DL expansion history object
or_and_dl [out] Pointer to Originator and DL expansion history object
Returns:
Zero on success or non-zero error code
Examples:
examples/x400_mtsend_rep.c.

int X400mtORandDLGet ( struct X400mtMessage *  msg,
int  entry,
struct X400ORandDL **  or_and_dl 
)

Get Originator and DL expansion history object.

Parameters:
msg [in] X.400 Message
entry [in] The orginator and dl expansion history object to use
or_and_dl [out] Pointer to orig ans dl expan history object
Returns:
Zero on success or non-zero error code
Examples:
examples/x400_mtrcv.c.

Copyright © 2008 Isode privacy   feedback Subscribe to our rss newsfeed