Documentation ¶
Overview ¶
Package server provides primitives to interact with the openapi HTTP API.
Code generated by github.com/deepmap/oapi-codegen version v1.11.1-0.20221010081618-45eb6bdf117a DO NOT EDIT.
Index ¶
- func GetSwagger() (swagger *openapi3.T, err error)
- func PathToRawSpec(pathToFile string) map[string]func() ([]byte, error)
- func RegisterHandlers(router EchoRouter, si ServerInterface)
- func RegisterHandlersWithBaseURL(router EchoRouter, si ServerInterface, baseURL string)
- type CreateTable200JSONResponse
- type CreateTableJSONRequestBody
- type CreateTableRequestObject
- type CreateTableResponseObject
- type CreateTabledefaultJSONResponse
- type DbSchema
- type DbSchema200JSONResponse
- type DbSchemaRequestObject
- type DbSchemaResponseObject
- type DbSchemadefaultJSONResponse
- type DeleteDuplicateRows200JSONResponse
- type DeleteDuplicateRowsRequestObject
- type DeleteDuplicateRowsResponseObject
- type DeleteDuplicateRowsdefaultJSONResponse
- type DeleteRows200JSONResponse
- type DeleteRowsJSONRequestBody
- type DeleteRowsRequestObject
- type DeleteRowsResponseObject
- type DeleteRowsdefaultJSONResponse
- type DeleteTable200JSONResponse
- type DeleteTableRequestObject
- type DeleteTableResponseObject
- type DeleteTabledefaultJSONResponse
- type EchoRouter
- type Error
- type Info
- type InsertRows200JSONResponse
- type InsertRowsJSONRequestBody
- type InsertRowsRequestObject
- type InsertRowsResponseObject
- type InsertRowsdefaultJSONResponse
- type Row
- type RowNames
- type Rows
- type Schema
- type SchemaType
- type SelectBody
- type SelectRows200JSONResponse
- type SelectRowsJSONRequestBody
- type SelectRowsRequestObject
- type SelectRowsResponseObject
- type SelectRowsdefaultJSONResponse
- type ServerInterface
- type ServerInterfaceWrapper
- func (w *ServerInterfaceWrapper) CreateTable(ctx echo.Context) error
- func (w *ServerInterfaceWrapper) DbSchema(ctx echo.Context) error
- func (w *ServerInterfaceWrapper) DeleteDuplicateRows(ctx echo.Context) error
- func (w *ServerInterfaceWrapper) DeleteRows(ctx echo.Context) error
- func (w *ServerInterfaceWrapper) DeleteTable(ctx echo.Context) error
- func (w *ServerInterfaceWrapper) InsertRows(ctx echo.Context) error
- func (w *ServerInterfaceWrapper) SelectRows(ctx echo.Context) error
- func (w *ServerInterfaceWrapper) UpdateRows(ctx echo.Context) error
- type StrictHandlerFunc
- type StrictMiddlewareFunc
- type StrictServerInterface
- type TableSchema
- type UpdateBody
- type UpdateRows200JSONResponse
- type UpdateRowsJSONRequestBody
- type UpdateRowsRequestObject
- type UpdateRowsResponseObject
- type UpdateRowsdefaultJSONResponse
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetSwagger ¶
GetSwagger returns the Swagger specification corresponding to the generated code in this file. The external references of Swagger specification are resolved. The logic of resolving external references is tightly connected to "import-mapping" feature. Externally referenced files must be embedded in the corresponding golang packages. Urls can be supported but this task was out of the scope.
func PathToRawSpec ¶
Constructs a synthetic filesystem for resolving external references when loading openapi specifications.
func RegisterHandlers ¶
func RegisterHandlers(router EchoRouter, si ServerInterface)
RegisterHandlers adds each server route to the EchoRouter.
func RegisterHandlersWithBaseURL ¶
func RegisterHandlersWithBaseURL(router EchoRouter, si ServerInterface, baseURL string)
Registers handlers, and prepends BaseURL to the paths, so that the paths can be served under a prefix.
Types ¶
type CreateTable200JSONResponse ¶
type CreateTable200JSONResponse Info
func (CreateTable200JSONResponse) VisitCreateTableResponse ¶
func (response CreateTable200JSONResponse) VisitCreateTableResponse(w http.ResponseWriter) error
type CreateTableJSONRequestBody ¶
type CreateTableJSONRequestBody = TableSchema
CreateTableJSONRequestBody defines body for CreateTable for application/json ContentType.
type CreateTableRequestObject ¶
type CreateTableRequestObject struct {
Body *CreateTableJSONRequestBody
}
type CreateTableResponseObject ¶
type CreateTableResponseObject interface {
VisitCreateTableResponse(w http.ResponseWriter) error
}
type CreateTabledefaultJSONResponse ¶
func (CreateTabledefaultJSONResponse) VisitCreateTableResponse ¶
func (response CreateTabledefaultJSONResponse) VisitCreateTableResponse(w http.ResponseWriter) error
type DbSchema200JSONResponse ¶
type DbSchema200JSONResponse DbSchema
func (DbSchema200JSONResponse) VisitDbSchemaResponse ¶
func (response DbSchema200JSONResponse) VisitDbSchemaResponse(w http.ResponseWriter) error
type DbSchemaRequestObject ¶
type DbSchemaRequestObject struct { }
type DbSchemaResponseObject ¶
type DbSchemaResponseObject interface {
VisitDbSchemaResponse(w http.ResponseWriter) error
}
type DbSchemadefaultJSONResponse ¶
func (DbSchemadefaultJSONResponse) VisitDbSchemaResponse ¶
func (response DbSchemadefaultJSONResponse) VisitDbSchemaResponse(w http.ResponseWriter) error
type DeleteDuplicateRows200JSONResponse ¶
type DeleteDuplicateRows200JSONResponse Info
func (DeleteDuplicateRows200JSONResponse) VisitDeleteDuplicateRowsResponse ¶
func (response DeleteDuplicateRows200JSONResponse) VisitDeleteDuplicateRowsResponse(w http.ResponseWriter) error
type DeleteDuplicateRowsRequestObject ¶
type DeleteDuplicateRowsRequestObject struct {
Name string `json:"name"`
}
type DeleteDuplicateRowsResponseObject ¶
type DeleteDuplicateRowsResponseObject interface {
VisitDeleteDuplicateRowsResponse(w http.ResponseWriter) error
}
type DeleteDuplicateRowsdefaultJSONResponse ¶
func (DeleteDuplicateRowsdefaultJSONResponse) VisitDeleteDuplicateRowsResponse ¶
func (response DeleteDuplicateRowsdefaultJSONResponse) VisitDeleteDuplicateRowsResponse(w http.ResponseWriter) error
type DeleteRows200JSONResponse ¶
type DeleteRows200JSONResponse Info
func (DeleteRows200JSONResponse) VisitDeleteRowsResponse ¶
func (response DeleteRows200JSONResponse) VisitDeleteRowsResponse(w http.ResponseWriter) error
type DeleteRowsJSONRequestBody ¶
type DeleteRowsJSONRequestBody = Row
DeleteRowsJSONRequestBody defines body for DeleteRows for application/json ContentType.
type DeleteRowsRequestObject ¶
type DeleteRowsRequestObject struct { Name string `json:"name"` Body *DeleteRowsJSONRequestBody }
type DeleteRowsResponseObject ¶
type DeleteRowsResponseObject interface {
VisitDeleteRowsResponse(w http.ResponseWriter) error
}
type DeleteRowsdefaultJSONResponse ¶
func (DeleteRowsdefaultJSONResponse) VisitDeleteRowsResponse ¶
func (response DeleteRowsdefaultJSONResponse) VisitDeleteRowsResponse(w http.ResponseWriter) error
type DeleteTable200JSONResponse ¶
type DeleteTable200JSONResponse Info
func (DeleteTable200JSONResponse) VisitDeleteTableResponse ¶
func (response DeleteTable200JSONResponse) VisitDeleteTableResponse(w http.ResponseWriter) error
type DeleteTableRequestObject ¶
type DeleteTableRequestObject struct {
Name string `json:"name"`
}
type DeleteTableResponseObject ¶
type DeleteTableResponseObject interface {
VisitDeleteTableResponse(w http.ResponseWriter) error
}
type DeleteTabledefaultJSONResponse ¶
func (DeleteTabledefaultJSONResponse) VisitDeleteTableResponse ¶
func (response DeleteTabledefaultJSONResponse) VisitDeleteTableResponse(w http.ResponseWriter) error
type EchoRouter ¶
type EchoRouter interface { CONNECT(path string, h echo.HandlerFunc, m ...echo.MiddlewareFunc) *echo.Route DELETE(path string, h echo.HandlerFunc, m ...echo.MiddlewareFunc) *echo.Route GET(path string, h echo.HandlerFunc, m ...echo.MiddlewareFunc) *echo.Route HEAD(path string, h echo.HandlerFunc, m ...echo.MiddlewareFunc) *echo.Route OPTIONS(path string, h echo.HandlerFunc, m ...echo.MiddlewareFunc) *echo.Route PATCH(path string, h echo.HandlerFunc, m ...echo.MiddlewareFunc) *echo.Route POST(path string, h echo.HandlerFunc, m ...echo.MiddlewareFunc) *echo.Route PUT(path string, h echo.HandlerFunc, m ...echo.MiddlewareFunc) *echo.Route TRACE(path string, h echo.HandlerFunc, m ...echo.MiddlewareFunc) *echo.Route }
This is a simple interface which specifies echo.Route addition functions which are present on both echo.Echo and echo.Group, since we want to allow using either of them for path registration
type InsertRows200JSONResponse ¶
type InsertRows200JSONResponse Info
func (InsertRows200JSONResponse) VisitInsertRowsResponse ¶
func (response InsertRows200JSONResponse) VisitInsertRowsResponse(w http.ResponseWriter) error
type InsertRowsJSONRequestBody ¶
type InsertRowsJSONRequestBody = Rows
InsertRowsJSONRequestBody defines body for InsertRows for application/json ContentType.
type InsertRowsRequestObject ¶
type InsertRowsRequestObject struct { Name string `json:"name"` Body *InsertRowsJSONRequestBody }
type InsertRowsResponseObject ¶
type InsertRowsResponseObject interface {
VisitInsertRowsResponse(w http.ResponseWriter) error
}
type InsertRowsdefaultJSONResponse ¶
func (InsertRowsdefaultJSONResponse) VisitInsertRowsResponse ¶
func (response InsertRowsdefaultJSONResponse) VisitInsertRowsResponse(w http.ResponseWriter) error
type Schema ¶
type Schema struct { Column string `json:"column"` Type SchemaType `json:"type"` }
Schema defines model for Schema.
type SchemaType ¶
type SchemaType string
SchemaType defines model for Schema.Type.
const ( Char SchemaType = "char" Image SchemaType = "image" Integer SchemaType = "integer" Real SchemaType = "real" RealInv SchemaType = "realInv" String SchemaType = "string" )
Defines values for SchemaType.
type SelectBody ¶
SelectBody defines model for SelectBody.
type SelectRows200JSONResponse ¶
type SelectRows200JSONResponse Rows
func (SelectRows200JSONResponse) VisitSelectRowsResponse ¶
func (response SelectRows200JSONResponse) VisitSelectRowsResponse(w http.ResponseWriter) error
type SelectRowsJSONRequestBody ¶
type SelectRowsJSONRequestBody = SelectBody
SelectRowsJSONRequestBody defines body for SelectRows for application/json ContentType.
type SelectRowsRequestObject ¶
type SelectRowsRequestObject struct { Name string `json:"name"` Body *SelectRowsJSONRequestBody }
type SelectRowsResponseObject ¶
type SelectRowsResponseObject interface {
VisitSelectRowsResponse(w http.ResponseWriter) error
}
type SelectRowsdefaultJSONResponse ¶
func (SelectRowsdefaultJSONResponse) VisitSelectRowsResponse ¶
func (response SelectRowsdefaultJSONResponse) VisitSelectRowsResponse(w http.ResponseWriter) error
type ServerInterface ¶
type ServerInterface interface { // (GET /.schema) DbSchema(ctx echo.Context) error // (POST /delete-table/{name}/) DeleteTable(ctx echo.Context, name string) error // (POST /table) CreateTable(ctx echo.Context) error // (PATCH /table/{name}) UpdateRows(ctx echo.Context, name string) error // (POST /table/{name}) InsertRows(ctx echo.Context, name string) error // (POST /table/{name}/delete) DeleteRows(ctx echo.Context, name string) error // (POST /table/{name}/remove-duplicates) DeleteDuplicateRows(ctx echo.Context, name string) error // (POST /table/{name}/select) SelectRows(ctx echo.Context, name string) error }
ServerInterface represents all server handlers.
func NewStrictHandler ¶
func NewStrictHandler(ssi StrictServerInterface, middlewares []StrictMiddlewareFunc) ServerInterface
type ServerInterfaceWrapper ¶
type ServerInterfaceWrapper struct {
Handler ServerInterface
}
ServerInterfaceWrapper converts echo contexts to parameters.
func (*ServerInterfaceWrapper) CreateTable ¶
func (w *ServerInterfaceWrapper) CreateTable(ctx echo.Context) error
CreateTable converts echo context to params.
func (*ServerInterfaceWrapper) DbSchema ¶
func (w *ServerInterfaceWrapper) DbSchema(ctx echo.Context) error
DbSchema converts echo context to params.
func (*ServerInterfaceWrapper) DeleteDuplicateRows ¶
func (w *ServerInterfaceWrapper) DeleteDuplicateRows(ctx echo.Context) error
DeleteDuplicateRows converts echo context to params.
func (*ServerInterfaceWrapper) DeleteRows ¶
func (w *ServerInterfaceWrapper) DeleteRows(ctx echo.Context) error
DeleteRows converts echo context to params.
func (*ServerInterfaceWrapper) DeleteTable ¶
func (w *ServerInterfaceWrapper) DeleteTable(ctx echo.Context) error
DeleteTable converts echo context to params.
func (*ServerInterfaceWrapper) InsertRows ¶
func (w *ServerInterfaceWrapper) InsertRows(ctx echo.Context) error
InsertRows converts echo context to params.
func (*ServerInterfaceWrapper) SelectRows ¶
func (w *ServerInterfaceWrapper) SelectRows(ctx echo.Context) error
SelectRows converts echo context to params.
func (*ServerInterfaceWrapper) UpdateRows ¶
func (w *ServerInterfaceWrapper) UpdateRows(ctx echo.Context) error
UpdateRows converts echo context to params.
type StrictHandlerFunc ¶
type StrictHandlerFunc func(ctx echo.Context, args interface{}) (interface{}, error)
type StrictMiddlewareFunc ¶
type StrictMiddlewareFunc func(f StrictHandlerFunc, operationID string) StrictHandlerFunc
type StrictServerInterface ¶
type StrictServerInterface interface { // (GET /.schema) DbSchema(ctx context.Context, request DbSchemaRequestObject) (DbSchemaResponseObject, error) // (POST /delete-table/{name}/) DeleteTable(ctx context.Context, request DeleteTableRequestObject) (DeleteTableResponseObject, error) // (POST /table) CreateTable(ctx context.Context, request CreateTableRequestObject) (CreateTableResponseObject, error) // (PATCH /table/{name}) UpdateRows(ctx context.Context, request UpdateRowsRequestObject) (UpdateRowsResponseObject, error) // (POST /table/{name}) InsertRows(ctx context.Context, request InsertRowsRequestObject) (InsertRowsResponseObject, error) // (POST /table/{name}/delete) DeleteRows(ctx context.Context, request DeleteRowsRequestObject) (DeleteRowsResponseObject, error) // (POST /table/{name}/remove-duplicates) DeleteDuplicateRows(ctx context.Context, request DeleteDuplicateRowsRequestObject) (DeleteDuplicateRowsResponseObject, error) // (POST /table/{name}/select) SelectRows(ctx context.Context, request SelectRowsRequestObject) (SelectRowsResponseObject, error) }
StrictServerInterface represents all server handlers.
type TableSchema ¶
type TableSchema struct { Schema *[]Schema `json:"schema,omitempty"` TableName *string `json:"tableName,omitempty"` }
TableSchema defines model for TableSchema.
type UpdateBody ¶
UpdateBody defines model for UpdateBody.
type UpdateRows200JSONResponse ¶
type UpdateRows200JSONResponse Info
func (UpdateRows200JSONResponse) VisitUpdateRowsResponse ¶
func (response UpdateRows200JSONResponse) VisitUpdateRowsResponse(w http.ResponseWriter) error
type UpdateRowsJSONRequestBody ¶
type UpdateRowsJSONRequestBody = UpdateBody
UpdateRowsJSONRequestBody defines body for UpdateRows for application/json ContentType.
type UpdateRowsRequestObject ¶
type UpdateRowsRequestObject struct { Name string `json:"name"` Body *UpdateRowsJSONRequestBody }
type UpdateRowsResponseObject ¶
type UpdateRowsResponseObject interface {
VisitUpdateRowsResponse(w http.ResponseWriter) error
}
type UpdateRowsdefaultJSONResponse ¶
func (UpdateRowsdefaultJSONResponse) VisitUpdateRowsResponse ¶
func (response UpdateRowsdefaultJSONResponse) VisitUpdateRowsResponse(w http.ResponseWriter) error