Versions in this module Expand all Collapse all v0 v0.1.2 Jul 2, 2024 Changes in this version + func DescribeParameters(params openapi3.Parameters) ([]ParameterDefinition, []ParameterDefinition, error) + func Initialize() error + func RefTypeMapping() map[string]string + type CodegenService struct + Config Configuration + Swagger *openapi3.T + func NewCodegenService(swagger *openapi3.T, config Configuration) *CodegenService + func (s CodegenService) Generate() (string, error) + type Configuration struct + OutputOptions OutputOptions + PackageName string + UserTemplates UserTemplates + WorkingDirectory string + func (c Configuration) UpdateDefaultValues() Configuration + func (c Configuration) Validate() error + type ControllerData struct + ClassName string + ControllerParentClass string + Definitions []Definition + ServiceName string + ServiceParentClass string + type Definition struct + BodyParameters RequestBodyDefinition + ControllerName string + HttpMethod string + IsResfulCreate bool + IsResfulDestroy bool + IsResfulIndex bool + IsResfulShow bool + IsResfulUpdate bool + MethodName string + Parameters []ParameterDefinition + Path string + type GeneratedDir struct + ControllerDir string + PackageDir string + RoutesDir string + ServiceDir string + type OperationDefinition struct + BodyParams RequestBodyDefinition + HeaderParams []ParameterDefinition + Method string + OperationId string + Path string + PathParams []ParameterDefinition + QueryParams []ParameterDefinition + Tag string + func OperationDefinitions(swagger *openapi3.T) ([]OperationDefinition, error) + type OutputOptions struct + ControllerDirectory string + ControllerParentClass string + ControllerPrefix string + RegenerateService bool + RoutesDirectory string + ServiceDirectory string + ServiceParentClass string + ServicePrefix string + type ParameterDefinition struct + In string + ParamName string + Required bool + Schema Schema + Spec *openapi3.Parameter + type ParameterDefinitions []ParameterDefinition + type Property struct + Name string + Required bool + Schema Schema + type RequestBodyDefinition struct + Schema Schema + Spec *openapi3.Schema + func DescribeRequestBody(requestBody *openapi3.RequestBodyRef) (RequestBodyDefinition, error) + type Schema struct + ArrayItems *Schema + EnumValues []string + OAPISchema *openapi3.Schema + Properties []Property + RefType string + func DescribeSchemaRef(schemaRef *openapi3.Schema) (Schema, error) + type UserTemplates struct + Controller string + Routes string + Service string