ModuleLoader class abstract
Resolves import paths to modules. Pluggable so alternative strategies (e.g. a filesystem loader) can be supplied without changing the resolver.
The default VMModuleLoader is web-safe: it resolves purely against
modules already loaded into an ApolloVM (plus core packages) using string
math — it never touches dart:io. A filesystem-backed loader would be a
separate, non-core implementation of this interface.
- 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
-
loadModule(
String moduleId, {String? language}) → LoadedModule? -
Loads the module with canonical id
moduleId, ornull. -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
resolveCorePackage(
String importPath) → CorePackageBase? -
Resolves
importPathto a built-in core package, ornull. -
resolveModuleId(
String importPath, {String? fromModule, String? language}) → String? -
Normalizes
importPath(optionally relative tofromModule) to the canonical id of a loadable module, ornullif none matches. -
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited