Mercurial > dive4elements > river
diff flys-artifacts/src/main/java/de/intevation/flys/exports/ChartSection.java @ 2046:2ae0627f956e
Improved ChartSettings and depending classes to avoid a lot of casting.
flys-artifacts/trunk@3534 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author | Ingo Weinzierl <ingo.weinzierl@intevation.de> |
---|---|
date | Fri, 23 Dec 2011 08:51:28 +0000 |
parents | 3632150dbe0b |
children | f97cf2e350c9 |
line wrap: on
line diff
--- a/flys-artifacts/src/main/java/de/intevation/flys/exports/ChartSection.java Thu Dec 22 13:22:55 2011 +0000 +++ b/flys-artifacts/src/main/java/de/intevation/flys/exports/ChartSection.java Fri Dec 23 08:51:28 2011 +0000 @@ -35,6 +35,12 @@ } + public String getTitle() { + StringAttribute attr = (StringAttribute) getAttribute(TITLE_ATTR); + return attr != null ? (String) attr.getValue() : null; + } + + public void setSubtitle(String subtitle) { if (subtitle == null || subtitle.length() == 0) { return; @@ -51,6 +57,12 @@ } + public String getSubtitle() { + StringAttribute attr = (StringAttribute) getAttribute(SUBTITLE_ATTR); + return attr != null ? (String) attr.getValue() : null; + } + + public void setDisplayGird(boolean displayGrid) { Attribute attr = getAttribute(DISPLAYGRID_ATTR); if (attr == null) { @@ -61,5 +73,11 @@ attr.setValue(displayGrid); } } + + + public Boolean getDisplayGrid() { + BooleanAttribute ba = (BooleanAttribute) getAttribute(DISPLAYGRID_ATTR); + return ba != null ? (Boolean) ba.getValue() : null; + } } // vim:set ts=4 sw=4 si et sta sts=4 fenc=utf8 :