purl

package
v1.10.1 Latest Latest
Warning

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

Go to latest
Published: Mar 20, 2026 License: AGPL-3.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func EcosystemForType

func EcosystemForType(purlType string) (string, bool)

EcosystemForType maps a PURL type to the VDB ecosystem name.

Types

type PackageURL

type PackageURL struct {
	Type       string
	Namespace  string
	Name       string
	Version    string
	Qualifiers map[string]string
	Subpath    string
}

PackageURL represents a parsed Package URL (PURL) per the spec.

func Parse

func Parse(raw string) (*PackageURL, error)

Parse parses a PURL string into a PackageURL struct.

func (*PackageURL) PackageName

func (p *PackageURL) PackageName() string

PackageName returns the type-specific package name suitable for VDB API queries.

func (*PackageURL) String

func (p *PackageURL) String() string

String returns the canonical PURL string representation.

Jump to

Keyboard shortcuts

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