Class ResponseImpl
- java.lang.Object
-
- com.sun.identity.saml2.protocol.impl.StatusResponseImpl
-
- com.sun.identity.saml2.protocol.impl.ResponseImpl
-
- All Implemented Interfaces:
Response,StatusResponse
public class ResponseImpl extends StatusResponseImpl implements Response
This is an implementation of interfaceResponse. TheResponsemessage element is used when a response consists of a list of zero or more assertions that satisfy the request. It has the complex typeResponseType.<complexType name="ResponseType"> <complexContent> <extension base="{urn:oasis:names:tc:SAML:2.0:protocol}StatusResponseType"> <choice maxOccurs="unbounded" minOccurs="0"> <element ref="{urn:oasis:names:tc:SAML:2.0:assertion}Assertion"/> <element ref="{urn:oasis:names:tc:SAML:2.0:assertion}EncryptedAssertion"/> </choice> </extension> </complexContent> </complexType>
-
-
Field Summary
-
Fields inherited from class com.sun.identity.saml2.protocol.impl.StatusResponseImpl
consent, destination, extensions, inResponseTo, isMutable, isSignatureValid, isSigned, issueInstant, issuer, publicKey, responseId, signatureString, signedXMLString, status, version
-
-
Constructor Summary
Constructors Constructor Description ResponseImpl()Class constructor.ResponseImpl(String xmlString)Class constructor withResponsein xml string format.ResponseImpl(Element element)Class constructor withResponseinElementformat.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ListgetAssertion()ReturnsAssertion(s) of the response.ListgetEncryptedAssertion()ReturnsEncryptedAssertion(s) of the response.voidmakeImmutable()Makes this object immutable.voidsetAssertion(List value)Sets Assertion(s) of the response.voidsetEncryptedAssertion(List value)SetsEncryptedAssertion(s) of the response.StringtoXMLString()Returns a String representation of this Object.StringtoXMLString(boolean includeNSPrefix, boolean declareNS)Returns a String representation of this Object.-
Methods inherited from class com.sun.identity.saml2.protocol.impl.StatusResponseImpl
getConsent, getDestination, getExtensions, getID, getInResponseTo, getIssueInstant, getIssuer, getSignature, getStatus, getVersion, isMutable, isSignatureValid, isSigned, setConsent, setDestination, setExtensions, setID, setInResponseTo, setIssueInstant, setIssuer, setStatus, setVersion, sign, validateData, validateID, validateIssueInstant, validateStatus, validateVersion
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.sun.identity.saml2.protocol.StatusResponse
getConsent, getDestination, getExtensions, getID, getInResponseTo, getIssueInstant, getIssuer, getSignature, getStatus, getVersion, isMutable, isSignatureValid, isSigned, setConsent, setDestination, setExtensions, setID, setInResponseTo, setIssueInstant, setIssuer, setStatus, setVersion, sign
-
-
-
-
Constructor Detail
-
ResponseImpl
public ResponseImpl()
Class constructor. Caller may need to call setters to populate the object.
-
ResponseImpl
public ResponseImpl(Element element) throws SAML2Exception
Class constructor withResponseinElementformat.- Parameters:
element- the Document Element.- Throws:
SAML2Exception- if there is an error.
-
ResponseImpl
public ResponseImpl(String xmlString) throws SAML2Exception
Class constructor withResponsein xml string format.- Parameters:
xmlString- the Response String..- Throws:
SAML2Exception- if there is an error.
-
-
Method Detail
-
getAssertion
public List getAssertion()
ReturnsAssertion(s) of the response.- Specified by:
getAssertionin interfaceResponse- Returns:
- List of
Assertion(s) in the response. - See Also:
setAssertion(List)
-
setAssertion
public void setAssertion(List value) throws SAML2Exception
Sets Assertion(s) of the response.- Specified by:
setAssertionin interfaceResponse- Parameters:
value- List of newAssertion(s).- Throws:
SAML2Exception- if the object is immutable.- See Also:
getAssertion()
-
getEncryptedAssertion
public List getEncryptedAssertion()
ReturnsEncryptedAssertion(s) of the response.- Specified by:
getEncryptedAssertionin interfaceResponse- Returns:
- List of
EncryptedAssertion(s) in the response. - See Also:
setEncryptedAssertion(List)
-
setEncryptedAssertion
public void setEncryptedAssertion(List value) throws SAML2Exception
SetsEncryptedAssertion(s) of the response.- Specified by:
setEncryptedAssertionin interfaceResponse- Parameters:
value- List of newEncryptedAssertion(s).- Throws:
SAML2Exception- if the object is immutable.- See Also:
getEncryptedAssertion()
-
makeImmutable
public void makeImmutable()
Makes this object immutable.- Specified by:
makeImmutablein interfaceStatusResponse- Overrides:
makeImmutablein classStatusResponseImpl
-
toXMLString
public String toXMLString() throws SAML2Exception
Returns a String representation of this Object.- Specified by:
toXMLStringin interfaceStatusResponse- Overrides:
toXMLStringin classStatusResponseImpl- Returns:
- a String representation of this Object.
- Throws:
SAML2Exception- if it could not create String object
-
toXMLString
public String toXMLString(boolean includeNSPrefix, boolean declareNS) throws SAML2Exception
Returns a String representation of this Object.- Specified by:
toXMLStringin interfaceStatusResponse- Overrides:
toXMLStringin classStatusResponseImpl- 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:
SAML2Exception- if it could not create String object.
-
-