Change WhenCondition to implement Condition.