"alesj" wrote : "richard.opalka(a)jboss.com" wrote :
| | Rule no. 1: Always implement comparable if your object instances represents
natural order.
| |
| There is a better rule.
| Only implement what you actually need.
| There is no need to really compare stages, at least not atm.
|
Agreed
"alesj" wrote :
| But you could do it this way:
| ControllerStateModel model = ...;
| DeploymentStage ds1 = ...;
| ControllerState cs1 = new ControllerState(ds1.getString());
| DeploymentStage ds2 = ...;
| ControllerState cs2 = new ControllerState(ds1.getString());
| boolean isBefore = model.isBefore(cs1, cs2);
|
IMHO ds1.compareTo(ds2) its more intuitive.
Your solution includes whole MC knowledge people usually don't have ;)
"alesj" wrote :
| But if I in both cases need A and output A, B,
| where in 1st deployer I set A.someprop
| but in 2nd deployer I use that A.someprop,
| all I need to do is express this via proper input/output,
| e.g. D1.output=A.someprop, D2.input=A.someprop
Then tell me what's wrong with this? Where's the lack of info I didn't
provide?
View the original post :
http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4240006#...
Reply to the post :
http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&a...