FCPXMLConverter
public struct FCPXMLConverter
Undocumented
-
Converts an XML string to a FCPXMLDocument value.
Declaration
Swift
public static func fcpxmlDocument(from xmlString: String) throws -> FCPXMLDocumentParameters
xmlStringThe XML string to be converted.
-
Converts a FCPXMLDocument value to a XML string.
Declaration
Swift
public static func xmlString(from fcpxmlDocument: FCPXMLDocument) throws -> StringParameters
fcpxmlDocumentThe FCPXMLDocument to be converted.
-
A generic function for decoding a FCPXML element from a valid XML string.
Declaration
Swift
public static func decode<T>(_ type: T.Type, from xmlString: String) throws -> T where T : DecodableParameters
typeThe type that represents the XML element in Swift.
xmlStringThe XML string to be decoded.
-
A generic function that converts a FCPXML element from its Swift representation to a XML string.
Declaration
Swift
public static func xmlString<T>(from fcpxmlElement: T, rootKey: String) throws -> String where T : EncodableParameters
fcpxmlElementThe FCPXML element to be converted.
rootKeyThe XML root key to use for the FCPXML element.
-
Converts a FCPXMLDocument to a XMLDocument. The returned XMLDocument uses an empty DTD so that its string representation does not include the full FCPXML DTD. For validation use the
validateFCPXMLmethod included as an extension on XMLDocument.Declaration
Swift
public static func xmlDocument(from fcpxmlDocument: FCPXMLDocument) throws -> XMLDocumentParameters
fcpxmlDocument<#fcpxmlDocument description#>
FCPXMLConverter Structure Reference