Classes in this File | Line Coverage | Branch Coverage | Complexity | ||||
HeaderField |
|
| 1.0;1 |
1 | /* | |
2 | * Copyright 2007 The Kuali Foundation | |
3 | * | |
4 | * Licensed under the Educational Community License, Version 1.0 (the "License"); | |
5 | * you may not use this file except in compliance with the License. | |
6 | * You may obtain a copy of the License at | |
7 | * | |
8 | * http://www.opensource.org/licenses/ecl1.php | |
9 | * | |
10 | * Unless required by applicable law or agreed to in writing, software | |
11 | * distributed under the License is distributed on an "AS IS" BASIS, | |
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | |
13 | * See the License for the specific language governing permissions and | |
14 | * limitations under the License. | |
15 | */ | |
16 | package org.kuali.rice.krad.uif.field; | |
17 | ||
18 | /** | |
19 | * Field that contains a header element and optionally a <code>Group</code> to | |
20 | * present along with the header text | |
21 | * | |
22 | * <p> | |
23 | * Generally the group is used to display content to the right of the header, | |
24 | * such as links for the group or other information | |
25 | * </p> | |
26 | * | |
27 | * @author Kuali Rice Team (rice.collab@kuali.org) | |
28 | */ | |
29 | public class HeaderField extends GroupField { | |
30 | private static final long serialVersionUID = -6950408292923393244L; | |
31 | ||
32 | private String headerText; | |
33 | private String headerLevel; | |
34 | private String headerStyleClasses; | |
35 | private String headerStyle; | |
36 | private String headerDivStyleClasses; | |
37 | private String headerDivStyle; | |
38 | ||
39 | public HeaderField() { | |
40 | 0 | super(); |
41 | 0 | } |
42 | ||
43 | /** | |
44 | * Text that should be displayed on the header | |
45 | * | |
46 | * @return String header text | |
47 | */ | |
48 | public String getHeaderText() { | |
49 | 0 | return this.headerText; |
50 | } | |
51 | ||
52 | /** | |
53 | * Setter for the header text | |
54 | * | |
55 | * @param headerText | |
56 | */ | |
57 | public void setHeaderText(String headerText) { | |
58 | 0 | this.headerText = headerText; |
59 | 0 | } |
60 | ||
61 | /** | |
62 | * HTML header level (h1 ... h6) that should be applied to the header text | |
63 | * | |
64 | * @return String header level | |
65 | */ | |
66 | public String getHeaderLevel() { | |
67 | 0 | return this.headerLevel; |
68 | } | |
69 | ||
70 | /** | |
71 | * Setter for the header level | |
72 | * | |
73 | * @param headerLevel | |
74 | */ | |
75 | public void setHeaderLevel(String headerLevel) { | |
76 | 0 | this.headerLevel = headerLevel; |
77 | 0 | } |
78 | ||
79 | /** | |
80 | * Style class that should be applied to the header text (h tag) | |
81 | * | |
82 | * <p> | |
83 | * Note the style class given here applies to only the header text. The | |
84 | * style class property inherited from the <code>Component</code> interface | |
85 | * can be used to set the class for the whole field div (which could | |
86 | * include a nested <code>Group</code>) | |
87 | * </p> | |
88 | * | |
89 | * @return String style class | |
90 | * @see org.kuali.rice.krad.uif.Component.getStyleClasses() | |
91 | */ | |
92 | public String getHeaderStyleClasses() { | |
93 | 0 | return this.headerStyleClasses; |
94 | } | |
95 | ||
96 | /** | |
97 | * Setter for the header style class | |
98 | * | |
99 | * @param headerStyleClasses | |
100 | */ | |
101 | public void setHeaderStyleClasses(String headerStyleClasses) { | |
102 | 0 | this.headerStyleClasses = headerStyleClasses; |
103 | 0 | } |
104 | ||
105 | /** | |
106 | * Style that should be applied to the header text | |
107 | * | |
108 | * <p> | |
109 | * Note the style given here applies to only the header text. The style | |
110 | * property inherited from the <code>Component</code> interface can be used | |
111 | * to set the style for the whole field div (which could include a nested | |
112 | * <code>Group</code>) | |
113 | * </p> | |
114 | * | |
115 | * @return String header style | |
116 | * @see org.kuali.rice.krad.uif.Component.getStyle() | |
117 | */ | |
118 | public String getHeaderStyle() { | |
119 | 0 | return this.headerStyle; |
120 | } | |
121 | ||
122 | /** | |
123 | * Setter for the header style | |
124 | * | |
125 | * @param headerStyle | |
126 | */ | |
127 | public void setHeaderStyle(String headerStyle) { | |
128 | 0 | this.headerStyle = headerStyle; |
129 | 0 | } |
130 | ||
131 | /** | |
132 | * Style class that should be applied to the header div | |
133 | * | |
134 | * <p> | |
135 | * Note the style class given here applies to the div surrounding the header tag only | |
136 | * </p> | |
137 | * | |
138 | * @return String style class | |
139 | * @see org.kuali.rice.krad.uif.Component.getStyleClasses() | |
140 | */ | |
141 | public String getHeaderDivStyleClasses() { | |
142 | 0 | return headerDivStyleClasses; |
143 | } | |
144 | ||
145 | /** | |
146 | * Setter for the header div class | |
147 | * | |
148 | * @param headerStyleClasses | |
149 | */ | |
150 | public void setHeaderDivStyleClasses(String headerDivStyleClasses) { | |
151 | 0 | this.headerDivStyleClasses = headerDivStyleClasses; |
152 | 0 | } |
153 | ||
154 | /** | |
155 | * Style that should be applied to the header div | |
156 | * | |
157 | * <p> | |
158 | * Note the style given here applies to the div surrounding the header tag only | |
159 | * </p> | |
160 | * | |
161 | * @return String header style | |
162 | * @see org.kuali.rice.krad.uif.Component.getStyle() | |
163 | */ | |
164 | public String getHeaderDivStyle() { | |
165 | 0 | return headerDivStyle; |
166 | } | |
167 | ||
168 | /** | |
169 | * Setter for the header div | |
170 | * | |
171 | * @param headerStyle | |
172 | */ | |
173 | public void setHeaderDivStyle(String headerDivStyle) { | |
174 | 0 | this.headerDivStyle = headerDivStyle; |
175 | 0 | } |
176 | } |