Encapsulates Dependency Injection for a path of nodes
UI-Router states are organized as a tree.
A nested state has a path of ancestors to the root of the tree.
When a state is being activated, each element in the path is wrapped as a PathNode.
PathNode is a stateful object that holds things like parameters and resolvables for the state being activated.
The ResolveContext closes over the PathNodes, and provides DI for the last node in the path.
Adds Resolvables to the node that matches the state
These new resolvables are not automatically fetched. The calling code should either fetch them, fetch something that depends on them, or rely on resolvePath being called when some state is being entered.
Note: each resolvable's ResolvePolicy is merged with the state's policy, and the global default.
the new Resolvables
Used to find the node to put the resolvable on
Gets the Resolvable that matches the token
Gets the last Resolvable that matches the token in this context, or undefined. Throws an error if it doesn't exist in the ResolveContext
Gets all the tokens found in the resolve context, de-duplicated
Returns a ResolveContext that includes a portion of this one
Given a state, this method creates a new ResolveContext from this one.
The new context starts at the first node (root) and stops at the node for the
When a transition is created, the nodes in the "To Path" are injected from a ResolveContext. A ResolveContext closes over a path of PathNodes and processes the resolvables. The "To State" can inject values from its own resolvables, as well as those from all its ancestor state's (node's). This method is used to create a narrower context when injecting ancestor nodes.
Generated using TypeDoc