| 7 | ) |
| 8 | |
| 9 | type PluginGen struct { |
| 10 | Base |
| 11 | Type Type // 类型 |
| 12 | Path string // 文件路径 |
| 13 | ImportPath string // 导包路径 |
| 14 | RelativePath string // 相对路径 |
| 15 | StructName string // 结构体名称 |
| 16 | PackageName string // 包名 |
| 17 | IsNew bool // 是否使用new关键字 |
| 18 | } |
| 19 | |
| 20 | func (a *PluginGen) Parse(filename string, writer io.Writer) (file *ast.File, err error) { |
| 21 | if filename == "" { |
nothing calls this directly
no outgoing calls
no test coverage detected