Mercurial > dive4elements > framework
changeset 244:3d14fe6e05f7
Improved the describe() of a State - a reference to an artifact has been added.
artifacts/trunk@1683 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author | Ingo Weinzierl <ingo.weinzierl@intevation.de> |
---|---|
date | Thu, 14 Apr 2011 08:26:25 +0000 |
parents | 33b9cc23ac9b |
children | def3daabc5b5 |
files | ChangeLog artifact-database/src/main/java/de/intevation/artifactdatabase/state/AbstractState.java artifact-database/src/main/java/de/intevation/artifactdatabase/state/State.java |
diffstat | 3 files changed, 13 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/ChangeLog Wed Apr 13 15:19:59 2011 +0000 +++ b/ChangeLog Thu Apr 14 08:26:25 2011 +0000 @@ -1,3 +1,10 @@ +2011-04-14 Ingo Weinzierl <ingo@intevation.de> + + * artifact-database/src/main/java/de/intevation/artifactdatabase/state/State.java, + artifact-database/src/main/java/de/intevation/artifactdatabase/state/AbstractState.java: + Added a reference to an artifact to the parameterlist of describe(). + This is needed to retrieve other necessary information of an artifact. + 2011-04-13 Sascha L. Teichmann <sascha.teichmann@intevation.de> * artifact-database/src/main/resources/sql/org-postgresql-driver.properties:
--- a/artifact-database/src/main/java/de/intevation/artifactdatabase/state/AbstractState.java Wed Apr 13 15:19:59 2011 +0000 +++ b/artifact-database/src/main/java/de/intevation/artifactdatabase/state/AbstractState.java Thu Apr 14 08:26:25 2011 +0000 @@ -21,6 +21,7 @@ import org.w3c.dom.Node; import org.w3c.dom.NodeList; +import de.intevation.artifacts.Artifact; import de.intevation.artifacts.ArtifactNamespaceContext; import de.intevation.artifacts.CallContext; @@ -280,12 +281,14 @@ * Describes the UI of the state. This method needs to be implemented by * concrete subclasses. * + * @param artifact A reference to the artifact this state belongs to. * @param document Describe doucment. * @param rootNode Parent node for all new elements. * @param context The CallContext. * @param uuid The uuid of an artifact. */ public abstract Element describe( + Artifact artifact, Document document, Node rootNode, CallContext context,
--- a/artifact-database/src/main/java/de/intevation/artifactdatabase/state/State.java Wed Apr 13 15:19:59 2011 +0000 +++ b/artifact-database/src/main/java/de/intevation/artifactdatabase/state/State.java Thu Apr 14 08:26:25 2011 +0000 @@ -15,6 +15,7 @@ import org.w3c.dom.Element; import org.w3c.dom.Node; +import de.intevation.artifacts.Artifact; import de.intevation.artifacts.CallContext; import de.intevation.artifactdatabase.data.StateData; @@ -83,12 +84,14 @@ * This method is called when an artifacts retrieves a describe request. It * creates the user interface description of the current state. * + * @param artifact A reference to the artifact this state belongs to. * @param document Describe doucment. * @param rootNode Parent node for all new elements. * @param context The CallContext. * @param uuid The uuid of an artifact. */ public Element describe( + Artifact artifact, Document document, Node rootNode, CallContext context,