Overview | Package | Class | Tree | Deprecated | Index | Help
| Copyright © 2006 BEA Systems, Inc. All Rights Reserved
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.bea.netuix.application.communities.invitations.email
Class ConfigPropertiesEmailInviterFactory

    java.lang.Object
      com.bea.netuix.application.communities.invitations.email.ConfigPropertiesEmailInviterFactory

    public class ConfigPropertiesEmailInviterFactory

extends Object

Factory class that assists in instantiating `EmailInviters` based on a set of Config Properties defined in communities-config.xml. Since many of the constructor arguments to the `EmailInviter` class are most likely things which should be set by a server administrator, they need a location where an admin can define them. To make use of this class, an application can require that an admin create a property-map element withing properties-config in communities-config.xml. Within this map, the administrator can set any of the following properties which this class will preferentially use in place of any of the create arguments: sender - the username of the email sender password - the smtp password for the email sender smtpServerAddress - the server name or ip address of the smtp server replyTo - the email address set as the reply-to invitationUrl - the url which links to the registration page for the invitation staticSubjectText - subject text to use if an `EmailTextFormatter` is not being used staticBodyText - body text to use if an `EmailTextFormatter` is not being used

Field Summary
`static String` | `INVITATION_URL` invitationURL property name
`static String` | `PASSWORD` password property name
`static String` | `REPLY_TO` replyTo property name
`static String` | `SENDER` sender property name
`static String` | `SMTP_SERVER_ADDRESS` smtpServerAddress property name
`static String` | `STATIC_BODY_TEXT` staticBodyText property name
`static String` | `STATIC_SUBJECT_TEXT` staticSubjectText property name

Method Summary
`EmailInviter` | `createEmailInviter(String configPropertyMapName, String sender, String password, String smtpServerAddress, String replyTo, String invitationURL, EmailTextFormatter emailFormatter)` Instantiator that uses a specified `EmailTextFormatter`.
`EmailInviter` | `createEmailInviter(String configPropertyMapName, String sender, String password, String smtpServerAddress, String replyTo, String invitationURL, String staticSubjectText, String staticBodyText)` Instantiator method that uses a default static text `EmailTextFormatter`.
`static ConfigPropertiesEmailInviterFactory` | `getInstance()` Gets the singleton instance of this factory

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### SENDER

    public static final String SENDER

  sender property name

  See Also
    Constants Summary

### PASSWORD

    public static final String PASSWORD

  password property name

  See Also
    Constants Summary

### SMTP_SERVER_ADDRESS

    public static final String SMTP_SERVER_ADDRESS

  smtpServerAddress property name

  See Also
    Constants Summary

### REPLY_TO

    public static final String REPLY_TO

  replyTo property name

  See Also
    Constants Summary

### INVITATION_URL

    public static final String INVITATION_URL

  invitationURL property name

  See Also
    Constants Summary

### STATIC_SUBJECT_TEXT

    public static final String STATIC_SUBJECT_TEXT

  staticSubjectText property name

  See Also
    Constants Summary

### STATIC_BODY_TEXT

    public static final String STATIC_BODY_TEXT

  staticBodyText property name

  See Also
    Constants Summary

Method Detail

### getInstance

    public static ConfigPropertiesEmailInviterFactory getInstance()

  Gets the singleton instance of this factory

  Returns
    the singleton `ConfigPropertiesEmailInviterFactory` instanc

### createEmailInviter

    public EmailInviter createEmailInviter(String configPropertyMapName,
                                           String sender,
                                           String password,
                                           String smtpServerAddress,
                                           String replyTo,
                                           String invitationURL,
                                           String staticSubjectText,
                                           String staticBodyText)

  Instantiator method that uses a default static text `EmailTextFormatter`. If another formatter is to be used, an alternate instantiator is available to specify it.

  Parameters
    `configPropertyMapName` - the name of the property-map in communities-config.xml to preferentially use as the source of input arguments. For each property entry in the map with a name matching one of the other input arguments to this method, the value of that property will be used in place of the argument to this method.
    `sender` - the username of the sending entity
    `password` - the smtp password for the sending entity. Can be null if using an open relay.
    `smtpServerAddress` - address of the smtp server to use to send the invitation emails
    `replyTo` - the email address that will be used as the reply-to in the invitation emails
    `invitationURL` - the full URL to the community registration page or the community itself, depending on whether or not the community is public or private. This needs to be assembled by the creator of this `EmailInviter` since invitations happen in an asynchronous context wherein there is no access to a request to determine necessary information such as server and port.
    `staticSubjectText` - the subject text to use for invitation emails
    `staticBodyText` - the body text to use for invitation emails

### createEmailInviter

    public EmailInviter createEmailInviter(String configPropertyMapName,
                                           String sender,
                                           String password,
                                           String smtpServerAddress,
                                           String replyTo,
                                           String invitationURL,
                                           EmailTextFormatter emailFormatter)

  Instantiator that uses a specified `EmailTextFormatter`. The Weblogic Portal Framework provides two implementations of `EmailTextFormatter`, the first a simple `StaticEmailTextFormatter`, which uses fixed Strings as the email text source, and a `JspEmailTextFormatter` which allows developers to use JSP's as the source for the email text, allowing for greater customizability. Additionally, custom implementations of the `EmailTextFormatter` interface may be supplied if developers wish to use a completely custom email text formatter.

  Parameters
    `configPropertyMapName` - the name of the property-map in communities-config.xml to preferentially use as the source of input arguments. For each property entry in the map with a name matching one of the other input arguments to this method, the value of that property will be used in place of the argument to this method.
    `sender` - the username of the sending entity
    `password` - the smtp password for the sending entity. Can be null if using an open relay.
    `smtpServerAddress` - address of the smtp server to use to send the invitation emails
    `replyTo` - the email address that will be used as the reply-to in the invitation emails
    `invitationURL` - the full URL to the community registration page or the community itself, depending on whether or not the community is public or private. This needs to be assembled by the creator of this `EmailInviter` since invitations happen in an asynchronous context wherein there is no access to a request to determine necessary information such as server and port.
    `emailFormatter` - an instance of an `EmailFormatter` that will be used by the `EmailInviter` to format the subject and body text of the emails

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2006 BEA Systems, Inc. All Rights Reserved