diff --git a/src/main/java/org/rometools/feed/module/sle/types/DateValue.java b/src/main/java/org/rometools/feed/module/sle/types/DateValue.java index 1bd30b1..3966787 100644 --- a/src/main/java/org/rometools/feed/module/sle/types/DateValue.java +++ b/src/main/java/org/rometools/feed/module/sle/types/DateValue.java @@ -28,19 +28,16 @@ import com.sun.syndication.feed.impl.ObjectBean; * * @author Robert "kebernet" Cooper */ -public class DateValue implements EntryValue { +public class DateValue implements EntryValue { + private static final long serialVersionUID = 8864338943592633517L; - private Date value; + private final ObjectBean obj = new ObjectBean(DateValue.class, this); + private Date value; private String element; private String label; private Namespace namespace = Namespace.XML_NAMESPACE; - /** Creates a new instance of DateValue */ - public DateValue() { - super(); - } - /** * * @param element @@ -88,7 +85,7 @@ public class DateValue implements EntryValue { * @return */ @Override - public Comparable getValue() { + public Date getValue() { return value; } diff --git a/src/main/java/org/rometools/feed/module/sle/types/EntryValue.java b/src/main/java/org/rometools/feed/module/sle/types/EntryValue.java index 6a80986..dbe6a33 100644 --- a/src/main/java/org/rometools/feed/module/sle/types/EntryValue.java +++ b/src/main/java/org/rometools/feed/module/sle/types/EntryValue.java @@ -26,7 +26,7 @@ import org.jdom2.Namespace; * * @author Robert "kebernet" Cooper */ -public interface EntryValue extends Serializable, Cloneable { +public interface EntryValue> extends Serializable, Cloneable { /** * Returns the name of the element. * @@ -46,7 +46,7 @@ public interface EntryValue extends Serializable, Cloneable { * * @return Returns the value of the element. */ - public Comparable getValue(); + public T getValue(); /** * Returns the namespace of the element. diff --git a/src/main/java/org/rometools/feed/module/sle/types/NumberValue.java b/src/main/java/org/rometools/feed/module/sle/types/NumberValue.java index e905036..78a6aad 100644 --- a/src/main/java/org/rometools/feed/module/sle/types/NumberValue.java +++ b/src/main/java/org/rometools/feed/module/sle/types/NumberValue.java @@ -28,18 +28,16 @@ import com.sun.syndication.feed.impl.ObjectBean; * * @author Robert "kebernet" Cooper */ -public class NumberValue implements EntryValue { +public class NumberValue implements EntryValue { + private static final long serialVersionUID = 8043418996659222922L; - private BigDecimal value; + private final ObjectBean obj = new ObjectBean(NumberValue.class, this); + private BigDecimal value; private String element; private String label; private Namespace namespace = Namespace.XML_NAMESPACE; - /** Creates a new instance of NumberValue */ - public NumberValue() { - } - public void setElement(final String element) { this.element = element; } @@ -63,7 +61,7 @@ public class NumberValue implements EntryValue { } @Override - public Comparable getValue() { + public BigDecimal getValue() { return value; } diff --git a/src/main/java/org/rometools/feed/module/sle/types/StringValue.java b/src/main/java/org/rometools/feed/module/sle/types/StringValue.java index 7666222..8582868 100644 --- a/src/main/java/org/rometools/feed/module/sle/types/StringValue.java +++ b/src/main/java/org/rometools/feed/module/sle/types/StringValue.java @@ -26,18 +26,16 @@ import com.sun.syndication.feed.impl.ObjectBean; * * @author Robert "kebernet" Cooper */ -public class StringValue implements EntryValue { +public class StringValue implements EntryValue { + private static final long serialVersionUID = -8384073300710802173L; + private final ObjectBean obj = new ObjectBean(StringValue.class, this); private String element; private String label; private String value; private Namespace namespace = Namespace.XML_NAMESPACE; - /** Creates a new instance of StringValue */ - public StringValue() { - } - public void setElement(final String element) { this.element = element; } @@ -61,7 +59,7 @@ public class StringValue implements EntryValue { } @Override - public Comparable getValue() { + public String getValue() { return value; }