1
0
-1

 The performance FAQ mentions serializing parsers to save on compile time but I do not see that DataParser or even ProcessorFactory can be serialized.

    CommentAdd your comment...

    1 answer

    1.  
      2
      1
      0

      The Java API classes are not serializable themselves (though, that's something we may be able to add).

      However, the DataProcessor class has a void save(output: java.nio.channels.WritableByteChannel) method, which allows you to serialize the DataProcessor to a WritableByteChannel. To reload a saved DataProcessor, the Compiler class has a static method DataProcessor reload(savedParser: java.ino.channels.ReadableByteChannel) which returns a DataProcessor. There is also a static reload method that accepts a java.io.File for convenience.

      ProcessorFactory's cannot be saved or reloaded. Only DataProcessors.

      A brief example for saving and reloading can be found in the javadoc for the japi package: https://opensource.ncsa.illinois.edu/projects/artifacts/DFDL/1.1.0/documentation/Javadoc/

      1. Sean Blanton

        Thanks, this worked great!

      CommentAdd your comment...