Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'org.eclipse.mylyn.reviews.core/src/org/eclipse/mylyn/reviews/internal/core/model/Comment.java')
-rw-r--r--org.eclipse.mylyn.reviews.core/src/org/eclipse/mylyn/reviews/internal/core/model/Comment.java10
1 files changed, 6 insertions, 4 deletions
diff --git a/org.eclipse.mylyn.reviews.core/src/org/eclipse/mylyn/reviews/internal/core/model/Comment.java b/org.eclipse.mylyn.reviews.core/src/org/eclipse/mylyn/reviews/internal/core/model/Comment.java
index 62f19ff3c..4af18a52b 100644
--- a/org.eclipse.mylyn.reviews.core/src/org/eclipse/mylyn/reviews/internal/core/model/Comment.java
+++ b/org.eclipse.mylyn.reviews.core/src/org/eclipse/mylyn/reviews/internal/core/model/Comment.java
@@ -314,11 +314,12 @@ public class Comment extends EObjectImpl implements IComment {
/**
* <!-- begin-user-doc --> <!-- end-user-doc -->
*
- * @generated
+ * @generated NOT
*/
public void setCreationDate(Date newCreationDate) {
Date oldCreationDate = creationDate;
- creationDate = newCreationDate;
+ //Protect against case where java.sql.Timestamp is used
+ creationDate = new Date(newCreationDate.getTime());
if (eNotificationRequired()) {
eNotify(new ENotificationImpl(this, Notification.SET, ReviewsPackage.COMMENT__CREATION_DATE,
oldCreationDate, creationDate));
@@ -337,11 +338,12 @@ public class Comment extends EObjectImpl implements IComment {
/**
* <!-- begin-user-doc --> <!-- end-user-doc -->
*
- * @generated
+ * @generated NOT
*/
public void setModificationDate(Date newModificationDate) {
Date oldModificationDate = modificationDate;
- modificationDate = newModificationDate;
+ //Protect against case where java.sql.Timestamp is used
+ modificationDate = new Date(newModificationDate.getTime());
if (eNotificationRequired()) {
eNotify(new ENotificationImpl(this, Notification.SET, ReviewsPackage.COMMENT__MODIFICATION_DATE,
oldModificationDate, modificationDate));

Back to the top