org.keycloak.saml.processing.core.parsers.saml.metadata

## Class SAMLAuthnAuthorityDescriptorParser

- java.lang.Object
- - org.keycloak.saml.common.parsers.AbstractStaxParser<T,SAMLMetadataQNames>
  - - org.keycloak.saml.processing.core.parsers.saml.metadata.AbstractStaxSamlMetadataParser<T>
    - - org.keycloak.saml.processing.core.parsers.saml.metadata.SAMLRoleDecriptorTypeParser<AuthnAuthorityDescriptorType>
      - - org.keycloak.saml.processing.core.parsers.saml.metadata.SAMLAuthnAuthorityDescriptorParser

- All Implemented Interfaces:
    StaxParser

      public class SAMLAuthnAuthorityDescriptorParser
      extends SAMLRoleDecriptorTypeParser<AuthnAuthorityDescriptorType>

  Author:
    mhajas

- - ### Field Summary

    - ### Fields inherited from class org.keycloak.saml.processing.core.parsers.saml.metadata.AbstractStaxSamlMetadataParser

      `LOOKUP`

    - ### Fields inherited from class org.keycloak.saml.common.parsers.AbstractStaxParser

      `expectedStartElement, LOGGER`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `SAMLAuthnAuthorityDescriptorParser()`

  - ### Method Summary

    All Methods Static Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `static SAMLAuthnAuthorityDescriptorParser` | `getInstance()`
    `protected AuthnAuthorityDescriptorType` | `instantiateElement(XMLEventReader xmlEventReader, StartElement element)` Instantiates the target Java class representing the current element. Precondition: Current event is the `StartElement` Postcondition: Current event is the `StartElement` or the `EndElement` corresponding to the `StartElement`
    `protected void` | `processSubElement(XMLEventReader xmlEventReader, AuthnAuthorityDescriptorType target, SAMLMetadataQNames element, StartElement elementDetail)` Processes the subelement of the element processed in `AbstractStaxParser.instantiateElement(javax.xml.stream.XMLEventReader, javax.xml.stream.events.StartElement)` method. Precondition: Current event: Last before the `StartElement` corresponding to the processed subelement, i.e.

    - ### Methods inherited from class org.keycloak.saml.processing.core.parsers.saml.metadata.SAMLRoleDecriptorTypeParser

      `parseOptionalArguments`

    - ### Methods inherited from class org.keycloak.saml.processing.core.parsers.saml.metadata.AbstractStaxSamlMetadataParser

      `getElementFromName`

    - ### Methods inherited from class org.keycloak.saml.common.parsers.AbstractStaxParser

      `isUnknownElement, parse, validateStartElement`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### SAMLAuthnAuthorityDescriptorParser

          public SAMLAuthnAuthorityDescriptorParser()

  - ### Method Detail

    - #### getInstance

          public static SAMLAuthnAuthorityDescriptorParser getInstance()

    - #### instantiateElement

          protected AuthnAuthorityDescriptorType instantiateElement(XMLEventReader xmlEventReader,
                                                                    StartElement element)
                                                             throws ParsingException

      Description copied from class: `AbstractStaxParser`
      Instantiates the target Java class representing the current element.
      Precondition: Current event is the `StartElement`
      Postcondition: Current event is the `StartElement` or the `EndElement` corresponding to the `StartElement`
      Specified by:
        `instantiateElement` in class `AbstractStaxParser<AuthnAuthorityDescriptorType,SAMLMetadataQNames>`
        `element` - The XML event that was just read from the `xmlEventReader`
      Returns:
      Throws:
        `ParsingException`

    - #### processSubElement

          protected void processSubElement(XMLEventReader xmlEventReader,
                                           AuthnAuthorityDescriptorType target,
                                           SAMLMetadataQNames element,
                                           StartElement elementDetail)
                                    throws ParsingException

      Description copied from class: `AbstractStaxParser`
      Processes the subelement of the element processed in `AbstractStaxParser.instantiateElement(javax.xml.stream.XMLEventReader, javax.xml.stream.events.StartElement)` method.
      Precondition: Current event: Last before the `StartElement` corresponding to the processed subelement, i.e. event obtained by `Iterator.next()` is the `StartElement` of the subelement being processed
      Postcondition: Event obtained by `Iterator.next()` is either the same `StartElement` (i.e. no change in position which causes this subelement to be skipped), the corresponding `EndElement`, or the event after the corresponding `EndElement`.

      Note that in case of recursive nesting the same element, the corresponding end element MUST be consumed in this method.

      Overrides:
        `processSubElement` in class `SAMLRoleDecriptorTypeParser<AuthnAuthorityDescriptorType>`
        `target` - Target object (the one created by the `AbstractStaxParser.instantiateElement(javax.xml.stream.XMLEventReader, javax.xml.stream.events.StartElement)` method.
        `element` - The constant corresponding to the current start element.
        `elementDetail` - The XML event that was just read from the `xmlEventReader`
      Throws:
        `ParsingException`

Copyright © 2020 JBoss by Red Hat. All rights reserved.