representation

package
v0.0.0-...-c57386b Latest Latest
Warning

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

Go to latest
Published: Mar 1, 2024 License: AGPL-3.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Representation

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

Representation represents a go package folder

func NewRepresentation

func NewRepresentation(dir string) *Representation

NewRepresentation creates a new folder with given path. Use ParseAST to parse ast from go files in path. The pkgPath is the import path of the package to be used by types.parseInfo.

func (*Representation) MappingBytes

func (s *Representation) MappingBytes() ([]byte, error)

MappingBytes retrieves the correct mapping to be written to mapping.json.

func (*Representation) Normalize

func (s *Representation) Normalize() error

Normalize processes the solutions AST to normalize the representation.

func (*Representation) ParseAST

func (s *Representation) ParseAST() (map[string]*ast.Package, error)

ParseAST will parse all to files in folder. It skips test files.

func (*Representation) RepresentationBytes

func (s *Representation) RepresentationBytes() ([]byte, error)

RepresentationBytes retrieves the bytes of the representation.

Jump to

Keyboard shortcuts

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