org.apache.jetspeed.layout.impl
Class BaseUserAction

java.lang.Object
  extended by org.apache.jetspeed.layout.impl.BaseUserAction
All Implemented Interfaces:
org.apache.jetspeed.ajax.AjaxAction, org.apache.jetspeed.ajax.AjaxBuilder, Constants
Direct Known Subclasses:
GetUserInformationAction, GetUserListAction

public abstract class BaseUserAction
extends Object
implements org.apache.jetspeed.ajax.AjaxAction, org.apache.jetspeed.ajax.AjaxBuilder, Constants

Abstract portlet placement action

Version:
$Id: $
Author:
David Gurney, David Sean Taylor, Mikko Wuokko

Field Summary
protected  String errorTemplate
           
protected  org.apache.commons.logging.Log log
           
protected  RolesSecurityBehavior securityBehavior
           
protected  String template
           
protected  org.apache.jetspeed.security.UserManager userManager
           
 
Fields inherited from interface org.apache.jetspeed.layout.impl.Constants
ABS, ACTION, CARTESIAN, COL, CUSTOM_MENUS, DEFAULT_LAYOUT, DESKTOP_EXTENDED, DESKTOP_PAGE_DECORATIONS, DESKTOP_PORTLET_DECORATIONS, DESTINATION, DOWN, FILTER, FOLDER, FOLDERS, FORMAT, FRAGMENTID, FRAGMENTS, GUESTUSERS, HEIGHT, INCLUDE_MENU_DEFS, IPADDRESS, LAYOUT, LAYOUTID, LAYOUTS, LEFT, LINK, LINKS, MENU, MENU_CONTEXT, MENU_DEFINITIONS, MENU_LOCALE, MENU_NAME, METADATA, NEWCOL, NEWROW, OFFLINE, OLD_DESKTOP_EXTENDED, OLD_HEIGHT, OLD_PORTLET_MODE, OLD_WIDTH, OLD_WINDOW_STATE, OLD_X, OLD_Y, OLD_Z, OLDCOL, OLDROW, ONLINE, PAGE, PAGE_DECORATIONS, PAGE_QUALIFIED_CREATE_ON_EDIT, PAGES, PORTLET_DECORATIONS, PORTLET_MODE, PORTLETENTITY, PORTLETID, PORTLETS, PROFILED_PATH, REASON, RESOURCE_NAME, RIGHT, ROLES, ROW, SECURITY_DEFS, SECURITY_OWNER, SECURITY_REFS, SESSIONS, SHORT_TITLE, SIZES, SOURCE, STANDARD_MENUS, STATUS, TITLE, TYPE, UP, USER_IS_ANONYMOUS, USERINFO, USERNAME, USERS, WIDTH, WINDOW_STATE, X, Y, Z
 
Constructor Summary
BaseUserAction(String template, String errorTemplate, RolesSecurityBehavior securityBehavior)
           
BaseUserAction(String template, String errorTemplate, org.apache.jetspeed.security.UserManager userManager)
           
BaseUserAction(String template, String errorTemplate, org.apache.jetspeed.security.UserManager userManager, RolesSecurityBehavior securityBehavior)
           
 
Method Summary
 boolean buildContext(org.apache.jetspeed.request.RequestContext requestContext, Map responseContext)
           
 boolean buildErrorContext(org.apache.jetspeed.request.RequestContext requestContext, Map responseContext)
           
 boolean checkAccess(org.apache.jetspeed.request.RequestContext context, String action)
           
 boolean createNewPageOnEdit(org.apache.jetspeed.request.RequestContext context)
           
 String getActionParameter(org.apache.jetspeed.request.RequestContext requestContext, String name)
           
 String getErrorTemplate()
           
 org.apache.jetspeed.om.page.Fragment getFragmentIdFromLocation(int row, int column, org.apache.jetspeed.om.page.Page page)
           
 org.apache.jetspeed.om.page.Fragment getParentFragmentById(String id, org.apache.jetspeed.om.page.Fragment root)
           
 String getTemplate()
           
 boolean isTrue(String parameter)
          Helper method to determine if a parameter is true.
 boolean runBatch(org.apache.jetspeed.request.RequestContext requestContext, Map resultMap)
           
protected  org.apache.jetspeed.om.page.Fragment searchForParentFragmentById(String id, org.apache.jetspeed.om.page.Fragment parent)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.apache.jetspeed.ajax.AjaxAction
run
 

Field Detail

log

protected org.apache.commons.logging.Log log

template

protected String template

userManager

protected org.apache.jetspeed.security.UserManager userManager

errorTemplate

protected String errorTemplate

securityBehavior

protected RolesSecurityBehavior securityBehavior
Constructor Detail

BaseUserAction

public BaseUserAction(String template,
                      String errorTemplate,
                      RolesSecurityBehavior securityBehavior)

BaseUserAction

public BaseUserAction(String template,
                      String errorTemplate,
                      org.apache.jetspeed.security.UserManager userManager)

BaseUserAction

public BaseUserAction(String template,
                      String errorTemplate,
                      org.apache.jetspeed.security.UserManager userManager,
                      RolesSecurityBehavior securityBehavior)
Method Detail

buildContext

public boolean buildContext(org.apache.jetspeed.request.RequestContext requestContext,
                            Map responseContext)
Specified by:
buildContext in interface org.apache.jetspeed.ajax.AjaxBuilder

buildErrorContext

public boolean buildErrorContext(org.apache.jetspeed.request.RequestContext requestContext,
                                 Map responseContext)
Specified by:
buildErrorContext in interface org.apache.jetspeed.ajax.AjaxBuilder

getErrorTemplate

public String getErrorTemplate()
Specified by:
getErrorTemplate in interface org.apache.jetspeed.ajax.AjaxBuilder

getTemplate

public String getTemplate()
Specified by:
getTemplate in interface org.apache.jetspeed.ajax.AjaxBuilder

checkAccess

public boolean checkAccess(org.apache.jetspeed.request.RequestContext context,
                           String action)
Specified by:
checkAccess in interface org.apache.jetspeed.ajax.AjaxAction

createNewPageOnEdit

public boolean createNewPageOnEdit(org.apache.jetspeed.request.RequestContext context)

getFragmentIdFromLocation

public org.apache.jetspeed.om.page.Fragment getFragmentIdFromLocation(int row,
                                                                      int column,
                                                                      org.apache.jetspeed.om.page.Page page)

runBatch

public boolean runBatch(org.apache.jetspeed.request.RequestContext requestContext,
                        Map resultMap)
                 throws org.apache.jetspeed.ajax.AJAXException
Specified by:
runBatch in interface org.apache.jetspeed.ajax.AjaxAction
Throws:
org.apache.jetspeed.ajax.AJAXException

getActionParameter

public String getActionParameter(org.apache.jetspeed.request.RequestContext requestContext,
                                 String name)

getParentFragmentById

public org.apache.jetspeed.om.page.Fragment getParentFragmentById(String id,
                                                                  org.apache.jetspeed.om.page.Fragment root)

searchForParentFragmentById

protected org.apache.jetspeed.om.page.Fragment searchForParentFragmentById(String id,
                                                                           org.apache.jetspeed.om.page.Fragment parent)

isTrue

public boolean isTrue(String parameter)
Helper method to determine if a parameter is true. Prevents accidental NullPointerExceptions when comparing or or using the parameter value.

Parameters:
parameter - The value to be determined as boolean true or false.
Returns:
boolean true or false according to the @param value.


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