Package space.kscience.dataforge.io
Types
Binary represents a fixed-size multi-read byte block, which is not attached to the Input which was used to create it. The binary could be associated with a resource, but it should guarantee that when someone is trying to read the binary, this resource is re-acquired.
A Json format for Meta representation
A format for meta serialization
A partially read envelope with meta, but without data
An envelope, which wraps existing envelope and adds one or several additional layers of meta
A streaming-friendly envelope format with a short binary tag. TODO add description
A text envelope format with human-readable tag. TODO add description
Functions
Represent envelope part by an envelope
Return inferred EnvelopeFormat if only one format could read given file. If no format accepts file, return null. If multiple formats accepts file, throw an error.
Read and envelope from file if the file exists, return null if file does not exist.
Read file containing meta using given formatOverride or file extension to infer meta type. If path is a directory search for file starting with meta
in it
Produce a buildByteArray representing an exact copy of this Binary
Add few meta layers to existing envelope (on top of existing meta)
Direct write of binary to the output. Returns the number of bytes written
Write separate meta and data files to given directory path
Write envelope file to given path using envelopeFormat and optional metaFormat
Write meta to file using metaFormat. If path is a directory, write a file with name equals name of metaFormat. Like "meta.json"