Document

public class Document : XML.Node

XML Document class

  • Undocumented

    Declaration

    Swift

    public var version: String?
  • Undocumented

    Declaration

    Swift

    public var characterEncoding: String?
  • Undocumented

    Declaration

    Swift

    public init()
  • Undocumented

    Declaration

    Swift

    public init(rootElement: XML.Element)
  • initialise with a block XML data

    Declaration

    Swift

    public init(data: Data) throws
  • set the root element of the document

    Declaration

    Swift

    public func setRootElement(_ rootElement: XML.Element)
  • return the root element

    Declaration

    Swift

    public func rootElement() -> XML.Element?
  • output formatted XML

    Declaration

    Swift

    override public var xmlString: String { get }
  • output formatted XML as Data

    Declaration

    Swift

    public var xmlData: Data { get }