MCPcopy
hub / github.com/zeromicro/go-zero / Node

Interface Node

tools/goctl/pkg/parser/api/ast/ast.go:13–26  ·  view source on GitHub ↗

Node represents a node in the AST.

Source from the content-addressed store, hash-verified

11
12// Node represents a node in the AST.
13type Node interface {
14 // Pos returns the position of the first character belonging to the node.
15 Pos() token.Position
16 // End returns the position of the first character immediately after the node.
17 End() token.Position
18 // Format returns the node's text after format.
19 Format(...string) string
20 // HasHeadCommentGroup returns true if the node has head comment group.
21 HasHeadCommentGroup() bool
22 // HasLeadingCommentGroup returns true if the node has leading comment group.
23 HasLeadingCommentGroup() bool
24 // CommentGroup returns the node's head comment group and leading comment group.
25 CommentGroup() (head, leading CommentGroup)
26}
27
28// Stmt represents a statement in the AST.
29type Stmt interface {

Callers 48

checkMethod · 0.65
checkNodeWithPrefixMethod · 0.65
convert2APIFunction · 0.65
checkServiceStmtMethod · 0.65
checkTypeExprContextMethod · 0.65
mergeAPIMethod · 0.65
astTypeToSpecMethod · 0.65
fillServiceMethod · 0.65
rewriteFileFunction · 0.65
replacePkgFunction · 0.65
EndMethod · 0.65
EndMethod · 0.65

Implementers 15

SyntaxStmttools/goctl/pkg/parser/api/ast/syntaxs
TokenNodetools/goctl/pkg/parser/api/ast/ast.go
CommentStmttools/goctl/pkg/parser/api/ast/comment
ImportLiteralStmttools/goctl/pkg/parser/api/ast/imports
ImportGroupStmttools/goctl/pkg/parser/api/ast/imports
TypeLiteralStmttools/goctl/pkg/parser/api/ast/typesta
TypeGroupStmttools/goctl/pkg/parser/api/ast/typesta
TypeExprtools/goctl/pkg/parser/api/ast/typesta
ElemExprtools/goctl/pkg/parser/api/ast/typesta
AnyDataTypetools/goctl/pkg/parser/api/ast/typesta
ArrayDataTypetools/goctl/pkg/parser/api/ast/typesta
BaseDataTypetools/goctl/pkg/parser/api/ast/typesta

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…