Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // ErrNotImplemented is returned when the JSON schema encoding logic for a schema.FieldValidator has not (yet) // been implemented. ErrNotImplemented = errors.New("not implemented") )
Functions ¶
This section is empty.
Types ¶
type Encoder ¶
Encoder writes the JSON Schema representation of a schema.Schema to an output stream. Note that only a sub-set of the FieldValidator types in the schema package is supported at the moment. Custom validators are also not yet handled. Attempting to encode a schema containing such fields will result in a ErrNotImplemented error.
func NewEncoder ¶
NewEncoder returns a new JSONSchema Encoder that writes to w.
Click to show internal directories.
Click to hide internal directories.