|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.edg.security.authorization.map.AttributeMapFactory
AttributeMapFactory Creates a Map from an XML snippet.
<map name="name" type="type" modify="boolean" > -- the supplied "config" node <!-- type specific data --> </map>The factory uses MapCreators, of which there are a set in this package. NOTE: If the "name" attribute is set, and another Map instance with the same "name" has already been created, that Map will be returned instead. NO CONSISTENCY CHECKS ARE PERFORMED to verify whether the two configurations actually would produce identical maps.
AttributeMapCreator
,
TableMapCreator (type = table)
,
FileMapCreator (type = file)
,
DbMapCreator (type = db)
,
CachedMapCreator (type = cached)
,
RegexMapCreator (type = regex)
Field Summary | |
protected java.util.Hashtable |
theCreatedMaps
Hashtable storing the created maps with their name as lookup key |
protected static java.util.Hashtable |
theMapCreators
Hashtable storing the String->Class mappings type -> AttributeMapCreator |
static java.lang.String |
theMapElement
|
static java.lang.String |
theModifyAttribute
|
static java.lang.String |
theNameAttribute
|
static java.lang.String |
theTypeAttribute
|
Constructor Summary | |
AttributeMapFactory()
|
Method Summary | |
AttributeMap |
getMap(org.w3c.dom.Element config)
Method getMap. |
AttributeMap |
getMap(java.lang.String name)
|
java.util.List |
getMapNames()
|
java.util.List |
getMaps(org.w3c.dom.Element config)
Method getMaps. |
java.util.List |
getMaps(java.io.File configFile)
Convenience method, loading all maps defined inside the root element of the supplied config file. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final java.lang.String theMapElement
public static final java.lang.String theTypeAttribute
public static final java.lang.String theNameAttribute
public static final java.lang.String theModifyAttribute
protected static java.util.Hashtable theMapCreators
protected java.util.Hashtable theCreatedMaps
Constructor Detail |
public AttributeMapFactory()
Method Detail |
public java.util.List getMapNames()
public AttributeMap getMap(java.lang.String name)
name
- The name of a previously configured map
public AttributeMap getMap(org.w3c.dom.Element config) throws java.lang.Exception
config
- The given configuration, containing 'map' element(s)
java.lang.Exception
- if the map could not be createdpublic java.util.List getMaps(org.w3c.dom.Element config) throws java.lang.Exception
config
- The given configuration, containing 'map' children nodes
java.lang.Exception
- if one of the 'map' elements cannot be createdpublic java.util.List getMaps(java.io.File configFile) throws java.lang.Exception
java.lang.Exception
getMaps(Element)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |