Package com.vst.model

Examples of com.vst.model.Hint


    public void setHintDao(HintDao dao) {
        this.dao = dao;
    }

    public void testAddHint() throws Exception {
        Hint hint = new Hint();

        // set required fields

        dao.saveHint(hint);

        // verify a primary key was assigned
        assertNotNull(hint.getHintId());

        // verify set fields are same after save
    }
View Full Code Here


        // verify set fields are same after save
    }

    public void testGetHint() throws Exception {
        Hint hint = dao.getHint(hintId);
        assertNotNull(hint);
    }
View Full Code Here

        Hint hint = dao.getHint(hintId);
        assertNotNull(hint);
    }

    public void testGetHints() throws Exception {
        Hint hint = new Hint();

        List results = dao.getHints(hint);
        assertTrue(results.size() > 0);
    }
View Full Code Here

        List results = dao.getHints(hint);
        assertTrue(results.size() > 0);
    }

    public void testSaveHint() throws Exception {
        Hint hint = dao.getHint(hintId);

        // update required fields

        dao.saveHint(hint);
View Full Code Here

         return Hint.class.isAssignableFrom(candidate);
     }

     public void validate(Object obj, Errors errors) {

         Hint hint=(Hint)obj;

         //checking if all answer contents were filled
         List questionList=hint.getQuestions();
         for (int i = 0; i < questionList.size(); i++) {
             Question question = (Question) questionList.get(i);
             if(question.getQuestionId().equals(new Long(-1))){
                 errors.rejectValue("questions["+i+"]", "hint.noQuestion");
             }
View Full Code Here

    /**
     * @see com.vst.dao.HintDao#getHint(Integer hintId)
     */
    public Hint getHint(final Integer hintId) {
        Hint hint = (Hint) getObject(hintId);
        return hint;
    }
View Full Code Here

TOP

Related Classes of com.vst.model.Hint

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.