Hi,
I am trying to send multiple bodies in “one” message using Smack. The message content seem to be fine in the sender side, however checking the raw packets shows that only one of the bodies is sent to the receiver. Has anyone successfully tried to send multiple bodies in one message using Smack?
Below is the code snippet and the packets.
Thank you,
- SmackUser
++++++++++++++++++++++++++++++++++++++++++++++++++++++++
…
message.addBody("en", "first body");
message.addBody("en", "second body");
message.addBody("en", "third body");
bodies = message.getBodies();
**for** (Object body1 : bodies) {
Message.Body body = (Message.Body) body1;
System.*out*.println("\tBody : "+ body.getMessage());
}
myMUC.sendMessage(message);
…
The sender’s side code correctly prints:
Body : first body
Body : third body
Body : second body
But the receiver gets only one body and only the following raw packets are sent from the sender:
MultiTextMessagesfirst body