Skip to main content
Log in

Mojo trait

MovableWriter

Allows moving a Writer into a buffer.

Implemented traits

AnyType, Movable, UnknownDestructibility, Writer

Methods

__moveinit__

__moveinit__(out self: _Self, owned existing: _Self, /)

Create a new instance of the value by moving the value of another.

Args:

  • existing (_Self): The value to move.

write_bytes

write_bytes(mut self: _Self, bytes: Span[SIMD[uint8, 1], origin])

Write a Span[Byte] to this Writer.

Args:

  • bytes (Span[SIMD[uint8, 1], origin]): The string slice to write to this Writer. Must NOT be null-terminated.

write

write[*Ts: Writable](mut self: _Self, *args: *Ts)

Write a sequence of Writable arguments to the provided Writer.

Parameters:

  • *Ts (Writable): Types of the provided argument sequence.

Args:

  • *args (*Ts): Sequence of arguments to write to this Writer.