# HG changeset patch # User Ingo Weinzierl # Date 1300877887 0 # Node ID c8e651530f34a499a1c8446f28bd1e566f32349d # Parent faf565d22c9a5380afdf54a3dd3c306db75f5772 Added an interface and its default implementation to describe an output mode of an artifact. flys-client/trunk@1545 c6561f87-3c4e-4783-a992-168aeb5c3f6f diff -r faf565d22c9a -r c8e651530f34 flys-client/ChangeLog --- a/flys-client/ChangeLog Mon Mar 21 09:56:00 2011 +0000 +++ b/flys-client/ChangeLog Wed Mar 23 10:58:07 2011 +0000 @@ -1,3 +1,10 @@ +2011-03-23 Ingo Weinzierl + + * src/main/java/de/intevation/flys/client/shared/model/OutputMode.java, + src/main/java/de/intevation/flys/client/shared/model/DefaultOutputMode.java: + New. An interface and its default implementation that describes + available output modes of artifacts. + 2011-03-21 Ingo Weinzierl * src/main/webapp/images/next.xcf: Moved to images/next.xcf to avoid that diff -r faf565d22c9a -r c8e651530f34 flys-client/src/main/java/de/intevation/flys/client/shared/model/DefaultOutputMode.java --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/flys-client/src/main/java/de/intevation/flys/client/shared/model/DefaultOutputMode.java Wed Mar 23 10:58:07 2011 +0000 @@ -0,0 +1,54 @@ +package de.intevation.flys.client.shared.model; + + +/** + * The default implementation of an Output. + * + * @author Ingo Weinzierl + */ +public class DefaultOutputMode implements OutputMode { + + /** The name of this mode.*/ + protected String name; + + /** The description of this mode.*/ + protected String description; + + /** The mime-type of this mode.*/ + protected String mimeType; + + + /** A convinience constructor.*/ + public DefaultOutputMode() { + } + + + /** + * The default constructor. + * + * @param name The name of this mode. + * @param description The description of this mode. + * @param mimeType The mime-type of this mode. + */ + public DefaultOutputMode(String name, String description, String mimeType) { + this.name = name; + this.description = description; + this.mimeType = mimeType; + } + + + public String getName() { + return name; + } + + + public String getDescription() { + return description; + } + + + public String getMimeType() { + return mimeType; + } +} +// vim:set ts=4 sw=4 si et sta sts=4 fenc=utf8 : diff -r faf565d22c9a -r c8e651530f34 flys-client/src/main/java/de/intevation/flys/client/shared/model/OutputMode.java --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/flys-client/src/main/java/de/intevation/flys/client/shared/model/OutputMode.java Wed Mar 23 10:58:07 2011 +0000 @@ -0,0 +1,37 @@ +package de.intevation.flys.client.shared.model; + +import java.io.Serializable; + + +/** + * This interface describes an output mode of an artifact. + * + * @author Ingo Weinzierl + */ +public interface OutputMode extends Serializable { + + /** + * Retrieves the name of this mode. + * + * @return the name of this mode. + */ + String getName(); + + + /** + * Retrieves the description of this mode. + * + * @return the description of this mode. + */ + String getDescription(); + + + /** + * Retrieves the mime-type of this mode. + * + * + * @return the mime-type of this mode. + */ + String getMimeType(); +} +// vim:set ts=4 sw=4 si et sta sts=4 fenc=utf8 :