The kind of the serialized form that determines the shape of the serialized data. Formats use serial kind to add and parse serializer-agnostic metadata to the result.

For example, JSON format wraps classes and StructureKind.MAP into brackets, while ProtoBuf just serialize these types in separate ways.

Kind should be consistent with the implementation, for example, if it is a primitive, then its elements count should be zero and vice versa.