Qualifier class

A reserved name that can be used alongside a provides annotation to further specify the key.

Qualifier must be placed at the same level as a @provides annotation. It is illegal to have more than one Qualifier for a given provider.

Example

const baseUri = const Qualifier(#baseUri);

abstract class RpcModule {
  @provides
  @baseUri
  String provideBaseUri() => 'https://foo.bar/service/v2';
}

The symbol #baseUri AND String are used to form the key in the dependency tree.

Constructors

Qualifier(Symbol name)
Create a named provider qualifier from name.
const
factory

Properties

hashCode int
The hash code for this object.
no setterinherited
name Symbol
Unique name of the identifier.
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

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