|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjava.util.EventObject
net.sf.jguiraffe.di.BeanCreationEvent
public class BeanCreationEvent
An event class for reporting the creation of a bean by the dependency injection framework.
Objects of this event class are received by BeanCreationListener
implementations, which can be registered at a BeanContext object.
Whenever the BeanContext is queried for a bean, and this bean has to
be newly created (e.g. because of the first access of a singleton bean or
because it is a factory bean), an event of this type is triggered.
| Field Summary |
|---|
| Fields inherited from class java.util.EventObject |
|---|
source |
| Constructor Summary | |
|---|---|
BeanCreationEvent(BeanContext source,
BeanProvider provider,
DependencyProvider depProvider,
java.lang.Object newBean)
Creates a new instance of BeanCreationEvent and initializes it. |
|
| Method Summary | |
|---|---|
java.lang.Object |
getBean()
Returns the newly created bean. |
BeanContext |
getBeanContext()
Returns the BeanContext that caused this event. |
BeanProvider |
getBeanProvider()
Returns the BeanProvider that created the new bean. |
DependencyProvider |
getDependencyProvider()
Returns the DependencyProvider involved in the bean creation
process. |
| Methods inherited from class java.util.EventObject |
|---|
getSource, toString |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public BeanCreationEvent(BeanContext source,
BeanProvider provider,
DependencyProvider depProvider,
java.lang.Object newBean)
BeanCreationEvent and initializes it.
source - the BeanContext that caused this eventprovider - the BeanProvider that created the beandepProvider - the DependencyProvider used for creating the
beannewBean - the newly created bean| Method Detail |
|---|
public BeanContext getBeanContext()
BeanContext that caused this event.
BeanContextpublic BeanProvider getBeanProvider()
BeanProvider that created the new bean.
BeanProviderpublic DependencyProvider getDependencyProvider()
DependencyProvider involved in the bean creation
process. This is the object that was passed to the BeanProvider
when it created the new bean.
DependencyProvider involved when creating the beanpublic java.lang.Object getBean()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||