Documentation ¶
Overview ¶
Code generated by ogen, DO NOT EDIT.
Index ¶
- func WithServerURL(ctx context.Context, u *url.URL) context.Context
- type Client
- func (c *Client) NullableStrings(ctx context.Context, request NilString) error
- func (c *Client) ObjectsWithConflictingArrayProperty(ctx context.Context, request *ObjectsWithConflictingArrayPropertyReq) error
- func (c *Client) ObjectsWithConflictingProperties(ctx context.Context, request *ObjectsWithConflictingPropertiesReq) error
- func (c *Client) ReferencedAllof(ctx context.Context, request ReferencedAllofReq) error
- func (c *Client) ReferencedAllofOptional(ctx context.Context, request ReferencedAllofOptionalReq) error
- func (c *Client) SimpleInteger(ctx context.Context, request int) error
- func (c *Client) SimpleObjects(ctx context.Context, request *SimpleObjectsReq) error
- func (c *Client) StringsNotype(ctx context.Context, request NilString) error
- type ClientOption
- type ErrorHandler
- type Handler
- type Invoker
- type Location
- func (s *Location) Decode(d *jx.Decoder) error
- func (s *Location) Encode(e *jx.Encoder)
- func (s *Location) GetLat() float64
- func (s *Location) GetLon() float64
- func (s *Location) MarshalJSON() ([]byte, error)
- func (s *Location) SetFake()
- func (s *Location) SetLat(val float64)
- func (s *Location) SetLon(val float64)
- func (s *Location) UnmarshalJSON(data []byte) error
- func (s *Location) Validate() error
- type Middleware
- type NilString
- func (o *NilString) Decode(d *jx.Decoder) error
- func (o NilString) Encode(e *jx.Encoder)
- func (o NilString) Get() (v string, ok bool)
- func (o NilString) IsNull() bool
- func (s NilString) MarshalJSON() ([]byte, error)
- func (o NilString) Or(d string) string
- func (s *NilString) SetFake()
- func (o *NilString) SetTo(v string)
- func (o *NilString) SetToNull()
- func (s *NilString) UnmarshalJSON(data []byte) error
- type NullableStringsOK
- type ObjectsWithConflictingArrayPropertyOK
- type ObjectsWithConflictingArrayPropertyReq
- func (s *ObjectsWithConflictingArrayPropertyReq) Decode(d *jx.Decoder) error
- func (s *ObjectsWithConflictingArrayPropertyReq) Encode(e *jx.Encoder)
- func (s *ObjectsWithConflictingArrayPropertyReq) GetBar() int
- func (s *ObjectsWithConflictingArrayPropertyReq) GetFoo() []int
- func (s *ObjectsWithConflictingArrayPropertyReq) MarshalJSON() ([]byte, error)
- func (s *ObjectsWithConflictingArrayPropertyReq) SetBar(val int)
- func (s *ObjectsWithConflictingArrayPropertyReq) SetFake()
- func (s *ObjectsWithConflictingArrayPropertyReq) SetFoo(val []int)
- func (s *ObjectsWithConflictingArrayPropertyReq) UnmarshalJSON(data []byte) error
- func (s *ObjectsWithConflictingArrayPropertyReq) Validate() error
- type ObjectsWithConflictingPropertiesOK
- type ObjectsWithConflictingPropertiesReq
- func (s *ObjectsWithConflictingPropertiesReq) Decode(d *jx.Decoder) error
- func (s *ObjectsWithConflictingPropertiesReq) Encode(e *jx.Encoder)
- func (s *ObjectsWithConflictingPropertiesReq) GetBar() OptInt
- func (s *ObjectsWithConflictingPropertiesReq) GetFoo() string
- func (s *ObjectsWithConflictingPropertiesReq) MarshalJSON() ([]byte, error)
- func (s *ObjectsWithConflictingPropertiesReq) SetBar(val OptInt)
- func (s *ObjectsWithConflictingPropertiesReq) SetFake()
- func (s *ObjectsWithConflictingPropertiesReq) SetFoo(val string)
- func (s *ObjectsWithConflictingPropertiesReq) UnmarshalJSON(data []byte) error
- func (s *ObjectsWithConflictingPropertiesReq) Validate() error
- type OptBool
- func (o *OptBool) Decode(d *jx.Decoder) error
- func (o OptBool) Encode(e *jx.Encoder)
- func (o OptBool) Get() (v bool, ok bool)
- func (o OptBool) IsSet() bool
- func (s OptBool) MarshalJSON() ([]byte, error)
- func (o OptBool) Or(d bool) bool
- func (o *OptBool) Reset()
- func (s *OptBool) SetFake()
- func (o *OptBool) SetTo(v bool)
- func (s *OptBool) UnmarshalJSON(data []byte) error
- type OptInt
- func (o *OptInt) Decode(d *jx.Decoder) error
- func (o OptInt) Encode(e *jx.Encoder)
- func (o OptInt) Get() (v int, ok bool)
- func (o OptInt) IsSet() bool
- func (s OptInt) MarshalJSON() ([]byte, error)
- func (o OptInt) Or(d int) int
- func (o *OptInt) Reset()
- func (s *OptInt) SetFake()
- func (o *OptInt) SetTo(v int)
- func (s *OptInt) UnmarshalJSON(data []byte) error
- type OptString
- func (o *OptString) Decode(d *jx.Decoder) error
- func (o OptString) Encode(e *jx.Encoder)
- func (o OptString) Get() (v string, ok bool)
- func (o OptString) IsSet() bool
- func (s OptString) MarshalJSON() ([]byte, error)
- func (o OptString) Or(d string) string
- func (o *OptString) Reset()
- func (s *OptString) SetFake()
- func (o *OptString) SetTo(v string)
- func (s *OptString) UnmarshalJSON(data []byte) error
- type Option
- type ReferencedAllofOK
- type ReferencedAllofOptionalOK
- type ReferencedAllofOptionalReq
- type ReferencedAllofOptionalReqEmptyBody
- type ReferencedAllofReq
- type Robot
- func (s *Robot) Decode(d *jx.Decoder) error
- func (s *Robot) Encode(e *jx.Encoder)
- func (s *Robot) GetID() uuid.UUID
- func (s *Robot) GetLocation() Location
- func (s *Robot) GetState() RobotState
- func (s *Robot) MarshalJSON() ([]byte, error)
- func (s *Robot) SetFake()
- func (s *Robot) SetID(val uuid.UUID)
- func (s *Robot) SetLocation(val Location)
- func (s *Robot) SetState(val RobotState)
- func (s *Robot) UnmarshalJSON(data []byte) error
- func (s *Robot) Validate() error
- type RobotMultipart
- func (s *RobotMultipart) GetID() uuid.UUID
- func (s *RobotMultipart) GetLocation() Location
- func (s *RobotMultipart) GetState() RobotMultipartState
- func (s *RobotMultipart) SetID(val uuid.UUID)
- func (s *RobotMultipart) SetLocation(val Location)
- func (s *RobotMultipart) SetState(val RobotMultipartState)
- func (s *RobotMultipart) Validate() error
- type RobotMultipartState
- type RobotState
- func (RobotState) AllValues() []RobotState
- func (s *RobotState) Decode(d *jx.Decoder) error
- func (s RobotState) Encode(e *jx.Encoder)
- func (s RobotState) MarshalJSON() ([]byte, error)
- func (s RobotState) MarshalText() ([]byte, error)
- func (s *RobotState) SetFake()
- func (s *RobotState) UnmarshalJSON(data []byte) error
- func (s *RobotState) UnmarshalText(data []byte) error
- func (s RobotState) Validate() error
- type Route
- type Server
- type ServerOption
- func WithErrorHandler(h ErrorHandler) ServerOption
- func WithMaxMultipartMemory(max int64) ServerOption
- func WithMethodNotAllowed(methodNotAllowed func(w http.ResponseWriter, r *http.Request, allowed string)) ServerOption
- func WithMiddleware(m ...Middleware) ServerOption
- func WithNotFound(notFound http.HandlerFunc) ServerOption
- func WithPathPrefix(prefix string) ServerOption
- type SimpleIntegerOK
- type SimpleObjectsOK
- type SimpleObjectsReq
- func (s *SimpleObjectsReq) Decode(d *jx.Decoder) error
- func (s *SimpleObjectsReq) Encode(e *jx.Encoder)
- func (s *SimpleObjectsReq) GetBar() OptBool
- func (s *SimpleObjectsReq) GetFoo() OptString
- func (s *SimpleObjectsReq) MarshalJSON() ([]byte, error)
- func (s *SimpleObjectsReq) SetBar(val OptBool)
- func (s *SimpleObjectsReq) SetFake()
- func (s *SimpleObjectsReq) SetFoo(val OptString)
- func (s *SimpleObjectsReq) UnmarshalJSON(data []byte) error
- type StringsNotypeOK
- type UnimplementedHandler
- func (UnimplementedHandler) NullableStrings(ctx context.Context, req NilString) error
- func (UnimplementedHandler) ObjectsWithConflictingArrayProperty(ctx context.Context, req *ObjectsWithConflictingArrayPropertyReq) error
- func (UnimplementedHandler) ObjectsWithConflictingProperties(ctx context.Context, req *ObjectsWithConflictingPropertiesReq) error
- func (UnimplementedHandler) ReferencedAllof(ctx context.Context, req ReferencedAllofReq) error
- func (UnimplementedHandler) ReferencedAllofOptional(ctx context.Context, req ReferencedAllofOptionalReq) error
- func (UnimplementedHandler) SimpleInteger(ctx context.Context, req int) error
- func (UnimplementedHandler) SimpleObjects(ctx context.Context, req *SimpleObjectsReq) error
- func (UnimplementedHandler) StringsNotype(ctx context.Context, req NilString) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client implements OAS client.
func NewClient ¶
func NewClient(serverURL string, opts ...ClientOption) (*Client, error)
NewClient initializes new Client defined by OAS.
func (*Client) NullableStrings ¶
NullableStrings invokes nullableStrings operation.
Nullable strings.
POST /nullableStrings
func (*Client) ObjectsWithConflictingArrayProperty ¶
func (c *Client) ObjectsWithConflictingArrayProperty(ctx context.Context, request *ObjectsWithConflictingArrayPropertyReq) error
ObjectsWithConflictingArrayProperty invokes objectsWithConflictingArrayProperty operation.
Objects with conflicting array property.
POST /objectsWithConflictingArrayProperty
func (*Client) ObjectsWithConflictingProperties ¶
func (c *Client) ObjectsWithConflictingProperties(ctx context.Context, request *ObjectsWithConflictingPropertiesReq) error
ObjectsWithConflictingProperties invokes objectsWithConflictingProperties operation.
Objects with conflicting properties.
POST /objectsWithConflictingProperties
func (*Client) ReferencedAllof ¶
func (c *Client) ReferencedAllof(ctx context.Context, request ReferencedAllofReq) error
ReferencedAllof invokes referencedAllof operation.
Referenced allOf.
POST /referencedAllof
func (*Client) ReferencedAllofOptional ¶
func (c *Client) ReferencedAllofOptional(ctx context.Context, request ReferencedAllofOptionalReq) error
ReferencedAllofOptional invokes referencedAllofOptional operation.
Referenced allOf, but requestBody is not required.
POST /referencedAllofOptional
func (*Client) SimpleInteger ¶
SimpleInteger invokes simpleInteger operation.
Simple integers with validation.
POST /simpleInteger
func (*Client) SimpleObjects ¶
func (c *Client) SimpleObjects(ctx context.Context, request *SimpleObjectsReq) error
SimpleObjects invokes simpleObjects operation.
Simple objects.
POST /simpleObjects
type ClientOption ¶ added in v0.55.0
type ClientOption interface {
// contains filtered or unexported methods
}
ClientOption is client config option.
func WithClient ¶
func WithClient(client ht.Client) ClientOption
WithClient specifies http client to use.
type Handler ¶
type Handler interface { // NullableStrings implements nullableStrings operation. // // Nullable strings. // // POST /nullableStrings NullableStrings(ctx context.Context, req NilString) error // ObjectsWithConflictingArrayProperty implements objectsWithConflictingArrayProperty operation. // // Objects with conflicting array property. // // POST /objectsWithConflictingArrayProperty ObjectsWithConflictingArrayProperty(ctx context.Context, req *ObjectsWithConflictingArrayPropertyReq) error // ObjectsWithConflictingProperties implements objectsWithConflictingProperties operation. // // Objects with conflicting properties. // // POST /objectsWithConflictingProperties ObjectsWithConflictingProperties(ctx context.Context, req *ObjectsWithConflictingPropertiesReq) error // ReferencedAllof implements referencedAllof operation. // // Referenced allOf. // // POST /referencedAllof ReferencedAllof(ctx context.Context, req ReferencedAllofReq) error // ReferencedAllofOptional implements referencedAllofOptional operation. // // Referenced allOf, but requestBody is not required. // // POST /referencedAllofOptional ReferencedAllofOptional(ctx context.Context, req ReferencedAllofOptionalReq) error // SimpleInteger implements simpleInteger operation. // // Simple integers with validation. // // POST /simpleInteger SimpleInteger(ctx context.Context, req int) error // SimpleObjects implements simpleObjects operation. // // Simple objects. // // POST /simpleObjects SimpleObjects(ctx context.Context, req *SimpleObjectsReq) error // StringsNotype implements stringsNotype operation. // // POST /stringsNotype StringsNotype(ctx context.Context, req NilString) error }
Handler handles operations described by OpenAPI v3 specification.
type Invoker ¶ added in v0.75.0
type Invoker interface { // NullableStrings invokes nullableStrings operation. // // Nullable strings. // // POST /nullableStrings NullableStrings(ctx context.Context, request NilString) error // ObjectsWithConflictingArrayProperty invokes objectsWithConflictingArrayProperty operation. // // Objects with conflicting array property. // // POST /objectsWithConflictingArrayProperty ObjectsWithConflictingArrayProperty(ctx context.Context, request *ObjectsWithConflictingArrayPropertyReq) error // ObjectsWithConflictingProperties invokes objectsWithConflictingProperties operation. // // Objects with conflicting properties. // // POST /objectsWithConflictingProperties ObjectsWithConflictingProperties(ctx context.Context, request *ObjectsWithConflictingPropertiesReq) error // ReferencedAllof invokes referencedAllof operation. // // Referenced allOf. // // POST /referencedAllof ReferencedAllof(ctx context.Context, request ReferencedAllofReq) error // ReferencedAllofOptional invokes referencedAllofOptional operation. // // Referenced allOf, but requestBody is not required. // // POST /referencedAllofOptional ReferencedAllofOptional(ctx context.Context, request ReferencedAllofOptionalReq) error // SimpleInteger invokes simpleInteger operation. // // Simple integers with validation. // // POST /simpleInteger SimpleInteger(ctx context.Context, request int) error // SimpleObjects invokes simpleObjects operation. // // Simple objects. // // POST /simpleObjects SimpleObjects(ctx context.Context, request *SimpleObjectsReq) error // StringsNotype invokes stringsNotype operation. // // POST /stringsNotype StringsNotype(ctx context.Context, request NilString) error }
Invoker invokes operations described by OpenAPI v3 specification.
type Location ¶
Ref: #/components/schemas/Location
func (*Location) MarshalJSON ¶
MarshalJSON implements stdjson.Marshaler.
func (*Location) UnmarshalJSON ¶
UnmarshalJSON implements stdjson.Unmarshaler.
type NilString ¶ added in v0.54.0
NilString is nullable string.
func NewNilString ¶ added in v0.54.0
NewNilString returns new NilString with value set to v.
func (NilString) Get ¶ added in v0.54.0
Get returns value and boolean that denotes whether value was set.
func (NilString) MarshalJSON ¶ added in v0.54.0
MarshalJSON implements stdjson.Marshaler.
func (*NilString) SetToNull ¶ added in v0.62.0
func (o *NilString) SetToNull()
SetNull sets value to null.
func (*NilString) UnmarshalJSON ¶ added in v0.54.0
UnmarshalJSON implements stdjson.Unmarshaler.
type NullableStringsOK ¶
type NullableStringsOK struct{}
NullableStringsOK is response for NullableStrings operation.
type ObjectsWithConflictingArrayPropertyOK ¶
type ObjectsWithConflictingArrayPropertyOK struct{}
ObjectsWithConflictingArrayPropertyOK is response for ObjectsWithConflictingArrayProperty operation.
type ObjectsWithConflictingArrayPropertyReq ¶
type ObjectsWithConflictingArrayPropertyReq struct { // Merged property. Foo []int `json:"foo"` Bar int `json:"bar"` }
Merged schema.
func (*ObjectsWithConflictingArrayPropertyReq) Decode ¶
func (s *ObjectsWithConflictingArrayPropertyReq) Decode(d *jx.Decoder) error
Decode decodes ObjectsWithConflictingArrayPropertyReq from json.
func (*ObjectsWithConflictingArrayPropertyReq) Encode ¶
func (s *ObjectsWithConflictingArrayPropertyReq) Encode(e *jx.Encoder)
Encode implements json.Marshaler.
func (*ObjectsWithConflictingArrayPropertyReq) GetBar ¶
func (s *ObjectsWithConflictingArrayPropertyReq) GetBar() int
GetBar returns the value of Bar.
func (*ObjectsWithConflictingArrayPropertyReq) GetFoo ¶
func (s *ObjectsWithConflictingArrayPropertyReq) GetFoo() []int
GetFoo returns the value of Foo.
func (*ObjectsWithConflictingArrayPropertyReq) MarshalJSON ¶
func (s *ObjectsWithConflictingArrayPropertyReq) MarshalJSON() ([]byte, error)
MarshalJSON implements stdjson.Marshaler.
func (*ObjectsWithConflictingArrayPropertyReq) SetBar ¶
func (s *ObjectsWithConflictingArrayPropertyReq) SetBar(val int)
SetBar sets the value of Bar.
func (*ObjectsWithConflictingArrayPropertyReq) SetFake ¶
func (s *ObjectsWithConflictingArrayPropertyReq) SetFake()
SetFake set fake values.
func (*ObjectsWithConflictingArrayPropertyReq) SetFoo ¶
func (s *ObjectsWithConflictingArrayPropertyReq) SetFoo(val []int)
SetFoo sets the value of Foo.
func (*ObjectsWithConflictingArrayPropertyReq) UnmarshalJSON ¶
func (s *ObjectsWithConflictingArrayPropertyReq) UnmarshalJSON(data []byte) error
UnmarshalJSON implements stdjson.Unmarshaler.
func (*ObjectsWithConflictingArrayPropertyReq) Validate ¶
func (s *ObjectsWithConflictingArrayPropertyReq) Validate() error
type ObjectsWithConflictingPropertiesOK ¶
type ObjectsWithConflictingPropertiesOK struct{}
ObjectsWithConflictingPropertiesOK is response for ObjectsWithConflictingProperties operation.
type ObjectsWithConflictingPropertiesReq ¶
type ObjectsWithConflictingPropertiesReq struct { // Merged property. Foo string `json:"foo"` Bar OptInt `json:"bar"` }
Merged schema.
func (*ObjectsWithConflictingPropertiesReq) Decode ¶
func (s *ObjectsWithConflictingPropertiesReq) Decode(d *jx.Decoder) error
Decode decodes ObjectsWithConflictingPropertiesReq from json.
func (*ObjectsWithConflictingPropertiesReq) Encode ¶
func (s *ObjectsWithConflictingPropertiesReq) Encode(e *jx.Encoder)
Encode implements json.Marshaler.
func (*ObjectsWithConflictingPropertiesReq) GetBar ¶
func (s *ObjectsWithConflictingPropertiesReq) GetBar() OptInt
GetBar returns the value of Bar.
func (*ObjectsWithConflictingPropertiesReq) GetFoo ¶
func (s *ObjectsWithConflictingPropertiesReq) GetFoo() string
GetFoo returns the value of Foo.
func (*ObjectsWithConflictingPropertiesReq) MarshalJSON ¶
func (s *ObjectsWithConflictingPropertiesReq) MarshalJSON() ([]byte, error)
MarshalJSON implements stdjson.Marshaler.
func (*ObjectsWithConflictingPropertiesReq) SetBar ¶
func (s *ObjectsWithConflictingPropertiesReq) SetBar(val OptInt)
SetBar sets the value of Bar.
func (*ObjectsWithConflictingPropertiesReq) SetFake ¶
func (s *ObjectsWithConflictingPropertiesReq) SetFake()
SetFake set fake values.
func (*ObjectsWithConflictingPropertiesReq) SetFoo ¶
func (s *ObjectsWithConflictingPropertiesReq) SetFoo(val string)
SetFoo sets the value of Foo.
func (*ObjectsWithConflictingPropertiesReq) UnmarshalJSON ¶
func (s *ObjectsWithConflictingPropertiesReq) UnmarshalJSON(data []byte) error
UnmarshalJSON implements stdjson.Unmarshaler.
func (*ObjectsWithConflictingPropertiesReq) Validate ¶
func (s *ObjectsWithConflictingPropertiesReq) Validate() error
type OptBool ¶
OptBool is optional bool.
func NewOptBool ¶
NewOptBool returns new OptBool with value set to v.
func (OptBool) MarshalJSON ¶
MarshalJSON implements stdjson.Marshaler.
func (*OptBool) UnmarshalJSON ¶
UnmarshalJSON implements stdjson.Unmarshaler.
type OptInt ¶
OptInt is optional int.
func (OptInt) MarshalJSON ¶
MarshalJSON implements stdjson.Marshaler.
func (*OptInt) UnmarshalJSON ¶
UnmarshalJSON implements stdjson.Unmarshaler.
type OptString ¶
OptString is optional string.
func NewOptString ¶
NewOptString returns new OptString with value set to v.
func (OptString) MarshalJSON ¶
MarshalJSON implements stdjson.Marshaler.
func (*OptString) UnmarshalJSON ¶
UnmarshalJSON implements stdjson.Unmarshaler.
type Option ¶
type Option interface { ServerOption ClientOption }
Option is config option.
func WithMeterProvider ¶
func WithMeterProvider(provider metric.MeterProvider) Option
WithMeterProvider specifies a meter provider to use for creating a meter.
If none is specified, the otel.GetMeterProvider() is used.
func WithTracerProvider ¶
func WithTracerProvider(provider trace.TracerProvider) Option
WithTracerProvider specifies a tracer provider to use for creating a tracer.
If none is specified, the global provider is used.
type ReferencedAllofOK ¶
type ReferencedAllofOK struct{}
ReferencedAllofOK is response for ReferencedAllof operation.
type ReferencedAllofOptionalOK ¶
type ReferencedAllofOptionalOK struct{}
ReferencedAllofOptionalOK is response for ReferencedAllofOptional operation.
type ReferencedAllofOptionalReq ¶
type ReferencedAllofOptionalReq interface {
// contains filtered or unexported methods
}
type ReferencedAllofOptionalReqEmptyBody ¶
type ReferencedAllofOptionalReqEmptyBody struct{}
type ReferencedAllofReq ¶
type ReferencedAllofReq interface {
// contains filtered or unexported methods
}
type Robot ¶
type Robot struct { State RobotState `json:"state"` ID uuid.UUID `json:"id"` Location Location `json:"location"` }
Merged schema. Ref: #/components/schemas/Robot
func (*Robot) GetLocation ¶
GetLocation returns the value of Location.
func (*Robot) MarshalJSON ¶
MarshalJSON implements stdjson.Marshaler.
func (*Robot) SetLocation ¶
SetLocation sets the value of Location.
func (*Robot) UnmarshalJSON ¶
UnmarshalJSON implements stdjson.Unmarshaler.
type RobotMultipart ¶ added in v0.64.0
type RobotMultipart struct { State RobotMultipartState `json:"state"` ID uuid.UUID `json:"id"` Location Location `json:"location"` }
Merged schema. Ref: #/components/schemas/Robot
func (*RobotMultipart) GetID ¶ added in v0.64.0
func (s *RobotMultipart) GetID() uuid.UUID
GetID returns the value of ID.
func (*RobotMultipart) GetLocation ¶ added in v0.64.0
func (s *RobotMultipart) GetLocation() Location
GetLocation returns the value of Location.
func (*RobotMultipart) GetState ¶ added in v0.64.0
func (s *RobotMultipart) GetState() RobotMultipartState
GetState returns the value of State.
func (*RobotMultipart) SetID ¶ added in v0.64.0
func (s *RobotMultipart) SetID(val uuid.UUID)
SetID sets the value of ID.
func (*RobotMultipart) SetLocation ¶ added in v0.64.0
func (s *RobotMultipart) SetLocation(val Location)
SetLocation sets the value of Location.
func (*RobotMultipart) SetState ¶ added in v0.64.0
func (s *RobotMultipart) SetState(val RobotMultipartState)
SetState sets the value of State.
func (*RobotMultipart) Validate ¶ added in v0.64.0
func (s *RobotMultipart) Validate() error
type RobotMultipartState ¶ added in v0.64.0
type RobotMultipartState string
const ( RobotMultipartStateOn RobotMultipartState = "on" RobotMultipartStateOff RobotMultipartState = "off" )
func (RobotMultipartState) AllValues ¶ added in v0.74.0
func (RobotMultipartState) AllValues() []RobotMultipartState
AllValues returns all RobotMultipartState values.
func (RobotMultipartState) MarshalText ¶ added in v0.64.0
func (s RobotMultipartState) MarshalText() ([]byte, error)
MarshalText implements encoding.TextMarshaler.
func (*RobotMultipartState) UnmarshalText ¶ added in v0.64.0
func (s *RobotMultipartState) UnmarshalText(data []byte) error
UnmarshalText implements encoding.TextUnmarshaler.
func (RobotMultipartState) Validate ¶ added in v0.64.0
func (s RobotMultipartState) Validate() error
type RobotState ¶
type RobotState string
const ( RobotStateOn RobotState = "on" RobotStateOff RobotState = "off" )
func (RobotState) AllValues ¶ added in v0.74.0
func (RobotState) AllValues() []RobotState
AllValues returns all RobotState values.
func (*RobotState) Decode ¶
func (s *RobotState) Decode(d *jx.Decoder) error
Decode decodes RobotState from json.
func (RobotState) Encode ¶
func (s RobotState) Encode(e *jx.Encoder)
Encode encodes RobotState as json.
func (RobotState) MarshalJSON ¶
func (s RobotState) MarshalJSON() ([]byte, error)
MarshalJSON implements stdjson.Marshaler.
func (RobotState) MarshalText ¶ added in v0.56.0
func (s RobotState) MarshalText() ([]byte, error)
MarshalText implements encoding.TextMarshaler.
func (*RobotState) UnmarshalJSON ¶
func (s *RobotState) UnmarshalJSON(data []byte) error
UnmarshalJSON implements stdjson.Unmarshaler.
func (*RobotState) UnmarshalText ¶ added in v0.56.0
func (s *RobotState) UnmarshalText(data []byte) error
UnmarshalText implements encoding.TextUnmarshaler.
func (RobotState) Validate ¶
func (s RobotState) Validate() error
type Route ¶
type Route struct {
// contains filtered or unexported fields
}
Route is route object.
func (Route) OperationID ¶
OperationID returns OpenAPI operationId.
func (Route) PathPattern ¶ added in v0.58.0
PathPattern returns OpenAPI path.
type Server ¶
type Server struct {
// contains filtered or unexported fields
}
Server implements http server based on OpenAPI v3 specification and calls Handler to handle requests.
func NewServer ¶
func NewServer(h Handler, opts ...ServerOption) (*Server, error)
NewServer creates new Server.
type ServerOption ¶ added in v0.55.0
type ServerOption interface {
// contains filtered or unexported methods
}
ServerOption is server config option.
func WithErrorHandler ¶
func WithErrorHandler(h ErrorHandler) ServerOption
WithErrorHandler specifies error handler to use.
func WithMaxMultipartMemory ¶
func WithMaxMultipartMemory(max int64) ServerOption
WithMaxMultipartMemory specifies limit of memory for storing file parts. File parts which can't be stored in memory will be stored on disk in temporary files.
func WithMethodNotAllowed ¶
func WithMethodNotAllowed(methodNotAllowed func(w http.ResponseWriter, r *http.Request, allowed string)) ServerOption
WithMethodNotAllowed specifies Method Not Allowed handler to use.
func WithMiddleware ¶
func WithMiddleware(m ...Middleware) ServerOption
WithMiddleware specifies middlewares to use.
func WithNotFound ¶
func WithNotFound(notFound http.HandlerFunc) ServerOption
WithNotFound specifies Not Found handler to use.
func WithPathPrefix ¶
func WithPathPrefix(prefix string) ServerOption
WithPathPrefix specifies server path prefix.
type SimpleIntegerOK ¶
type SimpleIntegerOK struct{}
SimpleIntegerOK is response for SimpleInteger operation.
type SimpleObjectsOK ¶
type SimpleObjectsOK struct{}
SimpleObjectsOK is response for SimpleObjects operation.
type SimpleObjectsReq ¶
Merged schema.
func (*SimpleObjectsReq) Decode ¶
func (s *SimpleObjectsReq) Decode(d *jx.Decoder) error
Decode decodes SimpleObjectsReq from json.
func (*SimpleObjectsReq) Encode ¶
func (s *SimpleObjectsReq) Encode(e *jx.Encoder)
Encode implements json.Marshaler.
func (*SimpleObjectsReq) GetBar ¶
func (s *SimpleObjectsReq) GetBar() OptBool
GetBar returns the value of Bar.
func (*SimpleObjectsReq) GetFoo ¶
func (s *SimpleObjectsReq) GetFoo() OptString
GetFoo returns the value of Foo.
func (*SimpleObjectsReq) MarshalJSON ¶
func (s *SimpleObjectsReq) MarshalJSON() ([]byte, error)
MarshalJSON implements stdjson.Marshaler.
func (*SimpleObjectsReq) SetBar ¶
func (s *SimpleObjectsReq) SetBar(val OptBool)
SetBar sets the value of Bar.
func (*SimpleObjectsReq) SetFoo ¶
func (s *SimpleObjectsReq) SetFoo(val OptString)
SetFoo sets the value of Foo.
func (*SimpleObjectsReq) UnmarshalJSON ¶
func (s *SimpleObjectsReq) UnmarshalJSON(data []byte) error
UnmarshalJSON implements stdjson.Unmarshaler.
type StringsNotypeOK ¶ added in v0.57.0
type StringsNotypeOK struct{}
StringsNotypeOK is response for StringsNotype operation.
type UnimplementedHandler ¶
type UnimplementedHandler struct{}
UnimplementedHandler is no-op Handler which returns http.ErrNotImplemented.
func (UnimplementedHandler) NullableStrings ¶
func (UnimplementedHandler) NullableStrings(ctx context.Context, req NilString) error
NullableStrings implements nullableStrings operation.
Nullable strings.
POST /nullableStrings
func (UnimplementedHandler) ObjectsWithConflictingArrayProperty ¶
func (UnimplementedHandler) ObjectsWithConflictingArrayProperty(ctx context.Context, req *ObjectsWithConflictingArrayPropertyReq) error
ObjectsWithConflictingArrayProperty implements objectsWithConflictingArrayProperty operation.
Objects with conflicting array property.
POST /objectsWithConflictingArrayProperty
func (UnimplementedHandler) ObjectsWithConflictingProperties ¶
func (UnimplementedHandler) ObjectsWithConflictingProperties(ctx context.Context, req *ObjectsWithConflictingPropertiesReq) error
ObjectsWithConflictingProperties implements objectsWithConflictingProperties operation.
Objects with conflicting properties.
POST /objectsWithConflictingProperties
func (UnimplementedHandler) ReferencedAllof ¶
func (UnimplementedHandler) ReferencedAllof(ctx context.Context, req ReferencedAllofReq) error
ReferencedAllof implements referencedAllof operation.
Referenced allOf.
POST /referencedAllof
func (UnimplementedHandler) ReferencedAllofOptional ¶
func (UnimplementedHandler) ReferencedAllofOptional(ctx context.Context, req ReferencedAllofOptionalReq) error
ReferencedAllofOptional implements referencedAllofOptional operation.
Referenced allOf, but requestBody is not required.
POST /referencedAllofOptional
func (UnimplementedHandler) SimpleInteger ¶
func (UnimplementedHandler) SimpleInteger(ctx context.Context, req int) error
SimpleInteger implements simpleInteger operation.
Simple integers with validation.
POST /simpleInteger
func (UnimplementedHandler) SimpleObjects ¶
func (UnimplementedHandler) SimpleObjects(ctx context.Context, req *SimpleObjectsReq) error
SimpleObjects implements simpleObjects operation.
Simple objects.
POST /simpleObjects
func (UnimplementedHandler) StringsNotype ¶ added in v0.57.0
func (UnimplementedHandler) StringsNotype(ctx context.Context, req NilString) error
StringsNotype implements stringsNotype operation.
POST /stringsNotype
Source Files ¶
- oas_cfg_gen.go
- oas_client_gen.go
- oas_faker_gen.go
- oas_handlers_gen.go
- oas_interfaces_gen.go
- oas_json_gen.go
- oas_middleware_gen.go
- oas_request_decoders_gen.go
- oas_request_encoders_gen.go
- oas_response_decoders_gen.go
- oas_response_encoders_gen.go
- oas_router_gen.go
- oas_schemas_gen.go
- oas_server_gen.go
- oas_unimplemented_gen.go
- oas_validators_gen.go