public class AudienceRestrictionImpl extends ConditionAbstractImpl implements AudienceRestriction
AudienceRestriction
specifies that the assertion
is addressed to one or more specific Audience
s.Modifier and Type | Field and Description |
---|---|
static String |
AUDIENCE_ELEMENT |
static String |
AUDIENCE_RESTRICTION_ELEMENT |
Constructor and Description |
---|
AudienceRestrictionImpl()
Default constructor
|
AudienceRestrictionImpl(Element element)
This constructor is used to build
AudienceRestriction
object from a block of existing XML that has already been built
into a DOM. |
AudienceRestrictionImpl(String xml)
This constructor is used to build
AudienceRestriction
object from a XML string. |
Modifier and Type | Method and Description |
---|---|
List<String> |
getAudience()
Returns a list of
String represented audiences |
boolean |
isMutable()
Returns true if the object is mutable
|
void |
makeImmutable()
Makes the object immutable
|
void |
setAudience(List audiences)
Sets the audiences
|
String |
toXMLString()
Returns a String representation
|
String |
toXMLString(boolean includeNSPrefix,
boolean declareNS)
Returns a String representation
|
public static String AUDIENCE_RESTRICTION_ELEMENT
public static String AUDIENCE_ELEMENT
public AudienceRestrictionImpl()
public AudienceRestrictionImpl(String xml) throws SAML2Exception
AudienceRestriction
object from a XML string.xml
- A java.lang.String
representing
a AudienceRestriction
objectSAML2Exception
- if it could not process the XML stringpublic AudienceRestrictionImpl(Element element) throws SAML2Exception
AudienceRestriction
object from a block of existing XML that has already been built
into a DOM.element
- A org.w3c.dom.Element
representing
DOM tree for AudienceRestriction
objectSAML2Exception
- if it could not process the Elementpublic List<String> getAudience()
String
represented audiencesgetAudience
in interface AudienceRestriction
String
represented audiencespublic void setAudience(List audiences) throws SAML2Exception
setAudience
in interface AudienceRestriction
audiences
- List of audiences as URI stringsSAML2Exception
- if the object is immutablepublic String toXMLString(boolean includeNSPrefix, boolean declareNS) throws SAML2Exception
toXMLString
in interface AudienceRestriction
toXMLString
in interface ConditionAbstract
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.SAML2Exception
- if something is wrong during conversionpublic String toXMLString() throws SAML2Exception
toXMLString
in interface AudienceRestriction
toXMLString
in interface ConditionAbstract
SAML2Exception
- if something is wrong during conversionpublic void makeImmutable()
makeImmutable
in interface AudienceRestriction
makeImmutable
in interface ConditionAbstract
makeImmutable
in class ConditionAbstractImpl
public boolean isMutable()
isMutable
in interface AudienceRestriction
isMutable
in interface ConditionAbstract
isMutable
in class ConditionAbstractImpl
Copyright © 2010–2025 Open Identity Platform Community. All rights reserved.