sqlproto

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Jun 1, 2026 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RemoveTableCommentSuffix

func RemoveTableCommentSuffix(input string) string

func WriteServiceProto

func WriteServiceProto(
	outputPath string,
	serviceType string,
	strategy string,
	targetModuleName, sourceModuleName, moduleVersion string,
	tableName string,
	tableComment string,
	protoFields ProtoFieldArray,
	customPkg string,
) error

func WriteServicesProto

func WriteServicesProto(
	outputPath string,
	serviceType string,
	strategy string,
	targetModuleName, sourceModuleName, moduleVersion string,
	tables TableDataArray,
	customPackages map[string]string,
) error

Types

type ProtoField

type ProtoField generators.ProtoField

type ProtoFieldArray

type ProtoFieldArray []generators.ProtoField

type TableDataArray

type TableDataArray []*internal.TableData

func Convert

func Convert(
	ctx context.Context,
	dsn, outputPath *string,
	moduleName, sourceModuleName, moduleVersion *string,
	serviceType *string,
	strategy string,
	customPackages map[string]string,
	includeTables, excludeTables []string,
	exportProto bool,
) (TableDataArray, error)

Convert converts the database schema into a protocol buffer definition.

Directories

Path Synopsis
mux

Jump to

Keyboard shortcuts

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