Documentation ¶
Overview ¶
Package openapi2conv converts an OpenAPI v2 specification to v3.
Index ¶
- func FromV3Operation(swagger *openapi3.Swagger, operation *openapi3.Operation) (*openapi2.Operation, error)
- func FromV3Parameter(ref *openapi3.ParameterRef) (*openapi2.Parameter, error)
- func FromV3PathItem(swagger *openapi3.Swagger, pathItem *openapi3.PathItem) (*openapi2.PathItem, error)
- func FromV3Ref(ref string) string
- func FromV3RequestBody(swagger *openapi3.Swagger, operation *openapi3.Operation, ...) (*openapi2.Parameter, error)
- func FromV3Response(ref *openapi3.ResponseRef) (*openapi2.Response, error)
- func FromV3Responses(responses map[string]*openapi3.ResponseRef) (map[string]*openapi2.Response, error)
- func FromV3SchemaRef(schema *openapi3.SchemaRef) *openapi3.SchemaRef
- func FromV3Schemas(schemas map[string]*openapi3.SchemaRef) map[string]*openapi3.SchemaRef
- func FromV3SecurityRequirements(requirements openapi3.SecurityRequirements) openapi2.SecurityRequirements
- func FromV3SecurityScheme(swagger *openapi3.Swagger, ref *openapi3.SecuritySchemeRef) (*openapi2.SecurityScheme, error)
- func FromV3Swagger(swagger *openapi3.Swagger) (*openapi2.Swagger, error)
- func ToV3Operation(swagger *openapi2.Swagger, pathItem *openapi2.PathItem, ...) (*openapi3.Operation, error)
- func ToV3Parameter(parameter *openapi2.Parameter) (*openapi3.ParameterRef, *openapi3.RequestBodyRef, error)
- func ToV3PathItem(swagger *openapi2.Swagger, pathItem *openapi2.PathItem) (*openapi3.PathItem, error)
- func ToV3Ref(ref string) string
- func ToV3Response(response *openapi2.Response) (*openapi3.ResponseRef, error)
- func ToV3SchemaRef(schema *openapi3.SchemaRef) *openapi3.SchemaRef
- func ToV3Schemas(defs map[string]*openapi3.SchemaRef) map[string]*openapi3.SchemaRef
- func ToV3SecurityRequirements(requirements openapi2.SecurityRequirements) openapi3.SecurityRequirements
- func ToV3SecurityScheme(securityScheme *openapi2.SecurityScheme) (*openapi3.SecuritySchemeRef, error)
- func ToV3Swagger(swagger *openapi2.Swagger) (*openapi3.Swagger, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func FromV3Operation ¶
func FromV3Parameter ¶
func FromV3Parameter(ref *openapi3.ParameterRef) (*openapi2.Parameter, error)
func FromV3PathItem ¶
func FromV3RequestBody ¶
func FromV3Response ¶
func FromV3Response(ref *openapi3.ResponseRef) (*openapi2.Response, error)
func FromV3Responses ¶
func FromV3Schemas ¶
func FromV3SecurityRequirements ¶
func FromV3SecurityRequirements(requirements openapi3.SecurityRequirements) openapi2.SecurityRequirements
func FromV3SecurityScheme ¶
func FromV3SecurityScheme(swagger *openapi3.Swagger, ref *openapi3.SecuritySchemeRef) (*openapi2.SecurityScheme, error)
func ToV3Operation ¶
func ToV3Parameter ¶
func ToV3Parameter(parameter *openapi2.Parameter) (*openapi3.ParameterRef, *openapi3.RequestBodyRef, error)
func ToV3PathItem ¶
func ToV3Response ¶
func ToV3Response(response *openapi2.Response) (*openapi3.ResponseRef, error)
func ToV3Schemas ¶
func ToV3SecurityRequirements ¶
func ToV3SecurityRequirements(requirements openapi2.SecurityRequirements) openapi3.SecurityRequirements
func ToV3SecurityScheme ¶
func ToV3SecurityScheme(securityScheme *openapi2.SecurityScheme) (*openapi3.SecuritySchemeRef, error)
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.