Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var MetadataContextInst = NewMetadataContext()
@Title 文件名称: metadata_context.go @Description 描述: 元数据--字典
@Author 作者: leijianming@163.com 时间(2024-01-31 22:38:21) @Update 作者: leijianming@163.com 时间(2024-01-31 22:38:21)
Functions ¶
This section is empty.
Types ¶
type MetadataContext ¶
type MetadataContext struct { DbType string `json:"db_type"` // contains filtered or unexported fields }
func NewMetadataContext ¶
func NewMetadataContext() *MetadataContext
func (*MetadataContext) FindEsType ¶
func (this *MetadataContext) FindEsType(fieldType string) (goType string)
func (*MetadataContext) FindGoType ¶
func (this *MetadataContext) FindGoType(fieldType string) (pbType string)
func (*MetadataContext) FindProtoType ¶
func (this *MetadataContext) FindProtoType(fieldType string) (goType string)
func (*MetadataContext) Mysql ¶
func (this *MetadataContext) Mysql() bool
type MetadataMysql ¶
type MetadataMysql struct { Db2GoMap map[string]string `json:"db2gomap"` /*创建集合 */ Db2ProtoMap map[string]string `json:"db2protomap"` /*创建集合 */ Db2EsMap map[string]string `json:"-"` }
原文链接:https://blog.csdn.net/PacosonSWJTU/article/details/127200021
func NewMetadataMysql ¶
func NewMetadataMysql() *MetadataMysql
func (*MetadataMysql) FindEsType ¶
func (this *MetadataMysql) FindEsType(fieldType string) (esType string)
func (*MetadataMysql) FindGoType ¶
func (this *MetadataMysql) FindGoType(fieldType string) (goType string)
func (*MetadataMysql) FindProtoType ¶
func (this *MetadataMysql) FindProtoType(fieldType string) (pbType string)
type MetadataPostgres ¶
type MetadataPostgres struct { DbType2GoMap map[string]string `json:"dbtype_2_gomap"` /*创建集合 */ DbType2ProtoMap map[string]string `json:"dbtype_2_protomap"` /*创建集合 */ Db2EsMap map[string]string `json:"db_2_esmap"` }
func NewMetadataPostgres ¶
func NewMetadataPostgres() *MetadataPostgres
func (*MetadataPostgres) FindEsType ¶
func (this *MetadataPostgres) FindEsType(fieldType string) (esType string)
func (*MetadataPostgres) FindGoType ¶
func (this *MetadataPostgres) FindGoType(fieldType string) (goType string)
func (*MetadataPostgres) FindProtoType ¶
func (this *MetadataPostgres) FindProtoType(fieldType string) (pbType string)
Click to show internal directories.
Click to hide internal directories.