Raxol.Terminal.OutputManager (Raxol v0.5.0)
View SourceManages terminal output buffering, control sequences, and formatting. Provides functionality for:
- Output buffering with size limits
- Control sequence handling
- Output formatting and styling
- Performance metrics tracking
- Batch processing
Summary
Functions
Adds a custom formatting rule to the manager.
Clears the control sequence buffer.
Clears the output buffer.
Enqueues a control sequence to the buffer. Returns {:ok, updated_manager} or {:error, :buffer_overflow}
Enqueues output to the buffer. Returns {:ok, updated_manager} or {:error, :buffer_overflow}
Flushes the control sequence buffer and returns its contents. Returns {sequences, updated_manager}
Flushes the output buffer and returns its contents. Returns {output, updated_manager}
Gets the current control sequence buffer contents.
Gets the current metrics.
Gets the current output buffer contents.
Creates a new OutputManager with default settings.
Types
@type t() :: %Raxol.Terminal.OutputManager{ batch_size: integer(), control_sequence_buffer: String.t(), format_rules: [function()], max_buffer_size: integer(), metrics: %{ processed_bytes: integer(), control_sequences: integer(), format_applications: integer(), style_applications: integer(), buffer_overflows: integer() }, output_buffer: String.t(), style_map: %{required(String.t()) => map()} }
Functions
Adds a custom formatting rule to the manager.
Clears the control sequence buffer.
Clears the output buffer.
Enqueues a control sequence to the buffer. Returns {:ok, updated_manager} or {:error, :buffer_overflow}
Enqueues output to the buffer. Returns {:ok, updated_manager} or {:error, :buffer_overflow}
Flushes the control sequence buffer and returns its contents. Returns {sequences, updated_manager}
Flushes the output buffer and returns its contents. Returns {output, updated_manager}
Gets the current control sequence buffer contents.
Gets the current metrics.
Gets the current output buffer contents.
Creates a new OutputManager with default settings.