org.apache.jetspeed.portlets.registration
Class UserRegistrationPortlet

java.lang.Object
  extended by javax.portlet.GenericPortlet
      extended by org.apache.portals.bridges.common.GenericServletPortlet
          extended by org.apache.portals.bridges.velocity.GenericVelocityPortlet
              extended by org.apache.portals.bridges.velocity.AbstractVelocityMessagingPortlet
                  extended by org.apache.jetspeed.portlets.registration.UserRegistrationPortlet
All Implemented Interfaces:
javax.portlet.Portlet, javax.portlet.PortletConfig

public class UserRegistrationPortlet
extends org.apache.portals.bridges.velocity.AbstractVelocityMessagingPortlet

This portlet allows a logged on user to change its password.

Version:
$Id: $
Author:
David Sean Taylor, Chris Schaefer

Field Summary
private  org.apache.jetspeed.administration.PortalAdministration admin
           
private static String CTX_FIELDS
           
private static String CTX_MESSAGE
           
private static String CTX_OPTION_GENERATE_PASSWORDS
           
private static String CTX_OPTION_USE_EMAIL_AS_USERNAME
           
private static String CTX_OPTIONALS
           
private static String CTX_REGED_USER_MSG
           
private static String CTX_RETURN_URL
           
private static String CTX_USERINFO
           
private  String emailSubject
          localized emailSubject
protected static Object[][] formKeys
           
private  List groups
          groups
private static String IP_GROUPS
           
private static String IP_OPTION_EMAILS_SYSTEM_UNIQUE
           
private static String IP_OPTION_GENERATE_PASSWORDS
           
private static String IP_OPTION_USE_EMAIL_AS_USERNAME
           
private static String IP_REDIRECT_PATH
           
private static String IP_RETURN_URL
           
private static String IP_ROLES
           
private static String IP_RULES_NAMES
           
private static String IP_RULES_VALUES
           
private static String IP_TEMPLATE_LOCATION
           
private static String IP_TEMPLATE_NAME
           
private static Integer IS_BDATE
           
private static Integer IS_EMAIL
           
private static Integer IS_PHONE
           
private static Integer IS_STRING
           
private static Integer IS_URL
           
private static String MSG_MESSAGE
           
private static String MSG_REGED_USER_MSG
           
private static String MSG_USERINFO
           
private static Boolean optional
           
private  boolean optionForceEmailAsUsername
          will use cause the portlet to use a user request username instead otherwise forces emailaddress
private  boolean optionForceEmailsToBeSystemUnique
          will check to make sure the email address is unique to the system
private  boolean optionForceGeneratedPasswords
          will force the passwords to be generated instead of picked by the user
private static String PATH_SEPARATOR
           
private static String RB_EMAIL_SUBJECT
           
private  String redirectPath
          path where to redirect to after pressing submit on the form
private static Boolean required
           
private  String returnUrlPath
          servlet path of the return url to be printed and href'd in email template
private  List roles
          roles
private  Map rules
          profile rules
private  String templateLocation
          email template to use for merging
private  org.apache.jetspeed.locator.JetspeedTemplateLocator templateLocator
           
private  String templateName
           
private static String USER_ATTRIBUTE_EMAIL
           
private  org.apache.jetspeed.security.UserManager userManager
           
 
Fields inherited from class org.apache.portals.bridges.velocity.AbstractVelocityMessagingPortlet
STATUS_MESSAGE
 
Fields inherited from class org.apache.portals.bridges.velocity.GenericVelocityPortlet
PORTLET_BRIDGE_CONTEXT
 
Fields inherited from class org.apache.portals.bridges.common.GenericServletPortlet
PARAM_ACTION_PAGE, PARAM_ALLOW_PREFERENCES, PARAM_CUSTOM_PAGE, PARAM_EDIT_PAGE, PARAM_HELP_PAGE, PARAM_MAX_PAGE, PARAM_VIEW_PAGE
 
Constructor Summary
UserRegistrationPortlet()
           
 
Method Summary
protected  String convertIfNeed(String key, String value)
           
protected  void doDispatch(javax.portlet.RenderRequest request, javax.portlet.RenderResponse response)
           
 void doEdit(javax.portlet.RenderRequest request, javax.portlet.RenderResponse response)
           
 void doView(javax.portlet.RenderRequest request, javax.portlet.RenderResponse response)
           
protected  String generateRedirectURL(javax.portlet.PortletRequest request, javax.portlet.PortletResponse response)
           
protected  String generateReturnURL(javax.portlet.PortletRequest request, javax.portlet.PortletResponse response, String urlGUID)
           
protected  String getEmailSubject(javax.portlet.PortletRequest request)
           
protected  List getInitParameterList(javax.portlet.PortletConfig config, String ipName)
           
protected  List getListOfNonSpecialFormKeys()
           
protected  Map getOptionalMap()
           
protected  List getPreferencesList(javax.portlet.PortletPreferences prefs, String prefName)
           
protected  String getTemplatePath(javax.portlet.ActionRequest request, javax.portlet.ActionResponse response)
           
 void init(javax.portlet.PortletConfig config)
           
 void processAction(javax.portlet.ActionRequest actionRequest, javax.portlet.ActionResponse actionResponse)
           
protected  boolean validateFormValue(String value, Integer length, Integer validationType)
           
 
Methods inherited from class org.apache.portals.bridges.velocity.AbstractVelocityMessagingPortlet
cancelRenderMessage, consumeRenderMessage, getTopic, isEmpty, publishRenderMessage, receiveRenderMessage, setTopic
 
Methods inherited from class org.apache.portals.bridges.velocity.GenericVelocityPortlet
doCustom, doHelp, doPreferencesEdit, getContext, getContext, render, setupPreferencesEdit
 
Methods inherited from class org.apache.portals.bridges.common.GenericServletPortlet
getDefaultActionPage, getDefaultCustomPage, getDefaultEditPage, getDefaultHelpPage, getDefaultViewPage, processPreferencesAction, setDefaultActionPage, setDefaultCustomPage, setDefaultEditPage, setDefaultHelpPage, setDefaultViewPage
 
Methods inherited from class javax.portlet.GenericPortlet
destroy, getInitParameter, getInitParameterNames, getPortletConfig, getPortletContext, getPortletName, getResourceBundle, getTitle, init
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

admin

private org.apache.jetspeed.administration.PortalAdministration admin

userManager

private org.apache.jetspeed.security.UserManager userManager

USER_ATTRIBUTE_EMAIL

private static final String USER_ATTRIBUTE_EMAIL
See Also:
Constant Field Values

MSG_MESSAGE

private static final String MSG_MESSAGE
See Also:
Constant Field Values

MSG_USERINFO

private static final String MSG_USERINFO
See Also:
Constant Field Values

MSG_REGED_USER_MSG

private static final String MSG_REGED_USER_MSG
See Also:
Constant Field Values

IP_ROLES

private static final String IP_ROLES
See Also:
Constant Field Values

IP_GROUPS

private static final String IP_GROUPS
See Also:
Constant Field Values

IP_TEMPLATE_LOCATION

private static final String IP_TEMPLATE_LOCATION
See Also:
Constant Field Values

IP_TEMPLATE_NAME

private static final String IP_TEMPLATE_NAME
See Also:
Constant Field Values

IP_RULES_NAMES

private static final String IP_RULES_NAMES
See Also:
Constant Field Values

IP_RULES_VALUES

private static final String IP_RULES_VALUES
See Also:
Constant Field Values

IP_REDIRECT_PATH

private static final String IP_REDIRECT_PATH
See Also:
Constant Field Values

IP_RETURN_URL

private static final String IP_RETURN_URL
See Also:
Constant Field Values

IP_OPTION_EMAILS_SYSTEM_UNIQUE

private static final String IP_OPTION_EMAILS_SYSTEM_UNIQUE
See Also:
Constant Field Values

IP_OPTION_GENERATE_PASSWORDS

private static final String IP_OPTION_GENERATE_PASSWORDS
See Also:
Constant Field Values

IP_OPTION_USE_EMAIL_AS_USERNAME

private static final String IP_OPTION_USE_EMAIL_AS_USERNAME
See Also:
Constant Field Values

CTX_RETURN_URL

private static final String CTX_RETURN_URL
See Also:
Constant Field Values

CTX_MESSAGE

private static final String CTX_MESSAGE
See Also:
Constant Field Values

CTX_USERINFO

private static final String CTX_USERINFO
See Also:
Constant Field Values

CTX_FIELDS

private static final String CTX_FIELDS
See Also:
Constant Field Values

CTX_OPTIONALS

private static final String CTX_OPTIONALS
See Also:
Constant Field Values

CTX_REGED_USER_MSG

private static final String CTX_REGED_USER_MSG
See Also:
Constant Field Values

CTX_OPTION_GENERATE_PASSWORDS

private static final String CTX_OPTION_GENERATE_PASSWORDS
See Also:
Constant Field Values

CTX_OPTION_USE_EMAIL_AS_USERNAME

private static final String CTX_OPTION_USE_EMAIL_AS_USERNAME
See Also:
Constant Field Values

RB_EMAIL_SUBJECT

private static final String RB_EMAIL_SUBJECT
See Also:
Constant Field Values

PATH_SEPARATOR

private static final String PATH_SEPARATOR
See Also:
Constant Field Values

templateLocation

private String templateLocation
email template to use for merging


templateName

private String templateName

templateLocator

private org.apache.jetspeed.locator.JetspeedTemplateLocator templateLocator

emailSubject

private String emailSubject
localized emailSubject


redirectPath

private String redirectPath
path where to redirect to after pressing submit on the form


returnUrlPath

private String returnUrlPath
servlet path of the return url to be printed and href'd in email template


roles

private List roles
roles


groups

private List groups
groups


rules

private Map rules
profile rules


optionForceGeneratedPasswords

private boolean optionForceGeneratedPasswords
will force the passwords to be generated instead of picked by the user


optionForceEmailAsUsername

private boolean optionForceEmailAsUsername
will use cause the portlet to use a user request username instead otherwise forces emailaddress


optionForceEmailsToBeSystemUnique

private boolean optionForceEmailsToBeSystemUnique
will check to make sure the email address is unique to the system


required

private static final Boolean required

optional

private static final Boolean optional

IS_STRING

private static final Integer IS_STRING

IS_EMAIL

private static final Integer IS_EMAIL

IS_PHONE

private static final Integer IS_PHONE

IS_URL

private static final Integer IS_URL

IS_BDATE

private static final Integer IS_BDATE

formKeys

protected static Object[][] formKeys
Constructor Detail

UserRegistrationPortlet

public UserRegistrationPortlet()
Method Detail

init

public void init(javax.portlet.PortletConfig config)
          throws javax.portlet.PortletException
Specified by:
init in interface javax.portlet.Portlet
Overrides:
init in class org.apache.portals.bridges.velocity.GenericVelocityPortlet
Throws:
javax.portlet.PortletException

doEdit

public void doEdit(javax.portlet.RenderRequest request,
                   javax.portlet.RenderResponse response)
            throws javax.portlet.PortletException,
                   IOException
Overrides:
doEdit in class org.apache.portals.bridges.velocity.GenericVelocityPortlet
Throws:
javax.portlet.PortletException
IOException

doDispatch

protected void doDispatch(javax.portlet.RenderRequest request,
                          javax.portlet.RenderResponse response)
                   throws javax.portlet.PortletException,
                          IOException
Overrides:
doDispatch in class javax.portlet.GenericPortlet
Throws:
javax.portlet.PortletException
IOException

doView

public void doView(javax.portlet.RenderRequest request,
                   javax.portlet.RenderResponse response)
            throws javax.portlet.PortletException,
                   IOException
Overrides:
doView in class org.apache.portals.bridges.velocity.GenericVelocityPortlet
Throws:
javax.portlet.PortletException
IOException

getListOfNonSpecialFormKeys

protected List getListOfNonSpecialFormKeys()

getOptionalMap

protected Map getOptionalMap()

validateFormValue

protected boolean validateFormValue(String value,
                                    Integer length,
                                    Integer validationType)

convertIfNeed

protected String convertIfNeed(String key,
                               String value)

processAction

public void processAction(javax.portlet.ActionRequest actionRequest,
                          javax.portlet.ActionResponse actionResponse)
                   throws javax.portlet.PortletException,
                          IOException
Specified by:
processAction in interface javax.portlet.Portlet
Overrides:
processAction in class org.apache.portals.bridges.velocity.GenericVelocityPortlet
Throws:
javax.portlet.PortletException
IOException

getEmailSubject

protected String getEmailSubject(javax.portlet.PortletRequest request)

getInitParameterList

protected List getInitParameterList(javax.portlet.PortletConfig config,
                                    String ipName)

getPreferencesList

protected List getPreferencesList(javax.portlet.PortletPreferences prefs,
                                  String prefName)

generateReturnURL

protected String generateReturnURL(javax.portlet.PortletRequest request,
                                   javax.portlet.PortletResponse response,
                                   String urlGUID)

generateRedirectURL

protected String generateRedirectURL(javax.portlet.PortletRequest request,
                                     javax.portlet.PortletResponse response)

getTemplatePath

protected String getTemplatePath(javax.portlet.ActionRequest request,
                                 javax.portlet.ActionResponse response)


Copyright © 1999-2007 Apache Software Foundation. All Rights Reserved.