Vuo  1.2.6
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
Classes | Functions

Description

Hierarchically structured information.

Classes

struct  VuoTree
 Hierarchically structured information. More...
 

Functions

VuoTree VuoTree_makeFromJson (struct json_object *js)
 Decodes the JSON object js to create a new value.
 
struct json_objectVuoTree_getJson (const VuoTree value)
 Encodes value as a JSON object that can only be decoded in the same process.
 
struct json_objectVuoTree_getInterprocessJson (const VuoTree value)
 Encodes value as a JSON object that can be decoded in a separate process.
 
char * VuoTree_getSummary (const VuoTree value)
 Returns a human-readable description of value.
 
VuoTree VuoTree_makeEmpty (void)
 Returns a tree with nothing in it.
 
VuoTree VuoTree_make (VuoText name, VuoDictionary_VuoText_VuoText attributes, VuoText content, VuoList_VuoTree children)
 Returns a tree that consists of the given components.
 
VuoTree VuoTree_makeFromJsonText (VuoText json)
 Returns a tree parsed from json.
 
VuoTree VuoTree_makeFromXmlText (VuoText xml, bool includeWhitespace)
 Returns a tree parsed from xml.
 
VuoText VuoTree_serializeAsXml (VuoTree tree, bool indent)
 Returns an XML-formatted string representation of a tree.
 
VuoText VuoTree_serializeAsJson (VuoTree tree, bool indent)
 Returns an JSON-formatted string representation of a tree.
 
void VuoTree_retain (VuoTree value)
 Replaces the auto-generated function.
 
void VuoTree_release (VuoTree value)
 Replaces the auto-generated function.
 
VuoText VuoTree_getName (VuoTree tree)
 Returns the name of the tree's root item.
 
VuoDictionary_VuoText_VuoText VuoTree_getAttributes (VuoTree tree)
 Returns the attributes of the tree's root item.
 
VuoText VuoTree_getAttribute (VuoTree tree, VuoText attribute)
 Returns the value of the attribute with the given name in the tree's root item, or an empty text if not found.
 
VuoText VuoTree_getContent (VuoTree tree, bool includeDescendants)
 Returns the content of the tree's root item and, optionally, of its descendants.
 
VuoList_VuoTree VuoTree_getChildren (VuoTree tree)
 Returns a list of the subtrees that are direct descendants of the tree's root item.
 
struct json_objectVuoTree_getContainedValue (VuoTree tree)
 Interprets the content and children of the tree as a JSON representation of a Vuo data type value.
 
VuoList_VuoTree VuoTree_findItemsUsingXpath (VuoTree tree, VuoText xpath)
 Returns the subtrees found by searching tree with XPath expression xpath, or an empty list if there's an error.
 
VuoList_VuoTree VuoTree_findItemsWithName (VuoTree tree, VuoText name, VuoTextComparison comparison, bool includeDescendants)
 Searches tree for subtrees whose name matches name.
 
VuoList_VuoTree VuoTree_findItemsWithAttribute (VuoTree tree, VuoText attribute, VuoText value, VuoTextComparison valueComparison, bool includeDescendants)
 Searches tree for subtrees that have an attribute called attribute (exact match) and its value matches value (based on valueComparison).
 
VuoList_VuoTree VuoTree_findItemsWithContent (VuoTree tree, VuoText content, VuoTextComparison comparison, bool includeDescendants)
 Searches tree for subtrees whose content matches name.
 
VuoTree VuoTree_makeFromString (const char *str)
 Automatically generated function.
 
char * VuoTree_getString (const VuoTree value)
 Automatically generated function.
 
char * VuoTree_getInterprocessString (const VuoTree value)
 Automatically generated function.
 

Class Documentation

struct VuoTree
Class Members
VuoList_VuoTree children Children of the tree, if it was constructed without parsing from text.
struct json_object * rootJson JSON representation of the tree, if it was parsed from JSON.
void * rootXmlNode XML representation of the tree — an xmlNode * of type element node.

Function Documentation

VuoList_VuoTree VuoTree_findItemsUsingXpath ( VuoTree  tree,
VuoText  xpath 
)

Returns the subtrees found by searching tree with XPath expression xpath, or an empty list if there's an error.

If xpath is a relative path, the root of tree is the context node.

VuoList_VuoTree VuoTree_findItemsWithAttribute ( VuoTree  tree,
VuoText  attribute,
VuoText  value,
VuoTextComparison  valueComparison,
bool  includeDescendants 
)

Searches tree for subtrees that have an attribute called attribute (exact match) and its value matches value (based on valueComparison).

If includeDescendants is false, only the tree's root and its immediate children are searched. If includeDescendants is true, all descendants are searched.

VuoList_VuoTree VuoTree_findItemsWithContent ( VuoTree  tree,
VuoText  content,
VuoTextComparison  comparison,
bool  includeDescendants 
)

Searches tree for subtrees whose content matches name.

If a subtree contains a child subtree whose content matches, only the child subtree is returned, not the parent.

If includeDescendants is false, only the tree's root and its immediate children are searched. If includeDescendants is true, all descendants are searched.

VuoList_VuoTree VuoTree_findItemsWithName ( VuoTree  tree,
VuoText  name,
VuoTextComparison  comparison,
bool  includeDescendants 
)

Searches tree for subtrees whose name matches name.

If includeDescendants is false, only the tree's root and its immediate children are searched. If includeDescendants is true, all descendants are searched.

VuoText VuoTree_getAttribute ( VuoTree  tree,
VuoText  attribute 
)

Returns the value of the attribute with the given name in the tree's root item, or an empty text if not found.

VuoDictionary_VuoText_VuoText VuoTree_getAttributes ( VuoTree  tree)

Returns the attributes of the tree's root item.

VuoList_VuoTree VuoTree_getChildren ( VuoTree  tree)

Returns a list of the subtrees that are direct descendants of the tree's root item.

struct json_object* VuoTree_getContainedValue ( VuoTree  tree)
read

Interprets the content and children of the tree as a JSON representation of a Vuo data type value.

VuoText VuoTree_getContent ( VuoTree  tree,
bool  includeDescendants 
)

Returns the content of the tree's root item and, optionally, of its descendants.

struct json_object* VuoTree_getInterprocessJson ( const VuoTree  value)
read

Encodes value as a JSON object that can be decoded in a separate process.

char* VuoTree_getInterprocessString ( const VuoTree  value)

Automatically generated function.

struct json_object* VuoTree_getJson ( const VuoTree  value)
read

Encodes value as a JSON object that can only be decoded in the same process.

VuoText VuoTree_getName ( VuoTree  tree)

Returns the name of the tree's root item.

char* VuoTree_getString ( const VuoTree  value)

Automatically generated function.

char* VuoTree_getSummary ( const VuoTree  value)

Returns a human-readable description of value.

VuoTree VuoTree_make ( VuoText  name,
VuoDictionary_VuoText_VuoText  attributes,
VuoText  content,
VuoList_VuoTree  children 
)

Returns a tree that consists of the given components.

VuoTree VuoTree_makeEmpty ( void  )

Returns a tree with nothing in it.

VuoTree VuoTree_makeFromJson ( struct json_object js)

Decodes the JSON object js to create a new value.

VuoTree VuoTree_makeFromJsonText ( VuoText  json)

Returns a tree parsed from json.

VuoTree VuoTree_makeFromString ( const char *  str)

Automatically generated function.

VuoTree VuoTree_makeFromXmlText ( VuoText  xml,
bool  includeWhitespace 
)

Returns a tree parsed from xml.

void VuoTree_release ( VuoTree  value)

Replaces the auto-generated function.

Skips rootXmlNode since we don't register it.

void VuoTree_retain ( VuoTree  value)

Replaces the auto-generated function.

Skips rootXmlNode since we don't register it.

VuoText VuoTree_serializeAsJson ( VuoTree  tree,
bool  indent 
)

Returns an JSON-formatted string representation of a tree.

VuoText VuoTree_serializeAsXml ( VuoTree  tree,
bool  indent 
)

Returns an XML-formatted string representation of a tree.