protobuf.impl.flatland.mapdef

Documentation forthcoming

->bytes

(->bytes map-def m)

Return the byte representation of the given protobuf.

combine

A convenience alias for util/combine

create

(create map-def)(create map-def m)(create map-def k v & kvs)

Construct a protobuf of the given map-def.

mapdef

(mapdef map-def)(mapdef map-def opts)

Create a protocol buffer map definition from a string or protobuf class.

mapdef->schema

(mapdef->schema & args)

Return the schema for the given mapdef.

mapdef?

(mapdef? obj)

Is the given object a PersistentProtocolBufferMap$Def?

parse

multimethod

Load a protobuf of the given map-def from a data source.

Supported data sources are either an array of bytes or an input stream.

read

(read map-def in)

Lazily read a sequence of length-delimited protobufs of the specified map-def from the given input stream.

write

(write out & ps)

Write the given protobufs to the given output stream, prefixing each with its length to delimit them.