Ruby
2.1.10p492(2016-04-01revision54464)
|
The emitter structure. More...
#include <yaml.h>
Data Fields | |
unsigned char * | buffer |
The buffer pointer. More... | |
size_t | size |
The buffer size. More... | |
size_t * | size_written |
The number of written bytes. More... | |
struct { | |
unsigned char * buffer | |
The buffer pointer. More... | |
size_t size | |
The buffer size. More... | |
size_t * size_written | |
The number of written bytes. More... | |
} | string |
String output data. More... | |
FILE * | file |
File output data. More... | |
yaml_char_t * | start |
The beginning of the buffer. More... | |
yaml_char_t * | end |
The end of the buffer. More... | |
yaml_char_t * | pointer |
The current position of the buffer. More... | |
yaml_char_t * | last |
The last filled position of the buffer. More... | |
unsigned char * | start |
The beginning of the buffer. More... | |
unsigned char * | end |
The end of the buffer. More... | |
unsigned char * | pointer |
The current position of the buffer. More... | |
unsigned char * | last |
The last filled position of the buffer. More... | |
yaml_emitter_state_t * | start |
The beginning of the stack. More... | |
yaml_emitter_state_t * | end |
The end of the stack. More... | |
yaml_emitter_state_t * | top |
The top of the stack. More... | |
yaml_event_t * | start |
The beginning of the event queue. More... | |
yaml_event_t * | end |
The end of the event queue. More... | |
yaml_event_t * | head |
The head of the event queue. More... | |
yaml_event_t * | tail |
The tail of the event queue. More... | |
int * | start |
The beginning of the stack. More... | |
int * | end |
The end of the stack. More... | |
int * | top |
The top of the stack. More... | |
yaml_tag_directive_t * | start |
The beginning of the list. More... | |
yaml_tag_directive_t * | end |
The end of the list. More... | |
yaml_tag_directive_t * | top |
The top of the list. More... | |
yaml_char_t * | anchor |
The anchor value. More... | |
size_t | anchor_length |
The anchor length. More... | |
int | alias |
Is it an alias? More... | |
yaml_char_t * | handle |
The tag handle. More... | |
size_t | handle_length |
The tag handle length. More... | |
yaml_char_t * | suffix |
The tag suffix. More... | |
size_t | suffix_length |
The tag suffix length. More... | |
yaml_char_t * | value |
The scalar value. More... | |
size_t | length |
The scalar length. More... | |
int | multiline |
Does the scalar contain line breaks? More... | |
int | flow_plain_allowed |
Can the scalar be expessed in the flow plain style? More... | |
int | block_plain_allowed |
Can the scalar be expressed in the block plain style? More... | |
int | single_quoted_allowed |
Can the scalar be expressed in the single quoted style? More... | |
int | block_allowed |
Can the scalar be expressed in the literal or folded styles? More... | |
yaml_scalar_style_t | style |
The output style. More... | |
int | references |
The number of references. More... | |
int | anchor |
The anchor id. More... | |
int | serialized |
If the node has been emitted? More... | |
Error handling | |
yaml_error_type_t | error |
Error type. More... | |
const char * | problem |
Error description. More... | |
Writer stuff | |
yaml_write_handler_t * | write_handler |
Write handler. More... | |
void * | write_handler_data |
A pointer for passing to the white handler. More... | |
union { | |
struct { | |
unsigned char * buffer | |
The buffer pointer. More... | |
size_t size | |
The buffer size. More... | |
size_t * size_written | |
The number of written bytes. More... | |
} string | |
String output data. More... | |
FILE * file | |
File output data. More... | |
} | output |
Standard (string or file) output data. More... | |
struct { | |
yaml_char_t * start | |
The beginning of the buffer. More... | |
yaml_char_t * end | |
The end of the buffer. More... | |
yaml_char_t * pointer | |
The current position of the buffer. More... | |
yaml_char_t * last | |
The last filled position of the buffer. More... | |
} | buffer |
The working buffer. More... | |
struct { | |
unsigned char * start | |
The beginning of the buffer. More... | |
unsigned char * end | |
The end of the buffer. More... | |
unsigned char * pointer | |
The current position of the buffer. More... | |
unsigned char * last | |
The last filled position of the buffer. More... | |
} | raw_buffer |
The raw buffer. More... | |
yaml_encoding_t | encoding |
The stream encoding. More... | |
Emitter stuff | |
int | canonical |
If the output is in the canonical style? More... | |
int | best_indent |
The number of indentation spaces. More... | |
int | best_width |
The preferred width of the output lines. More... | |
int | unicode |
Allow unescaped non-ASCII characters? More... | |
yaml_break_t | line_break |
The preferred line break. More... | |
struct { | |
yaml_emitter_state_t * start | |
The beginning of the stack. More... | |
yaml_emitter_state_t * end | |
The end of the stack. More... | |
yaml_emitter_state_t * top | |
The top of the stack. More... | |
} | states |
The stack of states. More... | |
yaml_emitter_state_t | state |
The current emitter state. More... | |
struct { | |
yaml_event_t * start | |
The beginning of the event queue. More... | |
yaml_event_t * end | |
The end of the event queue. More... | |
yaml_event_t * head | |
The head of the event queue. More... | |
yaml_event_t * tail | |
The tail of the event queue. More... | |
} | events |
The event queue. More... | |
struct { | |
int * start | |
The beginning of the stack. More... | |
int * end | |
The end of the stack. More... | |
int * top | |
The top of the stack. More... | |
} | indents |
The stack of indentation levels. More... | |
struct { | |
yaml_tag_directive_t * start | |
The beginning of the list. More... | |
yaml_tag_directive_t * end | |
The end of the list. More... | |
yaml_tag_directive_t * top | |
The top of the list. More... | |
} | tag_directives |
The list of tag directives. More... | |
int | indent |
The current indentation level. More... | |
int | flow_level |
The current flow level. More... | |
int | root_context |
Is it the document root context? More... | |
int | sequence_context |
Is it a sequence context? More... | |
int | mapping_context |
Is it a mapping context? More... | |
int | simple_key_context |
Is it a simple mapping key context? More... | |
int | line |
The current line. More... | |
int | column |
The current column. More... | |
int | whitespace |
If the last character was a whitespace? More... | |
int | indention |
If the last character was an indentation character (' ', '-', '?', ':')? More... | |
int | open_ended |
If an explicit document end is required? More... | |
struct { | |
yaml_char_t * anchor | |
The anchor value. More... | |
size_t anchor_length | |
The anchor length. More... | |
int alias | |
Is it an alias? More... | |
} | anchor_data |
Anchor analysis. More... | |
struct { | |
yaml_char_t * handle | |
The tag handle. More... | |
size_t handle_length | |
The tag handle length. More... | |
yaml_char_t * suffix | |
The tag suffix. More... | |
size_t suffix_length | |
The tag suffix length. More... | |
} | tag_data |
Tag analysis. More... | |
struct { | |
yaml_char_t * value | |
The scalar value. More... | |
size_t length | |
The scalar length. More... | |
int multiline | |
Does the scalar contain line breaks? More... | |
int flow_plain_allowed | |
Can the scalar be expessed in the flow plain style? More... | |
int block_plain_allowed | |
Can the scalar be expressed in the block plain style? More... | |
int single_quoted_allowed | |
Can the scalar be expressed in the single quoted style? More... | |
int block_allowed | |
Can the scalar be expressed in the literal or folded styles? More... | |
yaml_scalar_style_t style | |
The output style. More... | |
} | scalar_data |
Scalar analysis. More... | |
Dumper stuff | |
int | opened |
If the stream was already opened? More... | |
int | closed |
If the stream was already closed? More... | |
struct { | |
int references | |
The number of references. More... | |
int anchor | |
The anchor id. More... | |
int serialized | |
If the node has been emitted? More... | |
} | anchors |
The information associated with the document nodes. More... | |
int | last_anchor_id |
The last assigned anchor id. More... | |
yaml_document_t * | document |
The currently emitted document. More... | |
The emitter structure.
All members are internal. Manage the structure using the yaml_emitter_
family of functions.
int yaml_emitter_s::alias |
Is it an alias?
Definition at line 1693 of file yaml.h.
Referenced by yaml_emitter_analyze_anchor(), and yaml_emitter_process_anchor().
yaml_char_t* yaml_emitter_s::anchor |
The anchor value.
Definition at line 1689 of file yaml.h.
Referenced by yaml_emitter_analyze_anchor(), yaml_emitter_analyze_event(), yaml_emitter_anchor_node(), yaml_emitter_dump_node(), and yaml_emitter_process_anchor().
struct { ... } yaml_emitter_s::anchor_data |
Anchor analysis.
Referenced by yaml_emitter_analyze_anchor(), yaml_emitter_analyze_event(), yaml_emitter_check_simple_key(), and yaml_emitter_process_anchor().
size_t yaml_emitter_s::anchor_length |
The anchor length.
Definition at line 1691 of file yaml.h.
Referenced by yaml_emitter_analyze_anchor(), yaml_emitter_analyze_event(), yaml_emitter_check_simple_key(), and yaml_emitter_process_anchor().
struct { ... } * yaml_emitter_s::anchors |
The information associated with the document nodes.
Referenced by yaml_emitter_anchor_node(), yaml_emitter_delete_document_and_anchors(), and yaml_emitter_dump_node().
int yaml_emitter_s::best_indent |
The number of indentation spaces.
Definition at line 1607 of file yaml.h.
Referenced by indentation(), yaml_emitter_emit_stream_start(), yaml_emitter_increase_indent(), and yaml_emitter_write_block_scalar_hints().
int yaml_emitter_s::best_width |
The preferred width of the output lines.
Definition at line 1609 of file yaml.h.
Referenced by line_width(), yaml_emitter_emit_flow_mapping_key(), yaml_emitter_emit_flow_mapping_value(), yaml_emitter_emit_flow_sequence_item(), yaml_emitter_emit_stream_start(), yaml_emitter_write_double_quoted_scalar(), yaml_emitter_write_folded_scalar(), yaml_emitter_write_plain_scalar(), and yaml_emitter_write_single_quoted_scalar().
int yaml_emitter_s::block_allowed |
Can the scalar be expressed in the literal or folded styles?
Definition at line 1723 of file yaml.h.
Referenced by yaml_emitter_analyze_scalar(), and yaml_emitter_select_scalar_style().
int yaml_emitter_s::block_plain_allowed |
Can the scalar be expressed in the block plain style?
Definition at line 1719 of file yaml.h.
Referenced by yaml_emitter_analyze_scalar(), and yaml_emitter_select_scalar_style().
unsigned char* yaml_emitter_s::buffer |
struct { ... } yaml_emitter_s::buffer |
The working buffer.
int yaml_emitter_s::canonical |
If the output is in the canonical style?
Definition at line 1605 of file yaml.h.
Referenced by canonical(), yaml_emitter_analyze_event(), yaml_emitter_emit_document_start(), yaml_emitter_emit_flow_mapping_key(), yaml_emitter_emit_flow_mapping_value(), yaml_emitter_emit_flow_sequence_item(), yaml_emitter_emit_mapping_start(), yaml_emitter_emit_sequence_start(), and yaml_emitter_select_scalar_style().
int yaml_emitter_s::closed |
int yaml_emitter_s::column |
The current column.
Definition at line 1678 of file yaml.h.
Referenced by yaml_emitter_emit_flow_mapping_key(), yaml_emitter_emit_flow_mapping_value(), yaml_emitter_emit_flow_sequence_item(), yaml_emitter_emit_stream_start(), yaml_emitter_write_double_quoted_scalar(), yaml_emitter_write_folded_scalar(), yaml_emitter_write_indent(), yaml_emitter_write_plain_scalar(), and yaml_emitter_write_single_quoted_scalar().
yaml_document_t* yaml_emitter_s::document |
The currently emitted document.
Definition at line 1756 of file yaml.h.
Referenced by yaml_emitter_anchor_node(), yaml_emitter_delete_document_and_anchors(), and yaml_emitter_dump_node().
yaml_encoding_t yaml_emitter_s::encoding |
The stream encoding.
Definition at line 1593 of file yaml.h.
Referenced by yaml_emitter_emit_stream_start().
yaml_char_t* yaml_emitter_s::end |
yaml_emitter_state_t* yaml_emitter_s::end |
yaml_event_t* yaml_emitter_s::end |
yaml_tag_directive_t* yaml_emitter_s::end |
yaml_error_type_t yaml_emitter_s::error |
Error type.
Definition at line 1533 of file yaml.h.
Referenced by yaml_emitter_append_tag_directive().
struct { ... } yaml_emitter_s::events |
The event queue.
Referenced by yaml_emitter_check_empty_mapping(), yaml_emitter_check_empty_sequence(), yaml_emitter_check_simple_key(), and yaml_emitter_need_more_events().
FILE* yaml_emitter_s::file |
int yaml_emitter_s::flow_level |
The current flow level.
Definition at line 1664 of file yaml.h.
Referenced by yaml_emitter_emit_flow_mapping_key(), yaml_emitter_emit_flow_sequence_item(), yaml_emitter_emit_mapping_start(), yaml_emitter_emit_sequence_start(), and yaml_emitter_select_scalar_style().
int yaml_emitter_s::flow_plain_allowed |
Can the scalar be expessed in the flow plain style?
Definition at line 1717 of file yaml.h.
Referenced by yaml_emitter_analyze_scalar(), and yaml_emitter_select_scalar_style().
yaml_char_t* yaml_emitter_s::handle |
The tag handle.
Definition at line 1699 of file yaml.h.
Referenced by yaml_emitter_analyze_event(), yaml_emitter_analyze_tag(), yaml_emitter_process_tag(), and yaml_emitter_select_scalar_style().
size_t yaml_emitter_s::handle_length |
The tag handle length.
Definition at line 1701 of file yaml.h.
Referenced by yaml_emitter_analyze_event(), yaml_emitter_analyze_tag(), yaml_emitter_check_simple_key(), yaml_emitter_process_tag(), and yaml_emitter_select_scalar_style().
yaml_event_t* yaml_emitter_s::head |
The head of the event queue.
Definition at line 1635 of file yaml.h.
Referenced by yaml_emitter_check_empty_mapping(), yaml_emitter_check_empty_sequence(), yaml_emitter_check_simple_key(), and yaml_emitter_need_more_events().
int yaml_emitter_s::indent |
The current indentation level.
Definition at line 1661 of file yaml.h.
Referenced by yaml_emitter_emit_block_mapping_key(), yaml_emitter_emit_block_sequence_item(), yaml_emitter_emit_flow_mapping_key(), yaml_emitter_emit_flow_sequence_item(), yaml_emitter_emit_scalar(), yaml_emitter_emit_stream_start(), yaml_emitter_increase_indent(), and yaml_emitter_write_indent().
int yaml_emitter_s::indention |
If the last character was an indentation character (' ', '-', '?', ':')?
Definition at line 1682 of file yaml.h.
Referenced by yaml_emitter_emit_block_sequence_item(), yaml_emitter_emit_stream_start(), yaml_emitter_write_anchor(), yaml_emitter_write_double_quoted_scalar(), yaml_emitter_write_folded_scalar(), yaml_emitter_write_indent(), yaml_emitter_write_indicator(), yaml_emitter_write_literal_scalar(), yaml_emitter_write_plain_scalar(), yaml_emitter_write_single_quoted_scalar(), yaml_emitter_write_tag_content(), and yaml_emitter_write_tag_handle().
struct { ... } yaml_emitter_s::indents |
The stack of indentation levels.
Referenced by yaml_emitter_emit_block_mapping_key(), yaml_emitter_emit_block_sequence_item(), yaml_emitter_emit_flow_mapping_key(), yaml_emitter_emit_flow_sequence_item(), yaml_emitter_emit_scalar(), and yaml_emitter_increase_indent().
yaml_char_t* yaml_emitter_s::last |
unsigned char* yaml_emitter_s::last |
int yaml_emitter_s::last_anchor_id |
The last assigned anchor id.
Definition at line 1753 of file yaml.h.
Referenced by yaml_emitter_anchor_node(), and yaml_emitter_delete_document_and_anchors().
size_t yaml_emitter_s::length |
The scalar length.
Definition at line 1713 of file yaml.h.
Referenced by yaml_emitter_analyze_event(), yaml_emitter_analyze_scalar(), yaml_emitter_check_simple_key(), yaml_emitter_process_scalar(), and yaml_emitter_select_scalar_style().
int yaml_emitter_s::line |
The current line.
Definition at line 1676 of file yaml.h.
Referenced by yaml_emitter_emit_stream_start().
yaml_break_t yaml_emitter_s::line_break |
The preferred line break.
Definition at line 1613 of file yaml.h.
Referenced by yaml_emitter_emit_stream_start().
int yaml_emitter_s::mapping_context |
Is it a mapping context?
Definition at line 1671 of file yaml.h.
Referenced by yaml_emitter_emit_block_sequence_item(), and yaml_emitter_emit_node().
int yaml_emitter_s::multiline |
Does the scalar contain line breaks?
Definition at line 1715 of file yaml.h.
Referenced by yaml_emitter_analyze_scalar(), yaml_emitter_check_simple_key(), and yaml_emitter_select_scalar_style().
int yaml_emitter_s::open_ended |
If an explicit document end is required?
Definition at line 1684 of file yaml.h.
Referenced by yaml_emitter_emit_document_start(), yaml_emitter_write_block_scalar_hints(), yaml_emitter_write_indicator(), and yaml_emitter_write_plain_scalar().
int yaml_emitter_s::opened |
union { ... } yaml_emitter_s::output |
Standard (string or file) output data.
Referenced by yaml_file_write_handler(), and yaml_string_write_handler().
yaml_char_t* yaml_emitter_s::pointer |
unsigned char* yaml_emitter_s::pointer |
const char* yaml_emitter_s::problem |
struct { ... } yaml_emitter_s::raw_buffer |
The raw buffer.
int yaml_emitter_s::references |
The number of references.
Definition at line 1745 of file yaml.h.
Referenced by yaml_emitter_anchor_node().
int yaml_emitter_s::root_context |
Is it the document root context?
Definition at line 1667 of file yaml.h.
Referenced by yaml_emitter_emit_node(), and yaml_emitter_write_plain_scalar().
struct { ... } yaml_emitter_s::scalar_data |
Scalar analysis.
Referenced by yaml_emitter_analyze_event(), yaml_emitter_analyze_scalar(), yaml_emitter_check_simple_key(), yaml_emitter_process_scalar(), and yaml_emitter_select_scalar_style().
int yaml_emitter_s::sequence_context |
Is it a sequence context?
Definition at line 1669 of file yaml.h.
Referenced by yaml_emitter_emit_node().
int yaml_emitter_s::serialized |
If the node has been emitted?
Definition at line 1749 of file yaml.h.
Referenced by yaml_emitter_delete_document_and_anchors(), and yaml_emitter_dump_node().
int yaml_emitter_s::simple_key_context |
Is it a simple mapping key context?
Definition at line 1673 of file yaml.h.
Referenced by yaml_emitter_emit_node(), yaml_emitter_process_scalar(), and yaml_emitter_select_scalar_style().
int yaml_emitter_s::single_quoted_allowed |
Can the scalar be expressed in the single quoted style?
Definition at line 1721 of file yaml.h.
Referenced by yaml_emitter_analyze_scalar(), and yaml_emitter_select_scalar_style().
size_t* yaml_emitter_s::size_written |
yaml_char_t* yaml_emitter_s::start |
The beginning of the buffer.
Definition at line 1571 of file yaml.h.
Referenced by yaml_emitter_analyze_tag(), and yaml_emitter_append_tag_directive().
unsigned char* yaml_emitter_s::start |
yaml_emitter_state_t* yaml_emitter_s::start |
yaml_event_t* yaml_emitter_s::start |
yaml_tag_directive_t* yaml_emitter_s::start |
yaml_emitter_state_t yaml_emitter_s::state |
The current emitter state.
Definition at line 1626 of file yaml.h.
Referenced by yaml_emitter_emit_alias(), yaml_emitter_emit_block_mapping_key(), yaml_emitter_emit_block_sequence_item(), yaml_emitter_emit_document_end(), yaml_emitter_emit_document_start(), yaml_emitter_emit_flow_mapping_key(), yaml_emitter_emit_flow_sequence_item(), yaml_emitter_emit_mapping_start(), yaml_emitter_emit_scalar(), yaml_emitter_emit_sequence_start(), yaml_emitter_emit_stream_start(), and yaml_emitter_state_machine().
struct { ... } yaml_emitter_s::states |
The stack of states.
Referenced by yaml_emitter_emit_alias(), yaml_emitter_emit_block_mapping_key(), yaml_emitter_emit_block_mapping_value(), yaml_emitter_emit_block_sequence_item(), yaml_emitter_emit_document_content(), yaml_emitter_emit_flow_mapping_key(), yaml_emitter_emit_flow_mapping_value(), yaml_emitter_emit_flow_sequence_item(), and yaml_emitter_emit_scalar().
struct { ... } yaml_emitter_s::string |
String output data.
Referenced by yaml_string_write_handler().
yaml_scalar_style_t yaml_emitter_s::style |
The output style.
Definition at line 1725 of file yaml.h.
Referenced by yaml_emitter_process_scalar(), and yaml_emitter_select_scalar_style().
yaml_char_t* yaml_emitter_s::suffix |
The tag suffix.
Definition at line 1703 of file yaml.h.
Referenced by yaml_emitter_analyze_event(), yaml_emitter_analyze_tag(), yaml_emitter_process_tag(), and yaml_emitter_select_scalar_style().
size_t yaml_emitter_s::suffix_length |
The tag suffix length.
Definition at line 1705 of file yaml.h.
Referenced by yaml_emitter_analyze_event(), yaml_emitter_analyze_tag(), yaml_emitter_check_simple_key(), and yaml_emitter_process_tag().
struct { ... } yaml_emitter_s::tag_data |
Tag analysis.
Referenced by yaml_emitter_analyze_event(), yaml_emitter_analyze_tag(), yaml_emitter_check_simple_key(), yaml_emitter_process_tag(), and yaml_emitter_select_scalar_style().
struct { ... } yaml_emitter_s::tag_directives |
The list of tag directives.
Referenced by yaml_emitter_analyze_tag(), yaml_emitter_append_tag_directive(), and yaml_emitter_emit_document_end().
yaml_event_t* yaml_emitter_s::tail |
The tail of the event queue.
Definition at line 1637 of file yaml.h.
Referenced by yaml_emitter_check_empty_mapping(), yaml_emitter_check_empty_sequence(), and yaml_emitter_need_more_events().
yaml_emitter_state_t* yaml_emitter_s::top |
The top of the stack.
Definition at line 1622 of file yaml.h.
Referenced by yaml_emitter_analyze_tag(), and yaml_emitter_append_tag_directive().
yaml_tag_directive_t* yaml_emitter_s::top |
int yaml_emitter_s::unicode |
Allow unescaped non-ASCII characters?
Definition at line 1611 of file yaml.h.
Referenced by yaml_emitter_analyze_scalar(), and yaml_emitter_write_double_quoted_scalar().
yaml_char_t* yaml_emitter_s::value |
The scalar value.
Definition at line 1711 of file yaml.h.
Referenced by yaml_emitter_analyze_event(), yaml_emitter_analyze_scalar(), and yaml_emitter_process_scalar().
int yaml_emitter_s::whitespace |
If the last character was a whitespace?
Definition at line 1680 of file yaml.h.
Referenced by yaml_emitter_emit_stream_start(), yaml_emitter_write_anchor(), yaml_emitter_write_double_quoted_scalar(), yaml_emitter_write_folded_scalar(), yaml_emitter_write_indent(), yaml_emitter_write_indicator(), yaml_emitter_write_literal_scalar(), yaml_emitter_write_plain_scalar(), yaml_emitter_write_single_quoted_scalar(), yaml_emitter_write_tag_content(), and yaml_emitter_write_tag_handle().
yaml_write_handler_t* yaml_emitter_s::write_handler |
void* yaml_emitter_s::write_handler_data |