Package com.sun.identity.xacml.context
Interface Attribute
-
- All Superinterfaces:
XmlSerializable
- All Known Implementing Classes:
AttributeImpl
@SupportedAll public interface Attribute extends XmlSerializable
TheAttribute
element specifies information about the action/subject/resource requested in theRequest
context by listing a sequence ofAttribute
elements associated with the action.<xs:element name="Attribute" type="xacml-context:AttributeType"/> <xs:complexType name="AttributeType"> <xs:sequence> <xs:element ref="xacml-context:AttributeValue" maxOccurs="unbounded"/> <xs:sequence> <xs:attribute name="AttributeId" type="xs:anyURI" use="required"/> <xs:attribute name="DataType" type="xs:anyURI" use="required"/> <xs:attribute name="Issuer" type="xs:string" use="optional"/> <xs:complexType>
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description URI
getAttributeId()
Returns the AttributeId of theAttribute
which the attribute identifier.List
getAttributeValues()
Returns one to manyAttributeValue
elements for this object each attribite value MAY have empty contents, occur once or occur multiple times.URI
getDataType()
Returns the datatype of the contents of theAttributeValue
elements.String
getIssuer()
Returns the issuer of theAttribute
.boolean
isMutable()
Returnstrue
if the object is mutable.void
makeImmutable()
Makes the object immutablevoid
setAttributeId(URI attributeID)
Sets the attributeId of theAttribute
.void
setAttributeStringValues(List attrValues)
Sets the attribute values for this objectvoid
setAttributeValues(List attrValues)
Sets theAttributeValue
elements of this objectvoid
setDataType(URI dataType)
Sets the data type of the contents of theAttributeValue
elements.void
setIssuer(String issuer)
Sets the issuer of theAttribute
.default String
toXMLString()
Returns a string representation of this object.default String
toXMLString(boolean includeNSPrefix, boolean declareNS)
Returns aString
representation of this object-
Methods inherited from interface com.sun.identity.saml2.common.XmlSerializable
toDocumentFragment
-
-
-
-
Method Detail
-
getAttributeId
URI getAttributeId()
Returns the AttributeId of theAttribute
which the attribute identifier.- Returns:
- the
URI
representing the data type.
-
setAttributeId
void setAttributeId(URI attributeID) throws XACMLException
Sets the attributeId of theAttribute
.- Parameters:
attributeID
-URI
representing the attribite id.- Throws:
XACMLException
- if the object is immutable
-
getIssuer
String getIssuer()
Returns the issuer of theAttribute
.- Returns:
String
representing the issuer. It MAY be an x500Name that binds to a public key or some other identification exchanged out-of-band by participating entities.
-
setIssuer
void setIssuer(String issuer) throws XACMLException
Sets the issuer of theAttribute
.- Parameters:
issuer
-String
representing the issuer. It MAY be an x500Name that binds to a public key or some other identification exchanged out-of-band by participating entities. This is optional so return value could be null or an emptyString
.- Throws:
XACMLException
- if the object is immutable
-
getDataType
URI getDataType()
Returns the datatype of the contents of theAttributeValue
elements. This will be either a primitive datatype defined by XACML 2.0 specification or a type ( primitive or structured) defined in a namespace declared in the <xacml-context> element.- Returns:
- the
URI
representing the data type.
-
setDataType
void setDataType(URI dataType) throws XACMLException
Sets the data type of the contents of theAttributeValue
elements.- Parameters:
dataType
-URI
representing the data type.- Throws:
XACMLException
- if the object is immutable
-
getAttributeValues
List getAttributeValues()
Returns one to manyAttributeValue
elements for this object each attribite value MAY have empty contents, occur once or occur multiple times.- Returns:
- the List
AttributeValue
elements of this object
-
setAttributeValues
void setAttributeValues(List attrValues) throws XACMLException
Sets theAttributeValue
elements of this object- Parameters:
attrValues
- List containingAttributeValue
elements of this object.- Throws:
XACMLException
- if the object is immutable An object is consideredimmutable
ifmakeImmutable()
has been invoked on it. It can be determined by callingisMutable
on the object.
-
setAttributeStringValues
void setAttributeStringValues(List attrValues) throws XACMLException
Sets the attribute values for this object- Parameters:
attrValues
-List
containingString
values of this object.- Throws:
XACMLException
- if the object is immutable An object is consideredimmutable
ifmakeImmutable()
has been invoked on it. It can be determined by callingisMutable
on the object.
-
toXMLString
default String toXMLString(boolean includeNSPrefix, boolean declareNS) throws XACMLException
Returns aString
representation of this object- Specified by:
toXMLString
in interfaceXmlSerializable
- Parameters:
includeNSPrefix
- Determines whether or not the namespace qualifier is prepended to the Element when converteddeclareNS
- Determines whether or not the namespace is declared within the Element.- Returns:
- a string representation of this object
- Throws:
XACMLException
- if conversion fails for any reason
-
toXMLString
default String toXMLString() throws XACMLException
Returns a string representation of this object.- Specified by:
toXMLString
in interfaceXmlSerializable
- Returns:
- a string representation of this object.
- Throws:
XACMLException
- if conversion fails for any reason.
-
makeImmutable
void makeImmutable()
Makes the object immutable
-
isMutable
boolean isMutable()
Returnstrue
if the object is mutable.- Returns:
true
if the object is mutable.
-
-