Expand description
XML structures XML structure definitions
Structs§
- Body
Renderer - Render for a
bodycomponent - Component
Arguments - A component can take various arguments (to pass down to its children), which are then later compiled into Rust function arguments - for example
- CssMatcher
- DivRenderer
- Render for a
divcomponent - DomXml
- Wrapper for the XML parser - necessary to easily create a Dom from
XML without putting an XML solver into
azul-core. - Duplicated
Attribute Error - Duplicated
Namespace Error - Dynamic
XmlComponent - Component that was created from a XML node (instead of being registered from Rust code). Necessary to
- Filtered
Component Arguments - Invalid
Char Error - Invalid
Char Multiple Error - Invalid
Quote Error - Invalid
Space Error - Invalid
String Error - NonXml
Char Error - Text
Renderer - Render for a
pcomponent - Unexpected
Close TagError - Unknown
Entity Reference Error - Unknown
Namespace Error - Xml
- XmlComponent
- XmlComponent
Map - Holds all XML components - builtin components
- XmlNode
- Represents one XML node tag
- XmlNode
Vec - XmlQualified
Name - XmlText
Error - XmlText
Pos
Enums§
- Compile
Error - Error that can happen from the translation from XML code to Rust code - stringified, since it is only used for printing and is not exposed in the public API
- Component
Error - Component
Parse Error - DomXml
Parse Error - Dynamic
Item - Item of a split string - either a variable name or a string
- Render
DomError - Result
XmlXml Error - XmlError
- XmlNode
Type - XmlNode
VecDestructor - XmlParse
Error - XmlStream
Error - c_void
Constants§
Traits§
- XmlComponent
Trait - Specifies a component that reacts to a parsed XML node
Functions§
- combine_
and_ replace_ dynamic_ items - Combines the split string back into its original form while replacing the variables with their values
- compile_
body_ node_ to_ rust_ code - compile_
component - compile_
components - compile_
components_ to_ rust_ code - Takes all components and generates the source code function from them
- compile_
node_ to_ rust_ code_ inner - find_
attribute - find_
node_ by_ type - Searches in the the
root_nodesfor anode_type, convenience function in order to for example find the firstnode in all these nodes. - format_
args_ dynamic - Given a string and a key => value mapping, replaces parts of the string with the value, i.e.:
- format_
component_ args - get_
body_ node - Find the one and only
<body>node, return error if there is no app node or there are multiple app nodes - get_
html_ node - Find the one and only
<body>node, return error if there is no app node or there are multiple app nodes - get_
item - Given a root node, traverses along the hierarchy, and returns a mutable reference to the last child node of the root node
- normalize_
casing - Normalizes input such as
abcDef,AbcDef,abc-defto the normalized form ofabc_def - parse_
bool - Parses a string (“true” or “false”)
- parse_
component_ arguments - Compiles a XML
args="a: String, b: bool"into a["a" => "String", "b" => "bool"]map - prepare_
string - render_
component_ inner - render_
dom_ from_ body_ node - render_
dom_ from_ body_ node_ inner - Takes a single (expanded) app node and renders the DOM or returns an error
- set_
attributes - set_
stringified_ attributes - split_
dynamic_ string - Splits a string into formatting arguments
- str_
to_ dom - Parses an XML string and returns a
StyledDomwith the components instantiated in the<app></app> - str_
to_ rust_ code - Parses an XML string and returns a
String, which contains the Rust source code (i.e. it compiles the XML to valid Rust) - validate_
and_ filter_ component_ args - Filters the XML attributes of a component given XmlAttributeMap
Type Aliases§
- Compiled
Component - Component
Argument Name - Component
Argument Order - Component
Argument Type - Component
Argument Types - Component
Name - Syntax
Error - Error that can happen during hot-reload - stringified, since it is only used for printing and is not exposed in the public API
- XmlAttribute
Map - Attributes of an XML node, such as
["color" => "blue"]in<button color="blue" />. - XmlTag
Name - Tag of an XML node, such as the “button” in
<button>Hello</button>. - XmlText
Content - (Unparsed) text content of an XML node, such as the “Hello” in
<button>Hello</button>.