| com.ivata.groupware.business.mail.server.MailServer
All known Subclasses: com.ivata.groupware.business.mail.server.HMailServer, com.ivata.groupware.business.mail.server.ScriptMailServer, com.ivata.groupware.business.mail.server.JavaMailServer,
Method Summary | |
public Store | connectStore(MailSession mailSession) Helper. | public Folder | getFolder(SecuritySession securitySession, Store store, String name) Wrapper for Store.getFolder to get around the fact that
courier/cyrus imap prefixes all "personal namespace" folder names with
"INBOX".
Parameters: securitySession - used to access the settings. Parameters: store - valid, connected store. Parameters: name - name of the folder you want to open. | List | getUserAliases(SecuritySession securitySession, String userName) Gets all of the email aliases for the user provided.
This method calls the script getUserAliases .
Parameters: userName - the user for whom to get the email aliases. | String | getUserForwarding(SecuritySession securitySession, String userName) Get the email addresss this user's mail is forwarded to.
This method calls the script getUserForwarding .
Parameters: userName - the user for whom to activate/deactive emailforwarding. | String | getVacationMessage(SecuritySession securitySession, String userName) Gets the current vacation method for the user provided. | boolean | hasNewMessages(SecuritySession securitySession, String userName, String folderName) Get the time the specified mail folder was last modified as a
long . | void | removeList(SecuritySession securitySession, String name) | void | setList(SecuritySession securitySession, String name, Collection users) | void | setUserAliases(SecuritySession securitySession, String userName, Collection aliases) | void | setUserForwarding(SecuritySession securitySession, String userName, String address) Set an email addresss to forward this user's mail to. | void | setVacationMessage(SecuritySession securitySession, String userName, String message) Sets the vacation method for the user provided. |
connectStore | public Store connectStore(MailSession mailSession) throws SystemException(Code) | | Helper. Get the store from the mail session and connect it.
|
getFolder | public Folder getFolder(SecuritySession securitySession, Store store, String name) throws SystemException(Code) | | Wrapper for Store.getFolder to get around the fact that
courier/cyrus imap prefixes all "personal namespace" folder names with
"INBOX".
Parameters: securitySession - used to access the settings. Parameters: store - valid, connected store. Parameters: name - name of the folder you want to open. folder for the name you passed. throws: SystemException - if the settings cannot be accessed, or there isany exception accessing the store. |
getUserAliases | List getUserAliases(SecuritySession securitySession, String userName) throws SystemException(Code) | | Gets all of the email aliases for the user provided.
This method calls the script getUserAliases .
Parameters: userName - the user for whom to get the email aliases. a java.util.Collection containingString values for each of the aliases. throws: BusinessException - containing the content of the standarderror stream, if the script returns non-zero. |
getUserForwarding | String getUserForwarding(SecuritySession securitySession, String userName) throws SystemException(Code) | | Get the email addresss this user's mail is forwarded to.
This method calls the script getUserForwarding .
Parameters: userName - the user for whom to activate/deactive emailforwarding. email address all email for this user is forwarded to, ornull if there is no forwarding for this user. throws: BusinessException - containing the content of the standarderror stream, if the script returns non-zero. |
getVacationMessage | String getVacationMessage(SecuritySession securitySession, String userName) throws SystemException(Code) | | Gets the current vacation method for the user provided.
This method calls the script
getVacationMessage .
Parameters: userName - the user for whom to set the vacation message. the current vacation message for this user, ornull ifthe user does not have a vacation message. throws: BusinessException - containing the content of the standarderror stream, if the script returns non-zero. |
hasNewMessages | boolean hasNewMessages(SecuritySession securitySession, String userName, String folderName) throws SystemException(Code) | | Get the time the specified mail folder was last modified as a
long . This can then be saved and compared to
subsequent
calls of this method to see if the folder has changed.
Parameters: userName - the name of the user for whom to locate the folder. Parameters: folderName - the name of the folder to locate. operating system specific timestamp indicating when thefolder was last changed. throws: BusinessException - if the folder doesn't exists or thereis an application problem retrieving the modified time. |
removeList | void removeList(SecuritySession securitySession, String name) throws SystemException(Code) | | Removes an existing mailing list from the system.
The removeList script is called with
name as its only parameter.
Parameters: name - the name of the list to remove. throws: BusinessException - containing the content of the standarderror stream, if the script returns non-zero. |
setList | void setList(SecuritySession securitySession, String name, Collection users) throws SystemException(Code) | | Adds or amends a mailing list with the name and users
provided.
This method calls the setList script with the name
as the first parameter and the user names of each of the users as
following parameters.
Parameters: name - the name of the list to be added. Parameters: users - java.util.Collection containingUserLocal instances of each of the users in the list.Note that if you are changing an existing list, this array shouldcontain all of the users, not just the new ones. throws: BusinessException - containing the content of the standarderror stream, if the script returns non-zero. |
setUserAliases | void setUserAliases(SecuritySession securitySession, String userName, Collection aliases) throws SystemException(Code) | | Gets all of the email aliases for the user provided.
This method calls the script setUserAliases .
Parameters: userName - the user for whom to get the email aliases. Parameters: aliases - a java.util.Collection containingString values for each of the aliases. throws: BusinessException - containing the content of the standarderror stream, if the script returns non-zero. |
setUserForwarding | void setUserForwarding(SecuritySession securitySession, String userName, String address) throws SystemException(Code) | | Set an email addresss to forward this user's mail to. If
address is set to null then any previous
email
forwarding is removed.
Parameters: userName - the user for whom to activate/deactive emailforwarding. Parameters: address - email address to forward all email for this user to.If thisaddress is set to null then any previous forwarding isremoved. throws: BusinessException - containing the content of the standarderrorstream, if the script returns non-zero. |
setVacationMessage | void setVacationMessage(SecuritySession securitySession, String userName, String message) throws SystemException(Code) | | Sets the vacation method for the user provided. This message
will be sent
to all mails received at this address until it has been cleared, by
calling
this method again with a null value for the
message
parameter.
This method calls the setVacationMessage script
with user name and message as parameters.
If the message parameter is null , then
the
script is called with just the
user name parameter.
Parameters: userName - the user for whom to set the vacation message. Parameters: message - the new vacation message for this user. Set tonull to remove any existing vacation message. throws: BusinessException - containing the content of the standarderror stream, if the script returns non-zero. |
|
|