Package p1

Examples of p1.T1


        }
    }
   
    public static DateUtil getEndDate(Quiz quiz)
    {
        Timestamp t = quiz.getAssessment().getExtension().getEndDate().getTimeStamp();
        try
        {
            DateUtil d = new DateUtil(t);
            return d;
        }
View Full Code Here


     * @param quiz The Quiz instance
     * @return whether the quiz is active
     */
    public static String getActive(Quiz quiz)
    {
        Procextension p = quiz.getAssessment().getExtension();
        if(p.getIsActive().equals("no")) {
            return "Disabled";
        }
        else
            return "Enabled";
    }
View Full Code Here

        }
    }
   
    public static String getPassword(Quiz quiz)
    {
        Procextension p = quiz.getAssessment().getExtension();
        return p.getPassword();
    }
View Full Code Here

        return p.getPassword();
    }
   
    public static String getTimeLimit(Quiz quiz)
    {
        Procextension p = quiz.getAssessment().getExtension();
        return Integer.toString(p.getTimeLimit());
    }
View Full Code Here

        return Integer.toString(p.getTimeLimit());
    }
   
    public static boolean isTimeEnforced(Quiz quiz)
    {
        Procextension p = quiz.getAssessment().getExtension();       
        return (p.getEnforceTimeLimit().equals("no"))? false : true;
    }
View Full Code Here

        return (p.getEnforceTimeLimit().equals("no"))? false : true;
    }
   
    public static String getAttempsAllowed(Quiz quiz)
    {
        Procextension p = quiz.getAssessment().getExtension();
        return Integer.toString(p.getAttemptsAllowed());
    }
View Full Code Here

    }
   
   
    private void setTimeFields(Quiz quiz)
    {
        DateUtil start = QuizFactory.getStartDate(quiz);
        DateUtil end = QuizFactory.getEndDate(quiz);
        if(start != null)
        {
            startDate.setValue(start.getDate());
            startHour.setText(start.getHour());
            startMin.setText(start.getMin());
            startAMPM.setValue(start.getTimeOfDay());
        }
        if(end != null)
        {
            endDate.setValue(end.getDate());
            endHour.setText(end.getHour());
            endMin.setText(end.getMin());
            endAMPM.setValue(end.getTimeOfDay());
        }
    }
View Full Code Here

    public static DateUtil getStartDate(Quiz quiz)
    {
        Timestamp t = quiz.getAssessment().getExtension().getStartDate().getTimeStamp();
        try
        {
            DateUtil d = new DateUtil(t);
            return d;
        }
        catch(NullPointerException e)
        {
            return null;
View Full Code Here

    public static DateUtil getEndDate(Quiz quiz)
    {
        Timestamp t = quiz.getAssessment().getExtension().getEndDate().getTimeStamp();
        try
        {
            DateUtil d = new DateUtil(t);
            return d;
        }
        catch(NullPointerException e)
        {
            return null;
View Full Code Here

TOP

Related Classes of p1.T1

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.