1 package org.apache.commons.betwixt.scarab; 2 3 18 19 import java.io.Serializable ; 20 import java.util.ArrayList ; 21 import java.util.List ; 22 23 import junit.framework.AssertionFailedError; 24 25 import org.apache.commons.logging.Log; 26 import org.apache.commons.logging.LogFactory; 27 28 34 public class ScarabSettings implements Serializable 35 { 36 37 40 private final static Log log = LogFactory.getLog(ScarabSettings.class); 41 42 private List globalAttributes; 43 44 private List modules; 45 46 private List globalIssueTypes; 47 48 51 public ScarabSettings() 52 { 53 globalAttributes = new ArrayList (); 54 modules = new ArrayList (); 55 globalIssueTypes = new ArrayList (); 56 } 57 58 public List getGlobalAttributes() 59 { 60 return globalAttributes; 61 } 62 63 public void addGlobalAttribute(GlobalAttribute globalAttribute) 64 { 65 if (globalAttribute.getName() == null) 68 { 69 throw new AssertionFailedError("Cannot add a new GlobalAttribute that has no name: " + globalAttribute); 70 } 71 globalAttributes.add(globalAttribute); 72 } 73 74 public List getGlobalIssueTypes() 75 { 76 return globalIssueTypes; 77 } 78 79 public void addGlobalIssueType(GlobalIssueType globalIssueType) 80 { 81 globalIssueTypes.add(globalIssueType); 82 } 83 84 public List getModules() 85 { 86 return modules; 87 } 88 89 public void addModule(Module module) 90 { 91 modules.add(module); 92 } 93 } 94 | Popular Tags |