Perhaps instead of directly extending existing Actions,
you could extract the over-lapping functionality into new super classes?
"kabir.khan at jboss.com" wrote :
| *** WebBeansPostConstructAction ???
| I need to invoke WBI.postConstruct()/preDestroy() from somewhere, but am unsure if I should do that as part of CREATE, START or if I need a new state. If I need a new state, where should that go?
|
I looks like you would need two new states.
POST_CONSTRUCT = after INSTANTAITE, before CONFIGURED (only @ install)
PRE_DESTROY = after CREATE, before START (only @ uninstall)
You can simply add new states to Controller, within some WB+MC singleton.
See DeployersImpl for example.
"kabir.khan at jboss.com" wrote :
|
| | public boolean resolve(Controller controller)
| | {
| | try
| | {
| | context.getManager().validate(injectionPoint);
| | setIDependOn(injectionPoint);
| | // addDependsOnMe(controller, context);
| | setResolved(true);
| | }
| | catch(ValidationException e)
| | {
| | setResolved(false);
| | }
| |
| | return isResolved();
| | }
| |
|
Pete, could we have here something that doesn't throw exception in order to see if it's resolved.
e.g.
| setResolved(context.getManager().canResolve(injectionPoint));
|
View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4249797#4249797
Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4249797