OptionalpeekOptional read without advancing; defaults to read followed by seek.
Read into owned scratch storage and advance the cursor.
outputScratch bytes; never detach or resize its buffer.
countMaximum number of bytes to read.
Integer in [0, count].
OptionalpopOptional tail removal; defaults to truncate().
Reduce the length and return the number of removed bytes.
lengthRequested byte length.
Nonnegative safe integer count of removed bytes.
OptionalpopOptional front removal; absence throws.
Reduce the length and return the number of removed bytes.
lengthRequested byte length.
Nonnegative safe integer count of removed bytes.
OptionalpushOptional append; defaults to seek, write and cursor restoration.
Write the supplied independent byte snapshot.
inputOwned snapshot; changes cannot affect the caller.
countMaximum number of bytes to write.
Integer in [0, count].
OptionalpushOptional prepend operation; absence throws.
Write the supplied independent byte snapshot.
inputOwned snapshot; changes cannot affect the caller.
countMaximum number of bytes to write.
Integer in [0, count].
OptionalcloseOptional explicit close callback; never invoked by GC or shutdown.
OptionalisEOSOptional EOF test; defaults to tell() greater than or equal to length().
End-of-stream state.
Return whether bytes are ready for reading.
Reading readiness.
Return whether bytes can be written now.
Writing readiness.
Return the total byte length as a nonnegative safe integer.
Total byte length.
Read into owned scratch storage and advance the cursor.
outputScratch bytes; never detach or resize its buffer.
countMaximum number of bytes to read.
Integer in [0, count].
Implement native seek; choose the callback's end-offset convention.
offsetSigned byte offset.
originNative seek origin.
Whether the cursor moved successfully.
Return the current byte position as a nonnegative safe integer.
Current byte position.
Reduce the length and return the number of removed bytes.
lengthRequested byte length.
Nonnegative safe integer count of removed bytes.
Write the supplied independent byte snapshot.
inputOwned snapshot; changes cannot affect the caller.
countMaximum number of bytes to write.
Integer in [0, count].
Synchronous implementations of Rml::Stream virtual methods.
Remarks
Methods are captured once. Read and peek receive owned scratch arrays; writes receive snapshots. Return exact counts or booleans, never Promises. Native API reentry is rejected. Callback cycles remain visible to the GC.