Package nbbrd.io.xml

Class Sax.Parser<T>

java.lang.Object
nbbrd.io.xml.Sax.Parser<T>
All Implemented Interfaces:
nbbrd.io.FileParser<T>, nbbrd.io.text.TextParser<T>, Xml.Parser<T>
Enclosing class:
Sax

public static final class Sax.Parser<T> extends Object implements Xml.Parser<T>
  • Constructor Details

    • Parser

      public Parser()
  • Method Details

    • of

      @NonNull public static <T> @NonNull Sax.Parser<T> of(@NonNull @NonNull ContentHandler handler, nbbrd.io.function.IOSupplier<? extends T> after)
    • parseFile

      @NonNull public T parseFile(@NonNull @NonNull File source) throws IOException
      Specified by:
      parseFile in interface nbbrd.io.FileParser<T>
      Specified by:
      parseFile in interface Xml.Parser<T>
      Throws:
      IOException
    • parseFile

      @NonNull public T parseFile(@NonNull @NonNull File source, @NonNull @NonNull Charset encoding) throws IOException
      Specified by:
      parseFile in interface nbbrd.io.text.TextParser<T>
      Specified by:
      parseFile in interface Xml.Parser<T>
      Throws:
      IOException
    • parseReader

      @NonNull public T parseReader(@NonNull @NonNull Reader resource) throws IOException
      Specified by:
      parseReader in interface nbbrd.io.text.TextParser<T>
      Throws:
      IOException
    • parseStream

      @NonNull public T parseStream(@NonNull @NonNull InputStream resource) throws IOException
      Specified by:
      parseStream in interface nbbrd.io.FileParser<T>
      Throws:
      IOException
    • parseStream

      @NonNull public T parseStream(@NonNull @NonNull InputStream resource, @NonNull @NonNull Charset encoding) throws IOException
      Specified by:
      parseStream in interface nbbrd.io.text.TextParser<T>
      Throws:
      IOException