dst: github.com/dave/dst/decorator/resolver Index | Files | Directories

package resolver

import "github.com/dave/dst/decorator/resolver"

Index

Package Files

resolver.go

Variables

var ErrPackageNotFound = errors.New("package not found")

ErrPackageNotFound means the package is not found

type DecoratorResolver Uses

type DecoratorResolver interface {
    ResolveIdent(file *ast.File, parent ast.Node, parentField string, id *ast.Ident) (path string, err error)
}

DecoratorResolver resolves an identifier to a local or remote reference.

Returns path == "" if the node is not a local or remote reference (e.g. a field in a composite literal, the selector in a selector expression etc.).

Returns path == "" is the node is a local reference.

Returns path != "" is the node is a remote reference.

type RestorerResolver Uses

type RestorerResolver interface {
    ResolvePackage(path string) (string, error)
}

RestorerResolver resolves a package path to a package name.

Directories

PathSynopsis
goast
gobuild
gopackages
gotypes
guess
simple

Package resolver imports 2 packages (graph) and is imported by 6 packages. Updated 2018-12-20. Refresh now. Tools for package owners.