PackageProvider class abstract
Resolves a Dart package: import to its library source, from a package host
(pub.dev or another) compatible with pubspec dependency declarations.
Implementations that touch the filesystem or network are kept out of the
web-safe core (see lib/apollovm_pub.dart); this interface itself is pure.
- Implementers
Constructors
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
availablePackages(
) → FutureOr< Set< String> > -
The set of package names this provider can serve (e.g. from a project's
pubspec/package-config), used to pre-provision imports. May be empty if the provider resolves lazily. -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
resolvePackage(
String pkg, String libPath) → FutureOr< PackageSource?> -
Resolves the source for
package:[pkg]/[libPath], ornullif this provider can't serve it. -
resolvePackageUri(
PackageUri uri) → FutureOr< PackageSource?> -
Resolves a full
package:importuri, ornull. -
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited