Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AstFile ¶
path and file path may different if user give folder instead of file path
func ParseGoFiles ¶
type GoAstHelper ¶
type GoAstHelper[Resp any] struct { Path []string // 2 type, first is point to file directly, for example a/b/c/d.go, second is point to folder, only need to show last folder, for example a/b/c Action func(path string, n ast.Node) (resp *Resp, next bool) // true mean skip }
func GetNewGoAstHelper ¶
func (*GoAstHelper[Resp]) Run ¶
func (a *GoAstHelper[Resp]) Run() (resps []Resp, err error)
func (*GoAstHelper[Resp]) RunAndReturnByFilePath ¶
func (a *GoAstHelper[Resp]) RunAndReturnByFilePath() (resps map[string]Resp, err error)
func (*GoAstHelper[Resp]) RunAndReturnByPath ¶
func (a *GoAstHelper[Resp]) RunAndReturnByPath() (resps map[string][]Resp, err error)
Click to show internal directories.
Click to hide internal directories.