plugin

package
v0.0.0-...-12f548e Latest Latest
Warning

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

Go to latest
Published: Mar 3, 2024 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GenerateFileForType

func GenerateFileForType(
	typeToGenerate Meta,
	template *template.Template,
) ([]byte, error)

func PostgresTableNameForMessage

func PostgresTableNameForMessage(message *protogen.Message) string

func PostgresTypeFromProtobufType

func PostgresTypeFromProtobufType(pbtype *protogen.Field) (string, error)

Types

type Fields

type Fields struct {
	Name               string
	GoType             string
	MainTypeLowercased string
}

type Meta

type Meta struct {
	TableName           string
	MainTypeCapitalized string
	MainTypeLowercased  string
	Types               []Fields
}

func MetaFromProtobufType

func MetaFromProtobufType(message *protogen.Message) (Meta, error)

Jump to

Keyboard shortcuts

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