Previous | Contents | Index |
Make a verbatim copy of a message header and content.
status = PMDF_copy_message
(dq_context, nq_context)
Argument Data type Access Mechanism dq_context context pointer read/write reference nq_context context pointer read/write reference
status = PMDFcopyMessage
(dq_context, nq_context)
int PMDFcopyMessage(PMDF_dq **dq_context, PMDF_nq **nq_context)
dq_context
A message dequeue context created withPMDFdequeueInitialize
.nq_context
A message enqueue context created withPMDFstartMessageEnvelope
.
UsePMDFcopyMessage
to efficiently copy to a new message being enqueued a verbatim copy of a message being dequeued. Only the portion of the dequeued message following the read point for that message will be copied. Thus, if the entire dequeued message --- header and content --- is to be copied, then it can be necessary to first callPMDFrewindMessage
.PMDFcopyMessage
is especially useful in cases where a message needs to have it's envelope changed but be left enqueued. For example, when a message was successfully delivered to some but not all recipients. In that case, if some of the recipients could not be delivered to owing to temporary problems, the message should be re-enqueued verbatim to just those recipients who could not be handled because of temporary problems. In such a case, be sure to also callPMDFaliasNoExpansion
while enqueuing the new message.
PMDF__OK Normal, successful completion. PMDF__BADCONTEXT Bad value passed for dq_context or nq_context.
Previous | Next | Contents | Index |