org.figure8.join.control.config
Class ActionConstraintConfig

java.lang.Object
  extended by org.figure8.join.control.config.ActionConstraintConfig
All Implemented Interfaces:
java.io.Serializable

public class ActionConstraintConfig
extends java.lang.Object
implements java.io.Serializable

A JavaBean representing security constraints on an <action> element from a Struts application module configuration file.
This JavaBean can have a set of security roles allowed to request the corresponding action. Because most of the actions in Join are entries to business operations, action may have no roles directly associated but instead provides security to its operations.
In this later case, roles associated with operation overrides roles associated with the action.

Version:
$Revision: 1.1 $
Author:
Laurent Broudoux
See Also:
Serialized Form

Constructor Summary
ActionConstraintConfig()
          Creates a new instance of ActionConstraintConfig
 
Method Summary
 void addOperationConstraint(OperationConstraintConfig constraint)
          Add a new OperationConstraintConfig instance to the set associated.
 void addRole(RoleConfig role)
          Add a new RoleConfig instance to the set associated.
 OperationConstraintConfig findOperationConstraint(java.lang.String name)
          Return the operation constraint configuration for the specified operation name, if any; otherwise return null.
 java.lang.String getPath()
           
 java.util.Collection getRoles()
          Return the list of security roles allowed to request the associated action if any; otherwise return an empty collection.
 void setPath(java.lang.String path)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ActionConstraintConfig

public ActionConstraintConfig()
Creates a new instance of ActionConstraintConfig

Method Detail

getPath

public java.lang.String getPath()
Returns:
The path this action constraint applies to

setPath

public void setPath(java.lang.String path)
Parameters:
path - The path this action constraint applies to

addRole

public void addRole(RoleConfig role)
Add a new RoleConfig instance to the set associated.

Parameters:
role - The new role configuration instance to be added

getRoles

public java.util.Collection getRoles()
Return the list of security roles allowed to request the associated action if any; otherwise return an empty collection.

Returns:
Collection of RoleConfig

addOperationConstraint

public void addOperationConstraint(OperationConstraintConfig constraint)
Add a new OperationConstraintConfig instance to the set associated.

Parameters:
constraint - The new constraint configuration instance to be added

findOperationConstraint

public OperationConstraintConfig findOperationConstraint(java.lang.String name)
Return the operation constraint configuration for the specified operation name, if any; otherwise return null.

Parameters:
name - Name of the operation constraint configuration to return
Returns:
The corresponding OperationConstraintConfig


Copyright © 2005-2008 Join. All Rights Reserved.