Luce packages
LuceLuce BaseLuciaOS

dymokomi/luce-ply

Source of release 0.1.0

0.1.0 / src / kernel.lucb

## The luce_ply.kernel export: PLY for Base callers and tests, over bytes and
## raw sets. Luce code uses `ply` instead.
import header
import reader
import writer
import warnings
import source
import errors

## The parsed header of a PLY file.
pub type Header = header.Header
## How a PLY body is stored: ascii, binary little-endian or big-endian.
pub type Format = header.Format
## Parse the header at the start of a file's bytes.
pub let parse_header = header.parse_header
## What a read or write left out, line by line.
pub type Warnings = warnings.Warnings
## A file's bytes as a GeometrySet (the caller disposes of it).
pub let decode = reader.decode
## A GeometrySet as a file's bytes on memory.heap (the caller frees them).
pub let encode = writer.encode
## A file's bytes, mapped.
pub let read_file = source.read
## Replace a file with bytes atomically.
pub let write_file = source.write
## The bytes are not PLY, or are malformed or truncated.
pub let invalid: ErrorCode = errors.invalid