Parent injector of which to extract mappings that are not present in current injector.
Whether Injector is destroyed
Number of active listeners on this dispatcher instance.
Add event listener.
Event name for which to listen to
Listener function that will be invoked as event with specified name is dispatched.
Listener scope which will be applied as listener is invoked. (You can leave it undefined, if you don't care about scope that much).
Null in case if event name is already mapped to same function. Or EventMapping object
which is to be used in order to set some of mapping properties like once()
which will make listener
to be executed upon first event dispatch and then be gone.
Create a new sub-injector. This injector instance will be the parent instance of the newly created injector.
Destroy injector and all of its direct mappings.
Check if some instance has pre destroy methods defined and if so - invoke them
instance of injected values client
Dispatch event object to all subscribed listeners.
Event object that defines event type and data
True if any event mappings to event name have been found; false otherwise.
Dispatch event notification by separate type and data arguments.
Event type to be dispatched.
Arbitrary data to ship along with event dispatch.
True if any event mappings to event name have been found; false otherwise.
Implement actual event dispatching
Event to dispatch
True if some event clients where found and event is delivered or false otherwise.
Get injected instance mapped by required type. Invoking this method will return existing mapping or create new one in case if there have been no requests for this mapping or it's not mapped with instantiate call.
Returns the mapping for the specified dependency class Note that getMapping will only return mappings in exactly this injector, not ones mapped in an ancestor injector. To get mappings from ancestor injectors, query them using parent. This restriction is in place to prevent accidental changing of mappings in ancestor injectors where only the child's response is meant to be altered.
The type of the dependency to return the mapping for
The mapping for the specified dependency class
Does this injector have a direct mapping for the given type?
The type
True if the mapping exists
Check if event dispatcher has mapping of certain event to listener.
Target event name.
Listener function.
Listener scope which will be applied as listener is invoked.
true if event mapping is found and false otherwise
Does this injector (or any parents) have a mapping for the given type?
The type
True if the mapping exists
Inspect given type and fill in type properties, clients for Injected values and invoke methods described with
The instance to inject into
Instance passed in via param with properties filled by injections and post construct methods invoked, or as it where in case if there is no metadata tpo apply.
Create instance of given type with constructor argument values injected, if any are described by metadata, and injected properties filled with values from Injector, if there are any. Invoking this method will also invoke any methods marked with @PostConstruct just as injected properties will be filled in.
Instance type to be created.
Newly created class instance of type described by input argument.
Add event listener that will be executed only once.
Event name for which to listen to
Listener function that will be invoked as event with specified name is dispatched.
Listener scope which will be applied as listener is invoked. (You can leave it undefined, if you don't care about scope that much).
Null in case if event name is already mapped to same function. Or EventMapping object
which is to be used in order to set some of mapping properties like once()
which will make listener
to be executed upon first event dispatch and then be gone.
Map type to injector.
The class type describing the mapping
Remove all listeners registered with specified scope or with the whole dispatcher instance.
Scope from which all listeners mapped listeners will be removed. If not specified, all listeners will be removed from whole dispatcher instance.
True if any listeners to remove where found; false otherwise.
Remove event listener.
Target event name.
Listener function.
Listener scope which will be applied as listener is invoked.
True if event name binding to listener function was found or false if it was found not.
Remove all listeners of a particular event from all scopes or the specified scope.
Event name to be unmapped from all listeners.
Listener scope from which all listeners mapped to eventType will be removed.
True if any of mappings have been found; false otherwise.
Removes the mapping described by the given type from current injector.
The class type describing the mapping
Dependencies provider implementation class
Jānis Radiņš / Kristaps Peļņa