1 | |
|
2 | |
|
3 | |
|
4 | |
|
5 | |
|
6 | |
|
7 | |
|
8 | |
|
9 | |
|
10 | |
|
11 | |
|
12 | |
|
13 | |
|
14 | |
|
15 | |
|
16 | |
|
17 | |
|
18 | |
|
19 | |
package org.apache.myfaces.config.impl.digester.elements; |
20 | |
|
21 | |
import java.util.List; |
22 | |
import java.util.ArrayList; |
23 | |
import java.util.Iterator; |
24 | |
import java.util.Collections; |
25 | |
|
26 | |
|
27 | |
|
28 | |
|
29 | |
|
30 | |
|
31 | |
|
32 | |
|
33 | |
|
34 | |
|
35 | |
|
36 | |
|
37 | |
|
38 | |
|
39 | |
|
40 | |
|
41 | |
|
42 | 0 | public class Property |
43 | |
{ |
44 | |
private List<String> _description; |
45 | |
private List<String> _displayName; |
46 | |
private List<String> _icon; |
47 | |
private String _propertyName; |
48 | |
private String _propertyClass; |
49 | |
private String _defaultValue; |
50 | |
private String _suggestedValue; |
51 | |
private List<String> _propertyExtension; |
52 | |
|
53 | |
|
54 | |
public void addDescription(String value) |
55 | |
{ |
56 | 0 | if(_description == null) |
57 | 0 | _description = new ArrayList<String>(); |
58 | |
|
59 | 0 | _description.add(value); |
60 | 0 | } |
61 | |
|
62 | |
public Iterator<String> getDescriptions() |
63 | |
{ |
64 | 0 | if(_description==null) |
65 | 0 | return Collections.EMPTY_LIST.iterator(); |
66 | |
|
67 | 0 | return _description.iterator(); |
68 | |
} |
69 | |
|
70 | |
public void addDisplayName(String value) |
71 | |
{ |
72 | 0 | if(_displayName == null) |
73 | 0 | _displayName = new ArrayList<String>(); |
74 | |
|
75 | 0 | _displayName.add(value); |
76 | 0 | } |
77 | |
|
78 | |
public Iterator<String> getDisplayNames() |
79 | |
{ |
80 | 0 | if(_displayName==null) |
81 | 0 | return Collections.EMPTY_LIST.iterator(); |
82 | |
|
83 | 0 | return _displayName.iterator(); |
84 | |
} |
85 | |
|
86 | |
public void addIcon(String value) |
87 | |
{ |
88 | 0 | if(_icon == null) |
89 | 0 | _icon = new ArrayList<String>(); |
90 | |
|
91 | 0 | _icon.add(value); |
92 | 0 | } |
93 | |
|
94 | |
public Iterator<String> getIcons() |
95 | |
{ |
96 | 0 | if(_icon==null) |
97 | 0 | return Collections.EMPTY_LIST.iterator(); |
98 | |
|
99 | 0 | return _icon.iterator(); |
100 | |
} |
101 | |
|
102 | |
public void setPropertyName(String propertyName) |
103 | |
{ |
104 | 0 | _propertyName = propertyName; |
105 | 0 | } |
106 | |
|
107 | |
public String getPropertyName() |
108 | |
{ |
109 | 0 | return _propertyName; |
110 | |
} |
111 | |
|
112 | |
public void setPropertyClass(String propertyClass) |
113 | |
{ |
114 | 0 | _propertyClass = propertyClass; |
115 | 0 | } |
116 | |
|
117 | |
public String getPropertyClass() |
118 | |
{ |
119 | 0 | return _propertyClass; |
120 | |
} |
121 | |
|
122 | |
public void setDefaultValue(String defaultValue) |
123 | |
{ |
124 | 0 | _defaultValue = defaultValue; |
125 | 0 | } |
126 | |
|
127 | |
public String getDefaultValue() |
128 | |
{ |
129 | 0 | return _defaultValue; |
130 | |
} |
131 | |
|
132 | |
public void setSuggestedValue(String suggestedValue) |
133 | |
{ |
134 | 0 | _suggestedValue = suggestedValue; |
135 | 0 | } |
136 | |
|
137 | |
public String getSuggestedValue() |
138 | |
{ |
139 | 0 | return _suggestedValue; |
140 | |
} |
141 | |
|
142 | |
public void addPropertyExtension(String propertyExtension) |
143 | |
{ |
144 | 0 | if(_propertyExtension == null) |
145 | 0 | _propertyExtension = new ArrayList<String>(); |
146 | |
|
147 | 0 | _propertyExtension.add(propertyExtension); |
148 | 0 | } |
149 | |
|
150 | |
public Iterator<String> getPropertyExtensions() |
151 | |
{ |
152 | 0 | if(_propertyExtension==null) |
153 | 0 | return Collections.EMPTY_LIST.iterator(); |
154 | |
|
155 | 0 | return _propertyExtension.iterator(); |
156 | |
} |
157 | |
|
158 | |
} |