data

package
v0.9.5 Latest Latest
Warning

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

Go to latest
Published: Aug 24, 2021 License: MIT Imports: 1 Imported by: 5

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CopyDepsRecursive

func CopyDepsRecursive(
	allMap DependencyMap,
	startPkg string,
	fltrMap DependencyMap,
	linkMap map[string]struct{},
)

CopyDepsRecursive copies dependencies recursively from allMap into fltrMap starting at startPkg and ignoring entries in linkMap.

func TypeFormat

func TypeFormat(t PkgType) string

TypeFormat returns the formatting string associated with package type t ("", "_", "`" or "**").

func TypeLetter

func TypeLetter(t PkgType) rune

TypeLetter returns the type letter associated with package type t ('S', 'T', 'D' or 'G').

Types

type DependencyMap

type DependencyMap map[string]PkgImports

DependencyMap is mapping importing package to imported packages. importingPackageName -> (importedPackageName -> PkgType) An imported package name could be added multiple times to the same importing package name due to test packages.

func FilterDepMap

func FilterDepMap(allMap DependencyMap, startPkg string, linkMap map[string]struct{}) DependencyMap

FilterDepMap filters allMap to contain only startPkg and it's transitive dependencies. Entries in linkMap are filtered, too.

type PkgImports

type PkgImports struct {
	PkgType PkgType
	Imports map[string]PkgType
}

PkgImports contains the package type and the imported internal packages with their types.

type PkgType

type PkgType int

PkgType can be one of: Standard, Tool, DB or God

const (
	TypeStandard PkgType = iota
	TypeTool
	TypeDB
	TypeGod
)

Enum of package types: Standard, Tool, DB and God

Jump to

Keyboard shortcuts

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