|
SunTM's XACML Implementation for JavaTM | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.sun.xacml.attr.AttributeFactory
This is an abstract factory class for creating XACML attribute values. There may be any number of factories available in the system, though there is always one default factory used by the core code.
Constructor Summary | |
protected |
AttributeFactory()
Default constructor. |
Method Summary | |
static void |
addAttributeProxy(String id,
AttributeProxy proxy)
Deprecated. As of version 1.2, replaced by addDatatype(String,AttributeProxy) .
The new factory system requires you to get a factory
instance and then call the non-static methods on that
factory. The static versions of these methods have been
left in for now, but are slower and will be removed in
a future version. |
abstract void |
addDatatype(String id,
AttributeProxy proxy)
Adds a proxy to the factory, which in turn will allow new attribute types to be created using the factory. |
static AttributeValue |
createAttribute(Node root)
Deprecated. As of version 1.2, replaced by createValue(Node) .
The new factory system requires you to get a factory
instance and then call the non-static methods on that
factory. The static versions of these methods have been
left in for now, but are slower and will be removed in
a future version. |
static AttributeValue |
createAttribute(Node root,
String type)
Deprecated. As of version 1.2, replaced by createValue(Node,String) .
The new factory system requires you to get a factory
instance and then call the non-static methods on that
factory. The static versions of these methods have been
left in for now, but are slower and will be removed in
a future version. |
static AttributeValue |
createAttribute(Node root,
URI dataType)
Deprecated. As of version 1.2, replaced by createValue(Node,URI) .
The new factory system requires you to get a factory
instance and then call the non-static methods on that
factory. The static versions of these methods have been
left in for now, but are slower and will be removed in
a future version. |
static AttributeValue |
createAttribute(URI dataType,
String value)
Deprecated. As of version 1.2, replaced by createValue(URI,String) .
The new factory system requires you to get a factory
instance and then call the non-static methods on that
factory. The static versions of these methods have been
left in for now, but are slower and will be removed in
a future version. |
abstract AttributeValue |
createValue(Node root)
Creates a value based on the given DOM root node. |
abstract AttributeValue |
createValue(Node root,
String type)
Creates a value based on the given DOM root node and data type. |
abstract AttributeValue |
createValue(Node root,
URI dataType)
Creates a value based on the given DOM root node and data type. |
abstract AttributeValue |
createValue(URI dataType,
String value)
Creates a value based on the given data type and text-encoded value. |
static AttributeFactory |
getInstance()
Returns the default factory. |
abstract Set |
getSupportedDatatypes()
Returns the datatype identifiers supported by this factory. |
static void |
setDefaultFactory(AttributeFactoryProxy proxy)
Sets the default factory. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
protected AttributeFactory()
Method Detail |
public static final AttributeFactory getInstance()
AttributeFactory
public static final void setDefaultFactory(AttributeFactoryProxy proxy)
public abstract void addDatatype(String id, AttributeProxy proxy)
AttributeValue
class.
id
- the name of the attribute typeproxy
- the proxy used to create new attributes of the given type
IllegalArgumentException
- if the given id is already in usepublic static void addAttributeProxy(String id, AttributeProxy proxy)
addDatatype(String,AttributeProxy)
.
The new factory system requires you to get a factory
instance and then call the non-static methods on that
factory. The static versions of these methods have been
left in for now, but are slower and will be removed in
a future version.
AttributeValue
class.
id
- the name of the attribute typeproxy
- the proxy used to create new attributes of the given type
IllegalArgumentException
- if the given id is already in usepublic abstract Set getSupportedDatatypes()
Set
of String
spublic abstract AttributeValue createValue(Node root) throws UnknownIdentifierException, ParsingException
DataType
, as is the case with the
AttributeValueType in the policy schema. The value is assumed to be
the first child of this node.
root
- the DOM root of an attribute value
AttributeValue
UnknownIdentifierException
- if the type in the node isn't
known to the factory
ParsingException
- if the node is invalid or can't be parsed
by the appropriate proxypublic static AttributeValue createAttribute(Node root) throws UnknownIdentifierException, ParsingException
createValue(Node)
.
The new factory system requires you to get a factory
instance and then call the non-static methods on that
factory. The static versions of these methods have been
left in for now, but are slower and will be removed in
a future version.
DataType
, as is the case with the
AttributeValueType in the policy schema. The value is assumed to be
the first child of this node. This uses the default factory.
root
- the DOM root of an attribute value
AttributeValue
UnknownIdentifierException
- if the type in the node isn't
known to the factory
ParsingException
- if the node is invalid or can't be parsed
by the appropriate proxypublic abstract AttributeValue createValue(Node root, URI dataType) throws UnknownIdentifierException, ParsingException
root
- the DOM root of an attribute valuedataType
- the type of the attribute
AttributeValue
UnknownIdentifierException
- if the data type isn't known to
the factory
ParsingException
- if the node is invalid or can't be parsed
by the appropriate proxypublic static AttributeValue createAttribute(Node root, URI dataType) throws UnknownIdentifierException, ParsingException
createValue(Node,URI)
.
The new factory system requires you to get a factory
instance and then call the non-static methods on that
factory. The static versions of these methods have been
left in for now, but are slower and will be removed in
a future version.
root
- the DOM root of an attribute valuedataType
- the type of the attribute
AttributeValue
UnknownIdentifierException
- if the data type isn't known to
the factory
ParsingException
- if the node is invalid or can't be parsed
by the appropriate proxypublic abstract AttributeValue createValue(Node root, String type) throws UnknownIdentifierException, ParsingException
root
- the DOM root of an attribute valuetype
- the type of the attribute
AttributeValue
UnknownIdentifierException
- if the type isn't known to
the factory
ParsingException
- if the node is invalid or can't be parsed
by the appropriate proxypublic static AttributeValue createAttribute(Node root, String type) throws UnknownIdentifierException, ParsingException
createValue(Node,String)
.
The new factory system requires you to get a factory
instance and then call the non-static methods on that
factory. The static versions of these methods have been
left in for now, but are slower and will be removed in
a future version.
root
- the DOM root of an attribute valuetype
- the type of the attribute
AttributeValue
UnknownIdentifierException
- if the type isn't known to
the factory
ParsingException
- if the node is invalid or can't be parsed
by the appropriate proxypublic abstract AttributeValue createValue(URI dataType, String value) throws UnknownIdentifierException, ParsingException
dataType
- the type of the attributevalue
- the text-encoded representation of an attribute's value
AttributeValue
UnknownIdentifierException
- if the data type isn't known to
the factory
ParsingException
- if the text is invalid or can't be parsed
by the appropriate proxypublic static AttributeValue createAttribute(URI dataType, String value) throws UnknownIdentifierException, ParsingException
createValue(URI,String)
.
The new factory system requires you to get a factory
instance and then call the non-static methods on that
factory. The static versions of these methods have been
left in for now, but are slower and will be removed in
a future version.
dataType
- the type of the attributevalue
- the text-encoded representation of an attribute's value
AttributeValue
UnknownIdentifierException
- if the data type isn't known to
the factory
ParsingException
- if the text is invalid or can't be parsed
by the appropriate proxy
|
Sun's XACML Implementation Version 1.2 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Sun, Sun Microsystems, the Sun Logo, and Java are trademarks or registered trademarks of Sun Microsystems, Inc. in the US and other countries.