F# Data


XmlRuntime

Namespace: FSharp.Data.Runtime

Static helper methods called from the generated code for working with XML

Static members

Static memberDescription
ConvertArray(xml, nameWithNS, f)
Signature: (xml:XmlElement * nameWithNS:string * f:Func<XmlElement,'R>) -> 'R []
Type parameters: 'R
ConvertAsName(xml, nameWithNS, f)
Signature: (xml:XmlElement * nameWithNS:string * f:Func<XmlElement,'R>) -> 'R option
Type parameters: 'R

Returns Some if the specified XmlElement has the specified name (otherwise None is returned). This is used when the current element can be one of multiple elements.

ConvertOptional(xml, nameWithNS, f)
Signature: (xml:XmlElement * nameWithNS:string * f:Func<XmlElement,'R>) -> 'R option
Type parameters: 'R
ConvertOptional2(xml, nameWithNS, f)
Signature: (xml:XmlElement * nameWithNS:string * f:Func<XmlElement,'R option>) -> 'R option
Type parameters: 'R
CreateRecord(...)
Signature: (nameWithNS:string * attributes:(string * '?7553) [] * elements:(string * obj) [] * cultureStr:string) -> XmlElement
Type parameters: '?7553
CreateValue(...)
Signature: (nameWithNS:string * value:obj * cultureStr:string) -> XmlElement

Creates a XElement with a scalar value and wraps it in a XmlElement

GetChild(value, nameWithNS)
Signature: (value:XmlElement * nameWithNS:string) -> XmlElement
GetJsonValue(xml, cultureStr)
Signature: (xml:XmlElement * cultureStr:string) -> IJsonDocument

Returns the contents of the element as a JsonValue

TryGetAttribute(xml, nameWithNS)
Signature: (xml:XmlElement * nameWithNS:string) -> string option
TryGetJsonValue(xml, cultureStr)
Signature: (xml:XmlElement * cultureStr:string) -> IJsonDocument option

Tries to return the contents of the element as a JsonValue

TryGetValue(xml)
Signature: xml:XmlElement -> string option
Fork me on GitHub