Mercurial > dive4elements > river
view flys-artifacts/src/main/java/de/intevation/flys/artifacts/model/AnnotationFacet.java @ 1058:c37084f31c84
Implemented a MapInfo service that returns some basic information to create maps for specific rivers.
flys-artifacts/trunk@2528 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author | Ingo Weinzierl <ingo.weinzierl@intevation.de> |
---|---|
date | Tue, 23 Aug 2011 07:53:41 +0000 |
parents | a39511688679 |
children | b1b0a0b61845 |
line wrap: on
line source
package de.intevation.flys.artifacts.model; import org.apache.log4j.Logger; import de.intevation.artifacts.Artifact; import de.intevation.artifacts.CallContext; import de.intevation.flys.artifacts.AnnotationArtifact; import de.intevation.artifactdatabase.state.DefaultFacet; /** * Facet to access Annotations of a river. */ public class AnnotationFacet extends DefaultFacet { /** Logger for this class. */ private static final Logger logger = Logger.getLogger(AnnotationFacet.class); /** * Trivial Constructor for a AnnotationFacet. * * @param index Database-Index to use. * @param name Name (~type) of Facet. * @param description Description of Facet. */ public AnnotationFacet(int index, String name, String description) { super(index, name, description); } /** * Get List of Annotations for river from Artifact. * * @param artifact (Annotation-)Artifact to query for list of Annotations. * @param context Ignored. */ @Override public Object getData(Artifact artifact, CallContext context) { AnnotationArtifact annotationArtifact = (AnnotationArtifact) artifact; return annotationArtifact.getAnnotations(); } }