Std.Bytes.Cursor
15 public declarations
- Cursor
A byte position within the original immutable input.
- CursorError
Invalid cursor state, invalid request, or insufficient remaining input.
- peek
&Std.Bytes.Cursor.Cursor -> Result[Option[UInt8], Std.Bytes.Cursor.CursorError]Observe the next byte without consuming it; EOF is `None`.
- remaining
&Std.Bytes.Cursor.Cursor -> Result[Int, Std.Bytes.Cursor.CursorError]Validate the cursor before subtracting its position from the input length.
- seek
&Std.Bytes.Cursor.Cursor -> Int -> Result[Std.Bytes.Cursor.Cursor, Std.Bytes.Cursor.CursorError]Move to an absolute byte position, including the end of input.
- skip
&Std.Bytes.Cursor.Cursor -> Int -> Result[Std.Bytes.Cursor.Cursor, Std.Bytes.Cursor.CursorError]Skip bytes using the same bounds contract as a read.
- start
&Bytes -> Std.Bytes.Cursor.CursorBegin reading without copying the input.
- take
&Std.Bytes.Cursor.Cursor -> Int -> Result[(Bytes, Std.Bytes.Cursor.Cursor), Std.Bytes.Cursor.CursorError]Read a shared view. A failed read leaves the original cursor usable.
- u16Be
&Std.Bytes.Cursor.Cursor -> Result[(UInt16, Std.Bytes.Cursor.Cursor), Std.Bytes.Cursor.CursorError]Read an unsigned integer in the byte order named by the function.
- u16Le
&Std.Bytes.Cursor.Cursor -> Result[(UInt16, Std.Bytes.Cursor.Cursor), Std.Bytes.Cursor.CursorError]The next two bytes as an unsigned number, least significant first.
- u32Be
&Std.Bytes.Cursor.Cursor -> Result[(UInt32, Std.Bytes.Cursor.Cursor), Std.Bytes.Cursor.CursorError]The next four bytes as an unsigned number, most significant first.
- u32Le
&Std.Bytes.Cursor.Cursor -> Result[(UInt32, Std.Bytes.Cursor.Cursor), Std.Bytes.Cursor.CursorError]The next four bytes as an unsigned number, least significant first.
- u64Be
&Std.Bytes.Cursor.Cursor -> Result[(UInt64, Std.Bytes.Cursor.Cursor), Std.Bytes.Cursor.CursorError]The next eight bytes as an unsigned number, most significant first.
- u64Le
&Std.Bytes.Cursor.Cursor -> Result[(UInt64, Std.Bytes.Cursor.Cursor), Std.Bytes.Cursor.CursorError]The next eight bytes as an unsigned number, least significant first.
- u8
&Std.Bytes.Cursor.Cursor -> Result[(UInt8, Std.Bytes.Cursor.Cursor), Std.Bytes.Cursor.CursorError]Read one octet without converting it through text.
