generator

package
v0.0.4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 18, 2026 License: MIT Imports: 18 Imported by: 0

Documentation

Index

Constants

View Source
const (

	// DefaultOpenAPIVersion and DefaultErrorSchemaName are exported because the
	// plugin uses them as flag defaults. Declaring them twice let the flag
	// default and the fallback drift apart.
	DefaultOpenAPIVersion  = "3.2.0"
	DefaultErrorSchemaName = "ForgeProblem"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Configuration

type Configuration struct {
	OpenAPIVersion   *string
	Version          *string
	Title            *string
	Description      *string
	Naming           *string
	FQSchemaNaming   *bool
	CircularDepth    *int
	DefaultResponse  *bool
	ErrorSchemaName  *string
	OutputMode       *string
	ValidationReason *bool
}

type OpenAPIv3Generator

type OpenAPIv3Generator struct {
	// contains filtered or unexported fields
}

OpenAPIv3Generator holds internal state needed to generate an OpenAPIv3 document for a transcoded Protocol Buffer service.

func NewOpenAPIv3Generator

func NewOpenAPIv3Generator(plugin *protogen.Plugin, conf Configuration, inputFiles []*protogen.File) *OpenAPIv3Generator

NewOpenAPIv3Generator creates a new generator for a protoc plugin invocation.

func (*OpenAPIv3Generator) Run

func (g *OpenAPIv3Generator) Run(outputFile *protogen.GeneratedFile) error

Run runs the generator.

type OpenAPIv3Reflector

type OpenAPIv3Reflector struct {
	// contains filtered or unexported fields
}

func NewOpenAPIv3Reflector

func NewOpenAPIv3Reflector(conf Configuration) *OpenAPIv3Reflector

NewOpenAPIv3Reflector creates a new reflector.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL