Nitido Inc.

com.nitido.nimx.nuggets.iplanetset
Class ExternalMailSetting

java.lang.Object
  extended by com.nitido.nimx.nuggets.iplanetset.ExternalMailSetting

public class ExternalMailSetting
extends java.lang.Object

ExternalMailSetting is a data object used to store the external mail settings. It provide methods for coverting to and from a string with field values concatenated together.


Field Summary
 java.lang.String _destFolder
          The location of where the destination folder will be stored.
 java.lang.String _host
          Host name of the external POP3 mail server.
 java.lang.String _indicator
          The color of the "indicator" for identifying the mail is downloaded from this external POP3 mail server.
 boolean _leaveMail
          Leave a copy of the mail on the external POP3 server.
 boolean _newOnly
          Donwload only new messages (instead of all) from the external POP3 server.
 int _order
          The order of the server in the list.
 java.lang.String _password
          The password to login to the external POP3 mail server.
 int _port
          Port of the external POP3 mail server.
 java.lang.String _status
          Indicate the status of the previous access to this external mail server.
 java.lang.String _username
          The user name to login to the external POP3 mail server.
 boolean _useSSL
          Indicate the POP server runs over SSL socket.
 
Constructor Summary
ExternalMailSetting()
          A lazy constructor with default values set.
ExternalMailSetting(int order, java.lang.String host, int port, java.lang.String username, java.lang.String password, java.lang.String destFolder, java.lang.String indicator, boolean leaveMail, boolean newOnly, java.lang.String status)
          Deprecated.  
ExternalMailSetting(int order, java.lang.String host, int port, java.lang.String username, java.lang.String password, java.lang.String destFolder, java.lang.String indicator, boolean leaveMail, boolean newOnly, java.lang.String status, boolean useSSL)
          The default constructor.
 
Method Summary
static ExternalMailSetting parse(java.lang.String setStr)
          Generate a ExternalMailSetting object by parsing the specified string.
 java.lang.String toString()
          Format different fields of this object into a single String.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

_order

public int _order
The order of the server in the list. This attribute is required for display purpose. It is because the LDAP multi-value attribute never guarantee the order of the values.

Default value is 0.


_host

public java.lang.String _host
Host name of the external POP3 mail server.

Default value is "localhost".


_port

public int _port
Port of the external POP3 mail server.

Default value is 110.


_username

public java.lang.String _username
The user name to login to the external POP3 mail server.

Default value is "username".


_password

public java.lang.String _password
The password to login to the external POP3 mail server.

Default value is "password".


_destFolder

public java.lang.String _destFolder
The location of where the destination folder will be stored.

Default value is "INBOX"


_indicator

public java.lang.String _indicator
The color of the "indicator" for identifying the mail is downloaded from this external POP3 mail server.

Default value is "red".


_leaveMail

public boolean _leaveMail
Leave a copy of the mail on the external POP3 server.

Default value is true.


_newOnly

public boolean _newOnly
Donwload only new messages (instead of all) from the external POP3 server.

Default value is true.


_status

public java.lang.String _status
Indicate the status of the previous access to this external mail server.

Default value is "OK".


_useSSL

public boolean _useSSL
Indicate the POP server runs over SSL socket.

Default value is false.

Constructor Detail

ExternalMailSetting

public ExternalMailSetting()
A lazy constructor with default values set.

This constructor will have the fields set to the following default values:

  _order      = 0;
  _host       = "localhost";
  _port       = 110;
  _username   = "username";
  _password   = "password";
  _destFolder = "INBOX";
  _indicator  = "red";
  _leaveMail  = true;
  _newOnly    = true;
  _status     = "OK";
 


ExternalMailSetting

public ExternalMailSetting(int order,
                           java.lang.String host,
                           int port,
                           java.lang.String username,
                           java.lang.String password,
                           java.lang.String destFolder,
                           java.lang.String indicator,
                           boolean leaveMail,
                           boolean newOnly,
                           java.lang.String status,
                           boolean useSSL)
The default constructor.


ExternalMailSetting

public ExternalMailSetting(int order,
                           java.lang.String host,
                           int port,
                           java.lang.String username,
                           java.lang.String password,
                           java.lang.String destFolder,
                           java.lang.String indicator,
                           boolean leaveMail,
                           boolean newOnly,
                           java.lang.String status)
Deprecated. 

The old default constructor. It is kept in order to support backward compatibility.

Method Detail

parse

public static ExternalMailSetting parse(java.lang.String setStr)
Generate a ExternalMailSetting object by parsing the specified string.

The string should have the format:
"order, host, port, username, password, destFolder, indicator, leaveMail, newOnly, status"

Parameters:
setStr - The initial string of the settings.

toString

public java.lang.String toString()
Format different fields of this object into a single String.

The resulting string will have the format:
"order, host, (s:)port, username, password, destFolder, indicator, leaveMail, newOnly, status"

NOTE: The "s:" before the host name indicates whether the external mail server is using SSL socket.

This method overwrites the default implementation of Object.toString().

Overrides:
toString in class java.lang.Object

Nitido NiM 2.5 Java API

These JavaDoc pages are generated for release/nim_2_5-2.5.44

Copyright © 1999-2009 Nitido Inc.    Proprietary and Confidential.    All Rights Reserved.