public void removePollingQuestion(AbstractPollingQuestion pollingQuestion) throws UsedQuestionException { if (!voteDao.isUsedQuestion(pollingQuestion)) { voteDao.remove(pollingQuestion); } else { throw new UsedQuestionException("question_is_used"); } }
public void removePollingTemplate(AbstractPollingTemplate pollingTemplate) throws UsedTemplateException { if (!voteDao.isUsedTemplate(pollingTemplate)) { voteDao.remove(pollingTemplate); } else { throw new UsedTemplateException("template_is_used"); } // pollingTemplate = findTemplateByName(pollingTemplate.getName()); // List<AbstractVomte> relatedPollingList = findAllVotesByTemplate(pollingTemplate); // if (!relatedPollingList.isEmpty()){ // //throws exception // return; // } }
public void remove(EntityObject obj) throws Exception { voteDao.remove(obj); }
public void removeVote(Vote vote) { voteDao.remove(vote); }