|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.apache.avalon.excalibur.system.AbstractRoleManager
The Excalibur Role Manager is used for Excalibur Role Mappings. All of the information is hard-coded.
Field Summary | |
protected static java.lang.String |
EMPTY_STRING
|
protected java.util.Map |
m_classNames
Map for role to classname mapping |
protected java.util.Map |
m_handlerNames
Map for role to handler classname mapping |
protected java.lang.ClassLoader |
m_loader
|
protected RoleManager |
m_parent
Parent RoleManager for nested resolution |
protected java.util.Map |
m_shorthands
Map for shorthand to class mapping |
Constructor Summary | |
AbstractRoleManager()
Default constructor--this RoleManager has no parent. |
|
AbstractRoleManager(RoleManager parent)
Alternate constructor--this RoleManager has the specified parent. |
|
AbstractRoleManager(RoleManager parent,
java.lang.ClassLoader loader)
Alternate constructor--this RoleManager has the specified parent. |
Method Summary | |
java.lang.Class[] |
getClassesForRole(java.lang.String role)
Retrieves the default class name for the specified role. |
java.lang.Class |
getClassForName(java.lang.String shorthandName)
Find the Class for the given shorthand name. |
java.lang.Class |
getHandlerClassForClass(java.lang.Class className)
Retrieves the handler class name for the specified class name. |
java.lang.String |
getNameForClass(java.lang.Class klass)
Retrieves the real role name from a shorthand name. |
java.lang.String |
getRoleForClass(java.lang.Class klass)
Retrieves a default class name for a role/hint combination. |
protected void |
setup(java.util.Map shorts,
java.util.Map classes,
java.util.Map handlers,
java.lang.String shortName,
java.lang.String role,
java.lang.String className,
java.lang.String handlerClassName)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
protected static final java.lang.String EMPTY_STRING
protected final java.lang.ClassLoader m_loader
protected java.util.Map m_shorthands
protected java.util.Map m_classNames
protected java.util.Map m_handlerNames
protected final RoleManager m_parent
RoleManager
for nested resolutionConstructor Detail |
public AbstractRoleManager()
public AbstractRoleManager(RoleManager parent)
parent
- The parent RoleManager
.public AbstractRoleManager(RoleManager parent, java.lang.ClassLoader loader)
parent
- The parent RoleManager
.Method Detail |
protected void setup(java.util.Map shorts, java.util.Map classes, java.util.Map handlers, java.lang.String shortName, java.lang.String role, java.lang.String className, java.lang.String handlerClassName)
public final java.lang.Class getClassForName(java.lang.String shorthandName)
null
. If this RoleManager does not have the match,
and there is a parent RoleManager, the parent will be asked to resolve
the request.getClassForName
in interface RoleManager
public final java.lang.String getNameForClass(java.lang.Class klass)
getNameForClass
in interface RoleManager
shorthandName
- The shortname that is an alias for the role.public final java.lang.Class getHandlerClassForClass(java.lang.Class className)
getHandlerClassForClass
in interface RoleManager
role
- The role that has a default implementation.public final java.lang.Class[] getClassesForRole(java.lang.String role)
getClassesForRole
in interface RoleManager
role
- The role that has a default implementation.public final java.lang.String getRoleForClass(java.lang.Class klass)
getRoleForClass
in interface RoleManager
role
- The role that this shorthand refers to.shorthand
- The shorthand name for the type of Component
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |