package
0.31.0
Repository: https://github.com/circl-dev/go-swagger.git
Documentation: pkg.go.dev

# Functions

AddFile adds a file to the default repository.
Asset loads and returns the asset for the given name.
AssetDigest returns the digest of the file with the given name.
AssetDir returns the file names below a certain directory embedded in the file by go-bindata.
AssetInfo loads and returns the asset info for the given name.
AssetNames returns the names of the assets.
AssetString returns the asset contents as a string (instead of a []byte).
DefaultFuncMap yields a map with default functions for use n the templates.
DefaultSectionOpts for a given opts, this is used when no config file is passed and uses the embedded templates when no local override can be found.
Digests returns a map of all known files and their checksums.
GenerateClient generates a client library for a swagger spec document.
GenerateDefinition generates a single model file for some schema definitions.
GenerateMarkdown documentation for a swagger specification.
GenerateModels generates all model files for some schema definitions.
GenerateServer generates a server application.
GenerateServerOperation generates a parameter model, parameter validator, http handler implementations for a given operation.
GenerateSupport generates the supporting files for an API.
GoLangOpts for rendering items as golang code.
MarkdownOpts for rendering a spec as markdown.
MarkdownSectionOpts for a given opts and output file.
MustAsset is like Asset but panics when Asset would return an error.
MustAssetString is like AssetString but panics when Asset would return an error.
NewRepository creates a new template repository with the provided functions defined.
ReadConfig at the specified path, when no path is specified it will look into the current directory and load a .swagger.{yml,json,hcl,toml,properties} file Returns a viper config or an error.
RestoreAsset restores an asset under the given directory.
RestoreAssets restores an asset under the given directory recursively.
WithAutoXOrder amends the spec to specify property order as they appear in the spec (supports yaml documents only).

# Constants

AssetDebug is true if the assets were built with the debug flag enabled.

# Variables

Debug when the env var DEBUG or SWAGGER_DEBUG is not empty the generators will be very noisy about what they are doing.
DefaultLanguageFunc defines the default generation language.
FuncMapFunc yields a map with all functions for templates.

# Structs

GenApp represents all the meta data needed to generate an application from a swagger spec.
GenCommon contains common properties needed across definitions, app and operations TargetImportPath may be used by templates to import other (possibly generated) packages in the generation path (e.g.
GenDefinition contains all the properties to generate a definition from a swagger spec.
GenHeader represents a header on a response for code generation.
GenItems represents the collection items for a collection parameter.
GenOperation represents an operation for code generation.
GenOperationGroup represents a named (tagged) group of operations.
GenOpts the options for the generator.
GenParameter is used to represent a parameter or a header for code generation.
GenResponse represents a response object for code generation.
GenResponseExample captures an example provided for a response for some mime type.
GenSchema contains all the information needed to generate the code for a schema.
GenSecurityRequirement represents a security requirement for an operation.
GenSecurityScheme represents a security scheme for code generation.
GenSecurityScope represents a scope descriptor for an OAuth2 security scheme.
GenSerGroup represents a group of serializers: this links a serializer to a list of prioritized media types (mime).
GenSerializer represents a single serializer for a particular media type.
LanguageDefinition in the configuration file.
LanguageOpts to describe a language to the code generator.
Repository is the repository for the generator templates.
SectionOpts allows for specifying options to customize the templates used for generation.
TemplateOpts allows for codegen customization.

# Type aliases

GenDefinitions represents a list of operations to generate this implements a sort by operation id.
GenHeaders is a sorted collection of headers for codegen.
GenOperationGroups is a sorted collection of operation groups.
GenOperations represents a list of operations to generate this implements a sort by operation id.
GenParameters represents a sorted parameter collection.
GenResponseExamples is a sortable collection []GenResponseExample.
GenSchemaList is a list of schemas for generation.
GenSecurityRequirements represents a compounded security requirement specification.
GenSecuritySchemes sorted representation of serializers.
GenSerGroups sorted representation of serializer groups.
GenSerializers sorted representation of serializers.
GenStatusCodeResponses a container for status code responses.
LanguageConfig structure that is obtained from parsing a config file.