From: Roland Haeder Date: Fri, 18 Sep 2015 06:49:49 +0000 (+0200) Subject: updated fields created and updated X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=b16fd8af48882de3f73eaabac07b66c1ef09df59;p=jcore.git updated fields created and updated Signed-off-by:Roland Häder --- diff --git a/src/org/mxchange/jcore/model/contact/BaseContact.java b/src/org/mxchange/jcore/model/contact/BaseContact.java index f978e67..0fb4d49 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.sql.Timestamp; import java.util.Objects; import org.mxchange.jcore.client.Client; import org.mxchange.jcore.model.contact.gender.Gender; @@ -26,12 +27,17 @@ import org.mxchange.jcore.model.contact.gender.Gender; * @author Roland Haeder * @version 0.0 */ -public abstract class BaseContact implements Contact, Comparable { +public class BaseContact implements Contact, Comparable { /** * Serial number */ private static final long serialVersionUID = 58_744_284_981_863L; + /** + * When the contact has been created + */ + private Timestamp created; + /** * Id number */ @@ -112,6 +118,11 @@ public abstract class BaseContact implements Contact, Comparable { */ private String street; + /** + * When the contact has been updated + */ + private Timestamp updated; + /** * ZIP code */ @@ -253,6 +264,16 @@ public abstract class BaseContact implements Contact, Comparable { this.companyName = companyName; } + @Override + public Timestamp getCreated () { + return this.created; + } + + @Override + public void setCreated (final Timestamp created) { + this.created = created; + } + /** * Id number * @return the id @@ -452,6 +473,16 @@ public abstract class BaseContact implements Contact, Comparable { this.street = street; } + @Override + public Timestamp getUpdated () { + return this.updated; + } + + @Override + public void setUpdated (final Timestamp updated) { + this.updated = updated; + } + /** * ZIP code * diff --git a/src/org/mxchange/jcore/model/contact/Contact.java b/src/org/mxchange/jcore/model/contact/Contact.java index 15d497e..33fbe37 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.sql.Timestamp; import org.mxchange.jcore.model.contact.gender.Gender; /** @@ -260,4 +261,32 @@ public interface Contact extends Serializable { * @param ownContact Own contact */ public void setOwnContact (final Boolean ownContact); + + /** + * Getter for "created" timestamp + * + * @return "created" timestamp + */ + public Timestamp getCreated (); + + /** + * Setter for "created" timestamp + * + * @param created "created" timestamp + */ + public void setCreated (final Timestamp created); + + /** + * Getter for "updated" timestamp + * + * @return "updated" timestamp + */ + public Timestamp getUpdated (); + + /** + * Getter for "updated" timestamp + * + * @param updated "updated" timestamp + */ + public void setUpdated (final Timestamp updated); }