libraryapi

package
v0.12.0-a.8 Latest Latest
Warning

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

Go to latest
Published: Oct 4, 2026 License: MIT Imports: 9 Imported by: 1 module, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Check

func Check(required string, descriptor Descriptor) error

Types

type Descriptor

type Descriptor struct {
	FormatVersion   int      `json:"format-version"`
	ImplementedAPIs []string `json:"implemented-apis"`
	GeneratorAPI    string   `json:"generator-api"`
}

func Current

func Current() Descriptor

func ReadDescriptor

func ReadDescriptor(moduleFS fs.FS) (Descriptor, error)

func (Descriptor) Validate

func (d Descriptor) Validate() error

type NewerMinorError

type NewerMinorError struct {
	Required    Version
	Implemented Version
}

func (*NewerMinorError) Error

func (e *NewerMinorError) Error() string

type UnsupportedMajorError

type UnsupportedMajorError struct {
	Required        Version
	ImplementedAPIs []string
}

func (*UnsupportedMajorError) Error

func (e *UnsupportedMajorError) Error() string

type Version

type Version struct {
	Major uint64
	Minor uint64
}

func Parse

func Parse(identifier string) (Version, error)

func (Version) String

func (v Version) String() string

Jump to

Keyboard shortcuts

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