solidc
Robust collection of general-purpose cross-platform C libraries and data structures designed for rapid and safe development in C
Loading...
Searching...
No Matches
Public Attributes | List of all members
string_stream Struct Reference

String stream internal state structure. More...

#include <stdstreams.h>

Public Attributes

char * data
 
size_t size
 
size_t capacity
 
size_t pos
 

Detailed Description

String stream internal state structure.

Exposed only to allow callers to embed it or calculate offsets. Memory is highly optimized via unified contiguous allocation internally. Always treat every field as strictly private — use the public API instead.

Definition at line 91 of file stdstreams.h.

Member Data Documentation

◆ capacity

size_t string_stream::capacity

Allocated physical capacity (including space for NUL)

Definition at line 94 of file stdstreams.h.

Referenced by create_string_stream().

◆ data

char* string_stream::data

Dynamically allocated buffer, always NUL-terminated

Definition at line 92 of file stdstreams.h.

Referenced by create_string_stream(), read_until(), string_stream_copy_fast(), string_stream_write(), and string_stream_write_len().

◆ pos

size_t string_stream::pos

Current read/write seek cursor position

Definition at line 95 of file stdstreams.h.

Referenced by create_string_stream(), read_until(), and string_stream_copy_fast().

◆ size

size_t string_stream::size

Current string length in bytes (excluding NUL)

Definition at line 93 of file stdstreams.h.

Referenced by create_string_stream(), read_until(), string_stream_copy_fast(), string_stream_write(), and string_stream_write_len().


The documentation for this struct was generated from the following file: