kubernetes/vendor/k8s.io/kube-openapi/pkg/validation/spec/schema.go

// BooleanProperty creates a boolean property
func BooleanProperty() *Schema {}

// BoolProperty creates a boolean property
func BoolProperty() *Schema {}

// StringProperty creates a string property
func StringProperty() *Schema {}

// CharProperty creates a string property
func CharProperty() *Schema {}

// Float64Property creates a float64/double property
func Float64Property() *Schema {}

// Float32Property creates a float32/float property
func Float32Property() *Schema {}

// Int8Property creates an int8 property
func Int8Property() *Schema {}

// Int16Property creates an int16 property
func Int16Property() *Schema {}

// Int32Property creates an int32 property
func Int32Property() *Schema {}

// Int64Property creates an int64 property
func Int64Property() *Schema {}

// StrFmtProperty creates a property for the named string format
func StrFmtProperty(format string) *Schema {}

// DateProperty creates a date property
func DateProperty() *Schema {}

// DateTimeProperty creates a date time property
func DateTimeProperty() *Schema {}

// MapProperty creates a map property
func MapProperty(property *Schema) *Schema {}

// RefProperty creates a ref property
func RefProperty(name string) *Schema {}

// RefSchema creates a ref property
func RefSchema(name string) *Schema {}

// ArrayProperty creates an array property
func ArrayProperty(items *Schema) *Schema {}

// ComposedSchema creates a schema with allOf
func ComposedSchema(schemas ...Schema) *Schema {}

type SchemaURL

// MarshalJSON marshal this to JSON
func (r SchemaURL) MarshalJSON() ([]byte, error) {}

// UnmarshalJSON unmarshal this from JSON
func (r *SchemaURL) UnmarshalJSON(data []byte) error {}

func (r *SchemaURL) fromMap(v map[string]interface{}

type SchemaProps

type schemaPropsOmitZero

type SwaggerSchemaProps

type swaggerSchemaPropsOmitZero

type Schema

// WithID sets the id for this schema, allows for chaining
func (s *Schema) WithID(id string) *Schema {}

// WithTitle sets the title for this schema, allows for chaining
func (s *Schema) WithTitle(title string) *Schema {}

// WithDescription sets the description for this schema, allows for chaining
func (s *Schema) WithDescription(description string) *Schema {}

// WithProperties sets the properties for this schema
func (s *Schema) WithProperties(schemas map[string]Schema) *Schema {}

// SetProperty sets a property on this schema
func (s *Schema) SetProperty(name string, schema Schema) *Schema {}

// WithAllOf sets the all of property
func (s *Schema) WithAllOf(schemas ...Schema) *Schema {}

// WithMaxProperties sets the max number of properties an object can have
func (s *Schema) WithMaxProperties(max int64) *Schema {}

// WithMinProperties sets the min number of properties an object must have
func (s *Schema) WithMinProperties(min int64) *Schema {}

// Typed sets the type of this schema for a single value item
func (s *Schema) Typed(tpe, format string) *Schema {}

// AddType adds a type with potential format to the types for this schema
func (s *Schema) AddType(tpe, format string) *Schema {}

// AsNullable flags this schema as nullable.
func (s *Schema) AsNullable() *Schema {}

// CollectionOf a fluent builder method for an array parameter
func (s *Schema) CollectionOf(items Schema) *Schema {}

// WithDefault sets the default value on this parameter
func (s *Schema) WithDefault(defaultValue interface{}

// WithRequired flags this parameter as required
func (s *Schema) WithRequired(items ...string) *Schema {}

// AddRequired  adds field names to the required properties array
func (s *Schema) AddRequired(items ...string) *Schema {}

// WithMaxLength sets a max length value
func (s *Schema) WithMaxLength(max int64) *Schema {}

// WithMinLength sets a min length value
func (s *Schema) WithMinLength(min int64) *Schema {}

// WithPattern sets a pattern value
func (s *Schema) WithPattern(pattern string) *Schema {}

// WithMultipleOf sets a multiple of value
func (s *Schema) WithMultipleOf(number float64) *Schema {}

// WithMaximum sets a maximum number value
func (s *Schema) WithMaximum(max float64, exclusive bool) *Schema {}

// WithMinimum sets a minimum number value
func (s *Schema) WithMinimum(min float64, exclusive bool) *Schema {}

// WithEnum sets a the enum values (replace)
func (s *Schema) WithEnum(values ...interface{}

// WithMaxItems sets the max items
func (s *Schema) WithMaxItems(size int64) *Schema {}

// WithMinItems sets the min items
func (s *Schema) WithMinItems(size int64) *Schema {}

// UniqueValues dictates that this array can only have unique items
func (s *Schema) UniqueValues() *Schema {}

// AllowDuplicates this array can have duplicates
func (s *Schema) AllowDuplicates() *Schema {}

// AddToAllOf adds a schema to the allOf property
func (s *Schema) AddToAllOf(schemas ...Schema) *Schema {}

// WithDiscriminator sets the name of the discriminator field
func (s *Schema) WithDiscriminator(discriminator string) *Schema {}

// AsReadOnly flags this schema as readonly
func (s *Schema) AsReadOnly() *Schema {}

// AsWritable flags this schema as writeable (not read-only)
func (s *Schema) AsWritable() *Schema {}

// WithExample sets the example for this schema
func (s *Schema) WithExample(example interface{}

// WithExternalDocs sets/removes the external docs for/from this schema.
// When you pass empty strings as params the external documents will be removed.
// When you pass non-empty string as one value then those values will be used on the external docs object.
// So when you pass a non-empty description, you should also pass the url and vice versa.
func (s *Schema) WithExternalDocs(description, url string) *Schema {}

// MarshalJSON marshal this to JSON
func (s Schema) MarshalJSON() ([]byte, error) {}

func (s Schema) MarshalNextJSON(opts jsonv2.MarshalOptions, enc *jsonv2.Encoder) error {}

// UnmarshalJSON marshal this from JSON
func (s *Schema) UnmarshalJSON(data []byte) error {}

func (s *Schema) UnmarshalNextJSON(opts jsonv2.UnmarshalOptions, dec *jsonv2.Decoder) error {}