Search in sources :

Example 6 with RequestUploadImage

use of com.fanap.podchat.requestobject.RequestUploadImage in project pod-chat-android-sdk by FanapSoft.

the class ChatActivity method createThreadWithMessage.

private void createThreadWithMessage() {
    List<Invitee> invite = new ArrayList<>();
    invite.add(new Invitee(1151568, InviteType.Constants.TO_BE_USER_CONTACT_ID));
    invite.add(new Invitee(1512305, InviteType.Constants.TO_BE_USER_CONTACT_ID));
    RequestUploadImage requestUploadThreadImageImage = new RequestUploadImage.Builder(ChatActivity.this, getUri()).setwC(140).sethC(140).build();
    RequestThreadInnerMessage message = new RequestThreadInnerMessage.Builder("Hi at " + new Date().toString(), TextMessageType.Constants.TEXT).build();
    RequestCreateThread requestCreateThread = new RequestCreateThread.Builder(ThreadType.Constants.OWNER_GROUP, invite).message(message).setUploadThreadImageRequest(requestUploadThreadImageImage).build();
    presenter.createThreadWithMessage(requestCreateThread);
}
Also used : Invitee(com.fanap.podchat.mainmodel.Invitee) RequestUploadImage(com.fanap.podchat.requestobject.RequestUploadImage) RequestThreadInnerMessage(com.fanap.podchat.mainmodel.RequestThreadInnerMessage) ArrayList(java.util.ArrayList) RequestCreateThread(com.fanap.podchat.requestobject.RequestCreateThread) Date(java.util.Date)

Aggregations

RequestUploadImage (com.fanap.podchat.requestobject.RequestUploadImage)6 ArrayList (java.util.ArrayList)4 Invitee (com.fanap.podchat.mainmodel.Invitee)3 RequestCreateThread (com.fanap.podchat.requestobject.RequestCreateThread)3 GsonBuilder (com.google.gson.GsonBuilder)2 Date (java.util.Date)2 ProgressHandler (com.fanap.podchat.ProgressHandler)1 Inviter (com.fanap.podchat.mainmodel.Inviter)1 RequestThreadInnerMessage (com.fanap.podchat.mainmodel.RequestThreadInnerMessage)1 ErrorOutPut (com.fanap.podchat.model.ErrorOutPut)1 ResultFile (com.fanap.podchat.model.ResultFile)1 ResultImageFile (com.fanap.podchat.model.ResultImageFile)1 ResultThread (com.fanap.podchat.model.ResultThread)1 RequestCreateThreadWithFile (com.fanap.podchat.requestobject.RequestCreateThreadWithFile)1 RequestFileMessage (com.fanap.podchat.requestobject.RequestFileMessage)1 RequestUploadFile (com.fanap.podchat.requestobject.RequestUploadFile)1 PodThreadManager (com.fanap.podchat.util.PodThreadManager)1