Search in sources :

Example 1 with DeleteMessageContent

use of com.fanap.podchat.model.DeleteMessageContent in project pod-chat-android-sdk by FanapSoft.

the class MessageManager method prepareDeleteMessageResponseForFind.

public static ChatResponse<ResultDeleteMessage> prepareDeleteMessageResponseForFind(MessageVO msg, String uniqueId, long threadId) {
    ChatResponse<ResultDeleteMessage> chatResponse = new ChatResponse<>();
    chatResponse.setUniqueId(uniqueId);
    ResultDeleteMessage resultDeleteMessage = new ResultDeleteMessage();
    DeleteMessageContent deleteMessage = new DeleteMessageContent();
    deleteMessage.setId(msg.getId());
    resultDeleteMessage.setDeletedMessage(deleteMessage);
    chatResponse.setResult(resultDeleteMessage);
    chatResponse.setSubjectId(threadId);
    return chatResponse;
}
Also used : ChatResponse(com.fanap.podchat.model.ChatResponse) ResultDeleteMessage(com.fanap.podchat.mainmodel.ResultDeleteMessage) DeleteMessageContent(com.fanap.podchat.model.DeleteMessageContent)

Example 2 with DeleteMessageContent

use of com.fanap.podchat.model.DeleteMessageContent in project pod-chat-android-sdk by FanapSoft.

the class MessageManager method prepareDeleteMessageResponse.

public static ChatResponse<ResultDeleteMessage> prepareDeleteMessageResponse(ChatMessage chatMessage, long messageId) {
    ChatResponse<ResultDeleteMessage> chatResponse = new ChatResponse<>();
    chatResponse.setUniqueId(chatMessage.getUniqueId());
    ResultDeleteMessage resultDeleteMessage = new ResultDeleteMessage();
    DeleteMessageContent deleteMessage = new DeleteMessageContent();
    deleteMessage.setId(messageId);
    resultDeleteMessage.setDeletedMessage(deleteMessage);
    chatResponse.setResult(resultDeleteMessage);
    chatResponse.setSubjectId(chatMessage.getSubjectId());
    return chatResponse;
}
Also used : ChatResponse(com.fanap.podchat.model.ChatResponse) ResultDeleteMessage(com.fanap.podchat.mainmodel.ResultDeleteMessage) DeleteMessageContent(com.fanap.podchat.model.DeleteMessageContent)

Aggregations

ResultDeleteMessage (com.fanap.podchat.mainmodel.ResultDeleteMessage)2 ChatResponse (com.fanap.podchat.model.ChatResponse)2 DeleteMessageContent (com.fanap.podchat.model.DeleteMessageContent)2