MergeInjector | @uirouter/angular
Options
All
  • Public
  • Public/Protected
  • All
Menu

Merge two injectors

This class implements the Injector ng2 interface but delegates to the Injectors provided in the constructor.

Hierarchy

  • MergeInjector

Implements

  • Injector

Index

Constructors

Properties

Methods

Constructors

constructor

Properties

Static NOT_FOUND

NOT_FOUND: {}

Type declaration

Methods

get

  • get(token: any, notFoundValue?: any): any
  • Get the token from the first injector which contains it.

    Delegates to the first Injector.get(). If not found, then delegates to the second Injector (and so forth). If no Injector contains the token, return the notFoundValue, or throw.

    Parameters

    • token: any

      the DI token

    • Optional notFoundValue: any

      the value to return if none of the Injectors contains the token.

    Returns any

    the DI value

Generated using TypeDoc