sequence.setLastMessage(new LastMessage(rmNamespaceValue));
}
}
}
AckRequested ackRequested = null;
boolean addAckRequested = false;
// if (!lastMessage)
// addAckRequested = true; //TODO decide the policy to add the
// ackRequested tag
// setting the Sequnece id.
// Set send = true/false depending on the availability of the out
// sequence id.
String identifierStr = null;
if (outSequenceBean == null || outSequenceBean.getValue() == null) {
identifierStr = Sandesha2Constants.TEMP_SEQUENCE_ID;
} else {
identifierStr = outSequenceBean.getValue();
}
Identifier id1 = new Identifier(rmNamespaceValue);
id1.setIndentifer(identifierStr);
sequence.setIdentifier(id1);
rmMsg.setMessagePart(Sandesha2Constants.MessageParts.SEQUENCE, sequence);
if (addAckRequested) {
ackRequested = new AckRequested(rmNamespaceValue);
Identifier id2 = new Identifier(rmNamespaceValue);
id2.setIndentifer(identifierStr);
ackRequested.setIdentifier(id2);
rmMsg.setMessagePart(Sandesha2Constants.MessageParts.ACK_REQUEST, ackRequested);
}
rmMsg.addSOAPEnvelope();