com.io7m.smfj.parser.api

## Interface SMFParserEventsType

- All Superinterfaces:
    SMFParserEventsErrorType
  All Known Subinterfaces:
    SMFByteBufferPackedMeshLoaderType, SMFFCopierType, SMFMemoryMeshProducerType
  All Known Implementing Classes:
    SMFByteBufferPackedMeshes, SMFFCopier, SMFMemoryMeshProducer

      public interface SMFParserEventsType
      extends SMFParserEventsErrorType

  A receiver of parse events.

- - ### Method Summary

    All Methods Instance Methods Abstract Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `onFinish()` Parsing has finished.
    `void` | `onStart()` Parsing has started.
    `Optional<SMFParserEventsHeaderType>` | `onVersionReceived(SMFFormatVersion version)` The file format version has been successfully parsed.

    - ### Methods inherited from interface com.io7m.smfj.parser.api.SMFParserEventsErrorType

      `onError, onWarning`

- - ### Method Detail

    - #### onStart

          void onStart()

      Parsing has started.

    - #### onVersionReceived

          Optional<SMFParserEventsHeaderType> onVersionReceived(SMFFormatVersion version)

      The file format version has been successfully parsed. The functions should return a receiver for the header information if parsing should continue, or `Optional.empty()` if parsing should stop.
      Parameters:
        `version` - The file format version
      Returns:
        A receiver for the header, if any

    - #### onFinish

          void onFinish()

      Parsing has finished. This method will be called unconditionally when the parser is closed, regardless of any errors encountered.

Copyright © 2017 <code@io7m.com> http://io7m.com