read(from:ofType:)
Sets the contents of this document by reading from data of a specified type.
Declaration
nonisolated func read(from data: Data, ofType typeName: String) throwsParameters
- data:
The data object from which the document contents are read.
- typeName:
The string that identifies the document type.
Discussion
The default implementation of this method throws an exception because at least one of the three reading methods (this method, read(from:ofType:), read(from:ofType:)), or every method that may invoke read(from:ofType:), must be overridden.