[Minor] Code cleanup
This commit is contained in:
parent
8811b39585
commit
5f80c4a344
|
@ -1,6 +1,5 @@
|
|||
package li.strolch.execution.policy;
|
||||
|
||||
import static li.strolch.model.StrolchModelConstants.PolicyConstants.BAG_OBJECTIVES;
|
||||
import static li.strolch.model.StrolchModelConstants.PolicyConstants.PARAM_DURATION;
|
||||
|
||||
import li.strolch.model.activity.Action;
|
||||
|
@ -26,7 +25,7 @@ public class DurationExecution extends SimpleExecution {
|
|||
public void toExecution(Action action) {
|
||||
if (this.delayToExecuted) {
|
||||
super.toExecution(action);
|
||||
if (action.findParameter(BAG_OBJECTIVES, PARAM_DURATION, true).isEmpty())
|
||||
if (action.findObjectivesParam(PARAM_DURATION, true).isEmpty())
|
||||
toExecuted(action);
|
||||
else
|
||||
delayToExecuted(action);
|
||||
|
|
|
@ -269,7 +269,7 @@ public abstract class ExecutionPolicy extends StrolchPolicy {
|
|||
* @return the {@link DurationParameter}
|
||||
*/
|
||||
protected DurationParameter findActionDuration(Action action) {
|
||||
return action.findParameter(BAG_OBJECTIVES, PARAM_DURATION, true);
|
||||
return action.findObjectivesParam(PARAM_DURATION, true);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Reference in New Issue