static private class SendToCoordinator extends Activity<SecondCycleCandidacyProcess> {
@Override
public void checkPreConditions(SecondCycleCandidacyProcess process, User userView) {
if (!isAllowedToManageProcess(userView)) {
throw new PreConditionNotValidException();
}
if (!process.isInStandBy() && !process.isSentToScientificCouncil()) {
throw new PreConditionNotValidException();
}
if (process.getCandidacyPeriod() == null || !process.hasStarted() || process.hasOpenCandidacyPeriod()) {
throw new PreConditionNotValidException();
}
}