|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
plugin.h
header file, included in The plugin.h Header File. For a quick reference to these functions and their uses, see "Functions."See the "News Program" for an sample code that uses many of these functions in a program that creates and posts a news messages from within an application.
These functions are a subset of the utility functions that are supported by the Collabra Server SDK Library. [Top] [Functions]
Message
structure to the News Server.
#include <plugin.h>
int PostArticle (char *Server,Message
*pMessage);
| Pointer to the host name of News Server to receive the message. |
|
Pointer to the name of the existing Message structure.
|
Returns
The function returns one of the following values:
Message
structure to the News Server. This function only sends mail to the Address
structures in the message that were created with the ADDRTYPE_NEWS
type.
Message
Message
structure.
#include <plugin.h>
int AddRecipient (Message *pMessage, Recipient *pRecipient);
|
Pointer to the name of the Message structure.
|
| Pointer to the address of the recipient. |
Returns
The function returns one of the following values:
Message
structure. It succeeds if both input parameters are valid and no memory errors occur. Currently, no specific error codes for failure are defined.
GetFirstRecipient
,
GetNextRecipient
,
GetRecipientAddress
,
NewRecipient
,
RemoveRecipient
[Top] [Functions]
#include <plugin.h>
void FreeMessage (Message
*pMessage);
pMessage |
Pointer to the Message structure with which the resources are associated.
|
Description
This function frees the resources associated with the Message structure pointed to by pMessage
.
See Also
NewMessage
#include <plugin.h>
char *GetBodyFile (Message *pMessage);
|
Pointer to the name of the Message structure.
|
Returns
The function returns one of the following values:
null
.Message
structure pointed to by pMessage
.
GetHeaderFile
#include <plugin.h>
Recipient *GetFirstRecipient (Message
*pMessage);
|
Pointer to the name of the Message structure.
|
Returns
The function returns one of the following values:
null
.Message
structure pointed to by the pMessage
parameter. Any subsequent call to GetFirstRecipient
resets the retrieval of recipients so that calls to
GetNextRecipient
return the second, third, and all subsequent recipients.
See Also
AddRecipient
,
GetNextRecipient
,
GetRecipientAddress
,
NewRecipient
,
RemoveRecipient
#include <plugin.h>
char *GetHeaderFile (Message
*pMessage);
|
Pointer to the name of the Message structure.
|
Returns
The function returns one of the following values:
null
.Message
structure pointed to by the pMessage
parameter.
GetBodyFile
#include <plugin.h>
Recipient *GetNextRecipient (RecipientList *pRecipientList);
pRecipientList |
Pointer to the list of recipients in the Message structure.
|
Returns
The function returns one of the following values:
null
.Message
structure.
AddRecipient
,
GetFirstRecipient
,
GetRecipientAddress
,
NewRecipient
,
RemoveRecipient
Recipient
structure.
#include <plugin.h>
char *GetRecipientAddress (Recipient *pRecipient);
| Pointer to the address of the recipient. |
Returns
The function returns one of the following values:
null
.Recipient
structure represented by the pRecipient
parameter.
AddRecipient
,
GetFirstRecipient
,
GetNextRecipient
,
NewRecipient
,
RemoveRecipient
#include <plugin.h>
Message
*NewMessage(char *szBodyFile,
char *szHeaderFile,
char *szSenderAddr);
Returns
The function returns one of the following values:
Message
structure. In the new message, it sets the sender
property of the Message
structure to szSenderAddr
. You must still set the From
header field in the header file.
FreeMessage
#include <plugin.h>
Recipient *NewRecipient (char *Address, long Type);
Address | Pointer to an address. Possible values include: |
Type |
ADDRTYPE_NEWS value. Use NEWS .
|
Returns
The function returns one of the following values:
Recipient
structure.null
.Recipient
structure.
To free a Recipient
structure, use standard memory management calls.
AddRecipient
,
GetFirstRecipient
,
GetNextRecipient
,
GetRecipientAddress
,
RemoveRecipient
#include <plugin.h>
int RemoveRecipient (Message *pMessage, Recipient *pRecipient);
|
Pointer to the name of the Message structure.
|
| Pointer to the address of the recipient. |
Returns
The function returns one of the following values:
Message
structure pointed to by pMessage
.
AddRecipient
,
GetFirstRecipient
,
GetNextRecipient
,
GetRecipientAddress
,
NewRecipient
| Represents a message. |
| Represents the address of the recipient of a message. |
| Represents the address of a recipient. |
#include <plugin.h>
struct message;
typedef structMessage
Message;
FreeMessage
,
GetBodyFile
,
GetFirstRecipient
,
GetHeaderFile
,
GetNextRecipient
,
NewMessage
,
NewRecipient
,
PostArticle
,
RemoveRecipient
[Top] [Structures]
#include <plugin.h>
struct address;
typedef struct address Recipient;
Address
that represents the address of the recipient of a message. An address can be an RFC821-compliant address or a newsgroup name string, for example: "devgroup@startup.com
" or "alt.server.ideateam
."
Address
,
AddRecipient
,
GetFirstRecipient
,
GetNextRecipient
,
GetRecipientAddress
,
RemoveRecipient
[Top] [Structures]
#include <plugin.h>
struct address;
typedef struct address Address;
devgroup@startup.com
" or "alt.server.ideateam
."
Recipient
,
NewRecipient
[Top] [Structures]
Last Updated: 10/01/97 14:00:56
Any sample code included above is provided for your use on an "AS IS" basis, under the Netscape License Agreement - Terms of Use