formatters

package
v0.2.1 Latest Latest
Warning

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

Go to latest
Published: Jul 30, 2026 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BaseFormatter

type BaseFormatter interface {
	MaxLength() int

	PrefixName(prefix string, name string) string
	ScopeEntity(scope string, name string) string
	QuoteEntity(name string) string
	QuoteValue(value any) string
	TrimSpaces(query string) string
}

type MySQLFormatter

type MySQLFormatter struct{}

func (*MySQLFormatter) MaxLength

func (f *MySQLFormatter) MaxLength() int

func (*MySQLFormatter) PrefixName

func (f *MySQLFormatter) PrefixName(prefix string, name string) string

func (*MySQLFormatter) QuoteEntity

func (f *MySQLFormatter) QuoteEntity(name string) string

func (*MySQLFormatter) QuoteValue

func (f *MySQLFormatter) QuoteValue(value any) string

func (*MySQLFormatter) ScopeEntity

func (f *MySQLFormatter) ScopeEntity(scope string, name string) string

func (*MySQLFormatter) TrimSpaces

func (f *MySQLFormatter) TrimSpaces(query string) string

type PostgreSQLFormatter

type PostgreSQLFormatter struct{}

func (*PostgreSQLFormatter) MaxLength

func (f *PostgreSQLFormatter) MaxLength() int

func (*PostgreSQLFormatter) PrefixName

func (f *PostgreSQLFormatter) PrefixName(prefix string, name string) string

func (*PostgreSQLFormatter) QuoteEntity

func (f *PostgreSQLFormatter) QuoteEntity(name string) string

func (*PostgreSQLFormatter) QuoteValue

func (f *PostgreSQLFormatter) QuoteValue(value any) string

func (*PostgreSQLFormatter) ScopeEntity

func (f *PostgreSQLFormatter) ScopeEntity(scope string, name string) string

func (*PostgreSQLFormatter) TrimSpaces

func (f *PostgreSQLFormatter) TrimSpaces(query string) string

Jump to

Keyboard shortcuts

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