gormmomzhcn

package
v0.0.26 Latest Latest
Warning

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

Go to latest
Published: Feb 10, 2025 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type T批量编码器

type T批量编码器 struct {
	// contains filtered or unexported fields
}

func NewT批量编码器

func NewT批量编码器(v表结构s []*T表结构, v配置项 *T配置项) *T批量编码器

func (*T批量编码器) ConfigBatch

func (c *T批量编码器) ConfigBatch() *gormmom.ConfigBatch

func (*T批量编码器) Gen替换源码

func (c *T批量编码器) Gen替换源码()

type T编码器

type T编码器 struct {
	// contains filtered or unexported fields
}

func NewT编码器

func NewT编码器(v表结构 *T表结构, v配置项 *T配置项) *T编码器

func (*T编码器) Config

func (cfg *T编码器) Config() *gormmom.Config

func (*T编码器) Gen替换源码

func (cfg *T编码器) Gen替换源码()

func (*T编码器) Get新建代码

func (cfg *T编码器) Get新建代码() []byte

type T表结构

type T表结构 struct {
	// contains filtered or unexported fields
}

func NewT表结构

func NewT表结构(sourcePath string, structName string, sch *schema.Schema) *T表结构

NewT表结构 创建参数信息

func NewT表结构V2

func NewT表结构V2[T any](sourcePath string) *T表结构

NewT表结构V2 使用泛型创建参数信息。T 只能传类型名称而非带指针的类型名

func NewT表结构V3

func NewT表结构V3(sourcePath string, object interface{}) *T表结构

NewT表结构V3 使用对象创建参数信息 object 传对象或者对象指针都行

func NewT表结构s

func NewT表结构s(root string, objects []interface{}) []*T表结构

func (*T表结构) SchemaCache

func (a *T表结构) SchemaCache() *gormmom.SchemaCache

func (*T表结构) Validate

func (a *T表结构) Validate()

type T配置项

type T配置项 struct {
	// contains filtered or unexported fields
}

func NewT配置项

func NewT配置项() *T配置项

func (*T配置项) Options

func (opt *T配置项) Options() *gormmom.Options

func (*T配置项) With列名命名策略

func (opt *T配置项) With列名命名策略(pattern gormmomname.ColumnNamePattern, naming gormmomname.Naming) *T配置项

func (*T配置项) With列名模式字段

func (opt *T配置项) With列名模式字段(columnNamePatternFieldName string) *T配置项

func (*T配置项) With命名总标签名

func (opt *T配置项) With命名总标签名(namingTagName string) *T配置项

func (*T配置项) With索引命名策略

func (opt *T配置项) With索引命名策略(pattern gormidxname.IndexNamePattern, naming gormidxname.Naming) *T配置项

func (*T配置项) With跳过基本命名

func (opt *T配置项) With跳过基本命名(skipBasicNaming bool) *T配置项

func (*T配置项) With重命名索引名

func (opt *T配置项) With重命名索引名(renewIndexName bool) *T配置项

func (*T配置项) With默认列名模式

func (opt *T配置项) With默认列名模式(pattern gormmomname.ColumnNamePattern) *T配置项

Jump to

Keyboard shortcuts

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