Class AuthnRequestImpl
- java.lang.Object
-
- com.sun.identity.saml2.protocol.impl.RequestAbstractImpl
-
- com.sun.identity.saml2.protocol.impl.AuthnRequestImpl
-
- All Implemented Interfaces:
AuthnRequest,RequestAbstract
public class AuthnRequestImpl extends RequestAbstractImpl implements AuthnRequest
TheAuthnRequestImplimplements the AuthnRequest interface , defines methods for properties required by a saml request.
-
-
Field Summary
-
Fields inherited from class com.sun.identity.saml2.protocol.impl.RequestAbstractImpl
consent, destinationURI, elementName, extensions, isMutable, isSignatureValid, isSigned, issueInstant, nameID, publicKey, requestId, signatureString, signedXMLString, version
-
-
Constructor Summary
Constructors Constructor Description AuthnRequestImpl()Constructor to createAuthnRequestObject .AuthnRequestImpl(String xmlString)Constructor to createAuthnRequestObject.AuthnRequestImpl(Element element)Constructor to createAuthnRequestObject.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description IntegergetAssertionConsumerServiceIndex()Returns the value of theAssertionConsumerServiceIndexattribute.StringgetAssertionConsumerServiceURL()Returns the value of theAssertionConsumerServiceURLattribute.IntegergetAttributeConsumingServiceIndex()Returns the value of theAttributeConsumingServiceIndexattribute.ConditionsgetConditions()Returns theConditionsobject.NameIDPolicygetNameIDPolicy()Returns theNameIDPolicyobject.StringgetProtocolBinding()Returns the value of theProtocolBindingattribute.StringgetProviderName()Returns theProviderNameattribute value.RequestedAuthnContextgetRequestedAuthnContext()Returns theRequestedAuthnContextobject.ScopinggetScoping()Returns theScopingobject.SubjectgetSubject()Returns theSubjectobject.BooleanisForceAuthn()Returns value ofisForceAuthnattribute.BooleanisPassive()Returns the value of theisPassiveattribute.voidmakeImmutable()Makes this object immutable.protected voidparseDOMElement(Element element)Parses the Docuemnt Element for this object.voidsetAssertionConsumerServiceIndex(Integer index)Sets the value of theAssertionConsumerServiceIndexattribute.voidsetAssertionConsumerServiceURL(String url)Sets the value of theAssertionConsumerServiceURLattribute.voidsetAttributeConsumingServiceIndex(Integer index)Sets the value of theAttributeConsumingServiceIndexattribute.voidsetConditions(Conditions conditions)Sets theConditionsobject.voidsetForceAuthn(Boolean value)Sets the value of theForceAuthnattribute.voidsetIsPassive(Boolean value)Sets the value of theIsPassiveattribute.voidsetNameIDPolicy(NameIDPolicy nameIDPolicy)Sets theNameIDPolicyobject.voidsetProtocolBinding(String protocolBinding)Sets the value of theProtocolBindingattribute.voidsetProviderName(String providerName)Sets theProviderNameattribute value.voidsetRequestedAuthnContext(RequestedAuthnContext reqAuthnContext)Sets theRequestedAuthnContext.voidsetScoping(Scoping scoping)Sets theScopingobject.voidsetSubject(Subject subject)Sets theSubjectobject.StringtoXMLString()Returns a String representation of this Object.StringtoXMLString(boolean includeNSPrefix, boolean declareNS)Returns a String representation-
Methods inherited from class com.sun.identity.saml2.protocol.impl.RequestAbstractImpl
getAttributesString, getConsent, getDestination, getElements, getExtensions, getID, getIssueInstant, getIssuer, getSignature, getVersion, getXMLString, isMutable, isSignatureValid, isSigned, parseDOMAttributes, parseDOMChileElements, setConsent, setDestination, setExtensions, setID, setIssueInstant, setIssuer, setVersion, sign, validateData, validateID, validateIssueInstant, 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.RequestAbstract
getConsent, getDestination, getExtensions, getID, getIssueInstant, getIssuer, getSignature, getVersion, isMutable, isSignatureValid, isSigned, setConsent, setDestination, setExtensions, setID, setIssueInstant, setIssuer, setVersion, sign
-
-
-
-
Constructor Detail
-
AuthnRequestImpl
public AuthnRequestImpl()
Constructor to createAuthnRequestObject .
-
AuthnRequestImpl
public AuthnRequestImpl(Element element) throws SAML2Exception
Constructor to createAuthnRequestObject.- Parameters:
element- the Document Element Object.- Throws:
SAML2Exception- if error creatingAuthnRequestObject.
-
AuthnRequestImpl
public AuthnRequestImpl(String xmlString) throws SAML2Exception
Constructor to createAuthnRequestObject.- Parameters:
xmlString- the XML String.- Throws:
SAML2Exception- if error creatingAuthnRequestObject.
-
-
Method Detail
-
getSubject
public Subject getSubject()
Returns theSubjectobject.- Specified by:
getSubjectin interfaceAuthnRequest- Returns:
- the
Subjectobject. - See Also:
setSubject(Subject)
-
setSubject
public void setSubject(Subject subject) throws SAML2Exception
Sets theSubjectobject.- Specified by:
setSubjectin interfaceAuthnRequest- Parameters:
subject- the newSubjectobject.- Throws:
SAML2Exception- if the object is immutable.- See Also:
getSubject()
-
getNameIDPolicy
public NameIDPolicy getNameIDPolicy()
Returns theNameIDPolicyobject.- Specified by:
getNameIDPolicyin interfaceAuthnRequest- Returns:
- the
NameIDPolicyobject. - See Also:
setNameIDPolicy(NameIDPolicy)
-
setNameIDPolicy
public void setNameIDPolicy(NameIDPolicy nameIDPolicy) throws SAML2Exception
Sets theNameIDPolicyobject.- Specified by:
setNameIDPolicyin interfaceAuthnRequest- Parameters:
nameIDPolicy- the newNameIDPolicyobject.- Throws:
SAML2Exception- if the object is immutable.- See Also:
getNameIDPolicy()
-
getConditions
public Conditions getConditions()
Returns theConditionsobject.- Specified by:
getConditionsin interfaceAuthnRequest- Returns:
- the
Conditionsobject. - See Also:
setConditions(Conditions)
-
setConditions
public void setConditions(Conditions conditions) throws SAML2Exception
Sets theConditionsobject.- Specified by:
setConditionsin interfaceAuthnRequest- Parameters:
conditions- the newConditionsobject.- Throws:
SAML2Exception- if the object is immutable.- See Also:
getConditions()
-
getRequestedAuthnContext
public RequestedAuthnContext getRequestedAuthnContext()
Returns theRequestedAuthnContextobject.- Specified by:
getRequestedAuthnContextin interfaceAuthnRequest- Returns:
- the
RequestAuthnContextobject. - See Also:
setRequestedAuthnContext(RequestedAuthnContext)
-
setRequestedAuthnContext
public void setRequestedAuthnContext(RequestedAuthnContext reqAuthnContext) throws SAML2Exception
Sets theRequestedAuthnContext.- Specified by:
setRequestedAuthnContextin interfaceAuthnRequest- Parameters:
reqAuthnContext- the newRequestedAuthnContextobject.- Throws:
SAML2Exception- if the object is immutable.- See Also:
getRequestedAuthnContext()
-
setScoping
public void setScoping(Scoping scoping) throws SAML2Exception
Sets theScopingobject.- Specified by:
setScopingin interfaceAuthnRequest- Parameters:
scoping- the newScopingObject.- Throws:
SAML2Exception- if the object is immutable.- See Also:
getScoping()
-
getScoping
public Scoping getScoping()
Returns theScopingobject.- Specified by:
getScopingin interfaceAuthnRequest- Returns:
- the
Scopingobject. - See Also:
setScoping(Scoping)
-
isForceAuthn
public Boolean isForceAuthn()
Returns value ofisForceAuthnattribute.- Specified by:
isForceAuthnin interfaceAuthnRequest- Returns:
- value of
isForceAuthnattribute.
-
setForceAuthn
public void setForceAuthn(Boolean value) throws SAML2Exception
Sets the value of theForceAuthnattribute.- Specified by:
setForceAuthnin interfaceAuthnRequest- Parameters:
value- the value ofForceAuthnattribute.- Throws:
SAML2Exception- if the object is immutable.
-
isPassive
public Boolean isPassive()
Returns the value of theisPassiveattribute.- Specified by:
isPassivein interfaceAuthnRequest- Returns:
- value of
isPassiveattribute.
-
setIsPassive
public void setIsPassive(Boolean value) throws SAML2Exception
Sets the value of theIsPassiveattribute.- Specified by:
setIsPassivein interfaceAuthnRequest- Parameters:
value- Value ofIsPassiveattribute.- Throws:
SAML2Exception- if the object is immutable.
-
setProtocolBinding
public void setProtocolBinding(String protocolBinding) throws SAML2Exception
Sets the value of theProtocolBindingattribute.- Specified by:
setProtocolBindingin interfaceAuthnRequest- Parameters:
protocolBinding- value of theProtocolBindingattribute.- Throws:
SAML2Exception- if the object is immutable.- See Also:
getProtocolBinding()
-
getProtocolBinding
public String getProtocolBinding()
Returns the value of theProtocolBindingattribute.- Specified by:
getProtocolBindingin interfaceAuthnRequest- Returns:
- the value of
ProtocolBindingattribute. - See Also:
setProtocolBinding(String)
-
getAssertionConsumerServiceURL
public String getAssertionConsumerServiceURL()
Returns the value of theAssertionConsumerServiceURLattribute.- Specified by:
getAssertionConsumerServiceURLin interfaceAuthnRequest- Returns:
- the value of
AssertionConsumerServiceURLattribute. - See Also:
setAssertionConsumerServiceURL(String)
-
setAssertionConsumerServiceURL
public void setAssertionConsumerServiceURL(String url) throws SAML2Exception
Sets the value of theAssertionConsumerServiceURLattribute.- Specified by:
setAssertionConsumerServiceURLin interfaceAuthnRequest- Parameters:
url- the value ofAssertionConsumerServiceURLattribute.- Throws:
SAML2Exception- if the object is immutable.- See Also:
getAssertionConsumerServiceURL()
-
getAssertionConsumerServiceIndex
public Integer getAssertionConsumerServiceIndex()
Returns the value of theAssertionConsumerServiceIndexattribute.- Specified by:
getAssertionConsumerServiceIndexin interfaceAuthnRequest- Returns:
- value of the
AssertionConsumerServiceIndexattribute. - See Also:
setAssertionConsumerServiceIndex(Integer)
-
setAssertionConsumerServiceIndex
public void setAssertionConsumerServiceIndex(Integer index) throws SAML2Exception
Sets the value of theAssertionConsumerServiceIndexattribute.- Specified by:
setAssertionConsumerServiceIndexin interfaceAuthnRequest- Parameters:
index- value of theAssertionConsumerServiceIndexattribute.- Throws:
SAML2Exception- if the object is immutable.- See Also:
getAssertionConsumerServiceIndex()
-
getAttributeConsumingServiceIndex
public Integer getAttributeConsumingServiceIndex()
Returns the value of theAttributeConsumingServiceIndexattribute.- Specified by:
getAttributeConsumingServiceIndexin interfaceAuthnRequest- Returns:
- value of the
AttributeConsumingServiceIndexattribute. - See Also:
setAttributeConsumingServiceIndex(Integer)
-
setAttributeConsumingServiceIndex
public void setAttributeConsumingServiceIndex(Integer index) throws SAML2Exception
Sets the value of theAttributeConsumingServiceIndexattribute.- Specified by:
setAttributeConsumingServiceIndexin interfaceAuthnRequest- Parameters:
index- value of theAttributeConsumingServiceIndexattribute.- Throws:
SAML2Exception- if the object is immutable.- See Also:
getAttributeConsumingServiceIndex()
-
setProviderName
public void setProviderName(String providerName) throws SAML2Exception
Sets theProviderNameattribute value.- Specified by:
setProviderNamein interfaceAuthnRequest- Parameters:
providerName- value of theProviderNameattribute.- Throws:
SAML2Exception- if the object is immutable.- See Also:
getProviderName()
-
getProviderName
public String getProviderName()
Returns theProviderNameattribute value.- Specified by:
getProviderNamein interfaceAuthnRequest- Returns:
- value of the
ProviderNameattribute value. - See Also:
setProviderName(String)
-
toXMLString
public String toXMLString() throws SAML2Exception
Returns a String representation of this Object.- Specified by:
toXMLStringin interfaceRequestAbstract- Overrides:
toXMLStringin classRequestAbstractImpl- 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- Specified by:
toXMLStringin interfaceRequestAbstract- Overrides:
toXMLStringin classRequestAbstractImpl- 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.
-
makeImmutable
public void makeImmutable()
Makes this object immutable.- Specified by:
makeImmutablein interfaceRequestAbstract- Overrides:
makeImmutablein classRequestAbstractImpl
-
parseDOMElement
protected void parseDOMElement(Element element) throws SAML2Exception
Parses the Docuemnt Element for this object.- Overrides:
parseDOMElementin classRequestAbstractImpl- Parameters:
element- the Document Element of this object.- Throws:
SAML2Exception- if error parsing the Document Element.
-
-