haystack.zinc.encode

Haystack zinc encode.

Members

Enums

DictBraces
enum DictBraces

Flag for wrapping zinc dicts in {}

SortedKeys
enum SortedKeys

Flag for sorting columns names and dictionary keys alphabetically

Functions

encode
void encode(const(Marker) , R writer)

Encodes Marker as 'M'. Expects an OutputRange as writer.

encode
void encode(const(Na) , R writer)

Encodes Na as 'NA'. Expects an OutputRange as writer.

encode
void encode(const(Bool) val, R writer)

Encodes Bool as 'T' or 'F'. Expects an OutputRange as writer.

encode
void encode(const(Num) value, R writer)

Encodes Num as 1, -34, 10_000, 5.4e-45, 9.23kg, 74.2°F, 4min, INF, -INF, NaN. Expects an OutputRange as writer.

encode
void encode(const(Str) val, R writer)

Encodes Str as "hello", "foo\nbar\"". Expects an OutputRange as writer.

encode
void encode(const(Coord) val, R writer)

Encodes Coord as C(74.0000, -77.000) Expects an OutputRange as writer.

encode
void encode(const(XStr) val, R writer)

Encodes XStr as Type("value"). Expects an OutputRange as writer.

encode
void encode(const(Uri) val, R writer)

Encodes Uri as /a/b/c. Expects an OutputRange as writer.

encode
void encode(const(Ref) val, R writer)

Encodes Ref as @someRef. Expects an OutputRange as writer.

encode
void encode(const(Date) val, R writer)

Encodes Date as 2016-12-07 (YYYY-MM-DD). Expects an OutputRange as writer.

encode
void encode(const(TimeOfDay) val, R writer)
void encode(const(Time) val, R writer)

Encodes Time as 08:43:44 (hh:mm:ss.FFF). Expects an OutputRange as writer.

encode
void encode(const(DateTime) val, R writer)

Encodes DateTime as 2009-11-09T15:39:00Z. Expects an OutputRange as writer.

encode
void encode(const(SysTime) val, R writer)

Encodes SysTime as 2016-13-07T08:56:00-05:00 New_York. Expects an OutputRange as writer.

encode
void encode(const(Tag) val, R writer, SortedKeys sorted)

Encodes any Tag as zinc. Expects an OutputRange as writer.

encode
void encode(const(List) val, R writer)

Encodes TagList as [1, 2, 3]. Expects an OutputRange as writer.

encode
void encode(const(Dict) dict, R writer, DictBraces useBraces, SortedKeys sorted)

Encodes Dict as {dis:"Building" site area:35000ft²}. Expects an OutputRange as writer.

encode
void encode(const(Grid) grid, R writer, SortedKeys sorted)

Encodes Grid as ver:"3.0" ... . Expects an OutputRange as writer.

encodeGridHeader
void encodeGridHeader(const(Dict) meta, R writer, SortedKeys sorted)
Undocumented in source. Be warned that the author may not have intended to support it.
zinc
void zinc(const(T) t, R writer, SortedKeys sorted)

Encodes any Tag type to Zinc using the OutputRange

zinc
string zinc(const(T) t, SortedKeys sorted)

Encodes any Tag type to a Zinc string

Meta

Authors

Radu Racariu