Safe Haskell | Safe-Infered |
---|
Serialize
functions for Vector
vectors. Orphan instances are provided for Vector
and
Primitive
vectors.
Instances are not provided for Unbox
vectors, as
they must be declared on an individual basis for each type the
vectors may contain. The genericGet
and genericPut
functions
should still work for these vectors without declaring instances.
The serialized format is an Int64
representing the
length of the Vector
, followed by the serialized contents of each
element.
Note that the instances specialized for Storable
are
much more performant for storable vectors.
- genericGetVector :: (Serialize a, Vector v a) => Get (v a)
- genericPutVector :: (Serialize a, Vector v a) => Putter (v a)