annotate flys-artifacts/src/main/java/de/intevation/flys/exports/ChartSection.java @ 5162:94c3eb995bf6

Fixed broken insert statements for axis_kinds.
author Sascha L. Teichmann <teichmann@intevation.de>
date Fri, 01 Mar 2013 20:52:31 +0100
parents b7867c03760a
children
rev   line source
1986
3632150dbe0b Implemented a ChartSettings with relevant Sections and Attributes for charts (NOTE: Work still in progress).
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
1 package de.intevation.flys.exports;
3632150dbe0b Implemented a ChartSettings with relevant Sections and Attributes for charts (NOTE: Work still in progress).
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
2
3617
05deafdcbf39 sloppy logo placement property implementation.
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 3615
diff changeset
3 import org.apache.log4j.Logger;
1986
3632150dbe0b Implemented a ChartSettings with relevant Sections and Attributes for charts (NOTE: Work still in progress).
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
4
3632150dbe0b Implemented a ChartSettings with relevant Sections and Attributes for charts (NOTE: Work still in progress).
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
5
3632150dbe0b Implemented a ChartSettings with relevant Sections and Attributes for charts (NOTE: Work still in progress).
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
6 /**
3632150dbe0b Implemented a ChartSettings with relevant Sections and Attributes for charts (NOTE: Work still in progress).
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
7 * @author <a href="mailto:ingo.weinzierl@intevation.de">Ingo Weinzierl</a>
3632150dbe0b Implemented a ChartSettings with relevant Sections and Attributes for charts (NOTE: Work still in progress).
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
8 */
2058
f97cf2e350c9 Some refactoring done: all Sections subclass TypeSection now to be able to use the convinience methods for string, integer, double and boolean attributes.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents: 2046
diff changeset
9 public class ChartSection extends TypeSection {
1986
3632150dbe0b Implemented a ChartSettings with relevant Sections and Attributes for charts (NOTE: Work still in progress).
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
10
3617
05deafdcbf39 sloppy logo placement property implementation.
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 3615
diff changeset
11 private static Logger logger = Logger.getLogger(ChartSection.class);
05deafdcbf39 sloppy logo placement property implementation.
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 3615
diff changeset
12
05deafdcbf39 sloppy logo placement property implementation.
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 3615
diff changeset
13 public static final String TITLE_ATTR = "title";
05deafdcbf39 sloppy logo placement property implementation.
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 3615
diff changeset
14 public static final String SUBTITLE_ATTR = "subtitle";
05deafdcbf39 sloppy logo placement property implementation.
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 3615
diff changeset
15 public static final String DISPLAYGRID_ATTR = "display-grid";
05deafdcbf39 sloppy logo placement property implementation.
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 3615
diff changeset
16 public static final String DISPLAYLOGO_ATTR = "display-logo";
3618
b7867c03760a Split logo placement property in two (vertical/horizontal).
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 3617
diff changeset
17 public static final String LOGOPLACEMENTH_ATTR = "logo-placeh";
b7867c03760a Split logo placement property in two (vertical/horizontal).
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 3617
diff changeset
18 public static final String LOGOPLACEMENTV_ATTR = "logo-placev";
1986
3632150dbe0b Implemented a ChartSettings with relevant Sections and Attributes for charts (NOTE: Work still in progress).
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
19
3632150dbe0b Implemented a ChartSettings with relevant Sections and Attributes for charts (NOTE: Work still in progress).
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
20
3632150dbe0b Implemented a ChartSettings with relevant Sections and Attributes for charts (NOTE: Work still in progress).
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
21 public ChartSection() {
3632150dbe0b Implemented a ChartSettings with relevant Sections and Attributes for charts (NOTE: Work still in progress).
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
22 super("chart");
3632150dbe0b Implemented a ChartSettings with relevant Sections and Attributes for charts (NOTE: Work still in progress).
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
23 }
3632150dbe0b Implemented a ChartSettings with relevant Sections and Attributes for charts (NOTE: Work still in progress).
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
24
3632150dbe0b Implemented a ChartSettings with relevant Sections and Attributes for charts (NOTE: Work still in progress).
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
25
3632150dbe0b Implemented a ChartSettings with relevant Sections and Attributes for charts (NOTE: Work still in progress).
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
26 public void setTitle(String title) {
2058
f97cf2e350c9 Some refactoring done: all Sections subclass TypeSection now to be able to use the convinience methods for string, integer, double and boolean attributes.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents: 2046
diff changeset
27 setStringValue(TITLE_ATTR, title);
1986
3632150dbe0b Implemented a ChartSettings with relevant Sections and Attributes for charts (NOTE: Work still in progress).
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
28 }
3632150dbe0b Implemented a ChartSettings with relevant Sections and Attributes for charts (NOTE: Work still in progress).
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
29
3632150dbe0b Implemented a ChartSettings with relevant Sections and Attributes for charts (NOTE: Work still in progress).
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
30
2046
2ae0627f956e Improved ChartSettings and depending classes to avoid a lot of casting.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents: 1986
diff changeset
31 public String getTitle() {
2058
f97cf2e350c9 Some refactoring done: all Sections subclass TypeSection now to be able to use the convinience methods for string, integer, double and boolean attributes.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents: 2046
diff changeset
32 return getStringValue(TITLE_ATTR);
2046
2ae0627f956e Improved ChartSettings and depending classes to avoid a lot of casting.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents: 1986
diff changeset
33 }
2ae0627f956e Improved ChartSettings and depending classes to avoid a lot of casting.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents: 1986
diff changeset
34
2ae0627f956e Improved ChartSettings and depending classes to avoid a lot of casting.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents: 1986
diff changeset
35
1986
3632150dbe0b Implemented a ChartSettings with relevant Sections and Attributes for charts (NOTE: Work still in progress).
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
36 public void setSubtitle(String subtitle) {
2058
f97cf2e350c9 Some refactoring done: all Sections subclass TypeSection now to be able to use the convinience methods for string, integer, double and boolean attributes.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents: 2046
diff changeset
37 setStringValue(SUBTITLE_ATTR, subtitle);
1986
3632150dbe0b Implemented a ChartSettings with relevant Sections and Attributes for charts (NOTE: Work still in progress).
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
38 }
3632150dbe0b Implemented a ChartSettings with relevant Sections and Attributes for charts (NOTE: Work still in progress).
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
39
3632150dbe0b Implemented a ChartSettings with relevant Sections and Attributes for charts (NOTE: Work still in progress).
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
40
2046
2ae0627f956e Improved ChartSettings and depending classes to avoid a lot of casting.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents: 1986
diff changeset
41 public String getSubtitle() {
2058
f97cf2e350c9 Some refactoring done: all Sections subclass TypeSection now to be able to use the convinience methods for string, integer, double and boolean attributes.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents: 2046
diff changeset
42 return getStringValue(SUBTITLE_ATTR);
2046
2ae0627f956e Improved ChartSettings and depending classes to avoid a lot of casting.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents: 1986
diff changeset
43 }
2ae0627f956e Improved ChartSettings and depending classes to avoid a lot of casting.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents: 1986
diff changeset
44
2ae0627f956e Improved ChartSettings and depending classes to avoid a lot of casting.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents: 1986
diff changeset
45
3617
05deafdcbf39 sloppy logo placement property implementation.
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 3615
diff changeset
46 /** Get Property-value for display-logo property. */
3615
f84854eba0b3 Preparations for logo inclusion in charts.
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 2064
diff changeset
47 public String getDisplayLogo() {
f84854eba0b3 Preparations for logo inclusion in charts.
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 2064
diff changeset
48 return getStringValue(DISPLAYLOGO_ATTR);
f84854eba0b3 Preparations for logo inclusion in charts.
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 2064
diff changeset
49 }
f84854eba0b3 Preparations for logo inclusion in charts.
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 2064
diff changeset
50
f84854eba0b3 Preparations for logo inclusion in charts.
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 2064
diff changeset
51
3617
05deafdcbf39 sloppy logo placement property implementation.
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 3615
diff changeset
52 /** Set Property-value for display-logo property. */
3615
f84854eba0b3 Preparations for logo inclusion in charts.
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 2064
diff changeset
53 public void setDisplayLogo(String logo) {
3617
05deafdcbf39 sloppy logo placement property implementation.
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 3615
diff changeset
54 logger.debug("Setting Display logo string.");
3615
f84854eba0b3 Preparations for logo inclusion in charts.
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 2064
diff changeset
55 setChoiceStringValue(DISPLAYLOGO_ATTR, logo, "logo");
f84854eba0b3 Preparations for logo inclusion in charts.
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 2064
diff changeset
56 }
f84854eba0b3 Preparations for logo inclusion in charts.
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 2064
diff changeset
57
f84854eba0b3 Preparations for logo inclusion in charts.
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 2064
diff changeset
58
3618
b7867c03760a Split logo placement property in two (vertical/horizontal).
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 3617
diff changeset
59 /** Get Property-value for horizontal logo-placement property. */
b7867c03760a Split logo placement property in two (vertical/horizontal).
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 3617
diff changeset
60 public String getLogoHPlacement() {
b7867c03760a Split logo placement property in two (vertical/horizontal).
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 3617
diff changeset
61 return getStringValue(LOGOPLACEMENTH_ATTR);
3617
05deafdcbf39 sloppy logo placement property implementation.
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 3615
diff changeset
62 }
05deafdcbf39 sloppy logo placement property implementation.
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 3615
diff changeset
63
05deafdcbf39 sloppy logo placement property implementation.
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 3615
diff changeset
64
3618
b7867c03760a Split logo placement property in two (vertical/horizontal).
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 3617
diff changeset
65 /** Set Property-value for horizontal logo-placement property. */
b7867c03760a Split logo placement property in two (vertical/horizontal).
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 3617
diff changeset
66 public void setLogoHPlacement(String place) {
b7867c03760a Split logo placement property in two (vertical/horizontal).
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 3617
diff changeset
67 setChoiceStringValue(LOGOPLACEMENTH_ATTR, place, "placeh");
b7867c03760a Split logo placement property in two (vertical/horizontal).
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 3617
diff changeset
68 }
b7867c03760a Split logo placement property in two (vertical/horizontal).
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 3617
diff changeset
69
b7867c03760a Split logo placement property in two (vertical/horizontal).
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 3617
diff changeset
70
b7867c03760a Split logo placement property in two (vertical/horizontal).
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 3617
diff changeset
71 /** Get Property-value for vertical logo-placement property. */
b7867c03760a Split logo placement property in two (vertical/horizontal).
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 3617
diff changeset
72 public String getLogoVPlacement() {
b7867c03760a Split logo placement property in two (vertical/horizontal).
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 3617
diff changeset
73 return getStringValue(LOGOPLACEMENTV_ATTR);
b7867c03760a Split logo placement property in two (vertical/horizontal).
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 3617
diff changeset
74 }
b7867c03760a Split logo placement property in two (vertical/horizontal).
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 3617
diff changeset
75
b7867c03760a Split logo placement property in two (vertical/horizontal).
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 3617
diff changeset
76
b7867c03760a Split logo placement property in two (vertical/horizontal).
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 3617
diff changeset
77 /** Set Property-value for vertical logo-placement property. */
b7867c03760a Split logo placement property in two (vertical/horizontal).
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 3617
diff changeset
78 public void setLogoVPlacement(String place) {
b7867c03760a Split logo placement property in two (vertical/horizontal).
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 3617
diff changeset
79 setChoiceStringValue(LOGOPLACEMENTV_ATTR, place, "placev");
3617
05deafdcbf39 sloppy logo placement property implementation.
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 3615
diff changeset
80 }
05deafdcbf39 sloppy logo placement property implementation.
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 3615
diff changeset
81
05deafdcbf39 sloppy logo placement property implementation.
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 3615
diff changeset
82
3615
f84854eba0b3 Preparations for logo inclusion in charts.
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 2064
diff changeset
83 public void setDisplayGrid(boolean displayGrid) {
2058
f97cf2e350c9 Some refactoring done: all Sections subclass TypeSection now to be able to use the convinience methods for string, integer, double and boolean attributes.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents: 2046
diff changeset
84 setBooleanValue(DISPLAYGRID_ATTR, displayGrid);
1986
3632150dbe0b Implemented a ChartSettings with relevant Sections and Attributes for charts (NOTE: Work still in progress).
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
85 }
2046
2ae0627f956e Improved ChartSettings and depending classes to avoid a lot of casting.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents: 1986
diff changeset
86
2ae0627f956e Improved ChartSettings and depending classes to avoid a lot of casting.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents: 1986
diff changeset
87
2ae0627f956e Improved ChartSettings and depending classes to avoid a lot of casting.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents: 1986
diff changeset
88 public Boolean getDisplayGrid() {
2058
f97cf2e350c9 Some refactoring done: all Sections subclass TypeSection now to be able to use the convinience methods for string, integer, double and boolean attributes.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents: 2046
diff changeset
89 return getBooleanValue(DISPLAYGRID_ATTR);
2046
2ae0627f956e Improved ChartSettings and depending classes to avoid a lot of casting.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents: 1986
diff changeset
90 }
1986
3632150dbe0b Implemented a ChartSettings with relevant Sections and Attributes for charts (NOTE: Work still in progress).
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
91 }
3632150dbe0b Implemented a ChartSettings with relevant Sections and Attributes for charts (NOTE: Work still in progress).
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
92 // vim:set ts=4 sw=4 si et sta sts=4 fenc=utf8 :

http://dive4elements.wald.intevation.org