Interface XMLParseEventHandler<T>

Type Parameters:
T - The type of the target data structure.
Functional Interface:
This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.

@ClassVersion(sourceVersion="$Id: XMLParseEventHandler.java 820 2020-12-29 20:34:22Z tquadrat $") @FunctionalInterface @API(status=EXPERIMENTAL, since="0.0.5") public interface XMLParseEventHandler<T>
The interface for an implementation of a parse event handler to be used with StAX parsing of XML files.

This is a functional interface whose functional method is process(XMLEventReader, XMLEvent, Object, HandlerProvider).
Author:
Thomas Thrien (thomas.thrien@tquadrat.org)
Version:
$Id: XMLParseEventHandler.java 820 2020-12-29 20:34:22Z tquadrat $
Since:
0.0.5
UML Diagram
UML Diagram for "org.tquadrat.foundation.xml.parse.XMLParseEventHandler"

UML Diagram for "org.tquadrat.foundation.xml.parse.XMLParseEventHandler"

UML Diagram for "org.tquadrat.foundation.xml.parse.XMLParseEventHandler"
  • Field Details

  • Method Details

    • process

      T process(XMLEventReader reader, XMLEvent xmlEvent, T target, HandlerProvider handlerProvider) throws XMLStreamException
      Handles the given event.
      Parameters:
      reader - The XML event reader.
      xmlEvent - The current XML event.
      target - The instance that takes the parse result; can be null if the handler will create a new target.
      handlerProvider - A provider for XML parse event handlers that are needed to process child elements.
      Returns:
      The instance that took the parse result; this is either the object that was provided with the target argument, or a new object if target was null.
      Throws:
      XMLStreamException - Something went wrong.