gopbuild

package
v0.25.0 Latest Latest
Warning

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

Go to latest
Published: Apr 27, 2024 License: Apache-2.0 Imports: 32 Imported by: 10

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BuildDir

func BuildDir(ctx *igop.Context, dir string) (data []byte, err error)

func BuildFSDir

func BuildFSDir(ctx *igop.Context, fs parser.FileSystem, dir string) (data []byte, err error)

func BuildFile

func BuildFile(ctx *igop.Context, filename string, src interface{}) (data []byte, err error)

func ClassKind added in v0.18.0

func ClassKind(fname string) (isProj, ok bool)

func RegisterClassFileType

func RegisterClassFileType(ext string, class string, works []*Class, pkgPaths ...string)

Types

type Class added in v0.17.0

type Class = cl.Class

type Context

type Context struct {
	// contains filtered or unexported fields
}

func NewContext

func NewContext(ctx *igop.Context) *Context

func (*Context) Import

func (c *Context) Import(path string) (*types.Package, error)

func (*Context) ParseDir

func (c *Context) ParseDir(dir string) (*Package, error)

func (*Context) ParseFSDir

func (c *Context) ParseFSDir(fs parser.FileSystem, dir string) (*Package, error)

func (*Context) ParseFile

func (c *Context) ParseFile(fname string, src interface{}) (*Package, error)

type Package

type Package struct {
	Fset *token.FileSet
	Pkg  *gogen.Package
}

func (*Package) ToAst

func (p *Package) ToAst() *goast.File

func (*Package) ToSource

func (p *Package) ToSource() ([]byte, error)

Jump to

Keyboard shortcuts

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