Octets builders, i.e., anything that implements the
trait, represent a buffer to which octets can be appended.
Whether the buffer can grow to accommodate appended data depends on the
OctetsBuilder trait only provides methods to append data to the
builder. Implementations may, however, provide more functionality. They
do so by implementing additional traits. Conversely, if additional
functionality is needed from a builder, this can be expressed by
adding trait bounds.
Some examples are:
- An attempt was made to write beyond the end of a buffer.
- An octets builder that can be newly created empty.
- An octets builder that can be frozen into a imutable octets sequence.
- An octets type that can be created from an octets builder.
- An octets type that can be converted into an octets builder.
- A buffer to construct an octet sequence.
- An octet sequence that can be shortened.
- Erases an error for infallible results.
- Erases an error for a closure returninb an infallible results.