javaref

package
v0.0.0-...-8593d01 Latest Latest
Warning

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

Go to latest
Published: Jul 23, 2026 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func MatchesEntityPath

func MatchesEntityPath(target ModuleTarget, entPath string) bool

MatchesEntityPath reports whether entPath (relative to target.Dir) belongs to target.

func ResolveImport

func ResolveImport(spec string, knownFiles map[string]bool) string

ResolveImport maps a Java type/package spec to a path: or java: reference. knownFiles keys are slash-separated paths relative to the ingest root.

func ResolvePackageDir

func ResolvePackageDir(spec, rootDir string) (string, error)

ResolvePackageDir resolves java:<package> to a filesystem directory under rootDir using package-path mapping and common source roots (src/main/java, src/test/java, src).

func ResolveTypeFile

func ResolveTypeFile(spec string, knownFiles map[string]bool) (string, bool)

ResolveTypeFile returns the relative path of the .java file for spec, if known.

Types

type ModuleTarget

type ModuleTarget struct {
	Dir  string
	File string // basename when the target is a single .java file
}

ModuleTarget is a resolved package or compilation unit on disk.

func ResolveModuleTarget

func ResolveModuleTarget(spec, rootDir string) (ModuleTarget, error)

ResolveModuleTarget resolves java:<spec> to a package dir and optional file.

type SymbolTarget

type SymbolTarget struct {
	Dir  string
	Name string
}

SymbolTarget points at a directory to ingest for a java: type reference.

func ResolveSymbolTarget

func ResolveSymbolTarget(spec, symbol, rootDir string) (SymbolTarget, bool, error)

ResolveSymbolTarget resolves java:<type-or-package>::<symbol>.

Jump to

Keyboard shortcuts

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