gilly/openapi/schema
Types
pub type ArraySchema {
ArraySchema(
min_items: option.Option(Int),
max_items: option.Option(Int),
items: Schema,
)
}
Constructors
-
ArraySchema( min_items: option.Option(Int), max_items: option.Option(Int), items: Schema, )
pub type BaseSchema {
BaseSchema(
type_name: TypeName,
title: option.Option(String),
description: option.Option(String),
nullable: Bool,
)
}
Constructors
-
BaseSchema( type_name: TypeName, title: option.Option(String), description: option.Option(String), nullable: Bool, )
pub type IntegerSchema {
IntegerSchema(
minimum: option.Option(Int),
maximum: option.Option(Int),
format: option.Option(String),
)
}
Constructors
-
IntegerSchema( minimum: option.Option(Int), maximum: option.Option(Int), format: option.Option(String), )
pub type Schema {
Ref(ref: String)
String(BaseSchema, StringSchema)
Integer(BaseSchema, IntegerSchema)
Number(BaseSchema)
Array(BaseSchema, ArraySchema)
Object(BaseSchema, ObjectSchema)
Boolean(BaseSchema)
}
Constructors
-
Ref(ref: String) -
String(BaseSchema, StringSchema) -
Integer(BaseSchema, IntegerSchema) -
Number(BaseSchema) -
Array(BaseSchema, ArraySchema) -
Object(BaseSchema, ObjectSchema) -
Boolean(BaseSchema)
pub type StringSchema {
StringSchema(
min_length: option.Option(Int),
max_length: option.Option(Int),
enum: option.Option(List(String)),
format: option.Option(String),
)
}
Constructors
-
StringSchema( min_length: option.Option(Int), max_length: option.Option(Int), enum: option.Option(List(String)), format: option.Option(String), )
Values
pub fn schema_decoder() -> decode.Decoder(Schema)