Documentation ¶
Index ¶
- func ConjureDefinitionsByPackage(root spec.ConjureDefinition) (map[string]spec.ConjureDefinition, error)
- func GetCustomConjureTypes(typeDefinitions []spec.TypeDefinition, conjurePkgToGoPk func(string) string) (types.CustomConjureTypes, error)
- func GetParamID(argDef spec.ArgumentDefinition) string
- func GetPossibleCookieAuth(authType spec.AuthType) (*spec.CookieAuthType, error)
- func GetPossibleHeaderAuth(authType spec.AuthType) (*spec.HeaderAuthType, error)
- func IsSpecificConjureType(rawType spec.Type, typeCheck TypeCheck) (bool, error)
- func NewConjureTypeProviderTyper(rawType spec.Type, info types.PkgInfo) (types.Typer, error)
- func ParseStringParam(argName spec.ArgumentName, argType spec.Type, stringExpr astgen.ASTExpr, ...) ([]astgen.ASTStmt, error)
- func TypeNameToTyperName(typeName spec.TypeName) string
- func VisitConjureDefinition(def spec.ConjureDefinition, visitor ConjureDefinitionVisitor) error
- type ArgumentDefinitionBodyParam
- type ArgumentDefinitionHeaderParam
- type ArgumentDefinitionPathParam
- type ArgumentDefinitionQueryParam
- type AuthTypeFilterer
- type ConjureDefinitionVisitor
- type ConjureTypeFilterVisitor
- func (c *ConjureTypeFilterVisitor) VisitAlias(aliasDefinition spec.AliasDefinition) error
- func (c *ConjureTypeFilterVisitor) VisitEnum(enumDefinition spec.EnumDefinition) error
- func (c *ConjureTypeFilterVisitor) VisitObject(objectDefinition spec.ObjectDefinition) error
- func (c *ConjureTypeFilterVisitor) VisitUnion(unionDefinition spec.UnionDefinition) error
- func (c *ConjureTypeFilterVisitor) VisitUnknown(typeName string) error
- type ConjureTypePackageCollector
- func (c *ConjureTypePackageCollector) VisitAlias(v spec.AliasDefinition) error
- func (c *ConjureTypePackageCollector) VisitEnum(v spec.EnumDefinition) error
- func (c *ConjureTypePackageCollector) VisitError(v spec.ErrorDefinition) error
- func (c *ConjureTypePackageCollector) VisitObject(v spec.ObjectDefinition) error
- func (c *ConjureTypePackageCollector) VisitService(v spec.ServiceDefinition) error
- func (c *ConjureTypePackageCollector) VisitUnion(v spec.UnionDefinition) error
- func (c *ConjureTypePackageCollector) VisitUnknown(typeName string) error
- type ConjureTypeProvider
- type CustomTypesVisitor
- func (c *CustomTypesVisitor) VisitAlias(aliasDefinition spec.AliasDefinition) error
- func (c *CustomTypesVisitor) VisitEnum(enumDefinition spec.EnumDefinition) error
- func (c *CustomTypesVisitor) VisitObject(objectDefinition spec.ObjectDefinition) error
- func (c *CustomTypesVisitor) VisitUnion(unionDefinition spec.UnionDefinition) error
- func (c *CustomTypesVisitor) VisitUnknown(typeName string) error
- type ParamIDVisitor
- func (p *ParamIDVisitor) VisitBody(v spec.BodyParameterType) error
- func (p *ParamIDVisitor) VisitHeader(v spec.HeaderParameterType) error
- func (p *ParamIDVisitor) VisitPath(v spec.PathParameterType) error
- func (p *ParamIDVisitor) VisitQuery(v spec.QueryParameterType) error
- func (p *ParamIDVisitor) VisitUnknown(typeName string) error
- type ParamTypeFilterer
- func (p *ParamTypeFilterer) VisitBody(bodyParameterType spec.BodyParameterType) error
- func (p *ParamTypeFilterer) VisitHeader(headerParameterType spec.HeaderParameterType) error
- func (p *ParamTypeFilterer) VisitPath(pathParameterType spec.PathParameterType) error
- func (p *ParamTypeFilterer) VisitQuery(queryParameterType spec.QueryParameterType) error
- func (p *ParamTypeFilterer) VisitUnknown(typeName string) error
- type TypeCheck
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ConjureDefinitionsByPackage ¶
func ConjureDefinitionsByPackage(root spec.ConjureDefinition) (map[string]spec.ConjureDefinition, error)
func GetCustomConjureTypes ¶
func GetCustomConjureTypes(typeDefinitions []spec.TypeDefinition, conjurePkgToGoPk func(string) string) (types.CustomConjureTypes, error)
func GetParamID ¶
func GetParamID(argDef spec.ArgumentDefinition) string
GetParamID returns the parameter ID for the provided argument definition. If the provided definition is a header or query parameter and its ParamId field is non-empty, it is returned; otherwise, the argName is returned.
func GetPossibleCookieAuth ¶
func GetPossibleCookieAuth(authType spec.AuthType) (*spec.CookieAuthType, error)
func GetPossibleHeaderAuth ¶
func GetPossibleHeaderAuth(authType spec.AuthType) (*spec.HeaderAuthType, error)
func IsSpecificConjureType ¶
func ParseStringParam ¶
func TypeNameToTyperName ¶
func VisitConjureDefinition ¶
func VisitConjureDefinition(def spec.ConjureDefinition, visitor ConjureDefinitionVisitor) error
Types ¶
type ArgumentDefinitionBodyParam ¶
type ArgumentDefinitionBodyParam struct { ArgumentDefinition spec.ArgumentDefinition BodyParameterType spec.BodyParameterType }
func GetBodyParams ¶
func GetBodyParams(argumentDefinitions []spec.ArgumentDefinition) ([]ArgumentDefinitionBodyParam, error)
type ArgumentDefinitionHeaderParam ¶
type ArgumentDefinitionHeaderParam struct { ArgumentDefinition spec.ArgumentDefinition HeaderParameterType spec.HeaderParameterType }
func GetHeaderParams ¶
func GetHeaderParams(argumentDefinitions []spec.ArgumentDefinition) ([]ArgumentDefinitionHeaderParam, error)
type ArgumentDefinitionPathParam ¶
type ArgumentDefinitionPathParam struct { ArgumentDefinition spec.ArgumentDefinition PathParameterType spec.PathParameterType }
func GetPathParams ¶
func GetPathParams(argumentDefinitions []spec.ArgumentDefinition) ([]ArgumentDefinitionPathParam, error)
type ArgumentDefinitionQueryParam ¶
type ArgumentDefinitionQueryParam struct { ArgumentDefinition spec.ArgumentDefinition QueryParameterType spec.QueryParameterType }
func GetQueryParams ¶
func GetQueryParams(argumentDefinitions []spec.ArgumentDefinition) ([]ArgumentDefinitionQueryParam, error)
type AuthTypeFilterer ¶
type AuthTypeFilterer struct {
// contains filtered or unexported fields
}
func (*AuthTypeFilterer) VisitCookie ¶
func (a *AuthTypeFilterer) VisitCookie(v spec.CookieAuthType) error
func (*AuthTypeFilterer) VisitHeader ¶
func (a *AuthTypeFilterer) VisitHeader(v spec.HeaderAuthType) error
func (*AuthTypeFilterer) VisitUnknown ¶
func (a *AuthTypeFilterer) VisitUnknown(typeName string) error
type ConjureDefinitionVisitor ¶
type ConjureDefinitionVisitor interface { spec.TypeDefinitionVisitor VisitError(v spec.ErrorDefinition) error VisitService(v spec.ServiceDefinition) error }
type ConjureTypeFilterVisitor ¶
type ConjureTypeFilterVisitor struct { AliasDefinitions []spec.AliasDefinition EnumDefinitions []spec.EnumDefinition ObjectDefinitions []spec.ObjectDefinition UnionDefinitions []spec.UnionDefinition }
func NewConjureTypeFilterVisitor ¶
func NewConjureTypeFilterVisitor() *ConjureTypeFilterVisitor
func (*ConjureTypeFilterVisitor) VisitAlias ¶
func (c *ConjureTypeFilterVisitor) VisitAlias(aliasDefinition spec.AliasDefinition) error
func (*ConjureTypeFilterVisitor) VisitEnum ¶
func (c *ConjureTypeFilterVisitor) VisitEnum(enumDefinition spec.EnumDefinition) error
func (*ConjureTypeFilterVisitor) VisitObject ¶
func (c *ConjureTypeFilterVisitor) VisitObject(objectDefinition spec.ObjectDefinition) error
func (*ConjureTypeFilterVisitor) VisitUnion ¶
func (c *ConjureTypeFilterVisitor) VisitUnion(unionDefinition spec.UnionDefinition) error
func (*ConjureTypeFilterVisitor) VisitUnknown ¶
func (c *ConjureTypeFilterVisitor) VisitUnknown(typeName string) error
type ConjureTypePackageCollector ¶
type ConjureTypePackageCollector struct {
// contains filtered or unexported fields
}
func (*ConjureTypePackageCollector) VisitAlias ¶
func (c *ConjureTypePackageCollector) VisitAlias(v spec.AliasDefinition) error
func (*ConjureTypePackageCollector) VisitEnum ¶
func (c *ConjureTypePackageCollector) VisitEnum(v spec.EnumDefinition) error
func (*ConjureTypePackageCollector) VisitError ¶
func (c *ConjureTypePackageCollector) VisitError(v spec.ErrorDefinition) error
func (*ConjureTypePackageCollector) VisitObject ¶
func (c *ConjureTypePackageCollector) VisitObject(v spec.ObjectDefinition) error
func (*ConjureTypePackageCollector) VisitService ¶
func (c *ConjureTypePackageCollector) VisitService(v spec.ServiceDefinition) error
func (*ConjureTypePackageCollector) VisitUnion ¶
func (c *ConjureTypePackageCollector) VisitUnion(v spec.UnionDefinition) error
func (*ConjureTypePackageCollector) VisitUnknown ¶
func (c *ConjureTypePackageCollector) VisitUnknown(typeName string) error
type ConjureTypeProvider ¶
type ConjureTypeProvider interface { ParseType(info types.PkgInfo) (types.Typer, error) CollectionInitializationIfNeeded(info types.PkgInfo) (*expression.CallExpression, error) IsSpecificType(typeCheck TypeCheck) bool }
func NewConjureTypeProvider ¶
func NewConjureTypeProvider(rawType spec.Type) (ConjureTypeProvider, error)
type CustomTypesVisitor ¶
type CustomTypesVisitor struct {
// contains filtered or unexported fields
}
func (*CustomTypesVisitor) VisitAlias ¶
func (c *CustomTypesVisitor) VisitAlias(aliasDefinition spec.AliasDefinition) error
func (*CustomTypesVisitor) VisitEnum ¶
func (c *CustomTypesVisitor) VisitEnum(enumDefinition spec.EnumDefinition) error
func (*CustomTypesVisitor) VisitObject ¶
func (c *CustomTypesVisitor) VisitObject(objectDefinition spec.ObjectDefinition) error
func (*CustomTypesVisitor) VisitUnion ¶
func (c *CustomTypesVisitor) VisitUnion(unionDefinition spec.UnionDefinition) error
func (*CustomTypesVisitor) VisitUnknown ¶
func (c *CustomTypesVisitor) VisitUnknown(typeName string) error
type ParamIDVisitor ¶
type ParamIDVisitor struct {
ParamID spec.ParameterId
}
func (*ParamIDVisitor) VisitBody ¶
func (p *ParamIDVisitor) VisitBody(v spec.BodyParameterType) error
func (*ParamIDVisitor) VisitHeader ¶
func (p *ParamIDVisitor) VisitHeader(v spec.HeaderParameterType) error
func (*ParamIDVisitor) VisitPath ¶
func (p *ParamIDVisitor) VisitPath(v spec.PathParameterType) error
func (*ParamIDVisitor) VisitQuery ¶
func (p *ParamIDVisitor) VisitQuery(v spec.QueryParameterType) error
func (*ParamIDVisitor) VisitUnknown ¶
func (p *ParamIDVisitor) VisitUnknown(typeName string) error
type ParamTypeFilterer ¶
type ParamTypeFilterer struct { CurrentArgumentDefinition spec.ArgumentDefinition BodyParameterTypes []ArgumentDefinitionBodyParam HeaderParameterTypes []ArgumentDefinitionHeaderParam PathParameterTypes []ArgumentDefinitionPathParam QueryParameterTypes []ArgumentDefinitionQueryParam }
func (*ParamTypeFilterer) VisitBody ¶
func (p *ParamTypeFilterer) VisitBody(bodyParameterType spec.BodyParameterType) error
func (*ParamTypeFilterer) VisitHeader ¶
func (p *ParamTypeFilterer) VisitHeader(headerParameterType spec.HeaderParameterType) error
func (*ParamTypeFilterer) VisitPath ¶
func (p *ParamTypeFilterer) VisitPath(pathParameterType spec.PathParameterType) error
func (*ParamTypeFilterer) VisitQuery ¶
func (p *ParamTypeFilterer) VisitQuery(queryParameterType spec.QueryParameterType) error
func (*ParamTypeFilterer) VisitUnknown ¶
func (p *ParamTypeFilterer) VisitUnknown(typeName string) error
Source Files ¶
- conjuretype_provider.go
- conjuretype_provider_visitor.go
- conjuretype_visit_external.go
- conjuretype_visit_list.go
- conjuretype_visit_map.go
- conjuretype_visit_optional.go
- conjuretype_visit_primitive.go
- conjuretype_visit_reference.go
- conjuretype_visit_set.go
- filter_auth_type.go
- filter_param_type.go
- visit_conjure_definition.go
- visit_custom_conjure_types.go
- visit_packages.go
- visit_param_id.go
- visit_string_param.go
- visit_type_definitions.go
Click to show internal directories.
Click to hide internal directories.