YamlError
public enum YamlError : Error
extension YamlError: CustomStringConvertible
Errors thrown by Yams APIs.
-
YAML_NO_ERROR. No error is produced.Declaration
Swift
case no -
YAML_MEMORY_ERROR. Cannot allocate or reallocate a block of memory.Declaration
Swift
case memory -
YAML_READER_ERROR. Cannot read or decode the input stream.Declaration
Swift
case reader(problem: String, offset: Int?, value: Int32, yaml: String)Parameters
problemError description.
offsetThe offset from
yaml.startIndexat which the problem occured.valueThe problematic value (-1 is none).
yamlYAML String which the problem occured while reading.
-
YAML_SCANNER_ERROR. Cannot scan the input stream.Parameters
contextError context.
problemError description.
markProblem position.
yamlYAML String which the problem occured while scanning.
-
YAML_PARSER_ERROR. Cannot parse the input stream.Parameters
contextError context.
problemError description.
markProblem position.
yamlYAML String which the problem occured while parsing.
-
YAML_COMPOSER_ERROR. Cannot compose a YAML document.Parameters
contextError context.
problemError description.
markProblem position.
yamlYAML String which the problem occured while composing.
-
YAML_WRITER_ERROR. Cannot write to the output stream.Declaration
Swift
case writer(problem: String)Parameters
problemError description.
-
YAML_EMITTER_ERROR. Cannot emit a YAML stream.Declaration
Swift
case emitter(problem: String)Parameters
problemError description.
-
Used in
NodeRepresentable.Declaration
Swift
case representer(problem: String)Parameters
problemError description.
-
String data could not be decoded with the specified encoding.
Declaration
Swift
case dataCouldNotBeDecoded(encoding: String.Encoding)Parameters
encodingThe string encoding used to decode the string data.
-
Multiple uses of the same key detected in a mapping
Declaration
Swift
case duplicatedKeysInMapping(duplicates: [String], context: Context)Parameters
duplicatesA dictionary keyed by the duplicated node value, with all nodes that duplicate the value
yamlYAML String which the problem occured while reading.
-
The error context.
See moreDeclaration
Swift
public struct Context : CustomStringConvertible, Sendable -
A textual representation of this instance.
Declaration
Swift
public var description: String { get }
View on GitHub
Install in Dash