check if a XML value contains another XML value
Try to get a given tag name out from an XML value, then grab the value from that Grabs the first tag that matches in the object
>>> import Xml exposing (Value(..))
>>> tag "name" string (Tag "name" Dict.empty (StrNode "noah"))
Ok "noah"
>>> tag "name" string (Tag "name" Dict.empty (IntNode 5))
Err "Not a string."
>>> tag "name" string (StrNode "noah")
Err "No tag called 'name' found."Collect as many values that pass the given converter
>>> collect (tag "name" string) [Tag "name" Dict.empty (StrNode "noah")]
[ "noah" ]
>>> collect (tag "name" string) [Tag "name" Dict.empty (IntNode 5)]
[ ]Set a default for a result
>> default "Cat" (Ok "Fish")
Ok "Fish"
>> default "Dog" (Err "flip")
Ok "Dog"Try to turn a value into a string
>>> string (IntNode 5)
Err "Not a string."
>>> string (StrNode "hello")
Ok "hello"Try to turn a value into an int >>> int (IntNode 5) Ok 5
>>> int (StrNode "hello")
Err "Not an int"Try to turn a value into an int >>> float (FloatNode 5.5) Ok 5.5
>>> float (StrNode "hello")
Err "Not a float"Try to turn a value into an int >>> bool (BoolNode True) Ok True
>>> bool (StrNode "hello")
Err "Not a bool"
Search an XML value for any tags matching