Converting Messaging Server Plug-in Files to 4.1
Table of Contents | Previous | Next | Index

Messaging Server Plug-in API Guide


Appendix A
Converting Messaging Server Plug-in Files to 4.1

This appendix tells you how to upgrade your existing Messaging Server Plug-in API 3.0 and 4.0 files to 4.1.

This appendix has the following sections:

Upgrade Summary

Between versions 3 and 4.1, the Messaging Server Plug-in API gained several new functions and structures. In addition, several structures and definitions were changed. For a summary of these changes, see "New in This Release."

Changes to Functions

Upgrading from 3.0 to 4.1

If you are upgrading from version 3.0 to 4.1, make the following changes:

Upgrading from 4.0 to 4.1

If you are upgrading from Messaging Server Plug-in API 4.0 to 4.1, you only need to recompile against the 4.1 msg4plugins.h header file. You can see this file in HTML format, or you can download the file.

Changes to Structures

Messaging Server Plug-in API 4.1 changes some existing structures and definitions and adds new structures. As long as you implement the pInitFunc function and compile against the 4.1 header file, these changes will not affect the operation of 3.0 or 4.0 SMTP plug-ins.

[Top]

Replacing Dropped 3.0 Functions

The GetMessageFile function, new in 4.0, combines two 3.0 functions, GetHeaderFile and GetBodyFile. In the 3.0 Messaging Server Plug-in API, these two functions were used to find, open, and rewrite or encode the header and body files of the message:

char *GetHeaderFile (Message *pMessage);
char *GetBodyFile (Message *pMessage);
In the Messaging Server Plug-in API, the header and body portions of the message are in the same file. The functions returned the full path name to the file that contained the RFC 822 header and RFC 822 body portions of the message.

To convert your 3.0 SMTP plug-in for use in the 4.1 Messaging Server, use the GetMessageFile function in place of the two 3.0 functions.

char *GetMessageFile (Message *pMessage);
This function returns the filename and path of the message file, which includes the header and body portions of the message. Your SMTP plug-in will need to read the message file and parse the header and body itself.

For an example that shows how to use GetMessageFile, see "Get the message file."

[Top]


Table of Contents | Previous | Next | Index

Last Updated: 05/13/99 11:41:54

Copyright © 1999 Netscape Communications Corporation.