/* * To change this template, choose Tools | Templates * and open the template in the editor. */ package gradebooktest; // to use this package elsewhere // import gradebooktest.Gradebook; import java.util.Scanner; import javax.swing.JOptionPane; /** * * @author jcmt */ public class GradebookTest { /** * @param args the command line arguments */ public static void main(String[] args) { /* String name = JOptionPane.showInputDialog("What is your name? "); String message = String.format("Welcome\nto\nJava, %s\n", name); JOptionPane.showMessageDialog(null, message); Scanner input = new Scanner(System.in); System.out.print("Enter the course name: "); String nameOfCourse = input.nextLine(); System.out.print("Enter the day of the month: "); Integer day = input.nextInt(); Gradebook BlahBlah = new Gradebook(); //BlahBlah.setCourseName(nameOfCourse); //BlahBlah.setDay(day); BlahBlah.displayNameMessage(); System.out.printf("Today is the %d - %d - %d \n",BlahBlah.getMonth(), BlahBlah.getDay(), BlahBlah.getYear()); */ for (ValidGrades vg: ValidGrades.values()) { System.out.printf("grade value for %s is %f \n",vg, vg.getValue()); } /* Gradebook Blah = new Gradebook(); Blah.displayNameMessage(); System.out.printf("Today is the %d - %d - %d \n",Blah.getMonth(), Blah.getDay(), Blah.getYear()); Blah.setDate(28, -6, 2012); Blah.displayNameMessage(); System.out.printf("Today is the %d - %d - %d \n",Blah.getMonth(), Blah.getDay(), Blah.getYear()); */ //Blah.average(5.4, 6.1); //Blah.average(9.9); //Blah.average(8.2, 4.3, 6.2, 9.5, 4.4); //Blah.displayEachGrade(); // Blah.checkFreq(Blah.getGrades()); } }