Documentation ¶
Index ¶
- func CommonValues(typeId int) string
- func FmtPackage(lang string, pkg string) string
- func GoTypes(typeId int) string
- func GoValues(typeId int) string
- func KotlinTypes(typeId int) string
- func KotlinValues(typeId int) string
- func PkgStyleLikeGo(pkg string) string
- func PkgStyleLikeJava(pkg string) string
- func ProtobufTypes(typeId int) string
- func PyTypes(typeId int) string
- func PythonValues(typeId int) string
- func ThriftTypes(typeId int) string
- func TsTypes(typeId int) string
- type CommonLang
- type Java
- type Lang
- type Protobuf
- type Python
- type Thrift
- type Typescript
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CommonValues ¶
func FmtPackage ¶
func KotlinTypes ¶
func KotlinValues ¶
func PkgStyleLikeGo ¶
PkgStyleLikeGo "go", "rust", "php", "python"
func PkgStyleLikeJava ¶
PkgStyleLikeJava case "java", "kotlin", "csharp", "py", "thrift", "protobuf":
func ProtobufTypes ¶
func PythonValues ¶
func ThriftTypes ¶
Types ¶
type CommonLang ¶
type CommonLang struct { }
func (CommonLang) DefaultValue ¶
func (c CommonLang) DefaultValue(typeId int) string
func (CommonLang) ParseType ¶
func (c CommonLang) ParseType(typeId int) string
func (CommonLang) PkgName ¶
func (c CommonLang) PkgName(pkg string) string
func (CommonLang) PkgPath ¶
func (c CommonLang) PkgPath(pkg string) string
func (CommonLang) SqlMapType ¶
func (c CommonLang) SqlMapType(typeId int, _ int) string
type Lang ¶
type Lang interface { // ParseType parse to lang type ParseType(typeId int) string // SqlMapType the type of orm mapping SqlMapType(typeId int, len int) string // DefaultValue get default value of lang DefaultValue(typeId int) string // PkgPath parse package path PkgPath(pkg string) string // PkgName get package name PkgName(pkg string) string }
type Typescript ¶
type Typescript struct { }
func (Typescript) DefaultValue ¶
func (t Typescript) DefaultValue(typeId int) string
func (Typescript) ParseType ¶
func (t Typescript) ParseType(typeId int) string
func (Typescript) PkgName ¶
func (t Typescript) PkgName(pkg string) string
func (Typescript) PkgPath ¶
func (t Typescript) PkgPath(pkg string) string
func (Typescript) SqlMapType ¶
func (t Typescript) SqlMapType(typeId int, len int) string
Source Files ¶
Click to show internal directories.
Click to hide internal directories.