Protonizable

Description

abstract class Tinman.Core.IO.Serialization.Protonizable

Derived from

IProtonizable

Abstract base class for IProtonizable implementations.

The implementation of IProtonizable.ProtoDeserialize uses a standard loop to consume the record stream, in order to populate the date fields:

  1. Call IProtonizer.ReadRecord.

  2. If Record.IsNone is true, return.

  3. Call ProtoDeserializeField.

  4. If false is returned, call Record.Skip.

  5. Go to 1.

The default implementation of IProtonizable.ProtoSerialize throws a IOException.CannotWrite exception.

Protected / Methods

Clear

2 overloads


protected static method Clear1 → (1)<T>

list in : IBag<T>

The collection to clear or null.

Clears the given collection, if it is not null.

See also

IBag.Clear


protected static method Clear2 → (1)

value in : IProtonizable

The value to clear or null.

Clears the given value, if it is not null.

Proto​Deserialize​Field


protected abstract method ProtoDeserializeField → (2)

wire in : IProtonizer

The wire format stream.

record in : Record

The record.

returns → bool

true if the record payload has been read,
false if not.

Deserializes the given record.

IOException

If an I/O error has occurred.