uLib
Data Fields
AZ_USTREAM_TAG Struct Reference

Structure for instance control block. More...

#include <ustream_base.h>

Data Fields

AZ_USTREAM_DATA_CBcontrol_block
 
offset_t offset_diff
 
offset_t inner_current_position
 
offset_t inner_first_valid_position
 
size_t length
 

Detailed Description

Structure for instance control block.

For any given ustream that is created, there may be mutliple AZ_USTREAM's pointing to the same AZ_USTREAM_DATA_CB. Each instance control block serves to manage a given developer's usage of the memory pointed to inside the AZ_USTREAM_DATA_CB. Each time an AZ_USTREAM is cloned using az_ustream_clone(), the ref_count inside the AZ_USTREAM_DATA_CB is incremented to signal a reference to the memory has been acquired. Once the instance is done being used, az_ustream_release() must be called to decrement ref_count.

Note
This structure should be viewed and used as internal to the implementation of the ustream. Users should therefore not act on it directly and only allocate the memory necessary for it to be passed to the ustream.

Definition at line 422 of file ustream_base.h.

Field Documentation

◆ control_block

AZ_USTREAM_DATA_CB* AZ_USTREAM_TAG::control_block

The AZ_USTREAM_DATA_CB* on which this instance operates on.

Definition at line 425 of file ustream_base.h.

◆ inner_current_position

offset_t AZ_USTREAM_TAG::inner_current_position

The offset_t used to keep track of the current position (next returned position).

Definition at line 429 of file ustream_base.h.

◆ inner_first_valid_position

offset_t AZ_USTREAM_TAG::inner_first_valid_position

The offset_t used to keep track of the earliest position to reset.

Definition at line 430 of file ustream_base.h.

◆ length

size_t AZ_USTREAM_TAG::length

The size_t with the length of the data in the control_block

Definition at line 431 of file ustream_base.h.

◆ offset_diff

offset_t AZ_USTREAM_TAG::offset_diff

The offset_t used as the logical position for this instance.

Definition at line 428 of file ustream_base.h.


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