1 16 package javax.faces.model; 17 18 29 public class SelectItemGroup extends SelectItem 30 { 31 private static final SelectItem[] EMPTY_SELECT_ITEMS = new SelectItem[0]; 32 33 private SelectItem[] _selectItems; 35 36 public SelectItemGroup() 38 { 39 super(); 40 _selectItems = EMPTY_SELECT_ITEMS; 41 } 42 43 public SelectItemGroup(String label) 44 { 45 super("", label, null, false); 46 _selectItems = EMPTY_SELECT_ITEMS; 47 } 48 49 public SelectItemGroup(String label, String description, boolean disabled, SelectItem[] selectItems) 50 { 51 super("", label, description, disabled); 52 if (selectItems == null) throw new NullPointerException ("selectItems"); 53 _selectItems = selectItems; 54 } 55 56 public SelectItem[] getSelectItems() 58 { 59 return _selectItems; 60 } 61 62 public void setSelectItems(SelectItem[] selectItems) 63 { 64 if (selectItems == null) throw new NullPointerException ("selectItems"); 65 _selectItems = selectItems; 66 } 67 } 68 | Popular Tags |