Documentation
¶
Index ¶
- Variables
- func Gen(path string, afterPath string, packet string, interceptors []*Interceptor) map[string]*ast.ImportSpec
- func GetGenerateImportPackage(workdir string) []string
- func GetProjectPackageName(projectDir string) string
- func GetTyperStructIdent(typer ast.Expr) (*ast.Ident, bool)
- func ParseProjectMod(projectDir string) *modfile.File
- func WalkGoFile(basePackage string, callback func(path string, info os.FileInfo) error) error
- type Interceptor
- type InterceptorParam
- type InterceptorResult
Constants ¶
This section is empty.
Variables ¶
View Source
var DocPrefix = "//inject:"
Functions ¶
func Gen ¶
func Gen(path string, afterPath string, packet string, interceptors []*Interceptor) map[string]*ast.ImportSpec
func GetProjectPackageName ¶
func ParseProjectMod ¶
Types ¶
type Interceptor ¶
type Interceptor struct { InterceptorName string StructType string StructTypePoint bool StructName string MethodName string MethodResults []*InterceptorResult Params []*InterceptorParam Imports []*ast.ImportSpec Body *ast.BlockStmt Results *ast.FieldList Mods []module.Version }
func GenInterceptor ¶
func GenInterceptor(node *ast.File) []*Interceptor
type InterceptorParam ¶
type InterceptorResult ¶
Click to show internal directories.
Click to hide internal directories.