-
Notifications
You must be signed in to change notification settings - Fork 72
/
oas_server_gen.go
48 lines (43 loc) · 1.15 KB
/
oas_server_gen.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
// Code generated by ogen, DO NOT EDIT.
package api
import (
"context"
)
// Handler handles operations described by OpenAPI v3 specification.
type Handler interface {
// CustomSecurity implements customSecurity operation.
//
// GET /customSecurity
CustomSecurity(ctx context.Context) error
// DisjointSecurity implements disjointSecurity operation.
//
// GET /disjointSecurity
DisjointSecurity(ctx context.Context) error
// IntersectSecurity implements intersectSecurity operation.
//
// GET /intersectSecurity
IntersectSecurity(ctx context.Context) error
// OptionalSecurity implements optionalSecurity operation.
//
// GET /optionalSecurity
OptionalSecurity(ctx context.Context) error
}
// Server implements http server based on OpenAPI v3 specification and
// calls Handler to handle requests.
type Server struct {
h Handler
sec SecurityHandler
baseServer
}
// NewServer creates new Server.
func NewServer(h Handler, sec SecurityHandler, opts ...ServerOption) (*Server, error) {
s, err := newServerConfig(opts...).baseServer()
if err != nil {
return nil, err
}
return &Server{
h: h,
sec: sec,
baseServer: s,
}, nil
}