Placed just before a constructor parameter, this parameter decorator allows for specificity and control over the type of the type of Object that will be injected into the parameter. In the absence of this decorator the container will use whatever is bound to a parameter's type (or throw an error if it is unable to recognize the type).
The identifier of the bound type that should be injected.
Placed just before a constructor parameter, this parameter decorator signals the container that it should supply the 'alt' constant value (undefined by default) if for any reason it is unable to otherwise resolve the type of the parameter. WARNING! It is your responsibility to ensure that alt is of the appropriate type/value.
Placed just before a class method, this method decorator flags a method that should be called after an object has been instantiated by the container, but before it is put into service. The method will be assumed to be synchronous unless the method signature explicitly declares it's return type to be ": Promise<something>" This decorator will throw if placed on a non-method or a static method of a class, or if placed on a method more than once, or if placed on more than one method for a class.
Universal id that can be bound to a constant, class, or factories.
Type definition for functions that return a value. The function should return a valid value, but may throw an exception if it cannot.
Type definition for functions that return a Promise for a value. The function must not throw and must return a valid Promise (e.g. pending, resolved, rejected).
Standard definition of a constructor.
You may bind an error handler which will be invoked, if the bound InjectableId could not be put into service. An error handler must not throw, but may return an Error that will be propagated back up the call chain.
Generated using TypeDoc
Placed just before the class declaration, this class decorator applies metadata to the class constructor indicating that the user intends to bind the class into the container. This decorator will throw if not placed on a class declaration, or if placed more than once on a class declaration.