From: Roland Haeder <roland@mxchange.org>
Date: Thu, 24 Sep 2015 09:32:23 +0000 (+0200)
Subject: Temporal values don't like strings, good!
X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=58ecd41432017c9e2cfdf553be990aea61ef35d9;p=jcore.git

Temporal values don't like strings, good!
Signed-off-by:Roland Häder <roland@mxchange.org>
---

diff --git a/src/org/mxchange/jcore/model/contact/BaseContact.java b/src/org/mxchange/jcore/model/contact/BaseContact.java
index 530a64f..0f163b7 100644
--- a/src/org/mxchange/jcore/model/contact/BaseContact.java
+++ b/src/org/mxchange/jcore/model/contact/BaseContact.java
@@ -16,6 +16,7 @@
  */
 package org.mxchange.jcore.model.contact;
 
+import java.util.Calendar;
 import java.util.Date;
 import java.util.Objects;
 import javax.annotation.PostConstruct;
@@ -91,7 +92,7 @@ public abstract class BaseContact implements Contact, Comparable<Contact> {
 	@Basic(optional = false)
 	@Temporal (TemporalType.TIMESTAMP)
 	@Column(nullable = false)
-	private String created;
+	private Calendar created;
 
 	/**
 	 * Email address
@@ -161,7 +162,7 @@ public abstract class BaseContact implements Contact, Comparable<Contact> {
 	 * When the contact has been updated
 	 */
 	@Temporal (TemporalType.TIMESTAMP)
-	private String updated;
+	private Calendar updated;
 
 	/**
 	 * ZIP code
@@ -313,12 +314,12 @@ public abstract class BaseContact implements Contact, Comparable<Contact> {
 	}
 
 	@Override
-	public String getCreated () {
+	public Calendar getCreated () {
 		return this.created;
 	}
 
 	@Override
-	public void setCreated (final String created) {
+	public void setCreated (final Calendar created) {
 		this.created = created;
 	}
 
@@ -419,12 +420,12 @@ public abstract class BaseContact implements Contact, Comparable<Contact> {
 	}
 
 	@Override
-	public String getUpdated () {
+	public Calendar getUpdated () {
 		return this.updated;
 	}
 
 	@Override
-	public void setUpdated (final String updated) {
+	public void setUpdated (final Calendar updated) {
 		this.updated = updated;
 	}
 
diff --git a/src/org/mxchange/jcore/model/contact/Contact.java b/src/org/mxchange/jcore/model/contact/Contact.java
index f41d833..94f9b7f 100644
--- a/src/org/mxchange/jcore/model/contact/Contact.java
+++ b/src/org/mxchange/jcore/model/contact/Contact.java
@@ -17,6 +17,7 @@
 package org.mxchange.jcore.model.contact;
 
 import java.io.Serializable;
+import java.util.Calendar;
 import java.util.Date;
 import org.mxchange.jcore.model.contact.gender.Gender;
 
@@ -275,26 +276,26 @@ public interface Contact extends Serializable {
 	 *
 	 * @return "created" timestamp
 	 */
-	public String getCreated ();
+	public Calendar getCreated ();
 
 	/**
 	 * Setter for "created" timestamp
 	 *
 	 * @param created "created" timestamp
 	 */
-	public void setCreated (final String created);
+	public void setCreated (final Calendar created);
 
 	/**
 	 * Getter for "updated" timestamp
 	 *
 	 * @return "updated" timestamp
 	 */
-	public String getUpdated ();
+	public Calendar getUpdated ();
 
 	/**
 	 * Getter for "updated" timestamp
 	 *
 	 * @param updated "updated" timestamp
 	 */
-	public void setUpdated (final String updated);
+	public void setUpdated (final Calendar updated);
 }