Function readVarint64
Decode one unsigned 64-bit protobuf varint.
bool readVarint64(
scope ref WireCursor cursor,
out ulong value,
out WireStatus status
) nothrow @nogc @safe;
Parameters
| Name | Description |
|---|---|
| cursor | Cursor positioned at the first byte of the varint. |
| value | Receives the decoded value on success. |
| status | Receives success or a precise wire-decoding failure. |
Returns
true on success; false for truncated or overflowing encodings.
Notes
Legal non-minimal protobuf encodings are accepted. On failure value is
reset to zero, while the cursor remains advanced to the point at which the
failure was detected.