From 0b065e1e0547885294d03df54d178587d801a15a Mon Sep 17 00:00:00 2001 From: Vitaly Takmazov Date: Sat, 6 Oct 2018 23:02:14 +0300 Subject: store external reply uri --- juick-common/src/main/java/com/juick/Message.java | 10 ++++++++++ .../src/main/java/com/juick/service/MessagesService.java | 4 ++++ 2 files changed, 14 insertions(+) (limited to 'juick-common/src/main/java/com') diff --git a/juick-common/src/main/java/com/juick/Message.java b/juick-common/src/main/java/com/juick/Message.java index 212cb2fa..de419b9b 100644 --- a/juick-common/src/main/java/com/juick/Message.java +++ b/juick-common/src/main/java/com/juick/Message.java @@ -25,6 +25,7 @@ import org.apache.commons.lang3.builder.ToStringBuilder; import javax.xml.bind.annotation.*; import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter; +import java.net.URI; import java.time.Instant; import java.util.ArrayList; import java.util.HashSet; @@ -75,6 +76,7 @@ public class Message implements Comparable { @XmlTransient private Set reactions; private boolean service; + private URI replyUri; private Set recommendations; @@ -347,4 +349,12 @@ public class Message implements Comparable { public void setUpdatedAt(Instant updatedAt) { this.updatedAt = updatedAt; } + + public URI getReplyUri() { + return replyUri; + } + + public void setReplyUri(URI replyUri) { + this.replyUri = replyUri; + } } diff --git a/juick-common/src/main/java/com/juick/service/MessagesService.java b/juick-common/src/main/java/com/juick/service/MessagesService.java index 5a3ff30a..f80fe32f 100644 --- a/juick-common/src/main/java/com/juick/service/MessagesService.java +++ b/juick-common/src/main/java/com/juick/service/MessagesService.java @@ -17,10 +17,12 @@ package com.juick.service; +import com.juick.Message; import com.juick.Reaction; import com.juick.User; import com.juick.model.ResponseReply; +import java.net.URI; import java.util.Collection; import java.util.List; import java.util.Map; @@ -128,4 +130,6 @@ public interface MessagesService { List getUnread(User user); boolean updateMessage(Integer mid, Integer rid, String body); + + boolean updateReplyUri(Message reply, URI replyUri); } -- cgit v1.2.3