# yaml_emitter_s Struct Reference
[Emitter Definitions]

The emitter structure. More...

`#include <yaml.h>`

## Data Fields
unsigned char * | buffer
| The buffer pointer.
size_t | size
| The buffer size.
size_t * | size_written
| The number of written bytes.
struct {
unsigned char * buffer
| The buffer pointer.
size_t size
| The buffer size.
size_t * size_written
| The number of written bytes.
} | string
| String output data.
FILE * | file
| File output data.
yaml_char_t * | start
| The beginning of the buffer.
yaml_char_t * | end
| The end of the buffer.
yaml_char_t * | pointer
| The current position of the buffer.
yaml_char_t * | last
| The last filled position of the buffer.
unsigned char * | start
| The beginning of the buffer.
unsigned char * | end
| The end of the buffer.
unsigned char * | pointer
| The current position of the buffer.
unsigned char * | last
| The last filled position of the buffer.
yaml_emitter_state_t * | start
| The beginning of the stack.
yaml_emitter_state_t * | end
| The end of the stack.
yaml_emitter_state_t * | top
| The top of the stack.
yaml_event_t * | start
| The beginning of the event queue.
yaml_event_t * | end
| The end of the event queue.
yaml_event_t * | head
| The head of the event queue.
yaml_event_t * | tail
| The tail of the event queue.
int * | start
| The beginning of the stack.
int * | end
| The end of the stack.
int * | top
| The top of the stack.
yaml_tag_directive_t * | start
| The beginning of the list.
yaml_tag_directive_t * | end
| The end of the list.
yaml_tag_directive_t * | top
| The top of the list.
yaml_char_t * | anchor
| The anchor value.
size_t | anchor_length
| The anchor length.
int | alias
| Is it an alias?
yaml_char_t * | handle
| The tag handle.
size_t | handle_length
| The tag handle length.
yaml_char_t * | suffix
| The tag suffix.
size_t | suffix_length
| The tag suffix length.
yaml_char_t * | value
| The scalar value.
size_t | length
| The scalar length.
int | multiline
| Does the scalar contain line breaks?
int | flow_plain_allowed
| Can the scalar be expessed in the flow plain style?
int | block_plain_allowed
| Can the scalar be expressed in the block plain style?
int | single_quoted_allowed
| Can the scalar be expressed in the single quoted style?
int | block_allowed
| Can the scalar be expressed in the literal or folded styles?
yaml_scalar_style_t | style
| The output style.
int | references
| The number of references.
int | anchor
| The anchor id.
int | serialized
| If the node has been emitted?
Error handling
yaml_error_type_t | error
| Error type.
const char * | problem
| Error description.
Writer stuff
yaml_write_handler_t * | write_handler
| Write handler.
void * | write_handler_data
| A pointer for passing to the white handler.
union {
struct {
unsigned char * buffer
| The buffer pointer.
size_t size
| The buffer size.
size_t * size_written
| The number of written bytes.
} string
| String output data.
FILE * file
| File output data.
} | output
| Standard (string or file) output data.
struct {
yaml_char_t * start
| The beginning of the buffer.
yaml_char_t * end
| The end of the buffer.
yaml_char_t * pointer
| The current position of the buffer.
yaml_char_t * last
| The last filled position of the buffer.
} | buffer
| The working buffer.
struct {
unsigned char * start
| The beginning of the buffer.
unsigned char * end
| The end of the buffer.
unsigned char * pointer
| The current position of the buffer.
unsigned char * last
| The last filled position of the buffer.
} | raw_buffer
| The raw buffer.
yaml_encoding_t | encoding
| The stream encoding.
Emitter stuff
int | canonical
| If the output is in the canonical style?
int | best_indent
| The number of indentation spaces.
int | best_width
| The preferred width of the output lines.
int | unicode
| Allow unescaped non-ASCII characters?
yaml_break_t | line_break
| The preferred line break.
struct {
yaml_emitter_state_t * start
| The beginning of the stack.
yaml_emitter_state_t * end
| The end of the stack.
yaml_emitter_state_t * top
| The top of the stack.
} | states
| The stack of states.
yaml_emitter_state_t | state
| The current emitter state.
struct {
yaml_event_t * start
| The beginning of the event queue.
yaml_event_t * end
| The end of the event queue.
yaml_event_t * head
| The head of the event queue.
yaml_event_t * tail
| The tail of the event queue.
} | events
| The event queue.
struct {
int * start
| The beginning of the stack.
int * end
| The end of the stack.
int * top
| The top of the stack.
} | indents
| The stack of indentation levels.
struct {
yaml_tag_directive_t * start
| The beginning of the list.
yaml_tag_directive_t * end
| The end of the list.
yaml_tag_directive_t * top
| The top of the list.
} | tag_directives
| The list of tag directives.
int | indent
| The current indentation level.
int | flow_level
| The current flow level.
int | root_context
| Is it the document root context?
int | sequence_context
| Is it a sequence context?
int | mapping_context
| Is it a mapping context?
int | simple_key_context
| Is it a simple mapping key context?
int | line
| The current line.
int | column
| The current column.
int | whitespace
| If the last character was a whitespace?
int | indention
| If the last character was an indentation character (' ', '-', '?', ':')?
int | open_ended
| If an explicit document end is required?
struct {
yaml_char_t * anchor
| The anchor value.
size_t anchor_length
| The anchor length.
int alias
| Is it an alias?
} | anchor_data
| Anchor analysis.
struct {
yaml_char_t * handle
| The tag handle.
size_t handle_length
| The tag handle length.
yaml_char_t * suffix
| The tag suffix.
size_t suffix_length
| The tag suffix length.
} | tag_data
| Tag analysis.
struct {
yaml_char_t * value
| The scalar value.
size_t length
| The scalar length.
int multiline
| Does the scalar contain line breaks?
int flow_plain_allowed
| Can the scalar be expessed in the flow plain style?
int block_plain_allowed
| Can the scalar be expressed in the block plain style?
int single_quoted_allowed
| Can the scalar be expressed in the single quoted style?
int block_allowed
| Can the scalar be expressed in the literal or folded styles?
yaml_scalar_style_t style
| The output style.
} | scalar_data
| Scalar analysis.
Dumper stuff
int | opened
| If the stream was already opened?
int | closed
| If the stream was already closed?
struct {
int references
| The number of references.
int anchor
| The anchor id.
int serialized
| If the node has been emitted?
} | anchors
| The information associated with the document nodes.
int | last_anchor_id
| The last assigned anchor id.
yaml_document_t * | document
| The currently emitted document.

## Detailed Description

The emitter structure.

All members are internal. Manage the structure using the `yaml_emitter_` family of functions.

## Field Documentation

yaml_error_type_t yaml_emitter_s::error

Error type.

const char* yaml_emitter_s::problem

Error description.

yaml_write_handler_t* yaml_emitter_s::write_handler

Write handler.

void* yaml_emitter_s::write_handler_data

A pointer for passing to the white handler.

unsigned char* yaml_emitter_s::buffer

The buffer pointer.

size_t yaml_emitter_s::size

The buffer size.

size_t* yaml_emitter_s::size_written

The number of written bytes.

struct { ... } yaml_emitter_s::string

String output data.

FILE* yaml_emitter_s::file

File output data.

union { ... } yaml_emitter_s::output

Standard (string or file) output data.

yaml_char_t* yaml_emitter_s::start

The beginning of the buffer.

yaml_char_t* yaml_emitter_s::end

The end of the buffer.

yaml_char_t* yaml_emitter_s::pointer

The current position of the buffer.

yaml_char_t* yaml_emitter_s::last

The last filled position of the buffer.

struct { ... } yaml_emitter_s::buffer

The working buffer.

unsigned char* yaml_emitter_s::start

The beginning of the buffer.

unsigned char* yaml_emitter_s::end

The end of the buffer.

unsigned char* yaml_emitter_s::pointer

The current position of the buffer.

unsigned char* yaml_emitter_s::last

The last filled position of the buffer.

struct { ... } yaml_emitter_s::raw_buffer

The raw buffer.

yaml_encoding_t yaml_emitter_s::encoding

The stream encoding.

int yaml_emitter_s::best_indent

The number of indentation spaces.

int yaml_emitter_s::best_width

The preferred width of the output lines.

yaml_break_t yaml_emitter_s::line_break

The preferred line break.

yaml_emitter_state_t* yaml_emitter_s::start

The beginning of the stack.

yaml_emitter_state_t* yaml_emitter_s::end

The end of the stack.

yaml_emitter_state_t* yaml_emitter_s::top

The top of the stack.

struct { ... } yaml_emitter_s::states

The stack of states.

yaml_emitter_state_t yaml_emitter_s::state

The current emitter state.

yaml_event_t* yaml_emitter_s::start

The beginning of the event queue.

yaml_event_t* yaml_emitter_s::end

The end of the event queue.

yaml_event_t* yaml_emitter_s::head

The head of the event queue.

yaml_event_t* yaml_emitter_s::tail

The tail of the event queue.

struct { ... } yaml_emitter_s::events

The event queue.

int* yaml_emitter_s::start

The beginning of the stack.

int* yaml_emitter_s::end

The end of the stack.

int* yaml_emitter_s::top

The top of the stack.

struct { ... } yaml_emitter_s::indents

The stack of indentation levels.

yaml_tag_directive_t* yaml_emitter_s::start

The beginning of the list.

yaml_tag_directive_t* yaml_emitter_s::end

The end of the list.

yaml_tag_directive_t* yaml_emitter_s::top

The top of the list.

struct { ... } yaml_emitter_s::tag_directives

The list of tag directives.

int yaml_emitter_s::indent

The current indentation level.

int yaml_emitter_s::flow_level

The current flow level.

int yaml_emitter_s::line

The current line.

int yaml_emitter_s::column

The current column.

yaml_char_t* yaml_emitter_s::anchor

The anchor value.

size_t yaml_emitter_s::anchor_length

The anchor length.

struct { ... } yaml_emitter_s::anchor_data

Anchor analysis.

yaml_char_t* yaml_emitter_s::handle

The tag handle.

size_t yaml_emitter_s::handle_length

The tag handle length.

yaml_char_t* yaml_emitter_s::suffix

The tag suffix.

size_t yaml_emitter_s::suffix_length

The tag suffix length.

struct { ... } yaml_emitter_s::tag_data

Tag analysis.

yaml_char_t* yaml_emitter_s::value

The scalar value.

size_t yaml_emitter_s::length

The scalar length.

yaml_scalar_style_t yaml_emitter_s::style

The output style.

struct { ... } yaml_emitter_s::scalar_data

Scalar analysis.

int yaml_emitter_s::references

The number of references.

int yaml_emitter_s::anchor

The anchor id.

struct { ... } * yaml_emitter_s::anchors

The information associated with the document nodes.

int yaml_emitter_s::last_anchor_id

The last assigned anchor id.

yaml_document_t* yaml_emitter_s::document

The currently emitted document.

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

- yaml.h