Documentation ¶
Index ¶
Constants ¶
View Source
const ( // ErrMalformedBaseYamlPrefix is just the prefix to the error message for when the program is unable to parse // data into the base yaml struct. ErrMalformedBaseYamlPrefix = "Unable to parse yaml data" )
Variables ¶
View Source
var ( // ErrNoDataToParse represents the case that there is no data to be found to be parsed (either nil or empty). ErrNoDataToParse = errors.New("No data to parse") // ErrUnknownSchemaVersion is thrown when the schema version is unknown to the parser. ErrUnknownSchemaVersion = errors.New("Unknown schema version") // ErrCantParseSemver is thrown when the semantic versioning can not be parsed. ErrCantParseSemver = errors.New("Can't parse semantic versioning of schema_version") )
View Source
var ( // SchemaV1_0_0 is the semantic versioning representation in object form for version 1.0.0 SchemaV1_0_0 = semver.Version{1, 0, 0, nil, nil} )
Functions ¶
func Parse ¶
func Parse(parser common.SchemaParser, data []byte) (common.BaseSchema, error)
Parse will try to parse the data and determine which specific version of schema to further parse.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.