pub library

Classes

CachedSource
Base class for a BoundSource that installs packages into pub's SystemCache.
DownloadPackageResult
Entrypoint
The context surrounding the workspace pub is operating on.
PackageDetail
An enum of different levels of detail that can be used when displaying a terse package name.
PackageId
A reference to a specific version of a package.
PackageRange
A reference to a constrained range of versions of one package.
PackageRef
A reference to a Package, but not any particular version(s) of it.
RepairResult
The result of repairing a single cache entry.
SolveResult
The result of a successful version resolution.
SystemCache
The system-wide cache of downloaded packages.

Enums

SolveType
An enum for types of version resolution.

Functions

resolveVersions(SolveType type, SystemCache cache, Package root, {LockFile? lockFile, Iterable<String> unlock = const [], Map<String, Version> sdkOverrides = const {}, Iterable<ConstraintAndCause>? additionalConstraints}) Future<SolveResult>
Attempts to select the best concrete versions for all of the transitive dependencies of root taking into account all of the VersionConstraints that those dependencies place on each other and the requirements imposed by lockFile.
tryResolveVersions(SolveType type, SystemCache cache, Package root, {LockFile? lockFile, Iterable<String>? unlock, Iterable<ConstraintAndCause>? additionalConstraints}) Future<SolveResult?>
Attempts to select the best concrete versions for all of the transitive dependencies of root taking into account all of the VersionConstraints that those dependencies place on each other and the requirements imposed by lockFile.

Typedefs

SourceRegistry = Source Function(String? name)

Exceptions / Errors

SolveFailure
An exception indicating that version solving failed.