Documentation ¶
Overview ¶
Code generated by sysl DO NOT EDIT.
Code generated by sysl DO NOT EDIT.
Code generated by sysl DO NOT EDIT.
Code generated by sysl DO NOT EDIT.
Code generated by sysl DO NOT EDIT.
Code generated by sysl DO NOT EDIT.
Index ¶
- Variables
- func NewServiceRouter(gc core.RestGenCallback, svcHandler *ServiceHandler) handlerinitialiser.HandlerInitialiser
- type Callback
- func (c Callback) AddMiddleware(ctx context.Context, r chi.Router)
- func (c Callback) BasePath() string
- func (c Callback) Config() validator.Validator
- func (c Callback) DownstreamTimeoutContext(ctx context.Context) (context.Context, context.CancelFunc)
- func (c Callback) MapError(ctx context.Context, cause error) *common.HTTPError
- type CallbackWithMapError
- type Client
- func (s *Client) GetApiDocsList(ctx context.Context, req *GetApiDocsListRequest) (*deps.ApiDoc, error)
- func (s *Client) GetJustOkAndJustErrorList(ctx context.Context, req *GetJustOkAndJustErrorListRequest) (*http.Header, error)
- func (s *Client) GetJustReturnErrorList(ctx context.Context, req *GetJustReturnErrorListRequest) error
- func (s *Client) GetJustReturnOkList(ctx context.Context, req *GetJustReturnOkListRequest) (*http.Header, error)
- func (s *Client) GetOkTypeAndJustErrorList(ctx context.Context, req *GetOkTypeAndJustErrorListRequest) (*Response, error)
- func (s *Client) GetOopsList(ctx context.Context, req *GetOopsListRequest) (*Response, error)
- func (s *Client) GetRawIntList(ctx context.Context, req *GetRawIntListRequest) (*Integer, error)
- func (s *Client) GetRawList(ctx context.Context, req *GetRawListRequest) (*Str, error)
- func (s *Client) GetStuffList(ctx context.Context, req *GetStuffListRequest) (*Stuff, error)
- func (s *Client) PostStuff(ctx context.Context, req *PostStuffRequest) (*Str, error)
- type Config
- type DefaultSimpleImpl
- type DownstreamConfig
- type Empty
- type GetApiDocsListClient
- type GetApiDocsListRequest
- type GetGetSomeBytesListClient
- type GetGetSomeBytesListRequest
- type GetJustOkAndJustErrorListClient
- type GetJustOkAndJustErrorListRequest
- type GetJustReturnErrorListClient
- type GetJustReturnErrorListRequest
- type GetJustReturnOkListClient
- type GetJustReturnOkListRequest
- type GetOkTypeAndJustErrorListClient
- type GetOkTypeAndJustErrorListRequest
- type GetOopsListClient
- type GetOopsListRequest
- type GetRawIntListClient
- type GetRawIntListRequest
- type GetRawListClient
- type GetRawListRequest
- type GetSimpleAPIDocsListClient
- type GetSimpleAPIDocsListRequest
- type GetStuffListClient
- type GetStuffListRequest
- type Handler
- type Integer
- type Item
- type ItemSet
- type Pdf
- type PostStuffClient
- type PostStuffRequest
- type Response
- type Router
- type Service
- type ServiceHandler
- func (s *ServiceHandler) GetApiDocsListHandler(w http.ResponseWriter, r *http.Request)
- func (s *ServiceHandler) GetGetSomeBytesListHandler(w http.ResponseWriter, r *http.Request)
- func (s *ServiceHandler) GetJustOkAndJustErrorListHandler(w http.ResponseWriter, r *http.Request)
- func (s *ServiceHandler) GetJustReturnErrorListHandler(w http.ResponseWriter, r *http.Request)
- func (s *ServiceHandler) GetJustReturnOkListHandler(w http.ResponseWriter, r *http.Request)
- func (s *ServiceHandler) GetOkTypeAndJustErrorListHandler(w http.ResponseWriter, r *http.Request)
- func (s *ServiceHandler) GetOopsListHandler(w http.ResponseWriter, r *http.Request)
- func (s *ServiceHandler) GetRawIntListHandler(w http.ResponseWriter, r *http.Request)
- func (s *ServiceHandler) GetRawListHandler(w http.ResponseWriter, r *http.Request)
- func (s *ServiceHandler) GetSimpleAPIDocsListHandler(w http.ResponseWriter, r *http.Request)
- func (s *ServiceHandler) GetStuffListHandler(w http.ResponseWriter, r *http.Request)
- func (s *ServiceHandler) PostStuffHandler(w http.ResponseWriter, r *http.Request)
- type ServiceInterface
- type ServiceRouter
- type Status
- type Str
- type Stuff
Constants ¶
This section is empty.
Variables ¶
var BusinessLogicError common.CustomError = map[string]string{"name": "BusinessLogicError", "http_code": "1001", "http_message": "foo", "http_status": "500"}
*BusinessLogicError error
var BusinessLogicError2 common.CustomError = map[string]string{"name": "BusinessLogicError2", "http_code": "1002", "http_message": "foo2", "http_status": "501"}
*BusinessLogicError2 error
Functions ¶
func NewServiceRouter ¶
func NewServiceRouter(gc core.RestGenCallback, svcHandler *ServiceHandler) handlerinitialiser.HandlerInitialiser
NewServiceRouter creates a new service router for Simple
Types ¶
type Callback ¶
type Callback struct {
// contains filtered or unexported fields
}
func (Callback) DownstreamTimeoutContext ¶
type CallbackWithMapError ¶ added in v0.5.0
type CallbackWithMapError struct{}
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client for Simple API
func (*Client) GetApiDocsList ¶
func (s *Client) GetApiDocsList(ctx context.Context, req *GetApiDocsListRequest) (*deps.ApiDoc, error)
GetApiDocsList ...
func (*Client) GetJustOkAndJustErrorList ¶
func (s *Client) GetJustOkAndJustErrorList(ctx context.Context, req *GetJustOkAndJustErrorListRequest) (*http.Header, error)
GetJustOkAndJustErrorList ...
func (*Client) GetJustReturnErrorList ¶
func (s *Client) GetJustReturnErrorList(ctx context.Context, req *GetJustReturnErrorListRequest) error
GetJustReturnErrorList ...
func (*Client) GetJustReturnOkList ¶
func (s *Client) GetJustReturnOkList(ctx context.Context, req *GetJustReturnOkListRequest) (*http.Header, error)
GetJustReturnOkList ...
func (*Client) GetOkTypeAndJustErrorList ¶
func (s *Client) GetOkTypeAndJustErrorList(ctx context.Context, req *GetOkTypeAndJustErrorListRequest) (*Response, error)
GetOkTypeAndJustErrorList ...
func (*Client) GetOopsList ¶
GetOopsList ...
func (*Client) GetRawIntList ¶
GetRawIntList ...
func (*Client) GetRawList ¶
GetRawList ...
func (*Client) GetStuffList ¶
GetStuffList ...
type DefaultSimpleImpl ¶
type DefaultSimpleImpl struct { }
DefaultSimpleImpl ...
func NewDefaultSimpleImpl ¶
func NewDefaultSimpleImpl() *DefaultSimpleImpl
NewDefaultSimpleImpl for Simple
type DownstreamConfig ¶
type DownstreamConfig struct { ContextTimeout time.Duration `yaml:"contextTimeout"` Deps config.CommonDownstreamData `yaml:"deps"` }
DownstreamConfig for Simple
type GetApiDocsListClient ¶
type GetApiDocsListClient struct {
GetApiDocsList func(ctx context.Context, req *deps.GetApiDocsListRequest) (*deps.ApiDoc, error)
}
GetApiDocsList Client
type GetGetSomeBytesListClient ¶ added in v0.9.0
type GetGetSomeBytesListClient struct { }
GetGetSomeBytesList Client
type GetGetSomeBytesListRequest ¶ added in v0.9.0
type GetGetSomeBytesListRequest struct { }
GetGetSomeBytesListRequest ...
type GetJustOkAndJustErrorListClient ¶
type GetJustOkAndJustErrorListClient struct { }
GetJustOkAndJustErrorList Client
type GetJustOkAndJustErrorListRequest ¶
type GetJustOkAndJustErrorListRequest struct { }
GetJustOkAndJustErrorListRequest ...
type GetJustReturnErrorListClient ¶
type GetJustReturnErrorListClient struct { }
GetJustReturnErrorList Client
type GetJustReturnErrorListRequest ¶
type GetJustReturnErrorListRequest struct { }
GetJustReturnErrorListRequest ...
type GetJustReturnOkListClient ¶
type GetJustReturnOkListClient struct { }
GetJustReturnOkList Client
type GetJustReturnOkListRequest ¶
type GetJustReturnOkListRequest struct { }
GetJustReturnOkListRequest ...
type GetOkTypeAndJustErrorListClient ¶
type GetOkTypeAndJustErrorListClient struct { }
GetOkTypeAndJustErrorList Client
type GetOkTypeAndJustErrorListRequest ¶
type GetOkTypeAndJustErrorListRequest struct { }
GetOkTypeAndJustErrorListRequest ...
type GetSimpleAPIDocsListClient ¶ added in v0.2.0
type GetSimpleAPIDocsListClient struct {
GetApiDocsList func(ctx context.Context, req *deps.GetApiDocsListRequest) (*deps.ApiDoc, error)
}
GetSimpleAPIDocsList Client
type GetSimpleAPIDocsListRequest ¶ added in v0.2.0
type GetSimpleAPIDocsListRequest struct { }
GetSimpleAPIDocsListRequest ...
type GetStuffListRequest ¶
GetStuffListRequest ...
type Handler ¶
type Handler interface { GetApiDocsListHandler(w http.ResponseWriter, r *http.Request) GetGetSomeBytesListHandler(w http.ResponseWriter, r *http.Request) GetJustOkAndJustErrorListHandler(w http.ResponseWriter, r *http.Request) GetJustReturnErrorListHandler(w http.ResponseWriter, r *http.Request) GetJustReturnOkListHandler(w http.ResponseWriter, r *http.Request) GetOkTypeAndJustErrorListHandler(w http.ResponseWriter, r *http.Request) GetOopsListHandler(w http.ResponseWriter, r *http.Request) GetRawListHandler(w http.ResponseWriter, r *http.Request) GetRawIntListHandler(w http.ResponseWriter, r *http.Request) GetSimpleAPIDocsListHandler(w http.ResponseWriter, r *http.Request) GetStuffListHandler(w http.ResponseWriter, r *http.Request) PostStuffHandler(w http.ResponseWriter, r *http.Request) }
Handler interface for Simple
type Integer ¶
type Integer int64
Integer ...
func GetRawIntList ¶
func GetRawIntList(ctx context.Context, req *GetRawIntListRequest, client GetRawIntListClient) (*Integer, error)
type Service ¶
type Service interface { GetJustOkAndJustErrorList(ctx context.Context, req *GetJustOkAndJustErrorListRequest) (*http.Header, error) GetJustReturnErrorList(ctx context.Context, req *GetJustReturnErrorListRequest) error GetJustReturnOkList(ctx context.Context, req *GetJustReturnOkListRequest) (*http.Header, error) GetOkTypeAndJustErrorList(ctx context.Context, req *GetOkTypeAndJustErrorListRequest) (*Response, error) GetApiDocsList(ctx context.Context, req *GetApiDocsListRequest) (*deps.ApiDoc, error) GetOopsList(ctx context.Context, req *GetOopsListRequest) (*Response, error) GetRawList(ctx context.Context, req *GetRawListRequest) (*Str, error) GetRawIntList(ctx context.Context, req *GetRawIntListRequest) (*Integer, error) GetStuffList(ctx context.Context, req *GetStuffListRequest) (*Stuff, error) PostStuff(ctx context.Context, req *PostStuffRequest) (*Str, error) }
Service interface for Simple
type ServiceHandler ¶
type ServiceHandler struct {
// contains filtered or unexported fields
}
ServiceHandler for Simple API
func NewServiceHandler ¶
func NewServiceHandler(genCallback core.RestGenCallback, serviceInterface *ServiceInterface, depsDepsService deps.Service) *ServiceHandler
NewServiceHandler for Simple
func (*ServiceHandler) GetApiDocsListHandler ¶
func (s *ServiceHandler) GetApiDocsListHandler(w http.ResponseWriter, r *http.Request)
GetApiDocsListHandler ...
func (*ServiceHandler) GetGetSomeBytesListHandler ¶ added in v0.9.0
func (s *ServiceHandler) GetGetSomeBytesListHandler(w http.ResponseWriter, r *http.Request)
GetGetSomeBytesListHandler ...
func (*ServiceHandler) GetJustOkAndJustErrorListHandler ¶
func (s *ServiceHandler) GetJustOkAndJustErrorListHandler(w http.ResponseWriter, r *http.Request)
GetJustOkAndJustErrorListHandler ...
func (*ServiceHandler) GetJustReturnErrorListHandler ¶
func (s *ServiceHandler) GetJustReturnErrorListHandler(w http.ResponseWriter, r *http.Request)
GetJustReturnErrorListHandler ...
func (*ServiceHandler) GetJustReturnOkListHandler ¶
func (s *ServiceHandler) GetJustReturnOkListHandler(w http.ResponseWriter, r *http.Request)
GetJustReturnOkListHandler ...
func (*ServiceHandler) GetOkTypeAndJustErrorListHandler ¶
func (s *ServiceHandler) GetOkTypeAndJustErrorListHandler(w http.ResponseWriter, r *http.Request)
GetOkTypeAndJustErrorListHandler ...
func (*ServiceHandler) GetOopsListHandler ¶
func (s *ServiceHandler) GetOopsListHandler(w http.ResponseWriter, r *http.Request)
GetOopsListHandler ...
func (*ServiceHandler) GetRawIntListHandler ¶
func (s *ServiceHandler) GetRawIntListHandler(w http.ResponseWriter, r *http.Request)
GetRawIntListHandler ...
func (*ServiceHandler) GetRawListHandler ¶
func (s *ServiceHandler) GetRawListHandler(w http.ResponseWriter, r *http.Request)
GetRawListHandler ...
func (*ServiceHandler) GetSimpleAPIDocsListHandler ¶ added in v0.4.0
func (s *ServiceHandler) GetSimpleAPIDocsListHandler(w http.ResponseWriter, r *http.Request)
GetSimpleAPIDocsListHandler ...
func (*ServiceHandler) GetStuffListHandler ¶
func (s *ServiceHandler) GetStuffListHandler(w http.ResponseWriter, r *http.Request)
GetStuffListHandler ...
func (*ServiceHandler) PostStuffHandler ¶
func (s *ServiceHandler) PostStuffHandler(w http.ResponseWriter, r *http.Request)
PostStuffHandler ...
type ServiceInterface ¶
type ServiceInterface struct { GetApiDocsList func(ctx context.Context, req *GetApiDocsListRequest, client GetApiDocsListClient) (*deps.ApiDoc, error) GetGetSomeBytesList func(ctx context.Context, req *GetGetSomeBytesListRequest, client GetGetSomeBytesListClient) (*Pdf, error) GetJustOkAndJustErrorList func(ctx context.Context, req *GetJustOkAndJustErrorListRequest, client GetJustOkAndJustErrorListClient) error GetJustReturnErrorList func(ctx context.Context, req *GetJustReturnErrorListRequest, client GetJustReturnErrorListClient) error GetJustReturnOkList func(ctx context.Context, req *GetJustReturnOkListRequest, client GetJustReturnOkListClient) error GetOkTypeAndJustErrorList func(ctx context.Context, req *GetOkTypeAndJustErrorListRequest, client GetOkTypeAndJustErrorListClient) (*Response, error) GetOopsList func(ctx context.Context, req *GetOopsListRequest, client GetOopsListClient) (*Response, error) GetRawList func(ctx context.Context, req *GetRawListRequest, client GetRawListClient) (*Str, error) GetRawIntList func(ctx context.Context, req *GetRawIntListRequest, client GetRawIntListClient) (*Integer, error) GetSimpleAPIDocsList func(ctx context.Context, req *GetSimpleAPIDocsListRequest, client GetSimpleAPIDocsListClient) (*deps.ApiDoc, error) GetStuffList func(ctx context.Context, req *GetStuffListRequest, client GetStuffListClient) (*Stuff, error) PostStuff func(ctx context.Context, req *PostStuffRequest, client PostStuffClient) (*Str, error) }
ServiceInterface for Simple
type ServiceRouter ¶
type ServiceRouter struct {
// contains filtered or unexported fields
}
ServiceRouter for Simple API
func (*ServiceRouter) WireRoutes ¶
func (s *ServiceRouter) WireRoutes(ctx context.Context, r chi.Router)
WireRoutes ...
type Status ¶
type Status struct {
StatusField string `json:"statusField"`
}
Status ...
type Str ¶
type Str string
Str ...
func GetRawList ¶
func GetRawList(ctx context.Context, req *GetRawListRequest, client GetRawListClient) (*Str, error)
type Stuff ¶
type Stuff struct { EmptyStuff Empty `json:"emptyStuff"` InnerStuff string `json:"innerStuff"` RawTimeStuff time.Time `json:"rawTimeStuff"` ResponseStuff Response `json:"responseStuff"` SensitiveStuff common.SensitiveString `json:"sensitiveStuff"` TimeStuff convert.JSONTime `json:"timeStuff"` }
Stuff just some stuff
func GetStuffList ¶
func GetStuffList(ctx context.Context, req *GetStuffListRequest, client GetStuffListClient) (*Stuff, error)