model

package
v0.1.4 Latest Latest
Warning

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

Go to latest
Published: Jun 22, 2023 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Field

type Field struct {
	*Validatable
	Name     string
	FType    string
	Tag      *Tag // TODO prepare a tag type
	TypeNode ast.Node
}

func (Field) String

func (f Field) String() string

type Range

type Range struct {
	Left, Right int
}

type Tag

type Tag struct {
	Ignore   bool
	Range    Range
	FuncName string
}

func (*Tag) IsIgnore

func (t *Tag) IsIgnore() bool

func (*Tag) String

func (t *Tag) String() string

type TemplateData

type TemplateData struct {
	ValidatorName  string
	TargetTypeName string
	Snippets       []string
}

type Validatable

type Validatable struct {
	ValidatorName string
	Name          string
	Fields        []Field
}

Jump to

Keyboard shortcuts

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