Home > Class Reference > ENSLIB namespace > EnsLib.EMail.InboundAdapter
Private  Storage   

EnsLib.EMail.InboundAdapter


class EnsLib.EMail.InboundAdapter extends Ens.InboundAdapter

Adapter that receives email messages via the POP3 protocol.

Inventory


Parameters Properties Methods Queries Indices ForeignKeys Triggers
2 11 3


Summary


Properties
%CredentialsObj %ILastMsg %UIDKey %WarnedLatest
BusinessHost CallInterval Credentials KeepaliveInterval
MailServer MatchFrom MatchSubject MatchTo
POP3Port POP3Server RegistryID SSLConfig

Methods
%AddToSaveSet %ClassIsLatestVersion %ClassName %ConstructClone
%DispatchClassMethod %DispatchGetModified %DispatchGetProperty %DispatchMethod
%DispatchSetModified %DispatchSetMultidimProperty %DispatchSetProperty %Extends
%GetParameter %IsA %IsModified %New
%NormalizeObject %ObjectModified %OriginalNamespace %PackageName
%RemoveFromSaveSet %SerializeObject %SetModified %ValidateObject
AssignOneSetting ClearAllAppData ClearRuntimeAppData ClearStaticAppData
CredentialsSet EnumerateSettingsClose EnumerateSettingsExecute EnumerateSettingsFetch
GetSettings OnInit OnKeepalive OnTask
OnTearDown


Parameters


• parameter SERVICEINPUTCLASS = "%Net.MailMessage";
• parameter SETTINGS = "POP3Server:Basic,POP3Port:Basic,Credentials:Basic:credentialsSelector,SSLConfig:Connection:sslConfigSelector,MatchFrom,MatchTo,MatchSubject";
List of properties can be set as settings in the configuration file format is a comma separated list of property names

Properties


• property %ILastMsg as %Integer [ InitialExpression = 0 ];
• property %UIDKey as %String;
• property MailServer as %Net.POP3;
• property MatchFrom as %String;
A list of strings to look for in the From: field of incoming email messages, separated by semicolons (';').

If empty, matches every message. If not, only messages containing any of these (partial) strings AND matching other match settings (To:,Subject:) will be processed.

• property MatchSubject as %String;
A list of strings to look for in the Subject: field of email messages, separated by semicolons (';').

If empty, matches every message. If not, only messages containing any of these (partial) strings AND matching other match settings (From:,To:) will be processed.

• property MatchTo as %String;
A list of strings to look for in the To: field of email messages, separated by semicolons (';').

If empty, matches every message. If not, only messages containing any of these (partial) strings AND matching other match settings (From:,Subject:) will be processed.

• property POP3Port as %Integer;
TCP Port on the POP3 Email Server to get mail from. If left blank, the adapter will use port 110 for plain text and port 995 for SSL/TLS.
• property POP3Server as %String;
Address of the POP3 Email Server to get mail from
• property SSLConfig as %String;
To use email with Secure Socket Layer / Transport Layer Security, the SSLConfig field must contain the name of an existing SSL/TLS Configuration of the Client type. You can create one using the System Management Portal [Security Management] > [SSL/TLS Configurations] page.

If your SSL Configuration requires you to supply a password when connecting, specify it in the SSLConfig field by adding a '|' after the configuration name, followed by the password string; for example:
MySSLItem|mypassword

When you specify a value in the SSLConfig field, the normal case is that inbound email will open a socket on default port 995 and use POP3 over SSL/TLS.

The SSLConfig field also supports the special case when you want the server interaction to begin on a normal TCP socket and then switch to SSL/TLS on the same port as the normal socket. (RFC2595 provides the details.) In this case the default port is 110 for POP3. To use this convention, append '*' to your entry in the SSLConfig field; for example:
MySSLItem*
or:
MySSLItem|mypassword*


Methods


• method OnInit() as %Status
This user callback method is called just after %OnNew()
• method OnTask() as %Status
default InboundAdapter behavior: always call ProcessInput on CallInterval
• method OnTearDown() as %Status
This user callback method is called just before %OnClose()