Class AssertionImpl

All Implemented Interfaces:
XMLObject, SAMLObject, SignableSAMLObject, Assertion, Evidentiary, SignableXMLObject

public class AssertionImpl extends AbstractSignableSAMLObject implements Assertion
This class implements the SAML 1 Assertion statement.
  • Field Details

    • id

      @Nullable private String id
      The AssertionID attrribute.
    • version

      @Nullable private SAMLVersion version
      SAML version of this assertion.
    • issuer

      @Nullable private String issuer
      Object version of the Issuer attribute.
    • issueInstant

      @Nullable private Instant issueInstant
      Object version of the IssueInstant attribute.
    • conditions

      @Nullable private Conditions conditions
      (Possibly null) Singleton object version of the Conditions element.
    • advice

      @Nullable private Advice advice
      (Possibly null) Singleton object version of the Advice element.
    • statements

      @Nonnull private final IndexedXMLObjectChildrenList<Statement> statements
      Object representation of all the Statement elements.
  • Constructor Details

    • AssertionImpl

      protected AssertionImpl(@Nullable String namespaceURI, @Nonnull String elementLocalName, @Nullable String namespacePrefix)
      Constructor.
      Parameters:
      namespaceURI - the namespace the element is in
      elementLocalName - the local name of the XML element this Object represents
      namespacePrefix - the prefix for the given namespace
  • Method Details

    • getMajorVersion

      @Nullable public Integer getMajorVersion()
      Get the MajorVersion attribute.

      Deprecated, use Assertion.getVersion().

      Specified by:
      getMajorVersion in interface Assertion
      Returns:
      the stored MajorVersion
    • getMinorVersion

      @Nullable public Integer getMinorVersion()
      Get the MinorVersion attribute.

      Deprecated, use Assertion.getVersion().

      Specified by:
      getMinorVersion in interface Assertion
      Returns:
      the stored MinorVersion
    • getVersion

      @Nullable public SAMLVersion getVersion()
      Gets the SAML version for this message.
      Specified by:
      getVersion in interface Assertion
      Returns:
      SAML version for this message
    • setVersion

      public void setVersion(@Nullable SAMLVersion newVersion)
      Set the SAML version of this assertion.
      Specified by:
      setVersion in interface Assertion
      Parameters:
      newVersion - the SAML version of this assertion
    • getID

      @Nullable public String getID()
      Set the ID.
      Specified by:
      getID in interface Assertion
      Returns:
      the ID
    • setID

      public void setID(@Nullable String newID)
      Get the ID.
      Specified by:
      setID in interface Assertion
      Parameters:
      newID - what to set
    • getIssuer

      @Nullable public String getIssuer()
      Get the Issuer (which is an attribute) .
      Specified by:
      getIssuer in interface Assertion
      Returns:
      the Issuer
    • setIssuer

      public void setIssuer(@Nullable String iss)
      Set the Issuer (attribute).
      Specified by:
      setIssuer in interface Assertion
      Parameters:
      iss - the value to set
    • getIssueInstant

      @Nullable public Instant getIssueInstant()
      Get the IssueInstant (attribute).
      Specified by:
      getIssueInstant in interface Assertion
      Returns:
      the Issue Instant (as a Date)
    • setIssueInstant

      public void setIssueInstant(@Nullable Instant instant)
      Set the IssueInstance (attribute).
      Specified by:
      setIssueInstant in interface Assertion
      Parameters:
      instant - the issue instant value to set
    • getConditions

      @Nullable public Conditions getConditions()
      Return the (singleton) Object, representing the Conditions sub element.
      Specified by:
      getConditions in interface Assertion
      Returns:
      the Conditions object.
    • setConditions

      public void setConditions(@Nullable Conditions c)
      Set the Object representing the Conditions Sub element.
      Specified by:
      setConditions in interface Assertion
      Parameters:
      c - the condition to List
    • getAdvice

      @Nullable public Advice getAdvice()
      advice is a (singleton) Object, representing the Advice sub element.
      Specified by:
      getAdvice in interface Assertion
      Returns:
      the advice object in this assertion
    • setAdvice

      public void setAdvice(@Nullable Advice adv)
      Set the Object representing the Advice sub element.
      Specified by:
      setAdvice in interface Assertion
      Parameters:
      adv - the object to set
    • getStatements

      @Nonnull @Live public List<Statement> getStatements()
      Return the List representing all the Statement sub elements.
      Specified by:
      getStatements in interface Assertion
      Returns:
      the List representing all the statements
    • getStatements

      @Nonnull @Live public List<Statement> getStatements(@Nonnull QName typeOrName)
      Return the List representing all the Statement sub elements with a given schema type or element name.
      Specified by:
      getStatements in interface Assertion
      Parameters:
      typeOrName - the schema type or element name
      Returns:
      the List representing all the statements
    • getSubjectStatements

      @Nonnull @Live public List<SubjectStatement> getSubjectStatements()
      Return the List representing all the SubjectStatement sub elements.
      Specified by:
      getSubjectStatements in interface Assertion
      Returns:
      all the SubjectStatements
    • getAuthenticationStatements

      @Nonnull @Live public List<AuthenticationStatement> getAuthenticationStatements()
      Return the List representing all the AuthenticationStatement sub elements.
      Specified by:
      getAuthenticationStatements in interface Assertion
      Returns:
      all the AuthenticationStatements
    • getAttributeStatements

      @Nonnull @Live public List<AttributeStatement> getAttributeStatements()
      Return all the AttributeStatement elements.
      Specified by:
      getAttributeStatements in interface Assertion
      Returns:
      all the attributeStatements
    • getAuthorizationDecisionStatements

      @Nonnull @Live public List<AuthorizationDecisionStatement> getAuthorizationDecisionStatements()
      Return the List representing all the AuthorizationStatement sub elements.
      Specified by:
      getAuthorizationDecisionStatements in interface Assertion
      Returns:
      all the authorizationDecisionStatements.
    • getSignatureReferenceID

      @Nullable public String getSignatureReferenceID()
      Gets the value of the ID attribute for this SAML object which will be used as its signature reference.
      Specified by:
      getSignatureReferenceID in interface SignableSAMLObject
      Returns:
      the value of this SAMLObject ID attribute
    • getOrderedChildren

      @Nullable @NotLive @Unmodifiable public List<XMLObject> getOrderedChildren()
      Gets an unmodifiable list of child elements in the order that they will appear in the DOM.
      Specified by:
      getOrderedChildren in interface XMLObject
      Returns:
      ordered list of child elements