Invocation class final
One dpk command line, split into dpk's own options, the command, and the arguments that belong to the command.
dpk's own options only count before the command name. Everything after the
command name belongs to the command, so dpk run test -v passes -v to
the test script, and dpk add http -C x passes -C x to dart pub add.
Constructors
-
Invocation({String? directory, String? cacheDirectory, bool verbose = false, bool quiet = false, bool? color, bool help = false, bool version = false, String? command, List<
String> commandArguments = const []}) -
const
-
Invocation.parse(List<
String> arguments) -
Parses
argumentsas typed afterdpk.factory
Properties
- cacheDirectory → String?
-
The
--cache-dirvalue, if given.final - color → bool?
-
final
- command → String?
-
The command name, such as
runorget.nullwhen only dpk options were given.final -
commandArguments
→ List<
String> -
Every argument after command, unchanged.
final
- directory → String?
-
The
-Cdirectory, if given.final - hashCode → int
-
The hash code for this object.
no setterinherited
- help → bool
-
final
- needsProject → bool
-
Whether the command can only run inside a dpk project.
no setter
- quiet → bool
-
final
-
runnerArguments
→ List<
String> -
The arguments to hand to the
argscommand runner: the command and its arguments, with--helpin front when it was given as a dpk option.no setter - runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- verbose → bool
-
final
- version → bool
-
final
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited