1 | |
package org.kuali.student.lum.common.client.configuration; |
2 | |
|
3 | |
import com.google.gwt.user.client.ui.Widget; |
4 | |
import org.kuali.student.common.ui.client.configurable.mvc.views.SectionView; |
5 | |
import org.kuali.student.common.ui.client.mvc.View; |
6 | |
|
7 | |
|
8 | |
|
9 | |
|
10 | 0 | public abstract class AbstractSectionConfiguration extends AbstractConfiguration { |
11 | |
|
12 | |
protected SectionView rootSection; |
13 | |
|
14 | |
@Override |
15 | |
public View getView() { |
16 | 0 | return getView(true); |
17 | |
} |
18 | |
|
19 | |
public View getView(boolean build) { |
20 | 0 | if (build) { |
21 | 0 | buildLayout(); |
22 | |
} |
23 | 0 | return rootSection; |
24 | |
} |
25 | |
|
26 | |
protected abstract void buildLayout(); |
27 | |
|
28 | |
@Override |
29 | |
public Widget asWidget() { |
30 | 0 | return rootSection; |
31 | |
} |
32 | |
|
33 | |
@Override |
34 | |
public Enum<?> getName() { |
35 | 0 | return rootSection.getViewEnum(); |
36 | |
} |
37 | |
} |