1 16 package org.apache.myfaces.config.impl.digester.elements; 17 18 import java.util.ArrayList ; 19 import java.util.List ; 20 import java.util.Iterator ; 21 import java.util.Collections ; 22 23 24 27 public class Converter 28 { 29 30 private String converterId; 31 private String forClass; 32 private String converterClass; 33 private List _properties = null; 34 private List _attributes = null; 35 36 37 public String getConverterId() 38 { 39 return converterId; 40 } 41 42 43 public void setConverterId(String converterId) 44 { 45 this.converterId = converterId; 46 } 47 48 49 public String getForClass() 50 { 51 return forClass; 52 } 53 54 55 public void setForClass(String forClass) 56 { 57 this.forClass = forClass; 58 } 59 60 61 public String getConverterClass() 62 { 63 return converterClass; 64 } 65 66 67 public void setConverterClass(String converterClass) 68 { 69 this.converterClass = converterClass; 70 } 71 72 public void addProperty(Property value) 73 { 74 if(_properties==null) 75 _properties = new ArrayList (); 76 77 _properties.add(value); 78 } 79 80 public Iterator getProperties() 81 { 82 if(_properties==null) 83 return Collections.EMPTY_LIST.iterator(); 84 85 return _properties.iterator(); 86 } 87 88 public void addAttribute(Attribute value) 89 { 90 if(_attributes == null) 91 _attributes = new ArrayList (); 92 93 _attributes.add(value); 94 } 95 96 public Iterator getAttributes() 97 { 98 if(_attributes==null) 99 return Collections.EMPTY_LIST.iterator(); 100 101 return _attributes.iterator(); 102 } 103 } 104 | Popular Tags |