void onConversationCreated(int requestId, Messages.ConvCommand convCommand) { String createdAt = convCommand.getCdate(); String cid = convCommand.getCid(); int tempTTL = convCommand.hasTempConvTTL()? convCommand.getTempConvTTL(): 0; // they are not necessary for create-callback(isTemp, isTransient), except for tempTTL. Bundle bundle = new Bundle(); bundle.putString(Conversation.callbackCreatedAt, createdAt); bundle.putString(Conversation.callbackConversationKey, cid); bundle.putInt(Conversation.callbackTemporaryTTL, tempTTL); BroadcastUtil.sendIMLocalBroadcast(session.getSelfPeerId(), conversationId, requestId, bundle, AVIMOperation.CONVERSATION_CREATION); }
getTempConv()); if (hasTempConvTTL()) { hash = (37 * hash) + TEMPCONVTTL_FIELD_NUMBER; hash = (53 * hash) + getTempConvTTL();
private AVIMConversation parseConversation(AVIMClient client, Messages.ConvCommand convCommand) { if (null == client || null == convCommand) { return null; } boolean isTemp = convCommand.hasTempConv()? convCommand.getTempConv() : false; boolean isTransient = convCommand.hasTransient()? convCommand.getTransient() : false; int tempTTL = convCommand.hasTempConvTTL()?convCommand.getTempConvTTL() : 0; AVIMConversation conversation = client.getConversation(this.conversationId, isTransient, isTemp); conversation.setTemporaryExpiredat(System.currentTimeMillis()/1000 + tempTTL); return conversation; }
setTempConv(other.getTempConv()); if (other.hasTempConvTTL()) { setTempConvTTL(other.getTempConvTTL());
== other.getTempConv()); result = result && (hasTempConvTTL() == other.hasTempConvTTL()); if (hasTempConvTTL()) { result = result && (getTempConvTTL() == other.getTempConvTTL());