RoleProvider<D extends Object> class abstract base

The implementation of a role by a module, such as the go_router module providing the router role.

A module has one provider object per role it provides, listed in ModuleDescriptor.providers. A provider requires and uses what its role requires and uses, and must generate the symbols of the role's RoleInterface. Its hooks receive the same input as the role's template.

Implementers

Constructors

RoleProvider()
Allows subclasses to have constant constructors.
const
RoleProvider.plain(Role<D> role)
Creates a provider of role without hooks, for a module whose bricks alone implement the role.
const
factory

Properties

hashCode → int
The hash code for this object.
no setterinherited
role → Role<D>
The role this object provides.
no setter
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
render(RoleHookInput<D> input) → RoleOutput
Returns the fragments, the variables of the module's bricks and the files that depend on the data, such as the routes of a router.
toString() → String
A string representation of this object.
inherited
validate(RoleHookInput<D> input) → List<SmfIssue>
Checks the data of the role against what this provider supports, such as the number of destinations a layout can show, and returns the problems found.

Operators

operator ==(Object other) → bool
The equality operator.
inherited