01: /**********************************************************************************
02: *
03: * $Id: LetterGradeMapping.java 9202 2006-05-09 20:57:37Z ray@media.berkeley.edu $
04: *
05: ***********************************************************************************
06: *
07: * Copyright (c) 2005 The Regents of the University of California, The MIT Corporation
08: *
09: * Licensed under the Educational Community License Version 1.0 (the "License");
10: * By obtaining, using and/or copying this Original Work, you agree that you have read,
11: * understand, and will comply with the terms and conditions of the Educational Community License.
12: * You may obtain a copy of the License at:
13: *
14: * http:cvs.sakaiproject.org/licenses/license_1_0.html
15: *
16: * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
17: * INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE
18: * AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
19: * DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
20: * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
21: *
22: **********************************************************************************/package org.sakaiproject.tool.gradebook;
23:
24: import java.util.*;
25:
26: /**
27: * A LetterGradeMapping defines the set of grades available to a gradebook as
28: * "A", "B", "C", "D", and "F", each of which can be mapped to a minimum
29: * percentage value.
30: *
31: * @deprecated
32: */
33: public class LetterGradeMapping extends GradeMapping {
34: private List grades;
35: private List defaultValues;
36:
37: public Collection getGrades() {
38: return grades;
39: }
40:
41: public List getDefaultValues() {
42: return defaultValues;
43: }
44:
45: public LetterGradeMapping() {
46: setGradeMap(new LinkedHashMap());
47:
48: grades = new ArrayList();
49: grades.add("A");
50: grades.add("B");
51: grades.add("C");
52: grades.add("D");
53: grades.add("F");
54:
55: defaultValues = new ArrayList();
56: defaultValues.add(new Double(90));
57: defaultValues.add(new Double(80));
58: defaultValues.add(new Double(70));
59: defaultValues.add(new Double(60));
60: defaultValues.add(new Double(00));
61:
62: setDefaultValues();
63: }
64:
65: public String getName() {
66: return "Letter Grades";
67: }
68: }
|