Versions in this module Expand all Collapse all v0 v0.24.0 Mar 28, 2022 Changes in this version + func FixEmptyDesc(rs *spec.Response) + func FixEmptyDescs(rs *spec.Responses) + func FixEmptyResponseDescriptions(s *spec.Swagger) + func Flatten(opts FlattenOpts) error + func GenLocation(parts sortref.SplitKey) string + func Mixin(primary *spec.Swagger, mixins ...*spec.Swagger) []string + type AnalyzedSchema struct + IsArray bool + IsBaseType bool + IsEnum bool + IsExtendedObject bool + IsKnownType bool + IsMap bool + IsSimpleArray bool + IsSimpleMap bool + IsSimpleSchema bool + IsTuple bool + IsTupleWithExtra bool + func Schema(opts SchemaOpts) (*AnalyzedSchema, error) + type ErrorOnParamFunc func(spec.Parameter, error) bool + type FlattenOpts struct + BasePath string + ContinueOnError bool + Expand bool + Minimal bool + RemoveUnused bool + Spec *Spec + Verbose bool + func (f *FlattenOpts) ExpandOpts(skipSchemas bool) *spec.ExpandOptions + func (f *FlattenOpts) Swagger() *spec.Swagger + type InlineSchemaNamer struct + Operations map[string]operations.OpRef + Spec *spec.Swagger + func (isn *InlineSchemaNamer) Name(key string, schema *spec.Schema, aschema *AnalyzedSchema) error + type SchemaOpts struct + BasePath string + Root interface{} + Schema *spec.Schema + type SchemaRef struct + Name string + Ref spec.Ref + Schema *spec.Schema + TopLevel bool + type SecurityRequirement struct + Name string + Scopes []string + type Spec struct + func New(doc *spec.Swagger) *Spec + func (s *Spec) AllDefinitionReferences() (result []string) + func (s *Spec) AllDefinitions() (result []SchemaRef) + func (s *Spec) AllEnums() map[string][]interface{} + func (s *Spec) AllItemsReferences() (result []string) + func (s *Spec) AllParameterReferences() (result []string) + func (s *Spec) AllPathItemReferences() (result []string) + func (s *Spec) AllPaths() map[string]spec.PathItem + func (s *Spec) AllPatterns() map[string]string + func (s *Spec) AllReferences() (result []string) + func (s *Spec) AllRefs() (result []spec.Ref) + func (s *Spec) AllResponseReferences() (result []string) + func (s *Spec) ConsumesFor(operation *spec.Operation) []string + func (s *Spec) HeaderEnums() map[string][]interface{} + func (s *Spec) HeaderPatterns() map[string]string + func (s *Spec) ItemsEnums() map[string][]interface{} + func (s *Spec) ItemsPatterns() map[string]string + func (s *Spec) OperationFor(method, path string) (*spec.Operation, bool) + func (s *Spec) OperationForName(operationID string) (string, string, *spec.Operation, bool) + func (s *Spec) OperationIDs() []string + func (s *Spec) OperationMethodPaths() []string + func (s *Spec) Operations() map[string]map[string]*spec.Operation + func (s *Spec) ParameterEnums() map[string][]interface{} + func (s *Spec) ParameterPatterns() map[string]string + func (s *Spec) ParametersFor(operationID string) []spec.Parameter + func (s *Spec) ParamsFor(method, path string) map[string]spec.Parameter + func (s *Spec) ProducesFor(operation *spec.Operation) []string + func (s *Spec) RequiredConsumes() []string + func (s *Spec) RequiredProduces() []string + func (s *Spec) RequiredSecuritySchemes() []string + func (s *Spec) SafeParametersFor(operationID string, callmeOnError ErrorOnParamFunc) []spec.Parameter + func (s *Spec) SafeParamsFor(method, path string, callmeOnError ErrorOnParamFunc) map[string]spec.Parameter + func (s *Spec) SchemaEnums() map[string][]interface{} + func (s *Spec) SchemaPatterns() map[string]string + func (s *Spec) SchemasWithAllOf() (result []SchemaRef) + func (s *Spec) SecurityDefinitionsFor(operation *spec.Operation) map[string]spec.SecurityScheme + func (s *Spec) SecurityDefinitionsForRequirements(requirements []SecurityRequirement) map[string]spec.SecurityScheme + func (s *Spec) SecurityRequirementsFor(operation *spec.Operation) [][]SecurityRequirement