core

package
v1.0.2 Latest Latest
Warning

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

Go to latest
Published: May 28, 2022 License: MIT Imports: 16 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

View Source
const RegexPatternRange = `[01],[01],[01]`

Variables

View Source
var (
	Logger logx.ILogger

	Setting  *setting.Settings
	TitleCtx []*TitleContext
	DataCtx  []*DataContext
	ConstCtx []*ConstContext
	Excel    *excel.ExcelProxy
)
View Source
var (
	TitleLanguageTemps = make(map[string]*temps.TemplateProxy)
	ConstLanguageTemps = make(map[string]*temps.TemplateProxy)
)

Functions

func Execute

func Execute(setting *setting.Settings, titleCtx []*TitleContext, dataCtx []*DataContext, constCtx []*ConstContext)

func SetLogger

func SetLogger(logger logx.ILogger)

Types

type ConstContext

type ConstContext struct {
	// 使用的字段索引名称
	RangeName string
	// 使用的字段索引
	RangeType FieldRangeType
	// 使用的编程语言
	ProgramLanguage string
}

func (ConstContext) String

func (o ConstContext) String() string

type ConstItem

type ConstItem struct {
	Name   string
	Value  string
	Type   string
	Remark string
}

type DataContext

type DataContext struct {
	// 使用的字段索引名称
	RangeName string
	// 使用的字段索引
	RangeType FieldRangeType
	// 输出的文件类型
	DataFileFormat string
}

func (DataContext) String

func (o DataContext) String() string

type FieldRangeType

type FieldRangeType uint
const (
	FieldRangeNone FieldRangeType = iota
	FieldRangeClient
	FieldRangeServer
	FieldRangeDatabase
)

type ModeType

type ModeType uint
const (
	ModeNone ModeType = iota
	ModeTitle
	ModeData
	ModeConst
)

type TempConstProxy

type TempConstProxy struct {
	Sheet     *excel.ExcelSheet
	Excel     *excel.ExcelProxy
	ConstCtx  *ConstContext
	FileName  string
	ClassName string
	Language  string
	StartRow  int
	EndRow    int
}

常量表代理

func (*TempConstProxy) GetItem

func (o *TempConstProxy) GetItem(row int) (item ConstItem, err error)

func (*TempConstProxy) GetItems

func (o *TempConstProxy) GetItems() []ConstItem

func (*TempConstProxy) ValueAtAxis

func (o *TempConstProxy) ValueAtAxis(axis string) string

type TempDataProxy

type TempDataProxy struct {
	Sheet     *excel.ExcelSheet
	Excel     *excel.ExcelProxy
	TitleCtx  *TitleContext
	FileName  string
	ClassName string
	Index     []int
	Language  string
}

数据表代理

func (*TempDataProxy) GetFieldName

func (o *TempDataProxy) GetFieldName(index int) string

func (*TempDataProxy) GetTitleFileKey

func (o *TempDataProxy) GetTitleFileKey(index int, fileType string) string

func (*TempDataProxy) GetTitleLangDefine

func (o *TempDataProxy) GetTitleLangDefine(index int) setting.FieldOperate

func (*TempDataProxy) GetTitleLangKey

func (o *TempDataProxy) GetTitleLangKey(index int, langName string) string

func (*TempDataProxy) GetTitleName

func (o *TempDataProxy) GetTitleName(index int) string

func (*TempDataProxy) GetTitleRemark

func (o *TempDataProxy) GetTitleRemark(index int) string

func (*TempDataProxy) ValueAtAxis

func (o *TempDataProxy) ValueAtAxis(axis string) string

type TitleContext

type TitleContext struct {
	// 使用的字段索引名称
	RangeName string
	// 使用的字段索引
	RangeType FieldRangeType
	// 使用的编程语言
	ProgramLanguage string
}

func (TitleContext) String

func (o TitleContext) String() string

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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