Expand description
An output value cell returned from yrs API methods. It describes a various types of data supported by yrs shared data types.
Since YOutput instances are always created by calling the corresponding yrs API functions,
they eventually should be deallocated using youtput_destroy function.
Fields§
§tag: i8Tag describing, which value type is being stored by this input cell. Can be one of:
- Y_JSON_BOOL for boolean flags.
- Y_JSON_NUM for 64-bit floating point numbers.
- Y_JSON_INT for 64-bit signed integers.
- Y_JSON_STR for null-terminated UTF-8 encoded strings.
- Y_JSON_BUF for embedded binary data.
- Y_JSON_ARR for arrays of JSON-like values.
- Y_JSON_MAP for JSON-like objects build from key-value pairs.
- Y_JSON_NULL for JSON-like null values.
- Y_JSON_UNDEF for JSON-like undefined values.
- Y_TEXT for pointers to
YTextdata types. - Y_ARRAY for pointers to
YArraydata types. - Y_MAP for pointers to
YMapdata types. - Y_XML_ELEM for pointers to
YXmlElementdata types. - Y_XML_TEXT for pointers to
YXmlTextdata types. - Y_DOC for pointers to nested
YDocRefdata types.
len: u32Length of the contents stored by a current YOutput cell.
For Y_JSON_NULL and Y_JSON_UNDEF its equal to 0.
For Y_JSON_ARR, Y_JSON_MAP it describes a number of passed elements.
For other types it’s always equal to 1.
Trait Implementations§
source§impl From<XmlElementRef> for YOutput
impl From<XmlElementRef> for YOutput
source§fn from(v: XmlElementRef) -> Self
fn from(v: XmlElementRef) -> Self
Converts to this type from the input type.
source§impl From<XmlFragmentRef> for YOutput
impl From<XmlFragmentRef> for YOutput
source§fn from(v: XmlFragmentRef) -> Self
fn from(v: XmlFragmentRef) -> Self
Converts to this type from the input type.
source§impl From<XmlTextRef> for YOutput
impl From<XmlTextRef> for YOutput
source§fn from(v: XmlTextRef) -> Self
fn from(v: XmlTextRef) -> Self
Converts to this type from the input type.