gpaparser

package
v1.0.2 Latest Latest
Warning

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

Go to latest
Published: Oct 8, 2019 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CRUD

type CRUD int8
const (
	Insert CRUD
	Select
	Update
	Delete
)

type GoInterface

type GoInterface struct {
	StructName string
	CommentMap ast.CommentMap
	Methods    []*GoMethod
}

type GoMethod

type GoMethod struct {
	Name     string
	Params   []*ast.Field
	Results  []*ast.Field
	Position token.Pos

	DML          CRUD
	DMLStatement string
}

type Parser

type Parser struct {
	FileSet *token.FileSet
	File    *ast.File

	Source  string
	Package string
	Imports map[string]string // path -> alias

	IFace     *GoInterface
	IFaceFrom token.Pos
	IFaceTo   token.Pos
}

func (*Parser) Parse

func (g *Parser) Parse()

func (*Parser) ParseStructFromImports

func (g *Parser) ParseStructFromImports(packageName, structName string) *om.OrderedMap

ParseStructFromImports return tag => Field

Jump to

Keyboard shortcuts

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