@Override protected void activityPreConditions(PhdProgramCandidacyProcess process, User userView) { if (PREVIOUS_STATE.contains(process.getActiveState())) { return; } throw new PreConditionNotValidException(); }
private void checkType( final PhdProgramCandidacyProcess process, final PhdProgramCandidacyProcessState type) { final PhdProgramCandidacyProcessState currentType = process.getActiveState(); if (currentType != null && currentType.equals(type)) { throw new DomainException( "error.PhdCandidacyProcessState.equals.previous.state", type.getLocalizedName()); } }