Documentation
¶
Index ¶
- Variables
- func FromRouter(r route.Router, options ...BuildOptionFunc) *oas.OpenAPI
- func RegisterPkgNamingPrefix(pkgPath string, prefix string)
- type BuildFunc
- type BuildOption
- type BuildOptionFunc
- type PkgNamingPrefix
- type ResponseContentSpecified
- type ResponseContentTypeSpecified
- type ResponseErrorsSpecified
- type ResponseStatusCodeSpecified
Constants ¶
This section is empty.
Variables ¶
View Source
var DefaultBuildFunc = func(r route.Router, fns ...BuildOptionFunc) *oas.OpenAPI { if v, ok := cached.Load(r); ok { return v.(*oas.OpenAPI) } o := FromRouter(r, fns...) cached.Store(r, o) return o }
Functions ¶
func FromRouter ¶
func FromRouter(r route.Router, options ...BuildOptionFunc) *oas.OpenAPI
func RegisterPkgNamingPrefix ¶
Types ¶
type BuildOption ¶
type BuildOption struct {
// contains filtered or unexported fields
}
type BuildOptionFunc ¶
type BuildOptionFunc func(o *BuildOption)
func Naming ¶
func Naming(naming func(t string) string) BuildOptionFunc
type PkgNamingPrefix ¶
func (PkgNamingPrefix) Register ¶
func (p PkgNamingPrefix) Register(pkgpath string, prefix string)
type ResponseContentSpecified ¶
type ResponseContentSpecified interface {
ResponseContent() any
}
type ResponseContentTypeSpecified ¶
type ResponseContentTypeSpecified interface {
ResponseContentType() string
}
type ResponseErrorsSpecified ¶
type ResponseErrorsSpecified interface {
ResponseErrors() []error
}
type ResponseStatusCodeSpecified ¶
type ResponseStatusCodeSpecified interface {
ResponseStatusCode() int
}
Click to show internal directories.
Click to hide internal directories.