Documentation
¶
Index ¶
- func GoogleTimestamp(f MessageField) (*openapi3.SchemaRef, error)
- func NavigaSaasServer(application string, infomaker bool) *openapi3.Server
- func ToOpenAPI(application string, version string, d Doc, _ *protogen.Plugin, ...) (openapi3.T, error)
- type CustomFieldFunc
- type Doc
- type Enum
- type EnumValue
- type File
- type Message
- type MessageField
- type Method
- type SchemaGenerator
- type Service
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GoogleTimestamp ¶
func GoogleTimestamp(f MessageField) (*openapi3.SchemaRef, error)
Types ¶
type CustomFieldFunc ¶
type CustomFieldFunc func(f MessageField) (*openapi3.SchemaRef, error)
type Message ¶
type Message struct {
Name string `json:"name"`
FullName string `json:"fullName"`
Description string `json:"description"`
Fields []MessageField `json:"fields"`
}
type MessageField ¶
type MessageField struct {
Name string `json:"name"`
Description string `json:"description"`
Type string `json:"type"`
FullType string `json:"fullType"`
IsRepeated bool `json:"isRepeated,omitempty"`
IsMap bool `json:"isMap"`
IsRequired bool `json:"isRequired"`
MapKey string `json:"mapKey,omitempty"`
MapValue string `json:"mapValue,omitempty"`
}
type SchemaGenerator ¶
type SchemaGenerator struct {
CustomFields map[string]CustomFieldFunc
// contains filtered or unexported fields
}
func NewSchemaGenerator ¶
func NewSchemaGenerator(doc Doc) *SchemaGenerator
func (*SchemaGenerator) EnumSchema ¶
func (sg *SchemaGenerator) EnumSchema(e Enum) (*openapi3.SchemaRef, error)
func (*SchemaGenerator) MessageSchema ¶
func (sg *SchemaGenerator) MessageSchema(typeName string) (*openapi3.SchemaRef, error)
Click to show internal directories.
Click to hide internal directories.