public void sendUnreadMessagesAck(ArrayList<AVIMMessage> messages, String conversationId) {
    if (AVIMOptions.getGlobalOptions().isOnlyPushCount() && null != messages && messages.size() > 0) {
      Long largestTimeStamp = 0L;
      for (AVIMMessage message : messages) {
        if (largestTimeStamp < message.getTimestamp()) {
          largestTimeStamp = message.getTimestamp();
        }
      }
      AVConnectionManager.getInstance().sendPacket(ConversationAckPacket.getConversationAckPacket(getSelfPeerId(),
              conversationId, largestTimeStamp));
    }
  }
public void sendUnreadMessagesAck ( ArrayList < AVIMMessage > messages , String conversationId ) { if ( AVIMOptions . getGlobalOptions ( ) . isOnlyPushCount ( ) && null != messages && messages . size ( ) > 0 ) { Long largestTimeStamp = 0L ; for ( AVIMMessage message : messages ) { if ( largestTimeStamp < message . getTimestamp ( ) ) { largestTimeStamp = message . getTimestamp ( ) ; } } AVConnectionManager . getInstance ( ) . sendPacket ( ConversationAckPacket . getConversationAckPacket ( getSelfPeerId ( ) , conversationId , largestTimeStamp ) ) ; } }
确认客户端已经拉取到未推送到本地的离线消息
因为没有办法判断哪些消息是离线消息，所以对所有拉取到的消息都发送 ack
@param messages
@param conversationId