public class UpgradeCheckNewAppsGuard extends Object implements org.springframework.statemachine.guard.Guard<SkipperStateMachineService.SkipperStates,SkipperStateMachineService.SkipperEvents>
Guard using extended state variable SkipperStateMachineService.SkipperVariables.UPGRADE_STATUS
to determine condition based on initialised upgradeStatus flag. Value of a
SkipperStateMachineService.SkipperVariables.UPGRADE_STATUS is set in UpgradeCheckTargetAppsAction
and as this same guard is used to protect 'succeed' and 'failure' transitions,
upgradeStatus is simply used to differentiate between the two.| Constructor and Description |
|---|
UpgradeCheckNewAppsGuard(boolean upgradeStatus)
Instantiates a new upgrade check new apps guard.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
evaluate(org.springframework.statemachine.StateContext<SkipperStateMachineService.SkipperStates,SkipperStateMachineService.SkipperEvents> context) |
public UpgradeCheckNewAppsGuard(boolean upgradeStatus)
upgradeStatus - the upgrade status flagpublic boolean evaluate(org.springframework.statemachine.StateContext<SkipperStateMachineService.SkipperStates,SkipperStateMachineService.SkipperEvents> context)
evaluate in interface org.springframework.statemachine.guard.Guard<SkipperStateMachineService.SkipperStates,SkipperStateMachineService.SkipperEvents>Copyright © 2023 Pivotal Software, Inc.. All rights reserved.