Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Schema ¶
type Schema struct { Version string `json:"$schema,omitempty"` ID string `json:"$id,omitempty"` Anchor string `json:"$anchor,omitempty"` Ref string `json:"$ref,omitempty"` DynamicRef string `json:"$dynamicRef,omitempty"` Definitions *orderedmap.OrderedMap `json:"definitions,omitempty"` AllOf []*Schema `json:"allOf,omitempty"` AnyOf []*Schema `json:"anyOf,omitempty"` OneOf []*Schema `json:"oneOf,omitempty"` Not *Schema `json:"not,omitempty"` Items []*Schema `json:"items,omitempty"` AdditionalItems *Schema `json:"additionalItems,omitempty"` Contains *Schema `json:"contains,omitempty"` Properties *orderedmap.OrderedMap `json:"properties,omitempty"` PatternProperties *orderedmap.OrderedMap `json:"patternProperties,omitempty"` AdditionalProperties *Schema `json:"additionalProperties,omitempty"` PropertyNames *Schema `json:"propertyNames,omitempty"` Type string `json:"type,omitempty"` Enum []any `json:"enum,omitempty"` Const *any `json:"const,omitempty"` MultipleOf *int `json:"multipleOf,omitempty"` Maximum *float64 `json:"maximum,omitempty"` ExclusiveMaximum *float64 `json:"exclusiveMaximum,omitempty"` Minimum *float64 `json:"minimum,omitempty"` ExclusiveMinimum *float64 `json:"exclusiveMinimum,omitempty"` MaxLength *int `json:"maxLength,omitempty"` MinLength *int `json:"minLength,omitempty"` Pattern string `json:"pattern,omitempty"` MaxItems *int `json:"maxItems,omitempty"` MinItems *int `json:"minItems,omitempty"` UniqueItems *bool `json:"uniqueItems,omitempty"` MaxContains *int `json:"maxContains,omitempty"` MinContains *int `json:"minContains,omitempty"` MaxProperties *int `json:"maxProperties,omitempty"` MinProperties *int `json:"minProperties,omitempty"` Required []string `json:"required,omitempty"` Format string `json:"format,omitempty"` Title string `json:"title,omitempty"` Description string `json:"description,omitempty"` Default *any `json:"default,omitempty"` Examples []any `json:"examples,omitempty"` Extras map[string]any `json:"-"` }
func New ¶
func New(schema *jsonschema.Schema) *Schema
Click to show internal directories.
Click to hide internal directories.