Documentation ¶
Overview ¶
Package openapi implements OpenAPI 3.x.
This package contains objects that comprise an OpenAPI spec, but only their interfaces are exported. For example, openapi.OpenAPI (the root node that encompasses an entire spec) is an interface, paths are stored under the openapi.Paths interface, and so forth.
The real objects are hidden within this package so that users cannot accidentally create an incomplete object (for example, the spec states that the root element must contain an "info" key, but if the openapi.OpenAPI was a struct you would be able to create an empty openapi.OpenAPI{}, which would be invalid)
The API limits your ability to accidentally create empty values (and also the ability to assign arbitrary values inot fields) because the whole OpenAPI spec is rather complex -- that is, when we translate the document structure into Go, and we try to work with it, it's not just a matter of processing each objects, but we need context. For example when working with Operation objects, we really need to know the path that we're dealing with, as well as the HTTP verb that go with it. However, these values are not defined within the Operation objects: they belong to the Paths object and PathItem objects. When processing through these objects we would either have to pass all of the objects, or we would need to somehow remember their relationships, so we can query them. This is where the limitation comes into play. By limiting unregulated access to fields, we provide automatic hooks to keep track of these relationships.
In doing so, we are able to provide API like this
oper := ... // Operation object if oper.Detached() { // has this been assigned to a PathItem? path := oper.Path() // path that this Operation belongs to verb := oper.Verb() // HTTP verb that this Operation is assigned to }
Building objects must happen through a builder object: The constructor for the object builder asks the user to pass the required parameters that have no default values, and everything else can be optionally passed via methods. When all values are handed, you call `Do()` to obtain the object.
openapi.NewParameter(name). // name parameter is required Required(true). // required parameter is optional Do()
The objects are *generally* immutable and therefore provide no mutator methods on themselves. However we realize that there are times when you just want to change them: To workaround this issue, we provide mutators which work almost identically as the builders.
openapi.MutatePrameter(p). Required(false). Do()
When we assign entity objects, the objects are automatically cloned to avoid mutation from outside of the OpenAPI tree
Index ¶
- Constants
- Variables
- func CallbackFromJSON(buf []byte, dst interface{}) error
- func ComponentsFromJSON(buf []byte, dst interface{}) error
- func ContactFromJSON(buf []byte, dst interface{}) error
- func DiscriminatorFromJSON(buf []byte, dst interface{}) error
- func EncodingFromJSON(buf []byte, dst interface{}) error
- func ExampleFromJSON(buf []byte, dst interface{}) error
- func ExternalDocumentationFromJSON(buf []byte, dst interface{}) error
- func HeaderFromJSON(buf []byte, dst interface{}) error
- func InfoFromJSON(buf []byte, dst interface{}) error
- func LicenseFromJSON(buf []byte, dst interface{}) error
- func LinkFromJSON(buf []byte, dst interface{}) error
- func MediaTypeFromJSON(buf []byte, dst interface{}) error
- func OAuthFlowFromJSON(buf []byte, dst interface{}) error
- func OAuthFlowsFromJSON(buf []byte, dst interface{}) error
- func OpenAPIFromJSON(buf []byte, dst interface{}) error
- func OperationFromJSON(buf []byte, dst interface{}) error
- func ParameterFromJSON(buf []byte, dst interface{}) error
- func PathItemFromJSON(buf []byte, dst interface{}) error
- func PathsFromJSON(buf []byte, dst interface{}) error
- func RequestBodyFromJSON(buf []byte, dst interface{}) error
- func ResponseFromJSON(buf []byte, dst interface{}) error
- func ResponsesFromJSON(buf []byte, dst interface{}) error
- func SchemaFromJSON(buf []byte, dst interface{}) error
- func SecurityRequirementFromJSON(buf []byte, dst interface{}) error
- func SecuritySchemeFromJSON(buf []byte, dst interface{}) error
- func ServerFromJSON(buf []byte, dst interface{}) error
- func ServerVariableFromJSON(buf []byte, dst interface{}) error
- func TagFromJSON(buf []byte, dst interface{}) error
- func Visit(ctx context.Context, handler, elem interface{}) error
- type Callback
- type CallbackBuilder
- type CallbackMap
- type CallbackMapIterator
- type CallbackMapKey
- type CallbackMutator
- type CallbackVisitor
- type Components
- type ComponentsBuilder
- func (b *ComponentsBuilder) Build(options ...Option) (Components, error)
- func (b *ComponentsBuilder) Callbacks(v map[string]Callback) *ComponentsBuilder
- func (b *ComponentsBuilder) Examples(v map[string]Example) *ComponentsBuilder
- func (b *ComponentsBuilder) Headers(v map[string]Header) *ComponentsBuilder
- func (b *ComponentsBuilder) Links(v map[string]Link) *ComponentsBuilder
- func (b *ComponentsBuilder) MustBuild(options ...Option) Components
- func (b *ComponentsBuilder) Parameters(v map[string]Parameter) *ComponentsBuilder
- func (b *ComponentsBuilder) Reference(v string) *ComponentsBuilder
- func (b *ComponentsBuilder) RequestBodies(v map[string]RequestBody) *ComponentsBuilder
- func (b *ComponentsBuilder) Responses(v map[string]Response) *ComponentsBuilder
- func (b *ComponentsBuilder) Schema(name string, s Schema) *ComponentsBuilder
- func (b *ComponentsBuilder) Schemas(v map[string]Schema) *ComponentsBuilder
- func (b *ComponentsBuilder) SecuritySchemes(v map[string]SecurityScheme) *ComponentsBuilder
- type ComponentsMutator
- func (b *ComponentsMutator) Callback(key CallbackMapKey, value Callback) *ComponentsMutator
- func (b *ComponentsMutator) ClearCallbacks() *ComponentsMutator
- func (b *ComponentsMutator) ClearExamples() *ComponentsMutator
- func (b *ComponentsMutator) ClearHeaders() *ComponentsMutator
- func (b *ComponentsMutator) ClearLinks() *ComponentsMutator
- func (b *ComponentsMutator) ClearParameters() *ComponentsMutator
- func (b *ComponentsMutator) ClearRequestBodies() *ComponentsMutator
- func (b *ComponentsMutator) ClearResponses() *ComponentsMutator
- func (b *ComponentsMutator) ClearSchemas() *ComponentsMutator
- func (b *ComponentsMutator) ClearSecuritySchemes() *ComponentsMutator
- func (b *ComponentsMutator) Do() error
- func (b *ComponentsMutator) Example(key ExampleMapKey, value Example) *ComponentsMutator
- func (b *ComponentsMutator) Header(key HeaderMapKey, value Header) *ComponentsMutator
- func (b *ComponentsMutator) Link(key LinkMapKey, value Link) *ComponentsMutator
- func (b *ComponentsMutator) Parameter(key ParameterMapKey, value Parameter) *ComponentsMutator
- func (b *ComponentsMutator) RequestBody(key RequestBodyMapKey, value RequestBody) *ComponentsMutator
- func (b *ComponentsMutator) Response(key ResponseMapKey, value Response) *ComponentsMutator
- func (b *ComponentsMutator) Schema(key SchemaMapKey, value Schema) *ComponentsMutator
- func (b *ComponentsMutator) SecurityScheme(key SecuritySchemeMapKey, value SecurityScheme) *ComponentsMutator
- type ComponentsVisitor
- type Contact
- type ContactBuilder
- func (b *ContactBuilder) Build(options ...Option) (Contact, error)
- func (b *ContactBuilder) Email(v string) *ContactBuilder
- func (b *ContactBuilder) MustBuild(options ...Option) Contact
- func (b *ContactBuilder) Name(v string) *ContactBuilder
- func (b *ContactBuilder) Reference(v string) *ContactBuilder
- func (b *ContactBuilder) URL(v string) *ContactBuilder
- type ContactMutator
- type ContactVisitor
- type Discriminator
- type DiscriminatorBuilder
- func (b *DiscriminatorBuilder) Build(options ...Option) (Discriminator, error)
- func (b *DiscriminatorBuilder) Mapping(v map[string]string) *DiscriminatorBuilder
- func (b *DiscriminatorBuilder) MustBuild(options ...Option) Discriminator
- func (b *DiscriminatorBuilder) Reference(v string) *DiscriminatorBuilder
- type DiscriminatorMutator
- type DiscriminatorVisitor
- type Encoding
- type EncodingBuilder
- func (b *EncodingBuilder) AllowReserved(v bool) *EncodingBuilder
- func (b *EncodingBuilder) Build(options ...Option) (Encoding, error)
- func (b *EncodingBuilder) ContentType(v string) *EncodingBuilder
- func (b *EncodingBuilder) Explode(v bool) *EncodingBuilder
- func (b *EncodingBuilder) Headers(v map[string]Header) *EncodingBuilder
- func (b *EncodingBuilder) MustBuild(options ...Option) Encoding
- func (b *EncodingBuilder) Reference(v string) *EncodingBuilder
- type EncodingMap
- type EncodingMapIterator
- type EncodingMapKey
- type EncodingMutator
- func (b *EncodingMutator) AllowReserved(v bool) *EncodingMutator
- func (b *EncodingMutator) ClearHeaders() *EncodingMutator
- func (b *EncodingMutator) ContentType(v string) *EncodingMutator
- func (b *EncodingMutator) Do() error
- func (b *EncodingMutator) Explode(v bool) *EncodingMutator
- func (b *EncodingMutator) Header(key HeaderMapKey, value Header) *EncodingMutator
- func (b *EncodingMutator) Name(v string) *EncodingMutator
- type EncodingVisitor
- type Example
- type ExampleBuilder
- func (b *ExampleBuilder) Build(options ...Option) (Example, error)
- func (b *ExampleBuilder) Description(v string) *ExampleBuilder
- func (b *ExampleBuilder) ExternalValue(v string) *ExampleBuilder
- func (b *ExampleBuilder) MustBuild(options ...Option) Example
- func (b *ExampleBuilder) Reference(v string) *ExampleBuilder
- func (b *ExampleBuilder) Value(v interface{}) *ExampleBuilder
- type ExampleMap
- type ExampleMapIterator
- type ExampleMapKey
- type ExampleMutator
- type ExampleVisitor
- type Extensions
- type ExternalDocumentation
- type ExternalDocumentationBuilder
- func (b *ExternalDocumentationBuilder) Build(options ...Option) (ExternalDocumentation, error)
- func (b *ExternalDocumentationBuilder) Description(v string) *ExternalDocumentationBuilder
- func (b *ExternalDocumentationBuilder) MustBuild(options ...Option) ExternalDocumentation
- func (b *ExternalDocumentationBuilder) Reference(v string) *ExternalDocumentationBuilder
- type ExternalDocumentationMutator
- type ExternalDocumentationVisitor
- type Header
- type HeaderBuilder
- func (b *HeaderBuilder) AllowEmptyValue(v bool) *HeaderBuilder
- func (b *HeaderBuilder) AllowReserved(v bool) *HeaderBuilder
- func (b *HeaderBuilder) Build(options ...Option) (Header, error)
- func (b *HeaderBuilder) Content(v map[string]MediaType) *HeaderBuilder
- func (b *HeaderBuilder) Deprecated(v bool) *HeaderBuilder
- func (b *HeaderBuilder) Description(v string) *HeaderBuilder
- func (b *HeaderBuilder) Examples(v map[string]Example) *HeaderBuilder
- func (b *HeaderBuilder) Explode(v bool) *HeaderBuilder
- func (b *HeaderBuilder) In(v Location) *HeaderBuilder
- func (b *HeaderBuilder) MustBuild(options ...Option) Header
- func (b *HeaderBuilder) Reference(v string) *HeaderBuilder
- func (b *HeaderBuilder) Required(v bool) *HeaderBuilder
- func (b *HeaderBuilder) Schema(v Schema) *HeaderBuilder
- type HeaderMap
- type HeaderMapIterator
- type HeaderMapKey
- type HeaderMutator
- func (b *HeaderMutator) AllowEmptyValue(v bool) *HeaderMutator
- func (b *HeaderMutator) AllowReserved(v bool) *HeaderMutator
- func (b *HeaderMutator) ClearContent() *HeaderMutator
- func (b *HeaderMutator) ClearExamples() *HeaderMutator
- func (b *HeaderMutator) Content(key MediaTypeMapKey, value MediaType) *HeaderMutator
- func (b *HeaderMutator) Deprecated(v bool) *HeaderMutator
- func (b *HeaderMutator) Description(v string) *HeaderMutator
- func (b *HeaderMutator) Do() error
- func (b *HeaderMutator) Example(key ExampleMapKey, value Example) *HeaderMutator
- func (b *HeaderMutator) Explode(v bool) *HeaderMutator
- func (b *HeaderMutator) In(v Location) *HeaderMutator
- func (b *HeaderMutator) Required(v bool) *HeaderMutator
- func (b *HeaderMutator) Schema(v Schema) *HeaderMutator
- type HeaderVisitor
- type Info
- type InfoBuilder
- func (b *InfoBuilder) Build(options ...Option) (Info, error)
- func (b *InfoBuilder) Contact(v Contact) *InfoBuilder
- func (b *InfoBuilder) Description(v string) *InfoBuilder
- func (b *InfoBuilder) License(v License) *InfoBuilder
- func (b *InfoBuilder) MustBuild(options ...Option) Info
- func (b *InfoBuilder) Reference(v string) *InfoBuilder
- func (b *InfoBuilder) TermsOfService(v string) *InfoBuilder
- func (b *InfoBuilder) Version(v string) *InfoBuilder
- type InfoMutator
- func (b *InfoMutator) Contact(v Contact) *InfoMutator
- func (b *InfoMutator) Description(v string) *InfoMutator
- func (b *InfoMutator) Do() error
- func (b *InfoMutator) License(v License) *InfoMutator
- func (b *InfoMutator) TermsOfService(v string) *InfoMutator
- func (b *InfoMutator) Title(v string) *InfoMutator
- func (b *InfoMutator) Version(v string) *InfoMutator
- type InfoVisitor
- type InterfaceList
- type InterfaceListIterator
- type InterfaceMap
- type InterfaceMapIterator
- type InterfaceMapKey
- type License
- type LicenseBuilder
- type LicenseMutator
- type LicenseVisitor
- type Link
- type LinkBuilder
- func (b *LinkBuilder) Build(options ...Option) (Link, error)
- func (b *LinkBuilder) Description(v string) *LinkBuilder
- func (b *LinkBuilder) MustBuild(options ...Option) Link
- func (b *LinkBuilder) OperationID(v string) *LinkBuilder
- func (b *LinkBuilder) OperationRef(v string) *LinkBuilder
- func (b *LinkBuilder) Parameters(v map[string]interface{}) *LinkBuilder
- func (b *LinkBuilder) Reference(v string) *LinkBuilder
- func (b *LinkBuilder) RequestBody(v interface{}) *LinkBuilder
- func (b *LinkBuilder) Server(v Server) *LinkBuilder
- type LinkMap
- type LinkMapIterator
- type LinkMapKey
- type LinkMutator
- func (b *LinkMutator) ClearParameters() *LinkMutator
- func (b *LinkMutator) Description(v string) *LinkMutator
- func (b *LinkMutator) Do() error
- func (b *LinkMutator) Name(v string) *LinkMutator
- func (b *LinkMutator) OperationID(v string) *LinkMutator
- func (b *LinkMutator) OperationRef(v string) *LinkMutator
- func (b *LinkMutator) Parameter(key InterfaceMapKey, value interface{}) *LinkMutator
- func (b *LinkMutator) RequestBody(v interface{}) *LinkMutator
- func (b *LinkMutator) Server(v Server) *LinkMutator
- type LinkVisitor
- type Location
- type MapQueryJSON
- type MediaType
- type MediaTypeBuilder
- func (b *MediaTypeBuilder) Build(options ...Option) (MediaType, error)
- func (b *MediaTypeBuilder) Encoding(v map[string]Encoding) *MediaTypeBuilder
- func (b *MediaTypeBuilder) Examples(v map[string]Example) *MediaTypeBuilder
- func (b *MediaTypeBuilder) MustBuild(options ...Option) MediaType
- func (b *MediaTypeBuilder) Reference(v string) *MediaTypeBuilder
- func (b *MediaTypeBuilder) Schema(v Schema) *MediaTypeBuilder
- type MediaTypeListIterator
- type MediaTypeMap
- type MediaTypeMapIterator
- type MediaTypeMapKey
- type MediaTypeMutator
- func (b *MediaTypeMutator) ClearEncoding() *MediaTypeMutator
- func (b *MediaTypeMutator) ClearExamples() *MediaTypeMutator
- func (b *MediaTypeMutator) Do() error
- func (b *MediaTypeMutator) Encoding(key EncodingMapKey, value Encoding) *MediaTypeMutator
- func (b *MediaTypeMutator) Example(key ExampleMapKey, value Example) *MediaTypeMutator
- func (b *MediaTypeMutator) Mime(v string) *MediaTypeMutator
- func (b *MediaTypeMutator) Name(v string) *MediaTypeMutator
- func (b *MediaTypeMutator) Schema(v Schema) *MediaTypeMutator
- type MediaTypeVisitor
- type OAuthFlow
- type OAuthFlowBuilder
- func (b *OAuthFlowBuilder) AuthorizationURL(v string) *OAuthFlowBuilder
- func (b *OAuthFlowBuilder) Build(options ...Option) (OAuthFlow, error)
- func (b *OAuthFlowBuilder) MustBuild(options ...Option) OAuthFlow
- func (b *OAuthFlowBuilder) Reference(v string) *OAuthFlowBuilder
- func (b *OAuthFlowBuilder) RefreshURL(v string) *OAuthFlowBuilder
- func (b *OAuthFlowBuilder) Scopes(v map[string]string) *OAuthFlowBuilder
- func (b *OAuthFlowBuilder) TokenURL(v string) *OAuthFlowBuilder
- type OAuthFlowMutator
- func (b *OAuthFlowMutator) AuthorizationURL(v string) *OAuthFlowMutator
- func (b *OAuthFlowMutator) ClearScopes() *OAuthFlowMutator
- func (b *OAuthFlowMutator) Do() error
- func (b *OAuthFlowMutator) RefreshURL(v string) *OAuthFlowMutator
- func (b *OAuthFlowMutator) Scope(key ScopeMapKey, value string) *OAuthFlowMutator
- func (b *OAuthFlowMutator) TokenURL(v string) *OAuthFlowMutator
- type OAuthFlowVisitor
- type OAuthFlows
- type OAuthFlowsBuilder
- func (b *OAuthFlowsBuilder) AuthorizationCode(v OAuthFlow) *OAuthFlowsBuilder
- func (b *OAuthFlowsBuilder) Build(options ...Option) (OAuthFlows, error)
- func (b *OAuthFlowsBuilder) ClientCredentials(v OAuthFlow) *OAuthFlowsBuilder
- func (b *OAuthFlowsBuilder) Implicit(v OAuthFlow) *OAuthFlowsBuilder
- func (b *OAuthFlowsBuilder) MustBuild(options ...Option) OAuthFlows
- func (b *OAuthFlowsBuilder) Password(v OAuthFlow) *OAuthFlowsBuilder
- func (b *OAuthFlowsBuilder) Reference(v string) *OAuthFlowsBuilder
- type OAuthFlowsMutator
- func (b *OAuthFlowsMutator) AuthorizationCode(v OAuthFlow) *OAuthFlowsMutator
- func (b *OAuthFlowsMutator) ClientCredentials(v OAuthFlow) *OAuthFlowsMutator
- func (b *OAuthFlowsMutator) Do() error
- func (b *OAuthFlowsMutator) Implicit(v OAuthFlow) *OAuthFlowsMutator
- func (b *OAuthFlowsMutator) Password(v OAuthFlow) *OAuthFlowsMutator
- type OAuthFlowsVisitor
- type OpenAPI
- type OpenAPIBuilder
- func (b *OpenAPIBuilder) Build(options ...Option) (OpenAPI, error)
- func (b *OpenAPIBuilder) Components(v Components) *OpenAPIBuilder
- func (b *OpenAPIBuilder) ExternalDocs(v ExternalDocumentation) *OpenAPIBuilder
- func (b *OpenAPIBuilder) MustBuild(options ...Option) OpenAPI
- func (b *OpenAPIBuilder) Reference(v string) *OpenAPIBuilder
- func (b *OpenAPIBuilder) Security(v SecurityRequirement) *OpenAPIBuilder
- func (b *OpenAPIBuilder) Servers(v []Server) *OpenAPIBuilder
- func (b *OpenAPIBuilder) Tags(v []Tag) *OpenAPIBuilder
- func (b *OpenAPIBuilder) Version(v string) *OpenAPIBuilder
- type OpenAPIMutator
- func (b *OpenAPIMutator) ClearServers() *OpenAPIMutator
- func (b *OpenAPIMutator) ClearTags() *OpenAPIMutator
- func (b *OpenAPIMutator) Components(v Components) *OpenAPIMutator
- func (b *OpenAPIMutator) Do() error
- func (b *OpenAPIMutator) ExternalDocs(v ExternalDocumentation) *OpenAPIMutator
- func (b *OpenAPIMutator) Info(v Info) *OpenAPIMutator
- func (b *OpenAPIMutator) Paths(v Paths) *OpenAPIMutator
- func (b *OpenAPIMutator) Security(v SecurityRequirement) *OpenAPIMutator
- func (b *OpenAPIMutator) Server(value Server) *OpenAPIMutator
- func (b *OpenAPIMutator) Tag(value Tag) *OpenAPIMutator
- func (b *OpenAPIMutator) Version(v string) *OpenAPIMutator
- type OpenAPIVisitor
- type Operation
- type OperationBuilder
- func (b *OperationBuilder) Build(options ...Option) (Operation, error)
- func (b *OperationBuilder) Callbacks(v map[string]Callback) *OperationBuilder
- func (b *OperationBuilder) Deprecated(v bool) *OperationBuilder
- func (b *OperationBuilder) Description(v string) *OperationBuilder
- func (b *OperationBuilder) ExternalDocs(v ExternalDocumentation) *OperationBuilder
- func (b *OperationBuilder) MustBuild(options ...Option) Operation
- func (b *OperationBuilder) OperationID(v string) *OperationBuilder
- func (b *OperationBuilder) Parameter(p Parameter) *OperationBuilder
- func (b *OperationBuilder) Parameters(v []Parameter) *OperationBuilder
- func (b *OperationBuilder) Reference(v string) *OperationBuilder
- func (b *OperationBuilder) RequestBody(v RequestBody) *OperationBuilder
- func (b *OperationBuilder) Security(v []SecurityRequirement) *OperationBuilder
- func (b *OperationBuilder) Servers(v []Server) *OperationBuilder
- func (b *OperationBuilder) Summary(v string) *OperationBuilder
- func (b *OperationBuilder) Tag(s string) *OperationBuilder
- func (b *OperationBuilder) Tags(v []string) *OperationBuilder
- type OperationListIterator
- type OperationMutator
- func (b *OperationMutator) Callback(key CallbackMapKey, value Callback) *OperationMutator
- func (b *OperationMutator) ClearCallbacks() *OperationMutator
- func (b *OperationMutator) ClearParameters() *OperationMutator
- func (b *OperationMutator) ClearSecurity() *OperationMutator
- func (b *OperationMutator) ClearServers() *OperationMutator
- func (b *OperationMutator) ClearTags() *OperationMutator
- func (b *OperationMutator) Deprecated(v bool) *OperationMutator
- func (b *OperationMutator) Description(v string) *OperationMutator
- func (b *OperationMutator) Do() error
- func (b *OperationMutator) ExternalDocs(v ExternalDocumentation) *OperationMutator
- func (b *OperationMutator) OperationID(v string) *OperationMutator
- func (b *OperationMutator) Parameter(value Parameter) *OperationMutator
- func (b *OperationMutator) RequestBody(v RequestBody) *OperationMutator
- func (b *OperationMutator) Responses(v Responses) *OperationMutator
- func (b *OperationMutator) Security(value SecurityRequirement) *OperationMutator
- func (b *OperationMutator) Server(value Server) *OperationMutator
- func (b *OperationMutator) Summary(v string) *OperationMutator
- func (b *OperationMutator) Tag(value string) *OperationMutator
- type OperationVisitor
- type Option
- type Parameter
- type ParameterBuilder
- func (b *ParameterBuilder) AllowEmptyValue(v bool) *ParameterBuilder
- func (b *ParameterBuilder) AllowReserved(v bool) *ParameterBuilder
- func (b *ParameterBuilder) Build(options ...Option) (Parameter, error)
- func (b *ParameterBuilder) Content(v map[string]MediaType) *ParameterBuilder
- func (b *ParameterBuilder) Deprecated(v bool) *ParameterBuilder
- func (b *ParameterBuilder) Description(v string) *ParameterBuilder
- func (b *ParameterBuilder) Examples(v map[string]Example) *ParameterBuilder
- func (b *ParameterBuilder) Explode(v bool) *ParameterBuilder
- func (b *ParameterBuilder) MustBuild(options ...Option) Parameter
- func (b *ParameterBuilder) Reference(v string) *ParameterBuilder
- func (b *ParameterBuilder) Required(v bool) *ParameterBuilder
- func (b *ParameterBuilder) Schema(v Schema) *ParameterBuilder
- type ParameterList
- type ParameterListIterator
- type ParameterMap
- type ParameterMapIterator
- type ParameterMapKey
- type ParameterMutator
- func (b *ParameterMutator) AllowEmptyValue(v bool) *ParameterMutator
- func (b *ParameterMutator) AllowReserved(v bool) *ParameterMutator
- func (b *ParameterMutator) ClearContent() *ParameterMutator
- func (b *ParameterMutator) ClearExamples() *ParameterMutator
- func (b *ParameterMutator) Content(key MediaTypeMapKey, value MediaType) *ParameterMutator
- func (b *ParameterMutator) Deprecated(v bool) *ParameterMutator
- func (b *ParameterMutator) Description(v string) *ParameterMutator
- func (b *ParameterMutator) Do() error
- func (b *ParameterMutator) Example(key ExampleMapKey, value Example) *ParameterMutator
- func (b *ParameterMutator) Explode(v bool) *ParameterMutator
- func (b *ParameterMutator) In(v Location) *ParameterMutator
- func (b *ParameterMutator) Name(v string) *ParameterMutator
- func (b *ParameterMutator) Required(v bool) *ParameterMutator
- func (b *ParameterMutator) Schema(v Schema) *ParameterMutator
- type ParameterVisitor
- type PathItem
- type PathItemBuilder
- func (b *PathItemBuilder) Build(options ...Option) (PathItem, error)
- func (m *PathItemBuilder) Delete(v Operation) *PathItemBuilder
- func (b *PathItemBuilder) Description(v string) *PathItemBuilder
- func (b *PathItemBuilder) Get(oper Operation) *PathItemBuilder
- func (m *PathItemBuilder) Head(v Operation) *PathItemBuilder
- func (b *PathItemBuilder) MustBuild(options ...Option) PathItem
- func (m *PathItemBuilder) Options(v Operation) *PathItemBuilder
- func (b *PathItemBuilder) Parameters(v []Parameter) *PathItemBuilder
- func (m *PathItemBuilder) Patch(v Operation) *PathItemBuilder
- func (b *PathItemBuilder) Path(v string) *PathItemBuilder
- func (m *PathItemBuilder) Post(v Operation) *PathItemBuilder
- func (m *PathItemBuilder) Put(v Operation) *PathItemBuilder
- func (b *PathItemBuilder) Reference(v string) *PathItemBuilder
- func (b *PathItemBuilder) Servers(v []Server) *PathItemBuilder
- func (b *PathItemBuilder) Summary(v string) *PathItemBuilder
- func (m *PathItemBuilder) Trace(v Operation) *PathItemBuilder
- type PathItemListIterator
- type PathItemMap
- type PathItemMapIterator
- type PathItemMapKey
- type PathItemMutator
- func (b *PathItemMutator) ClearParameters() *PathItemMutator
- func (b *PathItemMutator) ClearServers() *PathItemMutator
- func (m *PathItemMutator) Delete(v Operation) *PathItemMutator
- func (b *PathItemMutator) Description(v string) *PathItemMutator
- func (b *PathItemMutator) Do() error
- func (m *PathItemMutator) Get(v Operation) *PathItemMutator
- func (m *PathItemMutator) Head(v Operation) *PathItemMutator
- func (b *PathItemMutator) Name(v string) *PathItemMutator
- func (m *PathItemMutator) Options(v Operation) *PathItemMutator
- func (b *PathItemMutator) Parameter(value Parameter) *PathItemMutator
- func (m *PathItemMutator) Patch(v Operation) *PathItemMutator
- func (b *PathItemMutator) Path(v string) *PathItemMutator
- func (m *PathItemMutator) Post(v Operation) *PathItemMutator
- func (m *PathItemMutator) Put(v Operation) *PathItemMutator
- func (b *PathItemMutator) Server(value Server) *PathItemMutator
- func (b *PathItemMutator) Summary(v string) *PathItemMutator
- func (m *PathItemMutator) Trace(v Operation) *PathItemMutator
- type PathItemVisitor
- type Paths
- type PathsBuilder
- func (b *PathsBuilder) Build(options ...Option) (Paths, error)
- func (b *PathsBuilder) MustBuild(options ...Option) Paths
- func (b *PathsBuilder) Path(path string, item PathItem) *PathsBuilder
- func (b *PathsBuilder) Paths(v map[string]PathItem) *PathsBuilder
- func (b *PathsBuilder) Reference(v string) *PathsBuilder
- type PathsMutator
- type PathsVisitor
- type PrimitiveType
- type QueryJSONer
- type RequestBody
- type RequestBodyBuilder
- func (b *RequestBodyBuilder) Build(options ...Option) (RequestBody, error)
- func (b *RequestBodyBuilder) Content(mime MediaTypeMapKey, mt MediaType) *RequestBodyBuilder
- func (b *RequestBodyBuilder) Description(v string) *RequestBodyBuilder
- func (b *RequestBodyBuilder) MustBuild(options ...Option) RequestBody
- func (b *RequestBodyBuilder) Reference(v string) *RequestBodyBuilder
- func (b *RequestBodyBuilder) Required(v bool) *RequestBodyBuilder
- type RequestBodyMap
- type RequestBodyMapIterator
- type RequestBodyMapKey
- type RequestBodyMutator
- func (b *RequestBodyMutator) Content(mime MediaTypeMapKey, mt MediaType) *RequestBodyMutator
- func (b *RequestBodyMutator) Description(v string) *RequestBodyMutator
- func (b *RequestBodyMutator) Do() error
- func (b *RequestBodyMutator) Name(v string) *RequestBodyMutator
- func (b *RequestBodyMutator) Required(v bool) *RequestBodyMutator
- type RequestBodyVisitor
- type Resolver
- type Response
- type ResponseBuilder
- func (b *ResponseBuilder) Build(options ...Option) (Response, error)
- func (b *ResponseBuilder) Content(mime string, desc MediaType) *ResponseBuilder
- func (b *ResponseBuilder) Header(name string, hdr Header) *ResponseBuilder
- func (b *ResponseBuilder) Headers(v map[string]Header) *ResponseBuilder
- func (b *ResponseBuilder) MustBuild(options ...Option) Response
- func (b *ResponseBuilder) Reference(v string) *ResponseBuilder
- type ResponseMap
- type ResponseMapIterator
- type ResponseMapKey
- type ResponseMutator
- func (b *ResponseMutator) ClearContent() *ResponseMutator
- func (b *ResponseMutator) ClearHeaders() *ResponseMutator
- func (b *ResponseMutator) ClearLinks() *ResponseMutator
- func (b *ResponseMutator) Content(key MediaTypeMapKey, value MediaType) *ResponseMutator
- func (b *ResponseMutator) Description(v string) *ResponseMutator
- func (b *ResponseMutator) Do() error
- func (b *ResponseMutator) Header(key HeaderMapKey, value Header) *ResponseMutator
- func (b *ResponseMutator) Link(key LinkMapKey, value Link) *ResponseMutator
- func (b *ResponseMutator) Name(v string) *ResponseMutator
- type ResponseVisitor
- type Responses
- type ResponsesBuilder
- func (b *ResponsesBuilder) Build(options ...Option) (Responses, error)
- func (b *ResponsesBuilder) Default(v Response) *ResponsesBuilder
- func (b *ResponsesBuilder) MustBuild(options ...Option) Responses
- func (b *ResponsesBuilder) Reference(v string) *ResponsesBuilder
- func (b *ResponsesBuilder) Response(code string, v Response) *ResponsesBuilder
- type ResponsesMutator
- type ResponsesVisitor
- type Schema
- type SchemaBuilder
- func (b *SchemaBuilder) AllOf(v []Schema) *SchemaBuilder
- func (b *SchemaBuilder) AnyOf(v []Schema) *SchemaBuilder
- func (b *SchemaBuilder) Build(options ...Option) (Schema, error)
- func (b *SchemaBuilder) Default(v interface{}) *SchemaBuilder
- func (b *SchemaBuilder) Deprecated(v bool) *SchemaBuilder
- func (b *SchemaBuilder) Discriminator(v Discriminator) *SchemaBuilder
- func (b *SchemaBuilder) Enum(v []interface{}) *SchemaBuilder
- func (b *SchemaBuilder) Example(v interface{}) *SchemaBuilder
- func (b *SchemaBuilder) ExclusiveMaximum(v float64) *SchemaBuilder
- func (b *SchemaBuilder) ExclusiveMinimum(v float64) *SchemaBuilder
- func (b *SchemaBuilder) ExternalDocs(v ExternalDocumentation) *SchemaBuilder
- func (b *SchemaBuilder) Format(v string) *SchemaBuilder
- func (b *SchemaBuilder) Items(v Schema) *SchemaBuilder
- func (b *SchemaBuilder) MaxItems(v int) *SchemaBuilder
- func (b *SchemaBuilder) MaxLength(v int) *SchemaBuilder
- func (b *SchemaBuilder) MaxProperties(v int) *SchemaBuilder
- func (b *SchemaBuilder) Maximum(v float64) *SchemaBuilder
- func (b *SchemaBuilder) MinItems(v int) *SchemaBuilder
- func (b *SchemaBuilder) MinLength(v int) *SchemaBuilder
- func (b *SchemaBuilder) MinProperties(v int) *SchemaBuilder
- func (b *SchemaBuilder) Minimum(v float64) *SchemaBuilder
- func (b *SchemaBuilder) MultipleOf(v float64) *SchemaBuilder
- func (b *SchemaBuilder) MustBuild(options ...Option) Schema
- func (b *SchemaBuilder) Not(v Schema) *SchemaBuilder
- func (b *SchemaBuilder) Nullable(v bool) *SchemaBuilder
- func (b *SchemaBuilder) OneOf(v []Schema) *SchemaBuilder
- func (b *SchemaBuilder) Pattern(v string) *SchemaBuilder
- func (b *SchemaBuilder) Properties(v map[string]Schema) *SchemaBuilder
- func (b *SchemaBuilder) Property(name string, s Schema) *SchemaBuilder
- func (b *SchemaBuilder) ReadOnly(v bool) *SchemaBuilder
- func (b *SchemaBuilder) Reference(v string) *SchemaBuilder
- func (b *SchemaBuilder) Required(v []string) *SchemaBuilder
- func (b *SchemaBuilder) Title(v string) *SchemaBuilder
- func (b *SchemaBuilder) Type(v PrimitiveType) *SchemaBuilder
- func (b *SchemaBuilder) UniqueItems(v bool) *SchemaBuilder
- func (b *SchemaBuilder) WriteOnly(v bool) *SchemaBuilder
- type SchemaList
- type SchemaListIterator
- type SchemaMap
- type SchemaMapIterator
- type SchemaMapKey
- type SchemaMutator
- func (b *SchemaMutator) AllOf(value Schema) *SchemaMutator
- func (b *SchemaMutator) AnyOf(value Schema) *SchemaMutator
- func (b *SchemaMutator) ClearAllOf() *SchemaMutator
- func (b *SchemaMutator) ClearAnyOf() *SchemaMutator
- func (b *SchemaMutator) ClearEnum() *SchemaMutator
- func (b *SchemaMutator) ClearOneOf() *SchemaMutator
- func (b *SchemaMutator) ClearProperties() *SchemaMutator
- func (b *SchemaMutator) ClearRequired() *SchemaMutator
- func (b *SchemaMutator) Default(v interface{}) *SchemaMutator
- func (b *SchemaMutator) Deprecated(v bool) *SchemaMutator
- func (b *SchemaMutator) Discriminator(v Discriminator) *SchemaMutator
- func (b *SchemaMutator) Do() error
- func (b *SchemaMutator) Enum(value interface{}) *SchemaMutator
- func (b *SchemaMutator) Example(v interface{}) *SchemaMutator
- func (b *SchemaMutator) ExclusiveMaximum(v float64) *SchemaMutator
- func (b *SchemaMutator) ExclusiveMinimum(v float64) *SchemaMutator
- func (b *SchemaMutator) ExternalDocs(v ExternalDocumentation) *SchemaMutator
- func (b *SchemaMutator) Format(v string) *SchemaMutator
- func (b *SchemaMutator) Items(v Schema) *SchemaMutator
- func (b *SchemaMutator) MaxItems(v int) *SchemaMutator
- func (b *SchemaMutator) MaxLength(v int) *SchemaMutator
- func (b *SchemaMutator) MaxProperties(v int) *SchemaMutator
- func (b *SchemaMutator) Maximum(v float64) *SchemaMutator
- func (b *SchemaMutator) MinItems(v int) *SchemaMutator
- func (b *SchemaMutator) MinLength(v int) *SchemaMutator
- func (b *SchemaMutator) MinProperties(v int) *SchemaMutator
- func (b *SchemaMutator) Minimum(v float64) *SchemaMutator
- func (b *SchemaMutator) MultipleOf(v float64) *SchemaMutator
- func (b *SchemaMutator) Name(v string) *SchemaMutator
- func (b *SchemaMutator) Not(v Schema) *SchemaMutator
- func (b *SchemaMutator) Nullable(v bool) *SchemaMutator
- func (b *SchemaMutator) OneOf(value Schema) *SchemaMutator
- func (b *SchemaMutator) Pattern(v string) *SchemaMutator
- func (b *SchemaMutator) Property(key SchemaMapKey, value Schema) *SchemaMutator
- func (b *SchemaMutator) ReadOnly(v bool) *SchemaMutator
- func (b *SchemaMutator) Required(value string) *SchemaMutator
- func (b *SchemaMutator) Title(v string) *SchemaMutator
- func (b *SchemaMutator) Type(v PrimitiveType) *SchemaMutator
- func (b *SchemaMutator) UniqueItems(v bool) *SchemaMutator
- func (b *SchemaMutator) WriteOnly(v bool) *SchemaMutator
- type SchemaVisitor
- type ScopeMap
- type ScopeMapIterator
- type ScopeMapKey
- type SecurityRequirement
- type SecurityRequirementBuilder
- func (b *SecurityRequirementBuilder) Build(options ...Option) (SecurityRequirement, error)
- func (b *SecurityRequirementBuilder) MustBuild(options ...Option) SecurityRequirement
- func (b *SecurityRequirementBuilder) Reference(v string) *SecurityRequirementBuilder
- func (b *SecurityRequirementBuilder) Schemes(v map[string][]string) *SecurityRequirementBuilder
- type SecurityRequirementList
- type SecurityRequirementListIterator
- type SecurityRequirementMutator
- type SecurityRequirementVisitor
- type SecurityScheme
- type SecuritySchemeBuilder
- func (b *SecuritySchemeBuilder) BearerFormat(v string) *SecuritySchemeBuilder
- func (b *SecuritySchemeBuilder) Build(options ...Option) (SecurityScheme, error)
- func (b *SecuritySchemeBuilder) Description(v string) *SecuritySchemeBuilder
- func (b *SecuritySchemeBuilder) MustBuild(options ...Option) SecurityScheme
- func (b *SecuritySchemeBuilder) Reference(v string) *SecuritySchemeBuilder
- type SecuritySchemeMap
- type SecuritySchemeMapIterator
- type SecuritySchemeMapKey
- type SecuritySchemeMutator
- func (b *SecuritySchemeMutator) BearerFormat(v string) *SecuritySchemeMutator
- func (b *SecuritySchemeMutator) Description(v string) *SecuritySchemeMutator
- func (b *SecuritySchemeMutator) Do() error
- func (b *SecuritySchemeMutator) Flows(v OAuthFlows) *SecuritySchemeMutator
- func (b *SecuritySchemeMutator) In(v string) *SecuritySchemeMutator
- func (b *SecuritySchemeMutator) Name(v string) *SecuritySchemeMutator
- func (b *SecuritySchemeMutator) OpenIDConnectURL(v string) *SecuritySchemeMutator
- func (b *SecuritySchemeMutator) Scheme(v string) *SecuritySchemeMutator
- func (b *SecuritySchemeMutator) Type(v string) *SecuritySchemeMutator
- type SecuritySchemeVisitor
- type Server
- type ServerBuilder
- func (b *ServerBuilder) Build(options ...Option) (Server, error)
- func (b *ServerBuilder) Description(v string) *ServerBuilder
- func (b *ServerBuilder) MustBuild(options ...Option) Server
- func (b *ServerBuilder) Reference(v string) *ServerBuilder
- func (b *ServerBuilder) Variables(v map[string]ServerVariable) *ServerBuilder
- type ServerList
- type ServerListIterator
- type ServerMutator
- func (b *ServerMutator) ClearVariables() *ServerMutator
- func (b *ServerMutator) Description(v string) *ServerMutator
- func (b *ServerMutator) Do() error
- func (b *ServerMutator) URL(v string) *ServerMutator
- func (b *ServerMutator) Variable(key ServerVariableMapKey, value ServerVariable) *ServerMutator
- type ServerVariable
- type ServerVariableBuilder
- func (b *ServerVariableBuilder) Build(options ...Option) (ServerVariable, error)
- func (b *ServerVariableBuilder) Description(v string) *ServerVariableBuilder
- func (b *ServerVariableBuilder) Enum(v []string) *ServerVariableBuilder
- func (b *ServerVariableBuilder) MustBuild(options ...Option) ServerVariable
- func (b *ServerVariableBuilder) Reference(v string) *ServerVariableBuilder
- type ServerVariableMap
- type ServerVariableMapIterator
- type ServerVariableMapKey
- type ServerVariableMutator
- func (b *ServerVariableMutator) ClearEnum() *ServerVariableMutator
- func (b *ServerVariableMutator) Default(v string) *ServerVariableMutator
- func (b *ServerVariableMutator) Description(v string) *ServerVariableMutator
- func (b *ServerVariableMutator) Do() error
- func (b *ServerVariableMutator) Enum(value string) *ServerVariableMutator
- func (b *ServerVariableMutator) Name(v string) *ServerVariableMutator
- type ServerVariableVisitor
- type ServerVisitor
- type SliceQueryJSON
- type StringList
- type StringListIterator
- type StringListListIterator
- type StringListMap
- type StringListMapIterator
- type StringListMapKey
- type StringMap
- type StringMapIterator
- type StringMapKey
- type Tag
- type TagBuilder
- type TagList
- type TagListIterator
- type TagMutator
- type TagVisitor
- type Validator
Constants ¶
const ( DefaultSpecVersion = "0.0.1" DefaultVersion = "3.0.1" )
Variables ¶
var ErrVisitAbort = errors.New(`visit aborted (non-error)`)
Functions ¶
func CallbackFromJSON ¶
CallbackFromJSON constructs a Callback from JSON buffer. `dst` must be a pointer to `Callback`
func ComponentsFromJSON ¶
ComponentsFromJSON constructs a Components from JSON buffer. `dst` must be a pointer to `Components`
func ContactFromJSON ¶
ContactFromJSON constructs a Contact from JSON buffer. `dst` must be a pointer to `Contact`
func DiscriminatorFromJSON ¶
DiscriminatorFromJSON constructs a Discriminator from JSON buffer. `dst` must be a pointer to `Discriminator`
func EncodingFromJSON ¶
EncodingFromJSON constructs a Encoding from JSON buffer. `dst` must be a pointer to `Encoding`
func ExampleFromJSON ¶
ExampleFromJSON constructs a Example from JSON buffer. `dst` must be a pointer to `Example`
func ExternalDocumentationFromJSON ¶
ExternalDocumentationFromJSON constructs a ExternalDocumentation from JSON buffer. `dst` must be a pointer to `ExternalDocumentation`
func HeaderFromJSON ¶
HeaderFromJSON constructs a Header from JSON buffer. `dst` must be a pointer to `Header`
func InfoFromJSON ¶
InfoFromJSON constructs a Info from JSON buffer. `dst` must be a pointer to `Info`
func LicenseFromJSON ¶
LicenseFromJSON constructs a License from JSON buffer. `dst` must be a pointer to `License`
func LinkFromJSON ¶
LinkFromJSON constructs a Link from JSON buffer. `dst` must be a pointer to `Link`
func MediaTypeFromJSON ¶
MediaTypeFromJSON constructs a MediaType from JSON buffer. `dst` must be a pointer to `MediaType`
func OAuthFlowFromJSON ¶
OAuthFlowFromJSON constructs a OAuthFlow from JSON buffer. `dst` must be a pointer to `OAuthFlow`
func OAuthFlowsFromJSON ¶
OAuthFlowsFromJSON constructs a OAuthFlows from JSON buffer. `dst` must be a pointer to `OAuthFlows`
func OpenAPIFromJSON ¶
OpenAPIFromJSON constructs a OpenAPI from JSON buffer. `dst` must be a pointer to `OpenAPI`
func OperationFromJSON ¶
OperationFromJSON constructs a Operation from JSON buffer. `dst` must be a pointer to `Operation`
func ParameterFromJSON ¶
ParameterFromJSON constructs a Parameter from JSON buffer. `dst` must be a pointer to `Parameter`
func PathItemFromJSON ¶
PathItemFromJSON constructs a PathItem from JSON buffer. `dst` must be a pointer to `PathItem`
func PathsFromJSON ¶
PathsFromJSON constructs a Paths from JSON buffer. `dst` must be a pointer to `Paths`
func RequestBodyFromJSON ¶
RequestBodyFromJSON constructs a RequestBody from JSON buffer. `dst` must be a pointer to `RequestBody`
func ResponseFromJSON ¶
ResponseFromJSON constructs a Response from JSON buffer. `dst` must be a pointer to `Response`
func ResponsesFromJSON ¶
ResponsesFromJSON constructs a Responses from JSON buffer. `dst` must be a pointer to `Responses`
func SchemaFromJSON ¶
SchemaFromJSON constructs a Schema from JSON buffer. `dst` must be a pointer to `Schema`
func SecurityRequirementFromJSON ¶
SecurityRequirementFromJSON constructs a SecurityRequirement from JSON buffer. `dst` must be a pointer to `SecurityRequirement`
func SecuritySchemeFromJSON ¶
SecuritySchemeFromJSON constructs a SecurityScheme from JSON buffer. `dst` must be a pointer to `SecurityScheme`
func ServerFromJSON ¶
ServerFromJSON constructs a Server from JSON buffer. `dst` must be a pointer to `Server`
func ServerVariableFromJSON ¶
ServerVariableFromJSON constructs a ServerVariable from JSON buffer. `dst` must be a pointer to `ServerVariable`
func TagFromJSON ¶
TagFromJSON constructs a Tag from JSON buffer. `dst` must be a pointer to `Tag`
Types ¶
type CallbackBuilder ¶
type CallbackBuilder struct {
// contains filtered or unexported fields
}
CallbackBuilder is used to build an instance of Callback. The user must call `Build()` after providing all the necessary information to build an instance of Callback
func NewCallback ¶
func NewCallback() *CallbackBuilder
NewCallback creates a new builder object for Callback
func (*CallbackBuilder) Build ¶
func (b *CallbackBuilder) Build(options ...Option) (Callback, error)
Build finalizes the building process for Callback and returns the result
func (*CallbackBuilder) MustBuild ¶
func (b *CallbackBuilder) MustBuild(options ...Option) Callback
MustBuild is a convenience function for those time when you know that the result of the builder must be successful
func (*CallbackBuilder) Reference ¶
func (b *CallbackBuilder) Reference(v string) *CallbackBuilder
Reference sets the $ref (reference) field for object Callback.
func (*CallbackBuilder) URLs ¶
func (b *CallbackBuilder) URLs(v map[string]PathItem) *CallbackBuilder
URLs sets the URLs field for object Callback.
type CallbackMap ¶
type CallbackMap map[CallbackMapKey]Callback
func (*CallbackMap) Clear ¶
func (v *CallbackMap) Clear() error
func (CallbackMap) QueryJSON ¶
func (v CallbackMap) QueryJSON(path string) (ret interface{}, ok bool)
func (*CallbackMap) UnmarshalJSON ¶
func (v *CallbackMap) UnmarshalJSON(data []byte) error
func (*CallbackMap) Validate ¶
func (v *CallbackMap) Validate(recurse bool) error
Validate checks the correctness of values in CallbackMap
type CallbackMapIterator ¶
type CallbackMapIterator struct {
// contains filtered or unexported fields
}
func (*CallbackMapIterator) Item ¶
func (iter *CallbackMapIterator) Item() (string, Callback)
Item returns the next item in this iterator. Make sure to call Next() before hand to check if the iterator has more items
type CallbackMapKey ¶
type CallbackMapKey = string
type CallbackMutator ¶
type CallbackMutator struct {
// contains filtered or unexported fields
}
CallbackMutator is used to build an instance of Callback. The user must call `Do()` after providing all the necessary information to the new instance of Callback with new values
func MutateCallback ¶
func MutateCallback(v Callback) *CallbackMutator
MutateCallback creates a new mutator object for Callback
func (*CallbackMutator) Do ¶
func (b *CallbackMutator) Do() error
Do finalizes the matuation process for Callback and returns the result
func (*CallbackMutator) Name ¶
func (b *CallbackMutator) Name(v string) *CallbackMutator
Name sets the Name field for object Callback.
func (*CallbackMutator) URLs ¶
func (b *CallbackMutator) URLs(v map[string]PathItem) *CallbackMutator
URLs sets the URLs field for object Callback.
type CallbackVisitor ¶
CallbackVisitor is an interface for objects that knows how to process Callback elements while traversing the OpenAPI structure
type Components ¶
type Components interface { Schemas() *SchemaMapIterator Responses() *ResponseMapIterator Parameters() *ParameterMapIterator Examples() *ExampleMapIterator RequestBodies() *RequestBodyMapIterator Headers() *HeaderMapIterator SecuritySchemes() *SecuritySchemeMapIterator Links() *LinkMapIterator Callbacks() *CallbackMapIterator MarshalJSON() ([]byte, error) Clone() Components Validator }
type ComponentsBuilder ¶
type ComponentsBuilder struct {
// contains filtered or unexported fields
}
ComponentsBuilder is used to build an instance of Components. The user must call `Build()` after providing all the necessary information to build an instance of Components
func NewComponents ¶
func NewComponents() *ComponentsBuilder
NewComponents creates a new builder object for Components
func (*ComponentsBuilder) Build ¶
func (b *ComponentsBuilder) Build(options ...Option) (Components, error)
Build finalizes the building process for Components and returns the result
func (*ComponentsBuilder) Callbacks ¶
func (b *ComponentsBuilder) Callbacks(v map[string]Callback) *ComponentsBuilder
Callbacks sets the Callbacks field for object Components.
func (*ComponentsBuilder) Examples ¶
func (b *ComponentsBuilder) Examples(v map[string]Example) *ComponentsBuilder
Examples sets the Examples field for object Components.
func (*ComponentsBuilder) Headers ¶
func (b *ComponentsBuilder) Headers(v map[string]Header) *ComponentsBuilder
Headers sets the Headers field for object Components.
func (*ComponentsBuilder) Links ¶
func (b *ComponentsBuilder) Links(v map[string]Link) *ComponentsBuilder
Links sets the Links field for object Components.
func (*ComponentsBuilder) MustBuild ¶
func (b *ComponentsBuilder) MustBuild(options ...Option) Components
MustBuild is a convenience function for those time when you know that the result of the builder must be successful
func (*ComponentsBuilder) Parameters ¶
func (b *ComponentsBuilder) Parameters(v map[string]Parameter) *ComponentsBuilder
Parameters sets the Parameters field for object Components.
func (*ComponentsBuilder) Reference ¶
func (b *ComponentsBuilder) Reference(v string) *ComponentsBuilder
Reference sets the $ref (reference) field for object Components.
func (*ComponentsBuilder) RequestBodies ¶
func (b *ComponentsBuilder) RequestBodies(v map[string]RequestBody) *ComponentsBuilder
RequestBodies sets the RequestBodies field for object Components.
func (*ComponentsBuilder) Responses ¶
func (b *ComponentsBuilder) Responses(v map[string]Response) *ComponentsBuilder
Responses sets the Responses field for object Components.
func (*ComponentsBuilder) Schema ¶
func (b *ComponentsBuilder) Schema(name string, s Schema) *ComponentsBuilder
Schema sets the schema identified by `name` to `s`
func (*ComponentsBuilder) Schemas ¶
func (b *ComponentsBuilder) Schemas(v map[string]Schema) *ComponentsBuilder
Schemas sets the Schemas field for object Components.
func (*ComponentsBuilder) SecuritySchemes ¶
func (b *ComponentsBuilder) SecuritySchemes(v map[string]SecurityScheme) *ComponentsBuilder
SecuritySchemes sets the SecuritySchemes field for object Components.
type ComponentsMutator ¶
type ComponentsMutator struct {
// contains filtered or unexported fields
}
ComponentsMutator is used to build an instance of Components. The user must call `Do()` after providing all the necessary information to the new instance of Components with new values
func MutateComponents ¶
func MutateComponents(v Components) *ComponentsMutator
MutateComponents creates a new mutator object for Components
func (*ComponentsMutator) Callback ¶
func (b *ComponentsMutator) Callback(key CallbackMapKey, value Callback) *ComponentsMutator
func (*ComponentsMutator) ClearCallbacks ¶
func (b *ComponentsMutator) ClearCallbacks() *ComponentsMutator
func (*ComponentsMutator) ClearExamples ¶
func (b *ComponentsMutator) ClearExamples() *ComponentsMutator
func (*ComponentsMutator) ClearHeaders ¶
func (b *ComponentsMutator) ClearHeaders() *ComponentsMutator
func (*ComponentsMutator) ClearLinks ¶
func (b *ComponentsMutator) ClearLinks() *ComponentsMutator
func (*ComponentsMutator) ClearParameters ¶
func (b *ComponentsMutator) ClearParameters() *ComponentsMutator
func (*ComponentsMutator) ClearRequestBodies ¶
func (b *ComponentsMutator) ClearRequestBodies() *ComponentsMutator
func (*ComponentsMutator) ClearResponses ¶
func (b *ComponentsMutator) ClearResponses() *ComponentsMutator
func (*ComponentsMutator) ClearSchemas ¶
func (b *ComponentsMutator) ClearSchemas() *ComponentsMutator
func (*ComponentsMutator) ClearSecuritySchemes ¶
func (b *ComponentsMutator) ClearSecuritySchemes() *ComponentsMutator
func (*ComponentsMutator) Do ¶
func (b *ComponentsMutator) Do() error
Do finalizes the matuation process for Components and returns the result
func (*ComponentsMutator) Example ¶
func (b *ComponentsMutator) Example(key ExampleMapKey, value Example) *ComponentsMutator
func (*ComponentsMutator) Header ¶
func (b *ComponentsMutator) Header(key HeaderMapKey, value Header) *ComponentsMutator
func (*ComponentsMutator) Link ¶
func (b *ComponentsMutator) Link(key LinkMapKey, value Link) *ComponentsMutator
func (*ComponentsMutator) Parameter ¶
func (b *ComponentsMutator) Parameter(key ParameterMapKey, value Parameter) *ComponentsMutator
func (*ComponentsMutator) RequestBody ¶
func (b *ComponentsMutator) RequestBody(key RequestBodyMapKey, value RequestBody) *ComponentsMutator
func (*ComponentsMutator) Response ¶
func (b *ComponentsMutator) Response(key ResponseMapKey, value Response) *ComponentsMutator
func (*ComponentsMutator) Schema ¶
func (b *ComponentsMutator) Schema(key SchemaMapKey, value Schema) *ComponentsMutator
func (*ComponentsMutator) SecurityScheme ¶
func (b *ComponentsMutator) SecurityScheme(key SecuritySchemeMapKey, value SecurityScheme) *ComponentsMutator
type ComponentsVisitor ¶
type ComponentsVisitor interface {
VisitComponents(context.Context, Components) error
}
ComponentsVisitor is an interface for objects that knows how to process Components elements while traversing the OpenAPI structure
type Contact ¶
type Contact interface { Name() string URL() string Email() string MarshalJSON() ([]byte, error) Clone() Contact Validator }
Contact represents the contact object https://github.com/OAI/OpenAPI-Specification/blob/master/versions/3.0.1.md#contactObject
type ContactBuilder ¶
type ContactBuilder struct {
// contains filtered or unexported fields
}
ContactBuilder is used to build an instance of Contact. The user must call `Build()` after providing all the necessary information to build an instance of Contact
func NewContact ¶
func NewContact() *ContactBuilder
NewContact creates a new builder object for Contact
func (*ContactBuilder) Build ¶
func (b *ContactBuilder) Build(options ...Option) (Contact, error)
Build finalizes the building process for Contact and returns the result
func (*ContactBuilder) Email ¶
func (b *ContactBuilder) Email(v string) *ContactBuilder
Email sets the Email field for object Contact.
func (*ContactBuilder) MustBuild ¶
func (b *ContactBuilder) MustBuild(options ...Option) Contact
MustBuild is a convenience function for those time when you know that the result of the builder must be successful
func (*ContactBuilder) Name ¶
func (b *ContactBuilder) Name(v string) *ContactBuilder
Name sets the Name field for object Contact.
func (*ContactBuilder) Reference ¶
func (b *ContactBuilder) Reference(v string) *ContactBuilder
Reference sets the $ref (reference) field for object Contact.
func (*ContactBuilder) URL ¶
func (b *ContactBuilder) URL(v string) *ContactBuilder
URL sets the URL field for object Contact.
type ContactMutator ¶
type ContactMutator struct {
// contains filtered or unexported fields
}
ContactMutator is used to build an instance of Contact. The user must call `Do()` after providing all the necessary information to the new instance of Contact with new values
func MutateContact ¶
func MutateContact(v Contact) *ContactMutator
MutateContact creates a new mutator object for Contact
func (*ContactMutator) Do ¶
func (b *ContactMutator) Do() error
Do finalizes the matuation process for Contact and returns the result
func (*ContactMutator) Email ¶
func (b *ContactMutator) Email(v string) *ContactMutator
Email sets the Email field for object Contact.
func (*ContactMutator) Name ¶
func (b *ContactMutator) Name(v string) *ContactMutator
Name sets the Name field for object Contact.
func (*ContactMutator) URL ¶
func (b *ContactMutator) URL(v string) *ContactMutator
URL sets the URL field for object Contact.
type ContactVisitor ¶
ContactVisitor is an interface for objects that knows how to process Contact elements while traversing the OpenAPI structure
type Discriminator ¶
type Discriminator interface { PropertyName() string Mapping() *StringMapIterator MarshalJSON() ([]byte, error) Clone() Discriminator Validator }
type DiscriminatorBuilder ¶
type DiscriminatorBuilder struct {
// contains filtered or unexported fields
}
DiscriminatorBuilder is used to build an instance of Discriminator. The user must call `Build()` after providing all the necessary information to build an instance of Discriminator
func NewDiscriminator ¶
func NewDiscriminator(propertyName string) *DiscriminatorBuilder
NewDiscriminator creates a new builder object for Discriminator
func (*DiscriminatorBuilder) Build ¶
func (b *DiscriminatorBuilder) Build(options ...Option) (Discriminator, error)
Build finalizes the building process for Discriminator and returns the result
func (*DiscriminatorBuilder) Mapping ¶
func (b *DiscriminatorBuilder) Mapping(v map[string]string) *DiscriminatorBuilder
Mapping sets the Mapping field for object Discriminator.
func (*DiscriminatorBuilder) MustBuild ¶
func (b *DiscriminatorBuilder) MustBuild(options ...Option) Discriminator
MustBuild is a convenience function for those time when you know that the result of the builder must be successful
func (*DiscriminatorBuilder) Reference ¶
func (b *DiscriminatorBuilder) Reference(v string) *DiscriminatorBuilder
Reference sets the $ref (reference) field for object Discriminator.
type DiscriminatorMutator ¶
type DiscriminatorMutator struct {
// contains filtered or unexported fields
}
DiscriminatorMutator is used to build an instance of Discriminator. The user must call `Do()` after providing all the necessary information to the new instance of Discriminator with new values
func MutateDiscriminator ¶
func MutateDiscriminator(v Discriminator) *DiscriminatorMutator
MutateDiscriminator creates a new mutator object for Discriminator
func (*DiscriminatorMutator) ClearMapping ¶
func (b *DiscriminatorMutator) ClearMapping() *DiscriminatorMutator
func (*DiscriminatorMutator) Do ¶
func (b *DiscriminatorMutator) Do() error
Do finalizes the matuation process for Discriminator and returns the result
func (*DiscriminatorMutator) Mapping ¶
func (b *DiscriminatorMutator) Mapping(key StringMapKey, value string) *DiscriminatorMutator
func (*DiscriminatorMutator) PropertyName ¶
func (b *DiscriminatorMutator) PropertyName(v string) *DiscriminatorMutator
PropertyName sets the PropertyName field for object Discriminator.
type DiscriminatorVisitor ¶
type DiscriminatorVisitor interface {
VisitDiscriminator(context.Context, Discriminator) error
}
DiscriminatorVisitor is an interface for objects that knows how to process Discriminator elements while traversing the OpenAPI structure
type EncodingBuilder ¶
type EncodingBuilder struct {
// contains filtered or unexported fields
}
EncodingBuilder is used to build an instance of Encoding. The user must call `Build()` after providing all the necessary information to build an instance of Encoding
func NewEncoding ¶
func NewEncoding() *EncodingBuilder
NewEncoding creates a new builder object for Encoding
func (*EncodingBuilder) AllowReserved ¶
func (b *EncodingBuilder) AllowReserved(v bool) *EncodingBuilder
AllowReserved sets the AllowReserved field for object Encoding.
func (*EncodingBuilder) Build ¶
func (b *EncodingBuilder) Build(options ...Option) (Encoding, error)
Build finalizes the building process for Encoding and returns the result
func (*EncodingBuilder) ContentType ¶
func (b *EncodingBuilder) ContentType(v string) *EncodingBuilder
ContentType sets the ContentType field for object Encoding.
func (*EncodingBuilder) Explode ¶
func (b *EncodingBuilder) Explode(v bool) *EncodingBuilder
Explode sets the Explode field for object Encoding.
func (*EncodingBuilder) Headers ¶
func (b *EncodingBuilder) Headers(v map[string]Header) *EncodingBuilder
Headers sets the Headers field for object Encoding.
func (*EncodingBuilder) MustBuild ¶
func (b *EncodingBuilder) MustBuild(options ...Option) Encoding
MustBuild is a convenience function for those time when you know that the result of the builder must be successful
func (*EncodingBuilder) Reference ¶
func (b *EncodingBuilder) Reference(v string) *EncodingBuilder
Reference sets the $ref (reference) field for object Encoding.
type EncodingMap ¶
type EncodingMap map[EncodingMapKey]Encoding
func (*EncodingMap) Clear ¶
func (v *EncodingMap) Clear() error
func (EncodingMap) QueryJSON ¶
func (v EncodingMap) QueryJSON(path string) (ret interface{}, ok bool)
func (*EncodingMap) UnmarshalJSON ¶
func (v *EncodingMap) UnmarshalJSON(data []byte) error
func (*EncodingMap) Validate ¶
func (v *EncodingMap) Validate(recurse bool) error
Validate checks the correctness of values in EncodingMap
type EncodingMapIterator ¶
type EncodingMapIterator struct {
// contains filtered or unexported fields
}
func (*EncodingMapIterator) Item ¶
func (iter *EncodingMapIterator) Item() (string, Encoding)
Item returns the next item in this iterator. Make sure to call Next() before hand to check if the iterator has more items
type EncodingMapKey ¶
type EncodingMapKey = string
type EncodingMutator ¶
type EncodingMutator struct {
// contains filtered or unexported fields
}
EncodingMutator is used to build an instance of Encoding. The user must call `Do()` after providing all the necessary information to the new instance of Encoding with new values
func MutateEncoding ¶
func MutateEncoding(v Encoding) *EncodingMutator
MutateEncoding creates a new mutator object for Encoding
func (*EncodingMutator) AllowReserved ¶
func (b *EncodingMutator) AllowReserved(v bool) *EncodingMutator
AllowReserved sets the AllowReserved field for object Encoding.
func (*EncodingMutator) ClearHeaders ¶
func (b *EncodingMutator) ClearHeaders() *EncodingMutator
func (*EncodingMutator) ContentType ¶
func (b *EncodingMutator) ContentType(v string) *EncodingMutator
ContentType sets the ContentType field for object Encoding.
func (*EncodingMutator) Do ¶
func (b *EncodingMutator) Do() error
Do finalizes the matuation process for Encoding and returns the result
func (*EncodingMutator) Explode ¶
func (b *EncodingMutator) Explode(v bool) *EncodingMutator
Explode sets the Explode field for object Encoding.
func (*EncodingMutator) Header ¶
func (b *EncodingMutator) Header(key HeaderMapKey, value Header) *EncodingMutator
func (*EncodingMutator) Name ¶
func (b *EncodingMutator) Name(v string) *EncodingMutator
Name sets the Name field for object Encoding.
type EncodingVisitor ¶
EncodingVisitor is an interface for objects that knows how to process Encoding elements while traversing the OpenAPI structure
type ExampleBuilder ¶
type ExampleBuilder struct {
// contains filtered or unexported fields
}
ExampleBuilder is used to build an instance of Example. The user must call `Build()` after providing all the necessary information to build an instance of Example
func NewExample ¶
func NewExample() *ExampleBuilder
NewExample creates a new builder object for Example
func (*ExampleBuilder) Build ¶
func (b *ExampleBuilder) Build(options ...Option) (Example, error)
Build finalizes the building process for Example and returns the result
func (*ExampleBuilder) Description ¶
func (b *ExampleBuilder) Description(v string) *ExampleBuilder
Description sets the Description field for object Example.
func (*ExampleBuilder) ExternalValue ¶
func (b *ExampleBuilder) ExternalValue(v string) *ExampleBuilder
ExternalValue sets the ExternalValue field for object Example.
func (*ExampleBuilder) MustBuild ¶
func (b *ExampleBuilder) MustBuild(options ...Option) Example
MustBuild is a convenience function for those time when you know that the result of the builder must be successful
func (*ExampleBuilder) Reference ¶
func (b *ExampleBuilder) Reference(v string) *ExampleBuilder
Reference sets the $ref (reference) field for object Example.
func (*ExampleBuilder) Value ¶
func (b *ExampleBuilder) Value(v interface{}) *ExampleBuilder
Value sets the Value field for object Example.
type ExampleMap ¶
type ExampleMap map[ExampleMapKey]Example
func (*ExampleMap) Clear ¶
func (v *ExampleMap) Clear() error
func (ExampleMap) QueryJSON ¶
func (v ExampleMap) QueryJSON(path string) (ret interface{}, ok bool)
func (*ExampleMap) UnmarshalJSON ¶
func (v *ExampleMap) UnmarshalJSON(data []byte) error
func (*ExampleMap) Validate ¶
func (v *ExampleMap) Validate(recurse bool) error
Validate checks the correctness of values in ExampleMap
type ExampleMapIterator ¶
type ExampleMapIterator struct {
// contains filtered or unexported fields
}
func (*ExampleMapIterator) Item ¶
func (iter *ExampleMapIterator) Item() (string, Example)
Item returns the next item in this iterator. Make sure to call Next() before hand to check if the iterator has more items
type ExampleMapKey ¶
type ExampleMapKey = string
type ExampleMutator ¶
type ExampleMutator struct {
// contains filtered or unexported fields
}
ExampleMutator is used to build an instance of Example. The user must call `Do()` after providing all the necessary information to the new instance of Example with new values
func MutateExample ¶
func MutateExample(v Example) *ExampleMutator
MutateExample creates a new mutator object for Example
func (*ExampleMutator) Description ¶
func (b *ExampleMutator) Description(v string) *ExampleMutator
Description sets the Description field for object Example.
func (*ExampleMutator) Do ¶
func (b *ExampleMutator) Do() error
Do finalizes the matuation process for Example and returns the result
func (*ExampleMutator) ExternalValue ¶
func (b *ExampleMutator) ExternalValue(v string) *ExampleMutator
ExternalValue sets the ExternalValue field for object Example.
func (*ExampleMutator) Name ¶
func (b *ExampleMutator) Name(v string) *ExampleMutator
Name sets the Name field for object Example.
func (*ExampleMutator) Value ¶
func (b *ExampleMutator) Value(v interface{}) *ExampleMutator
Value sets the Value field for object Example.
type ExampleVisitor ¶
ExampleVisitor is an interface for objects that knows how to process Example elements while traversing the OpenAPI structure
type Extensions ¶
type Extensions map[string]interface{}
type ExternalDocumentation ¶
type ExternalDocumentationBuilder ¶
type ExternalDocumentationBuilder struct {
// contains filtered or unexported fields
}
ExternalDocumentationBuilder is used to build an instance of ExternalDocumentation. The user must call `Build()` after providing all the necessary information to build an instance of ExternalDocumentation
func NewExternalDocumentation ¶
func NewExternalDocumentation(url string) *ExternalDocumentationBuilder
NewExternalDocumentation creates a new builder object for ExternalDocumentation
func (*ExternalDocumentationBuilder) Build ¶
func (b *ExternalDocumentationBuilder) Build(options ...Option) (ExternalDocumentation, error)
Build finalizes the building process for ExternalDocumentation and returns the result
func (*ExternalDocumentationBuilder) Description ¶
func (b *ExternalDocumentationBuilder) Description(v string) *ExternalDocumentationBuilder
Description sets the Description field for object ExternalDocumentation.
func (*ExternalDocumentationBuilder) MustBuild ¶
func (b *ExternalDocumentationBuilder) MustBuild(options ...Option) ExternalDocumentation
MustBuild is a convenience function for those time when you know that the result of the builder must be successful
func (*ExternalDocumentationBuilder) Reference ¶
func (b *ExternalDocumentationBuilder) Reference(v string) *ExternalDocumentationBuilder
Reference sets the $ref (reference) field for object ExternalDocumentation.
type ExternalDocumentationMutator ¶
type ExternalDocumentationMutator struct {
// contains filtered or unexported fields
}
ExternalDocumentationMutator is used to build an instance of ExternalDocumentation. The user must call `Do()` after providing all the necessary information to the new instance of ExternalDocumentation with new values
func MutateExternalDocumentation ¶
func MutateExternalDocumentation(v ExternalDocumentation) *ExternalDocumentationMutator
MutateExternalDocumentation creates a new mutator object for ExternalDocumentation
func (*ExternalDocumentationMutator) Description ¶
func (b *ExternalDocumentationMutator) Description(v string) *ExternalDocumentationMutator
Description sets the Description field for object ExternalDocumentation.
func (*ExternalDocumentationMutator) Do ¶
func (b *ExternalDocumentationMutator) Do() error
Do finalizes the matuation process for ExternalDocumentation and returns the result
func (*ExternalDocumentationMutator) URL ¶
func (b *ExternalDocumentationMutator) URL(v string) *ExternalDocumentationMutator
URL sets the URL field for object ExternalDocumentation.
type ExternalDocumentationVisitor ¶
type ExternalDocumentationVisitor interface {
VisitExternalDocumentation(context.Context, ExternalDocumentation) error
}
ExternalDocumentationVisitor is an interface for objects that knows how to process ExternalDocumentation elements while traversing the OpenAPI structure
type Header ¶
type Header interface { Name() string In() Location Required() bool Description() string Deprecated() bool AllowEmptyValue() bool Explode() bool AllowReserved() bool Schema() Schema Examples() *ExampleMapIterator Content() *MediaTypeMapIterator MarshalJSON() ([]byte, error) Clone() Header Validator // contains filtered or unexported methods }
type HeaderBuilder ¶
type HeaderBuilder struct {
// contains filtered or unexported fields
}
HeaderBuilder is used to build an instance of Header. The user must call `Build()` after providing all the necessary information to build an instance of Header
func (*HeaderBuilder) AllowEmptyValue ¶
func (b *HeaderBuilder) AllowEmptyValue(v bool) *HeaderBuilder
AllowEmptyValue sets the AllowEmptyValue field for object Header.
func (*HeaderBuilder) AllowReserved ¶
func (b *HeaderBuilder) AllowReserved(v bool) *HeaderBuilder
AllowReserved sets the AllowReserved field for object Header.
func (*HeaderBuilder) Build ¶
func (b *HeaderBuilder) Build(options ...Option) (Header, error)
Build finalizes the building process for Header and returns the result
func (*HeaderBuilder) Content ¶
func (b *HeaderBuilder) Content(v map[string]MediaType) *HeaderBuilder
Content sets the Content field for object Header.
func (*HeaderBuilder) Deprecated ¶
func (b *HeaderBuilder) Deprecated(v bool) *HeaderBuilder
Deprecated sets the Deprecated field for object Header.
func (*HeaderBuilder) Description ¶
func (b *HeaderBuilder) Description(v string) *HeaderBuilder
Description sets the Description field for object Header.
func (*HeaderBuilder) Examples ¶
func (b *HeaderBuilder) Examples(v map[string]Example) *HeaderBuilder
Examples sets the Examples field for object Header.
func (*HeaderBuilder) Explode ¶
func (b *HeaderBuilder) Explode(v bool) *HeaderBuilder
Explode sets the Explode field for object Header.
func (*HeaderBuilder) In ¶
func (b *HeaderBuilder) In(v Location) *HeaderBuilder
In sets the In field for object Header. If this is not called, a default value (InHeader) is assigned to this field
func (*HeaderBuilder) MustBuild ¶
func (b *HeaderBuilder) MustBuild(options ...Option) Header
MustBuild is a convenience function for those time when you know that the result of the builder must be successful
func (*HeaderBuilder) Reference ¶
func (b *HeaderBuilder) Reference(v string) *HeaderBuilder
Reference sets the $ref (reference) field for object Header.
func (*HeaderBuilder) Required ¶
func (b *HeaderBuilder) Required(v bool) *HeaderBuilder
Required sets the Required field for object Header.
func (*HeaderBuilder) Schema ¶
func (b *HeaderBuilder) Schema(v Schema) *HeaderBuilder
Schema sets the Schema field for object Header.
type HeaderMapIterator ¶
type HeaderMapIterator struct {
// contains filtered or unexported fields
}
func (*HeaderMapIterator) Item ¶
func (iter *HeaderMapIterator) Item() (string, Header)
Item returns the next item in this iterator. Make sure to call Next() before hand to check if the iterator has more items
type HeaderMapKey ¶
type HeaderMapKey = string
type HeaderMutator ¶
type HeaderMutator struct {
// contains filtered or unexported fields
}
HeaderMutator is used to build an instance of Header. The user must call `Do()` after providing all the necessary information to the new instance of Header with new values
func MutateHeader ¶
func MutateHeader(v Header) *HeaderMutator
MutateHeader creates a new mutator object for Header
func (*HeaderMutator) AllowEmptyValue ¶
func (b *HeaderMutator) AllowEmptyValue(v bool) *HeaderMutator
AllowEmptyValue sets the AllowEmptyValue field for object Header.
func (*HeaderMutator) AllowReserved ¶
func (b *HeaderMutator) AllowReserved(v bool) *HeaderMutator
AllowReserved sets the AllowReserved field for object Header.
func (*HeaderMutator) ClearContent ¶
func (b *HeaderMutator) ClearContent() *HeaderMutator
func (*HeaderMutator) ClearExamples ¶
func (b *HeaderMutator) ClearExamples() *HeaderMutator
func (*HeaderMutator) Content ¶
func (b *HeaderMutator) Content(key MediaTypeMapKey, value MediaType) *HeaderMutator
func (*HeaderMutator) Deprecated ¶
func (b *HeaderMutator) Deprecated(v bool) *HeaderMutator
Deprecated sets the Deprecated field for object Header.
func (*HeaderMutator) Description ¶
func (b *HeaderMutator) Description(v string) *HeaderMutator
Description sets the Description field for object Header.
func (*HeaderMutator) Do ¶
func (b *HeaderMutator) Do() error
Do finalizes the matuation process for Header and returns the result
func (*HeaderMutator) Example ¶
func (b *HeaderMutator) Example(key ExampleMapKey, value Example) *HeaderMutator
func (*HeaderMutator) Explode ¶
func (b *HeaderMutator) Explode(v bool) *HeaderMutator
Explode sets the Explode field for object Header.
func (*HeaderMutator) In ¶
func (b *HeaderMutator) In(v Location) *HeaderMutator
In sets the In field for object Header.
func (*HeaderMutator) Required ¶
func (b *HeaderMutator) Required(v bool) *HeaderMutator
Required sets the Required field for object Header.
func (*HeaderMutator) Schema ¶
func (b *HeaderMutator) Schema(v Schema) *HeaderMutator
Schema sets the Schema field for object Header.
type HeaderVisitor ¶
HeaderVisitor is an interface for objects that knows how to process Header elements while traversing the OpenAPI structure
type InfoBuilder ¶
type InfoBuilder struct {
// contains filtered or unexported fields
}
InfoBuilder is used to build an instance of Info. The user must call `Build()` after providing all the necessary information to build an instance of Info
func NewInfo ¶
func NewInfo(title string) *InfoBuilder
NewInfo creates a new builder object for Info
func (*InfoBuilder) Build ¶
func (b *InfoBuilder) Build(options ...Option) (Info, error)
Build finalizes the building process for Info and returns the result
func (*InfoBuilder) Contact ¶
func (b *InfoBuilder) Contact(v Contact) *InfoBuilder
Contact sets the Contact field for object Info.
func (*InfoBuilder) Description ¶
func (b *InfoBuilder) Description(v string) *InfoBuilder
Description sets the Description field for object Info.
func (*InfoBuilder) License ¶
func (b *InfoBuilder) License(v License) *InfoBuilder
License sets the License field for object Info.
func (*InfoBuilder) MustBuild ¶
func (b *InfoBuilder) MustBuild(options ...Option) Info
MustBuild is a convenience function for those time when you know that the result of the builder must be successful
func (*InfoBuilder) Reference ¶
func (b *InfoBuilder) Reference(v string) *InfoBuilder
Reference sets the $ref (reference) field for object Info.
func (*InfoBuilder) TermsOfService ¶
func (b *InfoBuilder) TermsOfService(v string) *InfoBuilder
TermsOfService sets the TermsOfService field for object Info.
func (*InfoBuilder) Version ¶
func (b *InfoBuilder) Version(v string) *InfoBuilder
Version sets the Version field for object Info. If this is not called, a default value (DefaultSpecVersion) is assigned to this field
type InfoMutator ¶
type InfoMutator struct {
// contains filtered or unexported fields
}
InfoMutator is used to build an instance of Info. The user must call `Do()` after providing all the necessary information to the new instance of Info with new values
func MutateInfo ¶
func MutateInfo(v Info) *InfoMutator
MutateInfo creates a new mutator object for Info
func (*InfoMutator) Contact ¶
func (b *InfoMutator) Contact(v Contact) *InfoMutator
Contact sets the Contact field for object Info.
func (*InfoMutator) Description ¶
func (b *InfoMutator) Description(v string) *InfoMutator
Description sets the Description field for object Info.
func (*InfoMutator) Do ¶
func (b *InfoMutator) Do() error
Do finalizes the matuation process for Info and returns the result
func (*InfoMutator) License ¶
func (b *InfoMutator) License(v License) *InfoMutator
License sets the License field for object Info.
func (*InfoMutator) TermsOfService ¶
func (b *InfoMutator) TermsOfService(v string) *InfoMutator
TermsOfService sets the TermsOfService field for object Info.
func (*InfoMutator) Title ¶
func (b *InfoMutator) Title(v string) *InfoMutator
Title sets the Title field for object Info.
func (*InfoMutator) Version ¶
func (b *InfoMutator) Version(v string) *InfoMutator
Version sets the Version field for object Info.
type InfoVisitor ¶
InfoVisitor is an interface for objects that knows how to process Info elements while traversing the OpenAPI structure
type InterfaceList ¶
type InterfaceList []interface{}
func (*InterfaceList) Clear ¶
func (v *InterfaceList) Clear() error
func (*InterfaceList) Validate ¶
func (v *InterfaceList) Validate(recurse bool) error
Validate checks for the values for correctness. If `recurse` is specified, child elements are also validated
type InterfaceListIterator ¶
type InterfaceListIterator struct {
// contains filtered or unexported fields
}
func (*InterfaceListIterator) Item ¶
func (iter *InterfaceListIterator) Item() interface{}
Item returns the next item in this iterator. Make sure to call Next() before hand to check if the iterator has more items
type InterfaceMap ¶
type InterfaceMap map[InterfaceMapKey]interface{}
func (*InterfaceMap) Clear ¶
func (v *InterfaceMap) Clear() error
func (InterfaceMap) QueryJSON ¶
func (v InterfaceMap) QueryJSON(path string) (ret interface{}, ok bool)
func (*InterfaceMap) Validate ¶
func (v *InterfaceMap) Validate(recurse bool) error
Validate checks the correctness of values in InterfaceMap
type InterfaceMapIterator ¶
type InterfaceMapIterator struct {
// contains filtered or unexported fields
}
func (*InterfaceMapIterator) Item ¶
func (iter *InterfaceMapIterator) Item() (string, interface{})
Item returns the next item in this iterator. Make sure to call Next() before hand to check if the iterator has more items
type InterfaceMapKey ¶
type InterfaceMapKey = string
type LicenseBuilder ¶
type LicenseBuilder struct {
// contains filtered or unexported fields
}
LicenseBuilder is used to build an instance of License. The user must call `Build()` after providing all the necessary information to build an instance of License
func NewLicense ¶
func NewLicense(name string) *LicenseBuilder
NewLicense creates a new builder object for License
func (*LicenseBuilder) Build ¶
func (b *LicenseBuilder) Build(options ...Option) (License, error)
Build finalizes the building process for License and returns the result
func (*LicenseBuilder) MustBuild ¶
func (b *LicenseBuilder) MustBuild(options ...Option) License
MustBuild is a convenience function for those time when you know that the result of the builder must be successful
func (*LicenseBuilder) Reference ¶
func (b *LicenseBuilder) Reference(v string) *LicenseBuilder
Reference sets the $ref (reference) field for object License.
func (*LicenseBuilder) URL ¶
func (b *LicenseBuilder) URL(v string) *LicenseBuilder
URL sets the URL field for object License.
type LicenseMutator ¶
type LicenseMutator struct {
// contains filtered or unexported fields
}
LicenseMutator is used to build an instance of License. The user must call `Do()` after providing all the necessary information to the new instance of License with new values
func MutateLicense ¶
func MutateLicense(v License) *LicenseMutator
MutateLicense creates a new mutator object for License
func (*LicenseMutator) Do ¶
func (b *LicenseMutator) Do() error
Do finalizes the matuation process for License and returns the result
func (*LicenseMutator) Name ¶
func (b *LicenseMutator) Name(v string) *LicenseMutator
Name sets the Name field for object License.
func (*LicenseMutator) URL ¶
func (b *LicenseMutator) URL(v string) *LicenseMutator
URL sets the URL field for object License.
type LicenseVisitor ¶
LicenseVisitor is an interface for objects that knows how to process License elements while traversing the OpenAPI structure
type LinkBuilder ¶
type LinkBuilder struct {
// contains filtered or unexported fields
}
LinkBuilder is used to build an instance of Link. The user must call `Build()` after providing all the necessary information to build an instance of Link
func (*LinkBuilder) Build ¶
func (b *LinkBuilder) Build(options ...Option) (Link, error)
Build finalizes the building process for Link and returns the result
func (*LinkBuilder) Description ¶
func (b *LinkBuilder) Description(v string) *LinkBuilder
Description sets the Description field for object Link.
func (*LinkBuilder) MustBuild ¶
func (b *LinkBuilder) MustBuild(options ...Option) Link
MustBuild is a convenience function for those time when you know that the result of the builder must be successful
func (*LinkBuilder) OperationID ¶
func (b *LinkBuilder) OperationID(v string) *LinkBuilder
OperationID sets the OperationID field for object Link.
func (*LinkBuilder) OperationRef ¶
func (b *LinkBuilder) OperationRef(v string) *LinkBuilder
OperationRef sets the OperationRef field for object Link.
func (*LinkBuilder) Parameters ¶
func (b *LinkBuilder) Parameters(v map[string]interface{}) *LinkBuilder
Parameters sets the Parameters field for object Link.
func (*LinkBuilder) Reference ¶
func (b *LinkBuilder) Reference(v string) *LinkBuilder
Reference sets the $ref (reference) field for object Link.
func (*LinkBuilder) RequestBody ¶
func (b *LinkBuilder) RequestBody(v interface{}) *LinkBuilder
RequestBody sets the RequestBody field for object Link.
func (*LinkBuilder) Server ¶
func (b *LinkBuilder) Server(v Server) *LinkBuilder
Server sets the Server field for object Link.
type LinkMapIterator ¶
type LinkMapIterator struct {
// contains filtered or unexported fields
}
func (*LinkMapIterator) Item ¶
func (iter *LinkMapIterator) Item() (string, Link)
Item returns the next item in this iterator. Make sure to call Next() before hand to check if the iterator has more items
type LinkMapKey ¶
type LinkMapKey = string
type LinkMutator ¶
type LinkMutator struct {
// contains filtered or unexported fields
}
LinkMutator is used to build an instance of Link. The user must call `Do()` after providing all the necessary information to the new instance of Link with new values
func MutateLink ¶
func MutateLink(v Link) *LinkMutator
MutateLink creates a new mutator object for Link
func (*LinkMutator) ClearParameters ¶
func (b *LinkMutator) ClearParameters() *LinkMutator
func (*LinkMutator) Description ¶
func (b *LinkMutator) Description(v string) *LinkMutator
Description sets the Description field for object Link.
func (*LinkMutator) Do ¶
func (b *LinkMutator) Do() error
Do finalizes the matuation process for Link and returns the result
func (*LinkMutator) Name ¶
func (b *LinkMutator) Name(v string) *LinkMutator
Name sets the Name field for object Link.
func (*LinkMutator) OperationID ¶
func (b *LinkMutator) OperationID(v string) *LinkMutator
OperationID sets the OperationID field for object Link.
func (*LinkMutator) OperationRef ¶
func (b *LinkMutator) OperationRef(v string) *LinkMutator
OperationRef sets the OperationRef field for object Link.
func (*LinkMutator) Parameter ¶
func (b *LinkMutator) Parameter(key InterfaceMapKey, value interface{}) *LinkMutator
func (*LinkMutator) RequestBody ¶
func (b *LinkMutator) RequestBody(v interface{}) *LinkMutator
RequestBody sets the RequestBody field for object Link.
func (*LinkMutator) Server ¶
func (b *LinkMutator) Server(v Server) *LinkMutator
Server sets the Server field for object Link.
type LinkVisitor ¶
LinkVisitor is an interface for objects that knows how to process Link elements while traversing the OpenAPI structure
type MapQueryJSON ¶
type MapQueryJSON map[string]interface{}
type MediaType ¶
type MediaType interface { Name() string Mime() string Schema() Schema Examples() *ExampleMapIterator Encoding() *EncodingMapIterator MarshalJSON() ([]byte, error) Clone() MediaType Validator // contains filtered or unexported methods }
type MediaTypeBuilder ¶
type MediaTypeBuilder struct {
// contains filtered or unexported fields
}
MediaTypeBuilder is used to build an instance of MediaType. The user must call `Build()` after providing all the necessary information to build an instance of MediaType
func NewMediaType ¶
func NewMediaType() *MediaTypeBuilder
NewMediaType creates a new builder object for MediaType
func (*MediaTypeBuilder) Build ¶
func (b *MediaTypeBuilder) Build(options ...Option) (MediaType, error)
Build finalizes the building process for MediaType and returns the result
func (*MediaTypeBuilder) Encoding ¶
func (b *MediaTypeBuilder) Encoding(v map[string]Encoding) *MediaTypeBuilder
Encoding sets the Encoding field for object MediaType.
func (*MediaTypeBuilder) Examples ¶
func (b *MediaTypeBuilder) Examples(v map[string]Example) *MediaTypeBuilder
Examples sets the Examples field for object MediaType.
func (*MediaTypeBuilder) MustBuild ¶
func (b *MediaTypeBuilder) MustBuild(options ...Option) MediaType
MustBuild is a convenience function for those time when you know that the result of the builder must be successful
func (*MediaTypeBuilder) Reference ¶
func (b *MediaTypeBuilder) Reference(v string) *MediaTypeBuilder
Reference sets the $ref (reference) field for object MediaType.
func (*MediaTypeBuilder) Schema ¶
func (b *MediaTypeBuilder) Schema(v Schema) *MediaTypeBuilder
Schema sets the Schema field for object MediaType.
type MediaTypeListIterator ¶
type MediaTypeListIterator struct {
// contains filtered or unexported fields
}
func (*MediaTypeListIterator) Item ¶
func (iter *MediaTypeListIterator) Item() MediaType
Item returns the next item in this iterator. Make sure to call Next() before hand to check if the iterator has more items
type MediaTypeMap ¶
type MediaTypeMap map[MediaTypeMapKey]MediaType
func (*MediaTypeMap) Clear ¶
func (v *MediaTypeMap) Clear() error
func (MediaTypeMap) QueryJSON ¶
func (v MediaTypeMap) QueryJSON(path string) (ret interface{}, ok bool)
func (*MediaTypeMap) UnmarshalJSON ¶
func (v *MediaTypeMap) UnmarshalJSON(data []byte) error
func (*MediaTypeMap) Validate ¶
func (v *MediaTypeMap) Validate(recurse bool) error
Validate checks the correctness of values in MediaTypeMap
type MediaTypeMapIterator ¶
type MediaTypeMapIterator struct {
// contains filtered or unexported fields
}
func (*MediaTypeMapIterator) Item ¶
func (iter *MediaTypeMapIterator) Item() (string, MediaType)
Item returns the next item in this iterator. Make sure to call Next() before hand to check if the iterator has more items
type MediaTypeMapKey ¶
type MediaTypeMapKey = string
type MediaTypeMutator ¶
type MediaTypeMutator struct {
// contains filtered or unexported fields
}
MediaTypeMutator is used to build an instance of MediaType. The user must call `Do()` after providing all the necessary information to the new instance of MediaType with new values
func MutateMediaType ¶
func MutateMediaType(v MediaType) *MediaTypeMutator
MutateMediaType creates a new mutator object for MediaType
func (*MediaTypeMutator) ClearEncoding ¶
func (b *MediaTypeMutator) ClearEncoding() *MediaTypeMutator
func (*MediaTypeMutator) ClearExamples ¶
func (b *MediaTypeMutator) ClearExamples() *MediaTypeMutator
func (*MediaTypeMutator) Do ¶
func (b *MediaTypeMutator) Do() error
Do finalizes the matuation process for MediaType and returns the result
func (*MediaTypeMutator) Encoding ¶
func (b *MediaTypeMutator) Encoding(key EncodingMapKey, value Encoding) *MediaTypeMutator
func (*MediaTypeMutator) Example ¶
func (b *MediaTypeMutator) Example(key ExampleMapKey, value Example) *MediaTypeMutator
func (*MediaTypeMutator) Mime ¶
func (b *MediaTypeMutator) Mime(v string) *MediaTypeMutator
Mime sets the Mime field for object MediaType.
func (*MediaTypeMutator) Name ¶
func (b *MediaTypeMutator) Name(v string) *MediaTypeMutator
Name sets the Name field for object MediaType.
func (*MediaTypeMutator) Schema ¶
func (b *MediaTypeMutator) Schema(v Schema) *MediaTypeMutator
Schema sets the Schema field for object MediaType.
type MediaTypeVisitor ¶
MediaTypeVisitor is an interface for objects that knows how to process MediaType elements while traversing the OpenAPI structure
type OAuthFlowBuilder ¶
type OAuthFlowBuilder struct {
// contains filtered or unexported fields
}
OAuthFlowBuilder is used to build an instance of OAuthFlow. The user must call `Build()` after providing all the necessary information to build an instance of OAuthFlow
func NewOAuthFlow ¶
func NewOAuthFlow() *OAuthFlowBuilder
NewOAuthFlow creates a new builder object for OAuthFlow
func (*OAuthFlowBuilder) AuthorizationURL ¶
func (b *OAuthFlowBuilder) AuthorizationURL(v string) *OAuthFlowBuilder
AuthorizationURL sets the AuthorizationURL field for object OAuthFlow.
func (*OAuthFlowBuilder) Build ¶
func (b *OAuthFlowBuilder) Build(options ...Option) (OAuthFlow, error)
Build finalizes the building process for OAuthFlow and returns the result
func (*OAuthFlowBuilder) MustBuild ¶
func (b *OAuthFlowBuilder) MustBuild(options ...Option) OAuthFlow
MustBuild is a convenience function for those time when you know that the result of the builder must be successful
func (*OAuthFlowBuilder) Reference ¶
func (b *OAuthFlowBuilder) Reference(v string) *OAuthFlowBuilder
Reference sets the $ref (reference) field for object OAuthFlow.
func (*OAuthFlowBuilder) RefreshURL ¶
func (b *OAuthFlowBuilder) RefreshURL(v string) *OAuthFlowBuilder
RefreshURL sets the RefreshURL field for object OAuthFlow.
func (*OAuthFlowBuilder) Scopes ¶
func (b *OAuthFlowBuilder) Scopes(v map[string]string) *OAuthFlowBuilder
Scopes sets the Scopes field for object OAuthFlow.
func (*OAuthFlowBuilder) TokenURL ¶
func (b *OAuthFlowBuilder) TokenURL(v string) *OAuthFlowBuilder
TokenURL sets the TokenURL field for object OAuthFlow.
type OAuthFlowMutator ¶
type OAuthFlowMutator struct {
// contains filtered or unexported fields
}
OAuthFlowMutator is used to build an instance of OAuthFlow. The user must call `Do()` after providing all the necessary information to the new instance of OAuthFlow with new values
func MutateOAuthFlow ¶
func MutateOAuthFlow(v OAuthFlow) *OAuthFlowMutator
MutateOAuthFlow creates a new mutator object for OAuthFlow
func (*OAuthFlowMutator) AuthorizationURL ¶
func (b *OAuthFlowMutator) AuthorizationURL(v string) *OAuthFlowMutator
AuthorizationURL sets the AuthorizationURL field for object OAuthFlow.
func (*OAuthFlowMutator) ClearScopes ¶
func (b *OAuthFlowMutator) ClearScopes() *OAuthFlowMutator
func (*OAuthFlowMutator) Do ¶
func (b *OAuthFlowMutator) Do() error
Do finalizes the matuation process for OAuthFlow and returns the result
func (*OAuthFlowMutator) RefreshURL ¶
func (b *OAuthFlowMutator) RefreshURL(v string) *OAuthFlowMutator
RefreshURL sets the RefreshURL field for object OAuthFlow.
func (*OAuthFlowMutator) Scope ¶
func (b *OAuthFlowMutator) Scope(key ScopeMapKey, value string) *OAuthFlowMutator
func (*OAuthFlowMutator) TokenURL ¶
func (b *OAuthFlowMutator) TokenURL(v string) *OAuthFlowMutator
TokenURL sets the TokenURL field for object OAuthFlow.
type OAuthFlowVisitor ¶
OAuthFlowVisitor is an interface for objects that knows how to process OAuthFlow elements while traversing the OpenAPI structure
type OAuthFlows ¶
type OAuthFlowsBuilder ¶
type OAuthFlowsBuilder struct {
// contains filtered or unexported fields
}
OAuthFlowsBuilder is used to build an instance of OAuthFlows. The user must call `Build()` after providing all the necessary information to build an instance of OAuthFlows
func NewOAuthFlows ¶
func NewOAuthFlows() *OAuthFlowsBuilder
NewOAuthFlows creates a new builder object for OAuthFlows
func (*OAuthFlowsBuilder) AuthorizationCode ¶
func (b *OAuthFlowsBuilder) AuthorizationCode(v OAuthFlow) *OAuthFlowsBuilder
AuthorizationCode sets the AuthorizationCode field for object OAuthFlows.
func (*OAuthFlowsBuilder) Build ¶
func (b *OAuthFlowsBuilder) Build(options ...Option) (OAuthFlows, error)
Build finalizes the building process for OAuthFlows and returns the result
func (*OAuthFlowsBuilder) ClientCredentials ¶
func (b *OAuthFlowsBuilder) ClientCredentials(v OAuthFlow) *OAuthFlowsBuilder
ClientCredentials sets the ClientCredentials field for object OAuthFlows.
func (*OAuthFlowsBuilder) Implicit ¶
func (b *OAuthFlowsBuilder) Implicit(v OAuthFlow) *OAuthFlowsBuilder
Implicit sets the Implicit field for object OAuthFlows.
func (*OAuthFlowsBuilder) MustBuild ¶
func (b *OAuthFlowsBuilder) MustBuild(options ...Option) OAuthFlows
MustBuild is a convenience function for those time when you know that the result of the builder must be successful
func (*OAuthFlowsBuilder) Password ¶
func (b *OAuthFlowsBuilder) Password(v OAuthFlow) *OAuthFlowsBuilder
Password sets the Password field for object OAuthFlows.
func (*OAuthFlowsBuilder) Reference ¶
func (b *OAuthFlowsBuilder) Reference(v string) *OAuthFlowsBuilder
Reference sets the $ref (reference) field for object OAuthFlows.
type OAuthFlowsMutator ¶
type OAuthFlowsMutator struct {
// contains filtered or unexported fields
}
OAuthFlowsMutator is used to build an instance of OAuthFlows. The user must call `Do()` after providing all the necessary information to the new instance of OAuthFlows with new values
func MutateOAuthFlows ¶
func MutateOAuthFlows(v OAuthFlows) *OAuthFlowsMutator
MutateOAuthFlows creates a new mutator object for OAuthFlows
func (*OAuthFlowsMutator) AuthorizationCode ¶
func (b *OAuthFlowsMutator) AuthorizationCode(v OAuthFlow) *OAuthFlowsMutator
AuthorizationCode sets the AuthorizationCode field for object OAuthFlows.
func (*OAuthFlowsMutator) ClientCredentials ¶
func (b *OAuthFlowsMutator) ClientCredentials(v OAuthFlow) *OAuthFlowsMutator
ClientCredentials sets the ClientCredentials field for object OAuthFlows.
func (*OAuthFlowsMutator) Do ¶
func (b *OAuthFlowsMutator) Do() error
Do finalizes the matuation process for OAuthFlows and returns the result
func (*OAuthFlowsMutator) Implicit ¶
func (b *OAuthFlowsMutator) Implicit(v OAuthFlow) *OAuthFlowsMutator
Implicit sets the Implicit field for object OAuthFlows.
func (*OAuthFlowsMutator) Password ¶
func (b *OAuthFlowsMutator) Password(v OAuthFlow) *OAuthFlowsMutator
Password sets the Password field for object OAuthFlows.
type OAuthFlowsVisitor ¶
type OAuthFlowsVisitor interface {
VisitOAuthFlows(context.Context, OAuthFlows) error
}
OAuthFlowsVisitor is an interface for objects that knows how to process OAuthFlows elements while traversing the OpenAPI structure
type OpenAPI ¶
type OpenAPI interface { Version() string Info() Info Servers() *ServerListIterator Paths() Paths Components() Components Security() SecurityRequirement Tags() *TagListIterator ExternalDocs() ExternalDocumentation MarshalJSON() ([]byte, error) Clone() OpenAPI Validator QueryJSON(string) (interface{}, bool) }
type OpenAPIBuilder ¶
type OpenAPIBuilder struct {
// contains filtered or unexported fields
}
OpenAPIBuilder is used to build an instance of OpenAPI. The user must call `Build()` after providing all the necessary information to build an instance of OpenAPI
func NewOpenAPI ¶
func NewOpenAPI(info Info, paths Paths) *OpenAPIBuilder
NewOpenAPI creates a new builder object for OpenAPI
func (*OpenAPIBuilder) Build ¶
func (b *OpenAPIBuilder) Build(options ...Option) (OpenAPI, error)
Build finalizes the building process for OpenAPI and returns the result
func (*OpenAPIBuilder) Components ¶
func (b *OpenAPIBuilder) Components(v Components) *OpenAPIBuilder
Components sets the Components field for object OpenAPI.
func (*OpenAPIBuilder) ExternalDocs ¶
func (b *OpenAPIBuilder) ExternalDocs(v ExternalDocumentation) *OpenAPIBuilder
ExternalDocs sets the ExternalDocs field for object OpenAPI.
func (*OpenAPIBuilder) MustBuild ¶
func (b *OpenAPIBuilder) MustBuild(options ...Option) OpenAPI
MustBuild is a convenience function for those time when you know that the result of the builder must be successful
func (*OpenAPIBuilder) Reference ¶
func (b *OpenAPIBuilder) Reference(v string) *OpenAPIBuilder
Reference sets the $ref (reference) field for object OpenAPI.
func (*OpenAPIBuilder) Security ¶
func (b *OpenAPIBuilder) Security(v SecurityRequirement) *OpenAPIBuilder
Security sets the Security field for object OpenAPI.
func (*OpenAPIBuilder) Servers ¶
func (b *OpenAPIBuilder) Servers(v []Server) *OpenAPIBuilder
Servers sets the Servers field for object OpenAPI.
func (*OpenAPIBuilder) Tags ¶
func (b *OpenAPIBuilder) Tags(v []Tag) *OpenAPIBuilder
Tags sets the Tags field for object OpenAPI.
func (*OpenAPIBuilder) Version ¶
func (b *OpenAPIBuilder) Version(v string) *OpenAPIBuilder
Version sets the Version field for object OpenAPI. If this is not called, a default value (DefaultVersion) is assigned to this field
type OpenAPIMutator ¶
type OpenAPIMutator struct {
// contains filtered or unexported fields
}
OpenAPIMutator is used to build an instance of OpenAPI. The user must call `Do()` after providing all the necessary information to the new instance of OpenAPI with new values
func MutateOpenAPI ¶
func MutateOpenAPI(v OpenAPI) *OpenAPIMutator
MutateOpenAPI creates a new mutator object for OpenAPI
func (*OpenAPIMutator) ClearServers ¶
func (b *OpenAPIMutator) ClearServers() *OpenAPIMutator
func (*OpenAPIMutator) ClearTags ¶
func (b *OpenAPIMutator) ClearTags() *OpenAPIMutator
func (*OpenAPIMutator) Components ¶
func (b *OpenAPIMutator) Components(v Components) *OpenAPIMutator
Components sets the Components field for object OpenAPI.
func (*OpenAPIMutator) Do ¶
func (b *OpenAPIMutator) Do() error
Do finalizes the matuation process for OpenAPI and returns the result
func (*OpenAPIMutator) ExternalDocs ¶
func (b *OpenAPIMutator) ExternalDocs(v ExternalDocumentation) *OpenAPIMutator
ExternalDocs sets the ExternalDocs field for object OpenAPI.
func (*OpenAPIMutator) Info ¶
func (b *OpenAPIMutator) Info(v Info) *OpenAPIMutator
Info sets the Info field for object OpenAPI.
func (*OpenAPIMutator) Paths ¶
func (b *OpenAPIMutator) Paths(v Paths) *OpenAPIMutator
Paths sets the Paths field for object OpenAPI.
func (*OpenAPIMutator) Security ¶
func (b *OpenAPIMutator) Security(v SecurityRequirement) *OpenAPIMutator
Security sets the Security field for object OpenAPI.
func (*OpenAPIMutator) Server ¶
func (b *OpenAPIMutator) Server(value Server) *OpenAPIMutator
func (*OpenAPIMutator) Tag ¶
func (b *OpenAPIMutator) Tag(value Tag) *OpenAPIMutator
func (*OpenAPIMutator) Version ¶
func (b *OpenAPIMutator) Version(v string) *OpenAPIMutator
Version sets the Version field for object OpenAPI.
type OpenAPIVisitor ¶
OpenAPIVisitor is an interface for objects that knows how to process OpenAPI elements while traversing the OpenAPI structure
type Operation ¶
type Operation interface { Verb() string PathItem() PathItem Tags() *StringListIterator Summary() string Description() string ExternalDocs() ExternalDocumentation OperationID() string Parameters() *ParameterListIterator RequestBody() RequestBody Responses() Responses Callbacks() *CallbackMapIterator Deprecated() bool Security() *SecurityRequirementListIterator Servers() *ServerListIterator MarshalJSON() ([]byte, error) Clone() Operation Validator Path() string Detached() bool // contains filtered or unexported methods }
type OperationBuilder ¶
type OperationBuilder struct {
// contains filtered or unexported fields
}
OperationBuilder is used to build an instance of Operation. The user must call `Build()` after providing all the necessary information to build an instance of Operation
func NewOperation ¶
func NewOperation(responses Responses) *OperationBuilder
NewOperation creates a new builder object for Operation
func (*OperationBuilder) Build ¶
func (b *OperationBuilder) Build(options ...Option) (Operation, error)
Build finalizes the building process for Operation and returns the result
func (*OperationBuilder) Callbacks ¶
func (b *OperationBuilder) Callbacks(v map[string]Callback) *OperationBuilder
Callbacks sets the Callbacks field for object Operation.
func (*OperationBuilder) Deprecated ¶
func (b *OperationBuilder) Deprecated(v bool) *OperationBuilder
Deprecated sets the Deprecated field for object Operation.
func (*OperationBuilder) Description ¶
func (b *OperationBuilder) Description(v string) *OperationBuilder
Description sets the Description field for object Operation.
func (*OperationBuilder) ExternalDocs ¶
func (b *OperationBuilder) ExternalDocs(v ExternalDocumentation) *OperationBuilder
ExternalDocs sets the ExternalDocs field for object Operation.
func (*OperationBuilder) MustBuild ¶
func (b *OperationBuilder) MustBuild(options ...Option) Operation
MustBuild is a convenience function for those time when you know that the result of the builder must be successful
func (*OperationBuilder) OperationID ¶
func (b *OperationBuilder) OperationID(v string) *OperationBuilder
OperationID sets the OperationID field for object Operation.
func (*OperationBuilder) Parameter ¶
func (b *OperationBuilder) Parameter(p Parameter) *OperationBuilder
Parameter adds parameter `p` to the operation
func (*OperationBuilder) Parameters ¶
func (b *OperationBuilder) Parameters(v []Parameter) *OperationBuilder
Parameters sets the Parameters field for object Operation.
func (*OperationBuilder) Reference ¶
func (b *OperationBuilder) Reference(v string) *OperationBuilder
Reference sets the $ref (reference) field for object Operation.
func (*OperationBuilder) RequestBody ¶
func (b *OperationBuilder) RequestBody(v RequestBody) *OperationBuilder
RequestBody sets the RequestBody field for object Operation.
func (*OperationBuilder) Security ¶
func (b *OperationBuilder) Security(v []SecurityRequirement) *OperationBuilder
Security sets the Security field for object Operation.
func (*OperationBuilder) Servers ¶
func (b *OperationBuilder) Servers(v []Server) *OperationBuilder
Servers sets the Servers field for object Operation.
func (*OperationBuilder) Summary ¶
func (b *OperationBuilder) Summary(v string) *OperationBuilder
Summary sets the Summary field for object Operation.
func (*OperationBuilder) Tag ¶
func (b *OperationBuilder) Tag(s string) *OperationBuilder
Tag adds tag `s` to the operation
func (*OperationBuilder) Tags ¶
func (b *OperationBuilder) Tags(v []string) *OperationBuilder
Tags sets the Tags field for object Operation.
type OperationListIterator ¶
type OperationListIterator struct {
// contains filtered or unexported fields
}
func (*OperationListIterator) Item ¶
func (iter *OperationListIterator) Item() Operation
Item returns the next item in this iterator. Make sure to call Next() before hand to check if the iterator has more items
type OperationMutator ¶
type OperationMutator struct {
// contains filtered or unexported fields
}
OperationMutator is used to build an instance of Operation. The user must call `Do()` after providing all the necessary information to the new instance of Operation with new values
func MutateOperation ¶
func MutateOperation(v Operation) *OperationMutator
MutateOperation creates a new mutator object for Operation
func (*OperationMutator) Callback ¶
func (b *OperationMutator) Callback(key CallbackMapKey, value Callback) *OperationMutator
func (*OperationMutator) ClearCallbacks ¶
func (b *OperationMutator) ClearCallbacks() *OperationMutator
func (*OperationMutator) ClearParameters ¶
func (b *OperationMutator) ClearParameters() *OperationMutator
func (*OperationMutator) ClearSecurity ¶
func (b *OperationMutator) ClearSecurity() *OperationMutator
func (*OperationMutator) ClearServers ¶
func (b *OperationMutator) ClearServers() *OperationMutator
func (*OperationMutator) ClearTags ¶
func (b *OperationMutator) ClearTags() *OperationMutator
func (*OperationMutator) Deprecated ¶
func (b *OperationMutator) Deprecated(v bool) *OperationMutator
Deprecated sets the Deprecated field for object Operation.
func (*OperationMutator) Description ¶
func (b *OperationMutator) Description(v string) *OperationMutator
Description sets the Description field for object Operation.
func (*OperationMutator) Do ¶
func (b *OperationMutator) Do() error
Do finalizes the matuation process for Operation and returns the result
func (*OperationMutator) ExternalDocs ¶
func (b *OperationMutator) ExternalDocs(v ExternalDocumentation) *OperationMutator
ExternalDocs sets the ExternalDocs field for object Operation.
func (*OperationMutator) OperationID ¶
func (b *OperationMutator) OperationID(v string) *OperationMutator
OperationID sets the OperationID field for object Operation.
func (*OperationMutator) Parameter ¶
func (b *OperationMutator) Parameter(value Parameter) *OperationMutator
func (*OperationMutator) RequestBody ¶
func (b *OperationMutator) RequestBody(v RequestBody) *OperationMutator
RequestBody sets the RequestBody field for object Operation.
func (*OperationMutator) Responses ¶
func (b *OperationMutator) Responses(v Responses) *OperationMutator
Responses sets the Responses field for object Operation.
func (*OperationMutator) Security ¶
func (b *OperationMutator) Security(value SecurityRequirement) *OperationMutator
func (*OperationMutator) Server ¶
func (b *OperationMutator) Server(value Server) *OperationMutator
func (*OperationMutator) Summary ¶
func (b *OperationMutator) Summary(v string) *OperationMutator
Summary sets the Summary field for object Operation.
func (*OperationMutator) Tag ¶
func (b *OperationMutator) Tag(value string) *OperationMutator
type OperationVisitor ¶
OperationVisitor is an interface for objects that knows how to process Operation elements while traversing the OpenAPI structure
type Option ¶
func WithValidate ¶
WithValidate specifies if validation should be performed on the object. This option can be passed to `ParseYAML`, `ParseJSON`, and `Do` methods for builders and mutators.
type Parameter ¶
type Parameter interface { Name() string In() Location Required() bool Description() string Deprecated() bool AllowEmptyValue() bool Explode() bool AllowReserved() bool Schema() Schema Examples() *ExampleMapIterator Content() *MediaTypeMapIterator MarshalJSON() ([]byte, error) Clone() Parameter Validator }
type ParameterBuilder ¶
type ParameterBuilder struct {
// contains filtered or unexported fields
}
ParameterBuilder is used to build an instance of Parameter. The user must call `Build()` after providing all the necessary information to build an instance of Parameter
func NewParameter ¶
func NewParameter(name string, in Location) *ParameterBuilder
NewParameter creates a new builder object for Parameter
func (*ParameterBuilder) AllowEmptyValue ¶
func (b *ParameterBuilder) AllowEmptyValue(v bool) *ParameterBuilder
AllowEmptyValue sets the AllowEmptyValue field for object Parameter.
func (*ParameterBuilder) AllowReserved ¶
func (b *ParameterBuilder) AllowReserved(v bool) *ParameterBuilder
AllowReserved sets the AllowReserved field for object Parameter.
func (*ParameterBuilder) Build ¶
func (b *ParameterBuilder) Build(options ...Option) (Parameter, error)
Build finalizes the building process for Parameter and returns the result
func (*ParameterBuilder) Content ¶
func (b *ParameterBuilder) Content(v map[string]MediaType) *ParameterBuilder
Content sets the Content field for object Parameter.
func (*ParameterBuilder) Deprecated ¶
func (b *ParameterBuilder) Deprecated(v bool) *ParameterBuilder
Deprecated sets the Deprecated field for object Parameter.
func (*ParameterBuilder) Description ¶
func (b *ParameterBuilder) Description(v string) *ParameterBuilder
Description sets the Description field for object Parameter.
func (*ParameterBuilder) Examples ¶
func (b *ParameterBuilder) Examples(v map[string]Example) *ParameterBuilder
Examples sets the Examples field for object Parameter.
func (*ParameterBuilder) Explode ¶
func (b *ParameterBuilder) Explode(v bool) *ParameterBuilder
Explode sets the Explode field for object Parameter.
func (*ParameterBuilder) MustBuild ¶
func (b *ParameterBuilder) MustBuild(options ...Option) Parameter
MustBuild is a convenience function for those time when you know that the result of the builder must be successful
func (*ParameterBuilder) Reference ¶
func (b *ParameterBuilder) Reference(v string) *ParameterBuilder
Reference sets the $ref (reference) field for object Parameter.
func (*ParameterBuilder) Required ¶
func (b *ParameterBuilder) Required(v bool) *ParameterBuilder
Required sets the Required field for object Parameter. If this is not called, a default value (defaultParameterRequiredFromLocation(in)) is assigned to this field
func (*ParameterBuilder) Schema ¶
func (b *ParameterBuilder) Schema(v Schema) *ParameterBuilder
Schema sets the Schema field for object Parameter.
type ParameterList ¶
type ParameterList []Parameter
func (*ParameterList) Clear ¶
func (v *ParameterList) Clear() error
func (*ParameterList) UnmarshalJSON ¶
func (v *ParameterList) UnmarshalJSON(data []byte) error
func (*ParameterList) Validate ¶
func (v *ParameterList) Validate(recurse bool) error
Validate checks for the values for correctness. If `recurse` is specified, child elements are also validated
type ParameterListIterator ¶
type ParameterListIterator struct {
// contains filtered or unexported fields
}
func (*ParameterListIterator) Item ¶
func (iter *ParameterListIterator) Item() Parameter
Item returns the next item in this iterator. Make sure to call Next() before hand to check if the iterator has more items
type ParameterMap ¶
type ParameterMap map[ParameterMapKey]Parameter
func (*ParameterMap) Clear ¶
func (v *ParameterMap) Clear() error
func (ParameterMap) QueryJSON ¶
func (v ParameterMap) QueryJSON(path string) (ret interface{}, ok bool)
func (*ParameterMap) UnmarshalJSON ¶
func (v *ParameterMap) UnmarshalJSON(data []byte) error
func (*ParameterMap) Validate ¶
func (v *ParameterMap) Validate(recurse bool) error
Validate checks the correctness of values in ParameterMap
type ParameterMapIterator ¶
type ParameterMapIterator struct {
// contains filtered or unexported fields
}
func (*ParameterMapIterator) Item ¶
func (iter *ParameterMapIterator) Item() (string, Parameter)
Item returns the next item in this iterator. Make sure to call Next() before hand to check if the iterator has more items
type ParameterMapKey ¶
type ParameterMapKey = string
type ParameterMutator ¶
type ParameterMutator struct {
// contains filtered or unexported fields
}
ParameterMutator is used to build an instance of Parameter. The user must call `Do()` after providing all the necessary information to the new instance of Parameter with new values
func MutateParameter ¶
func MutateParameter(v Parameter) *ParameterMutator
MutateParameter creates a new mutator object for Parameter
func (*ParameterMutator) AllowEmptyValue ¶
func (b *ParameterMutator) AllowEmptyValue(v bool) *ParameterMutator
AllowEmptyValue sets the AllowEmptyValue field for object Parameter.
func (*ParameterMutator) AllowReserved ¶
func (b *ParameterMutator) AllowReserved(v bool) *ParameterMutator
AllowReserved sets the AllowReserved field for object Parameter.
func (*ParameterMutator) ClearContent ¶
func (b *ParameterMutator) ClearContent() *ParameterMutator
func (*ParameterMutator) ClearExamples ¶
func (b *ParameterMutator) ClearExamples() *ParameterMutator
func (*ParameterMutator) Content ¶
func (b *ParameterMutator) Content(key MediaTypeMapKey, value MediaType) *ParameterMutator
func (*ParameterMutator) Deprecated ¶
func (b *ParameterMutator) Deprecated(v bool) *ParameterMutator
Deprecated sets the Deprecated field for object Parameter.
func (*ParameterMutator) Description ¶
func (b *ParameterMutator) Description(v string) *ParameterMutator
Description sets the Description field for object Parameter.
func (*ParameterMutator) Do ¶
func (b *ParameterMutator) Do() error
Do finalizes the matuation process for Parameter and returns the result
func (*ParameterMutator) Example ¶
func (b *ParameterMutator) Example(key ExampleMapKey, value Example) *ParameterMutator
func (*ParameterMutator) Explode ¶
func (b *ParameterMutator) Explode(v bool) *ParameterMutator
Explode sets the Explode field for object Parameter.
func (*ParameterMutator) In ¶
func (b *ParameterMutator) In(v Location) *ParameterMutator
In sets the In field for object Parameter.
func (*ParameterMutator) Name ¶
func (b *ParameterMutator) Name(v string) *ParameterMutator
Name sets the Name field for object Parameter.
func (*ParameterMutator) Required ¶
func (b *ParameterMutator) Required(v bool) *ParameterMutator
Required sets the Required field for object Parameter.
func (*ParameterMutator) Schema ¶
func (b *ParameterMutator) Schema(v Schema) *ParameterMutator
Schema sets the Schema field for object Parameter.
type ParameterVisitor ¶
ParameterVisitor is an interface for objects that knows how to process Parameter elements while traversing the OpenAPI structure
type PathItem ¶
type PathItem interface { Name() string Path() string Summary() string Description() string Get() Operation Put() Operation Post() Operation Delete() Operation Options() Operation Head() Operation Patch() Operation Trace() Operation Servers() *ServerListIterator Parameters() *ParameterListIterator MarshalJSON() ([]byte, error) Clone() PathItem Validator Operations() *OperationListIterator // contains filtered or unexported methods }
type PathItemBuilder ¶
type PathItemBuilder struct {
// contains filtered or unexported fields
}
PathItemBuilder is used to build an instance of PathItem. The user must call `Build()` after providing all the necessary information to build an instance of PathItem
func NewPathItem ¶
func NewPathItem() *PathItemBuilder
NewPathItem creates a new builder object for PathItem
func (*PathItemBuilder) Build ¶
func (b *PathItemBuilder) Build(options ...Option) (PathItem, error)
Build finalizes the building process for PathItem and returns the result
func (*PathItemBuilder) Delete ¶
func (m *PathItemBuilder) Delete(v Operation) *PathItemBuilder
func (*PathItemBuilder) Description ¶
func (b *PathItemBuilder) Description(v string) *PathItemBuilder
Description sets the Description field for object PathItem.
func (*PathItemBuilder) Get ¶
func (b *PathItemBuilder) Get(oper Operation) *PathItemBuilder
func (*PathItemBuilder) Head ¶
func (m *PathItemBuilder) Head(v Operation) *PathItemBuilder
func (*PathItemBuilder) MustBuild ¶
func (b *PathItemBuilder) MustBuild(options ...Option) PathItem
MustBuild is a convenience function for those time when you know that the result of the builder must be successful
func (*PathItemBuilder) Options ¶
func (m *PathItemBuilder) Options(v Operation) *PathItemBuilder
func (*PathItemBuilder) Parameters ¶
func (b *PathItemBuilder) Parameters(v []Parameter) *PathItemBuilder
Parameters sets the Parameters field for object PathItem.
func (*PathItemBuilder) Patch ¶
func (m *PathItemBuilder) Patch(v Operation) *PathItemBuilder
func (*PathItemBuilder) Path ¶
func (b *PathItemBuilder) Path(v string) *PathItemBuilder
Path sets the Path field for object PathItem.
func (*PathItemBuilder) Post ¶
func (m *PathItemBuilder) Post(v Operation) *PathItemBuilder
func (*PathItemBuilder) Put ¶
func (m *PathItemBuilder) Put(v Operation) *PathItemBuilder
func (*PathItemBuilder) Reference ¶
func (b *PathItemBuilder) Reference(v string) *PathItemBuilder
Reference sets the $ref (reference) field for object PathItem.
func (*PathItemBuilder) Servers ¶
func (b *PathItemBuilder) Servers(v []Server) *PathItemBuilder
Servers sets the Servers field for object PathItem.
func (*PathItemBuilder) Summary ¶
func (b *PathItemBuilder) Summary(v string) *PathItemBuilder
Summary sets the Summary field for object PathItem.
func (*PathItemBuilder) Trace ¶
func (m *PathItemBuilder) Trace(v Operation) *PathItemBuilder
type PathItemListIterator ¶
type PathItemListIterator struct {
// contains filtered or unexported fields
}
func (*PathItemListIterator) Item ¶
func (iter *PathItemListIterator) Item() PathItem
Item returns the next item in this iterator. Make sure to call Next() before hand to check if the iterator has more items
type PathItemMap ¶
type PathItemMap map[PathItemMapKey]PathItem
func (*PathItemMap) Clear ¶
func (v *PathItemMap) Clear() error
func (PathItemMap) QueryJSON ¶
func (v PathItemMap) QueryJSON(path string) (ret interface{}, ok bool)
func (*PathItemMap) UnmarshalJSON ¶
func (v *PathItemMap) UnmarshalJSON(data []byte) error
func (*PathItemMap) Validate ¶
func (v *PathItemMap) Validate(recurse bool) error
Validate checks the correctness of values in PathItemMap
type PathItemMapIterator ¶
type PathItemMapIterator struct {
// contains filtered or unexported fields
}
func (*PathItemMapIterator) Item ¶
func (iter *PathItemMapIterator) Item() (string, PathItem)
Item returns the next item in this iterator. Make sure to call Next() before hand to check if the iterator has more items
type PathItemMapKey ¶
type PathItemMapKey = string
type PathItemMutator ¶
type PathItemMutator struct {
// contains filtered or unexported fields
}
PathItemMutator is used to build an instance of PathItem. The user must call `Do()` after providing all the necessary information to the new instance of PathItem with new values
func MutatePathItem ¶
func MutatePathItem(v PathItem) *PathItemMutator
MutatePathItem creates a new mutator object for PathItem
func (*PathItemMutator) ClearParameters ¶
func (b *PathItemMutator) ClearParameters() *PathItemMutator
func (*PathItemMutator) ClearServers ¶
func (b *PathItemMutator) ClearServers() *PathItemMutator
func (*PathItemMutator) Delete ¶
func (m *PathItemMutator) Delete(v Operation) *PathItemMutator
func (*PathItemMutator) Description ¶
func (b *PathItemMutator) Description(v string) *PathItemMutator
Description sets the Description field for object PathItem.
func (*PathItemMutator) Do ¶
func (b *PathItemMutator) Do() error
Do finalizes the matuation process for PathItem and returns the result
func (*PathItemMutator) Get ¶
func (m *PathItemMutator) Get(v Operation) *PathItemMutator
func (*PathItemMutator) Head ¶
func (m *PathItemMutator) Head(v Operation) *PathItemMutator
func (*PathItemMutator) Name ¶
func (b *PathItemMutator) Name(v string) *PathItemMutator
Name sets the Name field for object PathItem.
func (*PathItemMutator) Options ¶
func (m *PathItemMutator) Options(v Operation) *PathItemMutator
func (*PathItemMutator) Parameter ¶
func (b *PathItemMutator) Parameter(value Parameter) *PathItemMutator
func (*PathItemMutator) Patch ¶
func (m *PathItemMutator) Patch(v Operation) *PathItemMutator
func (*PathItemMutator) Path ¶
func (b *PathItemMutator) Path(v string) *PathItemMutator
Path sets the Path field for object PathItem.
func (*PathItemMutator) Post ¶
func (m *PathItemMutator) Post(v Operation) *PathItemMutator
func (*PathItemMutator) Put ¶
func (m *PathItemMutator) Put(v Operation) *PathItemMutator
func (*PathItemMutator) Server ¶
func (b *PathItemMutator) Server(value Server) *PathItemMutator
func (*PathItemMutator) Summary ¶
func (b *PathItemMutator) Summary(v string) *PathItemMutator
Summary sets the Summary field for object PathItem.
func (*PathItemMutator) Trace ¶
func (m *PathItemMutator) Trace(v Operation) *PathItemMutator
type PathItemVisitor ¶
PathItemVisitor is an interface for objects that knows how to process PathItem elements while traversing the OpenAPI structure
type Paths ¶
type Paths interface { Paths() *PathItemMapIterator MarshalJSON() ([]byte, error) Clone() Paths Validator }
type PathsBuilder ¶
type PathsBuilder struct {
// contains filtered or unexported fields
}
PathsBuilder is used to build an instance of Paths. The user must call `Build()` after providing all the necessary information to build an instance of Paths
func (*PathsBuilder) Build ¶
func (b *PathsBuilder) Build(options ...Option) (Paths, error)
Build finalizes the building process for Paths and returns the result
func (*PathsBuilder) MustBuild ¶
func (b *PathsBuilder) MustBuild(options ...Option) Paths
MustBuild is a convenience function for those time when you know that the result of the builder must be successful
func (*PathsBuilder) Path ¶
func (b *PathsBuilder) Path(path string, item PathItem) *PathsBuilder
Path sets the path item for path `path` to `item`
func (*PathsBuilder) Paths ¶
func (b *PathsBuilder) Paths(v map[string]PathItem) *PathsBuilder
Paths sets the Paths field for object Paths.
func (*PathsBuilder) Reference ¶
func (b *PathsBuilder) Reference(v string) *PathsBuilder
Reference sets the $ref (reference) field for object Paths.
type PathsMutator ¶
type PathsMutator struct {
// contains filtered or unexported fields
}
PathsMutator is used to build an instance of Paths. The user must call `Do()` after providing all the necessary information to the new instance of Paths with new values
func MutatePaths ¶
func MutatePaths(v Paths) *PathsMutator
MutatePaths creates a new mutator object for Paths
func (*PathsMutator) Do ¶
func (b *PathsMutator) Do() error
Do finalizes the matuation process for Paths and returns the result
func (*PathsMutator) Path ¶
func (m *PathsMutator) Path(path string, item PathItem) *PathsMutator
Path sets the path item for path `path` to `item`
type PathsVisitor ¶
PathsVisitor is an interface for objects that knows how to process Paths elements while traversing the OpenAPI structure
type PrimitiveType ¶
type PrimitiveType string
const ( Invalid PrimitiveType = "invalid" Integer PrimitiveType = "integer" Number PrimitiveType = "number" String PrimitiveType = "string" Boolean PrimitiveType = "boolean" Object PrimitiveType = "object" Array PrimitiveType = "array" Null PrimitiveType = "null" )
type QueryJSONer ¶
type RequestBody ¶
type RequestBody interface { Name() string Description() string Content() *MediaTypeMapIterator Required() bool MarshalJSON() ([]byte, error) Clone() RequestBody Validator // contains filtered or unexported methods }
type RequestBodyBuilder ¶
type RequestBodyBuilder struct {
// contains filtered or unexported fields
}
RequestBodyBuilder is used to build an instance of RequestBody. The user must call `Build()` after providing all the necessary information to build an instance of RequestBody
func NewRequestBody ¶
func NewRequestBody() *RequestBodyBuilder
NewRequestBody creates a new builder object for RequestBody
func (*RequestBodyBuilder) Build ¶
func (b *RequestBodyBuilder) Build(options ...Option) (RequestBody, error)
Build finalizes the building process for RequestBody and returns the result
func (*RequestBodyBuilder) Content ¶
func (b *RequestBodyBuilder) Content(mime MediaTypeMapKey, mt MediaType) *RequestBodyBuilder
Content sets the Content field for object RequestBody.
func (*RequestBodyBuilder) Description ¶
func (b *RequestBodyBuilder) Description(v string) *RequestBodyBuilder
Description sets the Description field for object RequestBody.
func (*RequestBodyBuilder) MustBuild ¶
func (b *RequestBodyBuilder) MustBuild(options ...Option) RequestBody
MustBuild is a convenience function for those time when you know that the result of the builder must be successful
func (*RequestBodyBuilder) Reference ¶
func (b *RequestBodyBuilder) Reference(v string) *RequestBodyBuilder
Reference sets the $ref (reference) field for object RequestBody.
func (*RequestBodyBuilder) Required ¶
func (b *RequestBodyBuilder) Required(v bool) *RequestBodyBuilder
Required sets the Required field for object RequestBody.
type RequestBodyMap ¶
type RequestBodyMap map[RequestBodyMapKey]RequestBody
func (*RequestBodyMap) Clear ¶
func (v *RequestBodyMap) Clear() error
func (RequestBodyMap) QueryJSON ¶
func (v RequestBodyMap) QueryJSON(path string) (ret interface{}, ok bool)
func (*RequestBodyMap) UnmarshalJSON ¶
func (v *RequestBodyMap) UnmarshalJSON(data []byte) error
func (*RequestBodyMap) Validate ¶
func (v *RequestBodyMap) Validate(recurse bool) error
Validate checks the correctness of values in RequestBodyMap
type RequestBodyMapIterator ¶
type RequestBodyMapIterator struct {
// contains filtered or unexported fields
}
func (*RequestBodyMapIterator) Item ¶
func (iter *RequestBodyMapIterator) Item() (string, RequestBody)
Item returns the next item in this iterator. Make sure to call Next() before hand to check if the iterator has more items
type RequestBodyMapKey ¶
type RequestBodyMapKey = string
type RequestBodyMutator ¶
type RequestBodyMutator struct {
// contains filtered or unexported fields
}
RequestBodyMutator is used to build an instance of RequestBody. The user must call `Do()` after providing all the necessary information to the new instance of RequestBody with new values
func MutateRequestBody ¶
func MutateRequestBody(v RequestBody) *RequestBodyMutator
MutateRequestBody creates a new mutator object for RequestBody
func (*RequestBodyMutator) Content ¶
func (b *RequestBodyMutator) Content(mime MediaTypeMapKey, mt MediaType) *RequestBodyMutator
Content sets the Content field for object RequestBody.
func (*RequestBodyMutator) Description ¶
func (b *RequestBodyMutator) Description(v string) *RequestBodyMutator
Description sets the Description field for object RequestBody.
func (*RequestBodyMutator) Do ¶
func (b *RequestBodyMutator) Do() error
Do finalizes the matuation process for RequestBody and returns the result
func (*RequestBodyMutator) Name ¶
func (b *RequestBodyMutator) Name(v string) *RequestBodyMutator
Name sets the Name field for object RequestBody.
func (*RequestBodyMutator) Required ¶
func (b *RequestBodyMutator) Required(v bool) *RequestBodyMutator
Required sets the Required field for object RequestBody.
type RequestBodyVisitor ¶
type RequestBodyVisitor interface {
VisitRequestBody(context.Context, RequestBody) error
}
RequestBodyVisitor is an interface for objects that knows how to process RequestBody elements while traversing the OpenAPI structure
type Resolver ¶
type Resolver struct {
// contains filtered or unexported fields
}
func NewResolver ¶
type Response ¶
type Response interface { Name() string Description() string Headers() *HeaderMapIterator Content() *MediaTypeMapIterator Links() *LinkMapIterator MarshalJSON() ([]byte, error) Clone() Response Validator // contains filtered or unexported methods }
type ResponseBuilder ¶
type ResponseBuilder struct {
// contains filtered or unexported fields
}
ResponseBuilder is used to build an instance of Response. The user must call `Build()` after providing all the necessary information to build an instance of Response
func NewResponse ¶
func NewResponse(description string) *ResponseBuilder
NewResponse creates a new builder object for Response
func (*ResponseBuilder) Build ¶
func (b *ResponseBuilder) Build(options ...Option) (Response, error)
Build finalizes the building process for Response and returns the result
func (*ResponseBuilder) Content ¶
func (b *ResponseBuilder) Content(mime string, desc MediaType) *ResponseBuilder
Content sets th content type `mime` to `desc`
func (*ResponseBuilder) Header ¶
func (b *ResponseBuilder) Header(name string, hdr Header) *ResponseBuilder
Header sets the header `name` to `hdr`
func (*ResponseBuilder) Headers ¶
func (b *ResponseBuilder) Headers(v map[string]Header) *ResponseBuilder
Headers sets the Headers field for object Response.
func (*ResponseBuilder) MustBuild ¶
func (b *ResponseBuilder) MustBuild(options ...Option) Response
MustBuild is a convenience function for those time when you know that the result of the builder must be successful
func (*ResponseBuilder) Reference ¶
func (b *ResponseBuilder) Reference(v string) *ResponseBuilder
Reference sets the $ref (reference) field for object Response.
type ResponseMap ¶
type ResponseMap map[ResponseMapKey]Response
func (*ResponseMap) Clear ¶
func (v *ResponseMap) Clear() error
func (ResponseMap) QueryJSON ¶
func (v ResponseMap) QueryJSON(path string) (ret interface{}, ok bool)
func (*ResponseMap) UnmarshalJSON ¶
func (v *ResponseMap) UnmarshalJSON(data []byte) error
func (*ResponseMap) Validate ¶
func (v *ResponseMap) Validate(recurse bool) error
Validate checks the correctness of values in ResponseMap
type ResponseMapIterator ¶
type ResponseMapIterator struct {
// contains filtered or unexported fields
}
func (*ResponseMapIterator) Item ¶
func (iter *ResponseMapIterator) Item() (string, Response)
Item returns the next item in this iterator. Make sure to call Next() before hand to check if the iterator has more items
type ResponseMapKey ¶
type ResponseMapKey = string
type ResponseMutator ¶
type ResponseMutator struct {
// contains filtered or unexported fields
}
ResponseMutator is used to build an instance of Response. The user must call `Do()` after providing all the necessary information to the new instance of Response with new values
func MutateResponse ¶
func MutateResponse(v Response) *ResponseMutator
MutateResponse creates a new mutator object for Response
func (*ResponseMutator) ClearContent ¶
func (b *ResponseMutator) ClearContent() *ResponseMutator
func (*ResponseMutator) ClearHeaders ¶
func (b *ResponseMutator) ClearHeaders() *ResponseMutator
func (*ResponseMutator) ClearLinks ¶
func (b *ResponseMutator) ClearLinks() *ResponseMutator
func (*ResponseMutator) Content ¶
func (b *ResponseMutator) Content(key MediaTypeMapKey, value MediaType) *ResponseMutator
func (*ResponseMutator) Description ¶
func (b *ResponseMutator) Description(v string) *ResponseMutator
Description sets the Description field for object Response.
func (*ResponseMutator) Do ¶
func (b *ResponseMutator) Do() error
Do finalizes the matuation process for Response and returns the result
func (*ResponseMutator) Header ¶
func (b *ResponseMutator) Header(key HeaderMapKey, value Header) *ResponseMutator
func (*ResponseMutator) Link ¶
func (b *ResponseMutator) Link(key LinkMapKey, value Link) *ResponseMutator
func (*ResponseMutator) Name ¶
func (b *ResponseMutator) Name(v string) *ResponseMutator
Name sets the Name field for object Response.
type ResponseVisitor ¶
ResponseVisitor is an interface for objects that knows how to process Response elements while traversing the OpenAPI structure
type ResponsesBuilder ¶
type ResponsesBuilder struct {
// contains filtered or unexported fields
}
ResponsesBuilder is used to build an instance of Responses. The user must call `Build()` after providing all the necessary information to build an instance of Responses
func NewResponses ¶
func NewResponses() *ResponsesBuilder
NewResponses creates a new builder object for Responses
func (*ResponsesBuilder) Build ¶
func (b *ResponsesBuilder) Build(options ...Option) (Responses, error)
Build finalizes the building process for Responses and returns the result
func (*ResponsesBuilder) Default ¶
func (b *ResponsesBuilder) Default(v Response) *ResponsesBuilder
Default sets the Default field for object Responses.
func (*ResponsesBuilder) MustBuild ¶
func (b *ResponsesBuilder) MustBuild(options ...Option) Responses
MustBuild is a convenience function for those time when you know that the result of the builder must be successful
func (*ResponsesBuilder) Reference ¶
func (b *ResponsesBuilder) Reference(v string) *ResponsesBuilder
Reference sets the $ref (reference) field for object Responses.
func (*ResponsesBuilder) Response ¶
func (b *ResponsesBuilder) Response(code string, v Response) *ResponsesBuilder
Response sets the response for status code `code` to `v`
type ResponsesMutator ¶
type ResponsesMutator struct {
// contains filtered or unexported fields
}
ResponsesMutator is used to build an instance of Responses. The user must call `Do()` after providing all the necessary information to the new instance of Responses with new values
func MutateResponses ¶
func MutateResponses(v Responses) *ResponsesMutator
MutateResponses creates a new mutator object for Responses
func (*ResponsesMutator) ClearResponses ¶
func (b *ResponsesMutator) ClearResponses() *ResponsesMutator
func (*ResponsesMutator) Default ¶
func (b *ResponsesMutator) Default(v Response) *ResponsesMutator
Default sets the Default field for object Responses.
func (*ResponsesMutator) Do ¶
func (b *ResponsesMutator) Do() error
Do finalizes the matuation process for Responses and returns the result
func (*ResponsesMutator) Response ¶
func (b *ResponsesMutator) Response(key ResponseMapKey, value Response) *ResponsesMutator
type ResponsesVisitor ¶
ResponsesVisitor is an interface for objects that knows how to process Responses elements while traversing the OpenAPI structure
type Schema ¶
type Schema interface { Name() string Title() string MultipleOf() float64 Maximum() float64 ExclusiveMaximum() float64 Minimum() float64 ExclusiveMinimum() float64 MaxLength() int MinLength() int Pattern() string MaxItems() int MinItems() int UniqueItems() bool MaxProperties() int MinProperties() int Required() *StringListIterator Enum() *InterfaceListIterator AllOf() *SchemaListIterator OneOf() *SchemaListIterator AnyOf() *SchemaListIterator Not() Schema Items() Schema Properties() *SchemaMapIterator Format() string Default() interface{} Nullable() bool Discriminator() Discriminator ReadOnly() bool WriteOnly() bool ExternalDocs() ExternalDocumentation Example() interface{} Deprecated() bool MarshalJSON() ([]byte, error) Clone() Schema Validator Type() PrimitiveType // contains filtered or unexported methods }
type SchemaBuilder ¶
type SchemaBuilder struct {
// contains filtered or unexported fields
}
SchemaBuilder is used to build an instance of Schema. The user must call `Build()` after providing all the necessary information to build an instance of Schema
func (*SchemaBuilder) AllOf ¶
func (b *SchemaBuilder) AllOf(v []Schema) *SchemaBuilder
AllOf sets the AllOf field for object Schema.
func (*SchemaBuilder) AnyOf ¶
func (b *SchemaBuilder) AnyOf(v []Schema) *SchemaBuilder
AnyOf sets the AnyOf field for object Schema.
func (*SchemaBuilder) Build ¶
func (b *SchemaBuilder) Build(options ...Option) (Schema, error)
Build finalizes the building process for Schema and returns the result
func (*SchemaBuilder) Default ¶
func (b *SchemaBuilder) Default(v interface{}) *SchemaBuilder
Default sets the Default field for object Schema.
func (*SchemaBuilder) Deprecated ¶
func (b *SchemaBuilder) Deprecated(v bool) *SchemaBuilder
Deprecated sets the Deprecated field for object Schema.
func (*SchemaBuilder) Discriminator ¶
func (b *SchemaBuilder) Discriminator(v Discriminator) *SchemaBuilder
Discriminator sets the Discriminator field for object Schema.
func (*SchemaBuilder) Enum ¶
func (b *SchemaBuilder) Enum(v []interface{}) *SchemaBuilder
Enum sets the Enum field for object Schema.
func (*SchemaBuilder) Example ¶
func (b *SchemaBuilder) Example(v interface{}) *SchemaBuilder
Example sets the Example field for object Schema.
func (*SchemaBuilder) ExclusiveMaximum ¶
func (b *SchemaBuilder) ExclusiveMaximum(v float64) *SchemaBuilder
ExclusiveMaximum sets the ExclusiveMaximum field for object Schema.
func (*SchemaBuilder) ExclusiveMinimum ¶
func (b *SchemaBuilder) ExclusiveMinimum(v float64) *SchemaBuilder
ExclusiveMinimum sets the ExclusiveMinimum field for object Schema.
func (*SchemaBuilder) ExternalDocs ¶
func (b *SchemaBuilder) ExternalDocs(v ExternalDocumentation) *SchemaBuilder
ExternalDocs sets the ExternalDocs field for object Schema.
func (*SchemaBuilder) Format ¶
func (b *SchemaBuilder) Format(v string) *SchemaBuilder
Format sets the Format field for object Schema.
func (*SchemaBuilder) Items ¶
func (b *SchemaBuilder) Items(v Schema) *SchemaBuilder
Items sets the Items field for object Schema.
func (*SchemaBuilder) MaxItems ¶
func (b *SchemaBuilder) MaxItems(v int) *SchemaBuilder
MaxItems sets the MaxItems field for object Schema.
func (*SchemaBuilder) MaxLength ¶
func (b *SchemaBuilder) MaxLength(v int) *SchemaBuilder
MaxLength sets the MaxLength field for object Schema.
func (*SchemaBuilder) MaxProperties ¶
func (b *SchemaBuilder) MaxProperties(v int) *SchemaBuilder
MaxProperties sets the MaxProperties field for object Schema.
func (*SchemaBuilder) Maximum ¶
func (b *SchemaBuilder) Maximum(v float64) *SchemaBuilder
Maximum sets the Maximum field for object Schema.
func (*SchemaBuilder) MinItems ¶
func (b *SchemaBuilder) MinItems(v int) *SchemaBuilder
MinItems sets the MinItems field for object Schema.
func (*SchemaBuilder) MinLength ¶
func (b *SchemaBuilder) MinLength(v int) *SchemaBuilder
MinLength sets the MinLength field for object Schema.
func (*SchemaBuilder) MinProperties ¶
func (b *SchemaBuilder) MinProperties(v int) *SchemaBuilder
MinProperties sets the MinProperties field for object Schema.
func (*SchemaBuilder) Minimum ¶
func (b *SchemaBuilder) Minimum(v float64) *SchemaBuilder
Minimum sets the Minimum field for object Schema.
func (*SchemaBuilder) MultipleOf ¶
func (b *SchemaBuilder) MultipleOf(v float64) *SchemaBuilder
MultipleOf sets the MultipleOf field for object Schema.
func (*SchemaBuilder) MustBuild ¶
func (b *SchemaBuilder) MustBuild(options ...Option) Schema
MustBuild is a convenience function for those time when you know that the result of the builder must be successful
func (*SchemaBuilder) Not ¶
func (b *SchemaBuilder) Not(v Schema) *SchemaBuilder
Not sets the Not field for object Schema.
func (*SchemaBuilder) Nullable ¶
func (b *SchemaBuilder) Nullable(v bool) *SchemaBuilder
Nullable sets the Nullable field for object Schema.
func (*SchemaBuilder) OneOf ¶
func (b *SchemaBuilder) OneOf(v []Schema) *SchemaBuilder
OneOf sets the OneOf field for object Schema.
func (*SchemaBuilder) Pattern ¶
func (b *SchemaBuilder) Pattern(v string) *SchemaBuilder
Pattern sets the Pattern field for object Schema.
func (*SchemaBuilder) Properties ¶
func (b *SchemaBuilder) Properties(v map[string]Schema) *SchemaBuilder
Properties sets the Properties field for object Schema.
func (*SchemaBuilder) Property ¶
func (b *SchemaBuilder) Property(name string, s Schema) *SchemaBuilder
Property sets property `name` to `s`
func (*SchemaBuilder) ReadOnly ¶
func (b *SchemaBuilder) ReadOnly(v bool) *SchemaBuilder
ReadOnly sets the ReadOnly field for object Schema.
func (*SchemaBuilder) Reference ¶
func (b *SchemaBuilder) Reference(v string) *SchemaBuilder
Reference sets the $ref (reference) field for object Schema.
func (*SchemaBuilder) Required ¶
func (b *SchemaBuilder) Required(v []string) *SchemaBuilder
Required sets the Required field for object Schema.
func (*SchemaBuilder) Title ¶
func (b *SchemaBuilder) Title(v string) *SchemaBuilder
Title sets the Title field for object Schema.
func (*SchemaBuilder) Type ¶
func (b *SchemaBuilder) Type(v PrimitiveType) *SchemaBuilder
Type sets the Type field for object Schema.
func (*SchemaBuilder) UniqueItems ¶
func (b *SchemaBuilder) UniqueItems(v bool) *SchemaBuilder
UniqueItems sets the UniqueItems field for object Schema.
func (*SchemaBuilder) WriteOnly ¶
func (b *SchemaBuilder) WriteOnly(v bool) *SchemaBuilder
WriteOnly sets the WriteOnly field for object Schema.
type SchemaList ¶
type SchemaList []Schema
func (*SchemaList) Clear ¶
func (v *SchemaList) Clear() error
func (*SchemaList) UnmarshalJSON ¶
func (v *SchemaList) UnmarshalJSON(data []byte) error
func (*SchemaList) Validate ¶
func (v *SchemaList) Validate(recurse bool) error
Validate checks for the values for correctness. If `recurse` is specified, child elements are also validated
type SchemaListIterator ¶
type SchemaListIterator struct {
// contains filtered or unexported fields
}
func (*SchemaListIterator) Item ¶
func (iter *SchemaListIterator) Item() Schema
Item returns the next item in this iterator. Make sure to call Next() before hand to check if the iterator has more items
type SchemaMapIterator ¶
type SchemaMapIterator struct {
// contains filtered or unexported fields
}
func (*SchemaMapIterator) Item ¶
func (iter *SchemaMapIterator) Item() (string, Schema)
Item returns the next item in this iterator. Make sure to call Next() before hand to check if the iterator has more items
type SchemaMapKey ¶
type SchemaMapKey = string
type SchemaMutator ¶
type SchemaMutator struct {
// contains filtered or unexported fields
}
SchemaMutator is used to build an instance of Schema. The user must call `Do()` after providing all the necessary information to the new instance of Schema with new values
func MutateSchema ¶
func MutateSchema(v Schema) *SchemaMutator
MutateSchema creates a new mutator object for Schema
func (*SchemaMutator) AllOf ¶
func (b *SchemaMutator) AllOf(value Schema) *SchemaMutator
func (*SchemaMutator) AnyOf ¶
func (b *SchemaMutator) AnyOf(value Schema) *SchemaMutator
func (*SchemaMutator) ClearAllOf ¶
func (b *SchemaMutator) ClearAllOf() *SchemaMutator
func (*SchemaMutator) ClearAnyOf ¶
func (b *SchemaMutator) ClearAnyOf() *SchemaMutator
func (*SchemaMutator) ClearEnum ¶
func (b *SchemaMutator) ClearEnum() *SchemaMutator
func (*SchemaMutator) ClearOneOf ¶
func (b *SchemaMutator) ClearOneOf() *SchemaMutator
func (*SchemaMutator) ClearProperties ¶
func (b *SchemaMutator) ClearProperties() *SchemaMutator
func (*SchemaMutator) ClearRequired ¶
func (b *SchemaMutator) ClearRequired() *SchemaMutator
func (*SchemaMutator) Default ¶
func (b *SchemaMutator) Default(v interface{}) *SchemaMutator
Default sets the Default field for object Schema.
func (*SchemaMutator) Deprecated ¶
func (b *SchemaMutator) Deprecated(v bool) *SchemaMutator
Deprecated sets the Deprecated field for object Schema.
func (*SchemaMutator) Discriminator ¶
func (b *SchemaMutator) Discriminator(v Discriminator) *SchemaMutator
Discriminator sets the Discriminator field for object Schema.
func (*SchemaMutator) Do ¶
func (b *SchemaMutator) Do() error
Do finalizes the matuation process for Schema and returns the result
func (*SchemaMutator) Enum ¶
func (b *SchemaMutator) Enum(value interface{}) *SchemaMutator
func (*SchemaMutator) Example ¶
func (b *SchemaMutator) Example(v interface{}) *SchemaMutator
Example sets the Example field for object Schema.
func (*SchemaMutator) ExclusiveMaximum ¶
func (b *SchemaMutator) ExclusiveMaximum(v float64) *SchemaMutator
ExclusiveMaximum sets the ExclusiveMaximum field for object Schema.
func (*SchemaMutator) ExclusiveMinimum ¶
func (b *SchemaMutator) ExclusiveMinimum(v float64) *SchemaMutator
ExclusiveMinimum sets the ExclusiveMinimum field for object Schema.
func (*SchemaMutator) ExternalDocs ¶
func (b *SchemaMutator) ExternalDocs(v ExternalDocumentation) *SchemaMutator
ExternalDocs sets the ExternalDocs field for object Schema.
func (*SchemaMutator) Format ¶
func (b *SchemaMutator) Format(v string) *SchemaMutator
Format sets the Format field for object Schema.
func (*SchemaMutator) Items ¶
func (b *SchemaMutator) Items(v Schema) *SchemaMutator
Items sets the Items field for object Schema.
func (*SchemaMutator) MaxItems ¶
func (b *SchemaMutator) MaxItems(v int) *SchemaMutator
MaxItems sets the MaxItems field for object Schema.
func (*SchemaMutator) MaxLength ¶
func (b *SchemaMutator) MaxLength(v int) *SchemaMutator
MaxLength sets the MaxLength field for object Schema.
func (*SchemaMutator) MaxProperties ¶
func (b *SchemaMutator) MaxProperties(v int) *SchemaMutator
MaxProperties sets the MaxProperties field for object Schema.
func (*SchemaMutator) Maximum ¶
func (b *SchemaMutator) Maximum(v float64) *SchemaMutator
Maximum sets the Maximum field for object Schema.
func (*SchemaMutator) MinItems ¶
func (b *SchemaMutator) MinItems(v int) *SchemaMutator
MinItems sets the MinItems field for object Schema.
func (*SchemaMutator) MinLength ¶
func (b *SchemaMutator) MinLength(v int) *SchemaMutator
MinLength sets the MinLength field for object Schema.
func (*SchemaMutator) MinProperties ¶
func (b *SchemaMutator) MinProperties(v int) *SchemaMutator
MinProperties sets the MinProperties field for object Schema.
func (*SchemaMutator) Minimum ¶
func (b *SchemaMutator) Minimum(v float64) *SchemaMutator
Minimum sets the Minimum field for object Schema.
func (*SchemaMutator) MultipleOf ¶
func (b *SchemaMutator) MultipleOf(v float64) *SchemaMutator
MultipleOf sets the MultipleOf field for object Schema.
func (*SchemaMutator) Name ¶
func (b *SchemaMutator) Name(v string) *SchemaMutator
Name sets the Name field for object Schema.
func (*SchemaMutator) Not ¶
func (b *SchemaMutator) Not(v Schema) *SchemaMutator
Not sets the Not field for object Schema.
func (*SchemaMutator) Nullable ¶
func (b *SchemaMutator) Nullable(v bool) *SchemaMutator
Nullable sets the Nullable field for object Schema.
func (*SchemaMutator) OneOf ¶
func (b *SchemaMutator) OneOf(value Schema) *SchemaMutator
func (*SchemaMutator) Pattern ¶
func (b *SchemaMutator) Pattern(v string) *SchemaMutator
Pattern sets the Pattern field for object Schema.
func (*SchemaMutator) Property ¶
func (b *SchemaMutator) Property(key SchemaMapKey, value Schema) *SchemaMutator
func (*SchemaMutator) ReadOnly ¶
func (b *SchemaMutator) ReadOnly(v bool) *SchemaMutator
ReadOnly sets the ReadOnly field for object Schema.
func (*SchemaMutator) Required ¶
func (b *SchemaMutator) Required(value string) *SchemaMutator
func (*SchemaMutator) Title ¶
func (b *SchemaMutator) Title(v string) *SchemaMutator
Title sets the Title field for object Schema.
func (*SchemaMutator) Type ¶
func (b *SchemaMutator) Type(v PrimitiveType) *SchemaMutator
Type sets the Type field for object Schema.
func (*SchemaMutator) UniqueItems ¶
func (b *SchemaMutator) UniqueItems(v bool) *SchemaMutator
UniqueItems sets the UniqueItems field for object Schema.
func (*SchemaMutator) WriteOnly ¶
func (b *SchemaMutator) WriteOnly(v bool) *SchemaMutator
WriteOnly sets the WriteOnly field for object Schema.
type SchemaVisitor ¶
SchemaVisitor is an interface for objects that knows how to process Schema elements while traversing the OpenAPI structure
type ScopeMap ¶
type ScopeMap map[ScopeMapKey]string
type ScopeMapIterator ¶
type ScopeMapIterator struct {
// contains filtered or unexported fields
}
func (*ScopeMapIterator) Item ¶
func (iter *ScopeMapIterator) Item() (string, string)
Item returns the next item in this iterator. Make sure to call Next() before hand to check if the iterator has more items
type ScopeMapKey ¶
type ScopeMapKey = string
type SecurityRequirement ¶
type SecurityRequirement interface { Schemes() *StringListMapIterator MarshalJSON() ([]byte, error) Clone() SecurityRequirement Validator }
type SecurityRequirementBuilder ¶
type SecurityRequirementBuilder struct {
// contains filtered or unexported fields
}
SecurityRequirementBuilder is used to build an instance of SecurityRequirement. The user must call `Build()` after providing all the necessary information to build an instance of SecurityRequirement
func NewSecurityRequirement ¶
func NewSecurityRequirement() *SecurityRequirementBuilder
NewSecurityRequirement creates a new builder object for SecurityRequirement
func (*SecurityRequirementBuilder) Build ¶
func (b *SecurityRequirementBuilder) Build(options ...Option) (SecurityRequirement, error)
Build finalizes the building process for SecurityRequirement and returns the result
func (*SecurityRequirementBuilder) MustBuild ¶
func (b *SecurityRequirementBuilder) MustBuild(options ...Option) SecurityRequirement
MustBuild is a convenience function for those time when you know that the result of the builder must be successful
func (*SecurityRequirementBuilder) Reference ¶
func (b *SecurityRequirementBuilder) Reference(v string) *SecurityRequirementBuilder
Reference sets the $ref (reference) field for object SecurityRequirement.
func (*SecurityRequirementBuilder) Schemes ¶
func (b *SecurityRequirementBuilder) Schemes(v map[string][]string) *SecurityRequirementBuilder
Schemes sets the Schemes field for object SecurityRequirement.
type SecurityRequirementList ¶
type SecurityRequirementList []SecurityRequirement
func (*SecurityRequirementList) Clear ¶
func (v *SecurityRequirementList) Clear() error
func (*SecurityRequirementList) UnmarshalJSON ¶
func (v *SecurityRequirementList) UnmarshalJSON(data []byte) error
func (*SecurityRequirementList) Validate ¶
func (v *SecurityRequirementList) Validate(recurse bool) error
Validate checks for the values for correctness. If `recurse` is specified, child elements are also validated
type SecurityRequirementListIterator ¶
type SecurityRequirementListIterator struct {
// contains filtered or unexported fields
}
func (*SecurityRequirementListIterator) Item ¶
func (iter *SecurityRequirementListIterator) Item() SecurityRequirement
Item returns the next item in this iterator. Make sure to call Next() before hand to check if the iterator has more items
type SecurityRequirementMutator ¶
type SecurityRequirementMutator struct {
// contains filtered or unexported fields
}
SecurityRequirementMutator is used to build an instance of SecurityRequirement. The user must call `Do()` after providing all the necessary information to the new instance of SecurityRequirement with new values
func MutateSecurityRequirement ¶
func MutateSecurityRequirement(v SecurityRequirement) *SecurityRequirementMutator
MutateSecurityRequirement creates a new mutator object for SecurityRequirement
func (*SecurityRequirementMutator) ClearSchemes ¶
func (b *SecurityRequirementMutator) ClearSchemes() *SecurityRequirementMutator
func (*SecurityRequirementMutator) Do ¶
func (b *SecurityRequirementMutator) Do() error
Do finalizes the matuation process for SecurityRequirement and returns the result
func (*SecurityRequirementMutator) Scheme ¶
func (b *SecurityRequirementMutator) Scheme(key StringListMapKey, value []string) *SecurityRequirementMutator
type SecurityRequirementVisitor ¶
type SecurityRequirementVisitor interface {
VisitSecurityRequirement(context.Context, SecurityRequirement) error
}
SecurityRequirementVisitor is an interface for objects that knows how to process SecurityRequirement elements while traversing the OpenAPI structure
type SecurityScheme ¶
type SecuritySchemeBuilder ¶
type SecuritySchemeBuilder struct {
// contains filtered or unexported fields
}
SecuritySchemeBuilder is used to build an instance of SecurityScheme. The user must call `Build()` after providing all the necessary information to build an instance of SecurityScheme
func NewSecurityScheme ¶
func NewSecurityScheme(typ string, name string, in string, scheme string, flows OAuthFlows, openIDConnectURL string) *SecuritySchemeBuilder
NewSecurityScheme creates a new builder object for SecurityScheme
func (*SecuritySchemeBuilder) BearerFormat ¶
func (b *SecuritySchemeBuilder) BearerFormat(v string) *SecuritySchemeBuilder
BearerFormat sets the BearerFormat field for object SecurityScheme.
func (*SecuritySchemeBuilder) Build ¶
func (b *SecuritySchemeBuilder) Build(options ...Option) (SecurityScheme, error)
Build finalizes the building process for SecurityScheme and returns the result
func (*SecuritySchemeBuilder) Description ¶
func (b *SecuritySchemeBuilder) Description(v string) *SecuritySchemeBuilder
Description sets the Description field for object SecurityScheme.
func (*SecuritySchemeBuilder) MustBuild ¶
func (b *SecuritySchemeBuilder) MustBuild(options ...Option) SecurityScheme
MustBuild is a convenience function for those time when you know that the result of the builder must be successful
func (*SecuritySchemeBuilder) Reference ¶
func (b *SecuritySchemeBuilder) Reference(v string) *SecuritySchemeBuilder
Reference sets the $ref (reference) field for object SecurityScheme.
type SecuritySchemeMap ¶
type SecuritySchemeMap map[SecuritySchemeMapKey]SecurityScheme
func (*SecuritySchemeMap) Clear ¶
func (v *SecuritySchemeMap) Clear() error
func (SecuritySchemeMap) QueryJSON ¶
func (v SecuritySchemeMap) QueryJSON(path string) (ret interface{}, ok bool)
func (*SecuritySchemeMap) UnmarshalJSON ¶
func (v *SecuritySchemeMap) UnmarshalJSON(data []byte) error
func (*SecuritySchemeMap) Validate ¶
func (v *SecuritySchemeMap) Validate(recurse bool) error
Validate checks the correctness of values in SecuritySchemeMap
type SecuritySchemeMapIterator ¶
type SecuritySchemeMapIterator struct {
// contains filtered or unexported fields
}
func (*SecuritySchemeMapIterator) Item ¶
func (iter *SecuritySchemeMapIterator) Item() (string, SecurityScheme)
Item returns the next item in this iterator. Make sure to call Next() before hand to check if the iterator has more items
type SecuritySchemeMapKey ¶
type SecuritySchemeMapKey = string
type SecuritySchemeMutator ¶
type SecuritySchemeMutator struct {
// contains filtered or unexported fields
}
SecuritySchemeMutator is used to build an instance of SecurityScheme. The user must call `Do()` after providing all the necessary information to the new instance of SecurityScheme with new values
func MutateSecurityScheme ¶
func MutateSecurityScheme(v SecurityScheme) *SecuritySchemeMutator
MutateSecurityScheme creates a new mutator object for SecurityScheme
func (*SecuritySchemeMutator) BearerFormat ¶
func (b *SecuritySchemeMutator) BearerFormat(v string) *SecuritySchemeMutator
BearerFormat sets the BearerFormat field for object SecurityScheme.
func (*SecuritySchemeMutator) Description ¶
func (b *SecuritySchemeMutator) Description(v string) *SecuritySchemeMutator
Description sets the Description field for object SecurityScheme.
func (*SecuritySchemeMutator) Do ¶
func (b *SecuritySchemeMutator) Do() error
Do finalizes the matuation process for SecurityScheme and returns the result
func (*SecuritySchemeMutator) Flows ¶
func (b *SecuritySchemeMutator) Flows(v OAuthFlows) *SecuritySchemeMutator
Flows sets the Flows field for object SecurityScheme.
func (*SecuritySchemeMutator) In ¶
func (b *SecuritySchemeMutator) In(v string) *SecuritySchemeMutator
In sets the In field for object SecurityScheme.
func (*SecuritySchemeMutator) Name ¶
func (b *SecuritySchemeMutator) Name(v string) *SecuritySchemeMutator
Name sets the Name field for object SecurityScheme.
func (*SecuritySchemeMutator) OpenIDConnectURL ¶
func (b *SecuritySchemeMutator) OpenIDConnectURL(v string) *SecuritySchemeMutator
OpenIDConnectURL sets the OpenIDConnectURL field for object SecurityScheme.
func (*SecuritySchemeMutator) Scheme ¶
func (b *SecuritySchemeMutator) Scheme(v string) *SecuritySchemeMutator
Scheme sets the Scheme field for object SecurityScheme.
func (*SecuritySchemeMutator) Type ¶
func (b *SecuritySchemeMutator) Type(v string) *SecuritySchemeMutator
Type sets the Type field for object SecurityScheme.
type SecuritySchemeVisitor ¶
type SecuritySchemeVisitor interface {
VisitSecurityScheme(context.Context, SecurityScheme) error
}
SecuritySchemeVisitor is an interface for objects that knows how to process SecurityScheme elements while traversing the OpenAPI structure
type ServerBuilder ¶
type ServerBuilder struct {
// contains filtered or unexported fields
}
ServerBuilder is used to build an instance of Server. The user must call `Build()` after providing all the necessary information to build an instance of Server
func NewServer ¶
func NewServer(url string) *ServerBuilder
NewServer creates a new builder object for Server
func (*ServerBuilder) Build ¶
func (b *ServerBuilder) Build(options ...Option) (Server, error)
Build finalizes the building process for Server and returns the result
func (*ServerBuilder) Description ¶
func (b *ServerBuilder) Description(v string) *ServerBuilder
Description sets the Description field for object Server.
func (*ServerBuilder) MustBuild ¶
func (b *ServerBuilder) MustBuild(options ...Option) Server
MustBuild is a convenience function for those time when you know that the result of the builder must be successful
func (*ServerBuilder) Reference ¶
func (b *ServerBuilder) Reference(v string) *ServerBuilder
Reference sets the $ref (reference) field for object Server.
func (*ServerBuilder) Variables ¶
func (b *ServerBuilder) Variables(v map[string]ServerVariable) *ServerBuilder
Variables sets the Variables field for object Server.
type ServerList ¶
type ServerList []Server
func (*ServerList) Clear ¶
func (v *ServerList) Clear() error
func (*ServerList) UnmarshalJSON ¶
func (v *ServerList) UnmarshalJSON(data []byte) error
func (*ServerList) Validate ¶
func (v *ServerList) Validate(recurse bool) error
Validate checks for the values for correctness. If `recurse` is specified, child elements are also validated
type ServerListIterator ¶
type ServerListIterator struct {
// contains filtered or unexported fields
}
func (*ServerListIterator) Item ¶
func (iter *ServerListIterator) Item() Server
Item returns the next item in this iterator. Make sure to call Next() before hand to check if the iterator has more items
type ServerMutator ¶
type ServerMutator struct {
// contains filtered or unexported fields
}
ServerMutator is used to build an instance of Server. The user must call `Do()` after providing all the necessary information to the new instance of Server with new values
func MutateServer ¶
func MutateServer(v Server) *ServerMutator
MutateServer creates a new mutator object for Server
func (*ServerMutator) ClearVariables ¶
func (b *ServerMutator) ClearVariables() *ServerMutator
func (*ServerMutator) Description ¶
func (b *ServerMutator) Description(v string) *ServerMutator
Description sets the Description field for object Server.
func (*ServerMutator) Do ¶
func (b *ServerMutator) Do() error
Do finalizes the matuation process for Server and returns the result
func (*ServerMutator) URL ¶
func (b *ServerMutator) URL(v string) *ServerMutator
URL sets the URL field for object Server.
func (*ServerMutator) Variable ¶
func (b *ServerMutator) Variable(key ServerVariableMapKey, value ServerVariable) *ServerMutator
type ServerVariable ¶
type ServerVariable interface { Name() string Enum() *StringListIterator Default() string Description() string MarshalJSON() ([]byte, error) Clone() ServerVariable Validator // contains filtered or unexported methods }
type ServerVariableBuilder ¶
type ServerVariableBuilder struct {
// contains filtered or unexported fields
}
ServerVariableBuilder is used to build an instance of ServerVariable. The user must call `Build()` after providing all the necessary information to build an instance of ServerVariable
func NewServerVariable ¶
func NewServerVariable(defaultValue string) *ServerVariableBuilder
NewServerVariable creates a new builder object for ServerVariable
func (*ServerVariableBuilder) Build ¶
func (b *ServerVariableBuilder) Build(options ...Option) (ServerVariable, error)
Build finalizes the building process for ServerVariable and returns the result
func (*ServerVariableBuilder) Description ¶
func (b *ServerVariableBuilder) Description(v string) *ServerVariableBuilder
Description sets the Description field for object ServerVariable.
func (*ServerVariableBuilder) Enum ¶
func (b *ServerVariableBuilder) Enum(v []string) *ServerVariableBuilder
Enum sets the Enum field for object ServerVariable.
func (*ServerVariableBuilder) MustBuild ¶
func (b *ServerVariableBuilder) MustBuild(options ...Option) ServerVariable
MustBuild is a convenience function for those time when you know that the result of the builder must be successful
func (*ServerVariableBuilder) Reference ¶
func (b *ServerVariableBuilder) Reference(v string) *ServerVariableBuilder
Reference sets the $ref (reference) field for object ServerVariable.
type ServerVariableMap ¶
type ServerVariableMap map[ServerVariableMapKey]ServerVariable
func (*ServerVariableMap) Clear ¶
func (v *ServerVariableMap) Clear() error
func (ServerVariableMap) QueryJSON ¶
func (v ServerVariableMap) QueryJSON(path string) (ret interface{}, ok bool)
func (*ServerVariableMap) UnmarshalJSON ¶
func (v *ServerVariableMap) UnmarshalJSON(data []byte) error
func (*ServerVariableMap) Validate ¶
func (v *ServerVariableMap) Validate(recurse bool) error
Validate checks the correctness of values in ServerVariableMap
type ServerVariableMapIterator ¶
type ServerVariableMapIterator struct {
// contains filtered or unexported fields
}
func (*ServerVariableMapIterator) Item ¶
func (iter *ServerVariableMapIterator) Item() (string, ServerVariable)
Item returns the next item in this iterator. Make sure to call Next() before hand to check if the iterator has more items
type ServerVariableMapKey ¶
type ServerVariableMapKey = string
type ServerVariableMutator ¶
type ServerVariableMutator struct {
// contains filtered or unexported fields
}
ServerVariableMutator is used to build an instance of ServerVariable. The user must call `Do()` after providing all the necessary information to the new instance of ServerVariable with new values
func MutateServerVariable ¶
func MutateServerVariable(v ServerVariable) *ServerVariableMutator
MutateServerVariable creates a new mutator object for ServerVariable
func (*ServerVariableMutator) ClearEnum ¶
func (b *ServerVariableMutator) ClearEnum() *ServerVariableMutator
func (*ServerVariableMutator) Default ¶
func (b *ServerVariableMutator) Default(v string) *ServerVariableMutator
Default sets the Default field for object ServerVariable.
func (*ServerVariableMutator) Description ¶
func (b *ServerVariableMutator) Description(v string) *ServerVariableMutator
Description sets the Description field for object ServerVariable.
func (*ServerVariableMutator) Do ¶
func (b *ServerVariableMutator) Do() error
Do finalizes the matuation process for ServerVariable and returns the result
func (*ServerVariableMutator) Enum ¶
func (b *ServerVariableMutator) Enum(value string) *ServerVariableMutator
func (*ServerVariableMutator) Name ¶
func (b *ServerVariableMutator) Name(v string) *ServerVariableMutator
Name sets the Name field for object ServerVariable.
type ServerVariableVisitor ¶
type ServerVariableVisitor interface {
VisitServerVariable(context.Context, ServerVariable) error
}
ServerVariableVisitor is an interface for objects that knows how to process ServerVariable elements while traversing the OpenAPI structure
type ServerVisitor ¶
ServerVisitor is an interface for objects that knows how to process Server elements while traversing the OpenAPI structure
type SliceQueryJSON ¶
type SliceQueryJSON []interface{}
type StringList ¶
type StringList []string
func (*StringList) Clear ¶
func (v *StringList) Clear() error
func (*StringList) Validate ¶
func (v *StringList) Validate(recurse bool) error
Validate checks for the values for correctness. If `recurse` is specified, child elements are also validated
type StringListIterator ¶
type StringListIterator struct {
// contains filtered or unexported fields
}
func (*StringListIterator) Item ¶
func (iter *StringListIterator) Item() string
Item returns the next item in this iterator. Make sure to call Next() before hand to check if the iterator has more items
type StringListListIterator ¶
type StringListListIterator struct {
// contains filtered or unexported fields
}
func (*StringListListIterator) Item ¶
func (iter *StringListListIterator) Item() []string
Item returns the next item in this iterator. Make sure to call Next() before hand to check if the iterator has more items
type StringListMap ¶
type StringListMap map[StringListMapKey][]string
func (*StringListMap) Clear ¶
func (v *StringListMap) Clear() error
func (StringListMap) QueryJSON ¶
func (v StringListMap) QueryJSON(path string) (ret interface{}, ok bool)
func (*StringListMap) Validate ¶
func (v *StringListMap) Validate(recurse bool) error
Validate checks the correctness of values in StringListMap
type StringListMapIterator ¶
type StringListMapIterator struct {
// contains filtered or unexported fields
}
func (*StringListMapIterator) Item ¶
func (iter *StringListMapIterator) Item() (string, []string)
Item returns the next item in this iterator. Make sure to call Next() before hand to check if the iterator has more items
type StringListMapKey ¶
type StringListMapKey = string
type StringMap ¶
type StringMap map[StringMapKey]string
type StringMapIterator ¶
type StringMapIterator struct {
// contains filtered or unexported fields
}
func (*StringMapIterator) Item ¶
func (iter *StringMapIterator) Item() (string, string)
Item returns the next item in this iterator. Make sure to call Next() before hand to check if the iterator has more items
type StringMapKey ¶
type StringMapKey = string
type TagBuilder ¶
type TagBuilder struct {
// contains filtered or unexported fields
}
TagBuilder is used to build an instance of Tag. The user must call `Build()` after providing all the necessary information to build an instance of Tag
func (*TagBuilder) Build ¶
func (b *TagBuilder) Build(options ...Option) (Tag, error)
Build finalizes the building process for Tag and returns the result
func (*TagBuilder) Description ¶
func (b *TagBuilder) Description(v string) *TagBuilder
Description sets the Description field for object Tag.
func (*TagBuilder) ExternalDocs ¶
func (b *TagBuilder) ExternalDocs(v ExternalDocumentation) *TagBuilder
ExternalDocs sets the ExternalDocs field for object Tag.
func (*TagBuilder) MustBuild ¶
func (b *TagBuilder) MustBuild(options ...Option) Tag
MustBuild is a convenience function for those time when you know that the result of the builder must be successful
func (*TagBuilder) Reference ¶
func (b *TagBuilder) Reference(v string) *TagBuilder
Reference sets the $ref (reference) field for object Tag.
type TagListIterator ¶
type TagListIterator struct {
// contains filtered or unexported fields
}
func (*TagListIterator) Item ¶
func (iter *TagListIterator) Item() Tag
Item returns the next item in this iterator. Make sure to call Next() before hand to check if the iterator has more items
type TagMutator ¶
type TagMutator struct {
// contains filtered or unexported fields
}
TagMutator is used to build an instance of Tag. The user must call `Do()` after providing all the necessary information to the new instance of Tag with new values
func (*TagMutator) Description ¶
func (b *TagMutator) Description(v string) *TagMutator
Description sets the Description field for object Tag.
func (*TagMutator) Do ¶
func (b *TagMutator) Do() error
Do finalizes the matuation process for Tag and returns the result
func (*TagMutator) ExternalDocs ¶
func (b *TagMutator) ExternalDocs(v ExternalDocumentation) *TagMutator
ExternalDocs sets the ExternalDocs field for object Tag.
func (*TagMutator) Name ¶
func (b *TagMutator) Name(v string) *TagMutator
Name sets the Name field for object Tag.
type TagVisitor ¶
TagVisitor is an interface for objects that knows how to process Tag elements while traversing the OpenAPI structure
Source Files ¶
- callback.go
- callback_accessors_gen.go
- callback_builder_gen.go
- callback_json_gen.go
- callback_map_gen.go
- callback_mutator_gen.go
- callback_visitor_gen.go
- cloner_gen.go
- components_accessors_gen.go
- components_builder.go
- components_builder_gen.go
- components_json_gen.go
- components_mutator_gen.go
- components_visitor_gen.go
- contact_accessors_gen.go
- contact_builder_gen.go
- contact_json_gen.go
- contact_mutator_gen.go
- contact_visitor_gen.go
- discriminator_accessors_gen.go
- discriminator_builder_gen.go
- discriminator_json_gen.go
- discriminator_mutator_gen.go
- discriminator_visitor_gen.go
- encoding.go
- encoding_accessors_gen.go
- encoding_builder_gen.go
- encoding_json_gen.go
- encoding_map_gen.go
- encoding_mutator_gen.go
- encoding_visitor_gen.go
- entity.go
- example.go
- example_accessors_gen.go
- example_builder_gen.go
- example_json_gen.go
- example_map_gen.go
- example_mutator_gen.go
- example_visitor_gen.go
- external_documentation_accessors_gen.go
- external_documentation_builder_gen.go
- external_documentation_json_gen.go
- external_documentation_mutator_gen.go
- external_documentation_visitor_gen.go
- header.go
- header_accessors_gen.go
- header_builder_gen.go
- header_json_gen.go
- header_map_gen.go
- header_mutator_gen.go
- header_visitor_gen.go
- info_accessors_gen.go
- info_builder_gen.go
- info_json_gen.go
- info_mutator_gen.go
- info_visitor_gen.go
- interface.go
- interface_gen.go
- interface_list_gen.go
- interface_map_gen.go
- iterator_gen.go
- license_accessors_gen.go
- license_builder_gen.go
- license_json_gen.go
- license_mutator_gen.go
- license_visitor_gen.go
- link.go
- link_accessors_gen.go
- link_builder_gen.go
- link_json_gen.go
- link_map_gen.go
- link_mutator_gen.go
- link_visitor_gen.go
- media_type.go
- media_type_accessors_gen.go
- media_type_builder_gen.go
- media_type_json_gen.go
- media_type_map_gen.go
- media_type_mutator_gen.go
- media_type_visitor_gen.go
- oauth_flow_accessors_gen.go
- oauth_flow_builder_gen.go
- oauth_flow_json_gen.go
- oauth_flow_mutator_gen.go
- oauth_flow_visitor_gen.go
- oauth_flows_accessors_gen.go
- oauth_flows_builder_gen.go
- oauth_flows_json_gen.go
- oauth_flows_mutator_gen.go
- oauth_flows_visitor_gen.go
- openapi.go
- openapi_accessors_gen.go
- openapi_builder_gen.go
- openapi_json_gen.go
- openapi_mutator_gen.go
- openapi_visitor_gen.go
- operation.go
- operation_accessors_gen.go
- operation_builder.go
- operation_builder_gen.go
- operation_json_gen.go
- operation_mutator_gen.go
- operation_visitor_gen.go
- options.go
- parameter.go
- parameter_accessors_gen.go
- parameter_builder_gen.go
- parameter_json_gen.go
- parameter_list_gen.go
- parameter_map_gen.go
- parameter_mutator_gen.go
- parameter_visitor_gen.go
- path_item.go
- path_item_accessors_gen.go
- path_item_builder.go
- path_item_builder_gen.go
- path_item_json_gen.go
- path_item_map_gen.go
- path_item_mutator.go
- path_item_mutator_gen.go
- path_item_visitor_gen.go
- paths.go
- paths_accessors_gen.go
- paths_builder.go
- paths_builder_gen.go
- paths_json_gen.go
- paths_mutator_gen.go
- paths_visitor_gen.go
- request_body.go
- request_body_accessors_gen.go
- request_body_builder.go
- request_body_builder_gen.go
- request_body_json_gen.go
- request_body_map_gen.go
- request_body_mutator_gen.go
- request_body_visitor_gen.go
- resolver.go
- response.go
- response_accessors_gen.go
- response_builder.go
- response_builder_gen.go
- response_json_gen.go
- response_map_gen.go
- response_mutator_gen.go
- response_visitor_gen.go
- responses.go
- responses_accessors_gen.go
- responses_builder.go
- responses_builder_gen.go
- responses_json_gen.go
- responses_mutator_gen.go
- responses_visitor_gen.go
- schema.go
- schema_accessors_gen.go
- schema_builder.go
- schema_builder_gen.go
- schema_json_gen.go
- schema_list_gen.go
- schema_map_gen.go
- schema_mutator_gen.go
- schema_visitor_gen.go
- scope_map_gen.go
- security_requirement_accessors_gen.go
- security_requirement_builder_gen.go
- security_requirement_json_gen.go
- security_requirement_list_gen.go
- security_requirement_mutator_gen.go
- security_requirement_visitor_gen.go
- security_scheme_accessors_gen.go
- security_scheme_builder_gen.go
- security_scheme_json_gen.go
- security_scheme_map_gen.go
- security_scheme_mutator_gen.go
- security_scheme_visitor_gen.go
- server_accessors_gen.go
- server_builder_gen.go
- server_json_gen.go
- server_list_gen.go
- server_mutator_gen.go
- server_variable.go
- server_variable_accessors_gen.go
- server_variable_builder_gen.go
- server_variable_json_gen.go
- server_variable_map_gen.go
- server_variable_mutator_gen.go
- server_variable_visitor_gen.go
- server_visitor_gen.go
- string_list_gen.go
- string_list_map_gen.go
- string_map_gen.go
- tag_accessors_gen.go
- tag_builder_gen.go
- tag_json_gen.go
- tag_list_gen.go
- tag_mutator_gen.go
- tag_visitor_gen.go
- validator.go
- visitor_gen.go