public class MyBinMessage : RemObjects.SDK.BinMessage
{
public override String DefaultDispatcherName
{
get
{
return "binenv";
}
}
}
var binMessageNoEnvelope = new BinMessage();
var binMessageWithEnvelope = new MyBinMessage();
channel.Dispatchers.Add(new MessageDispatcher("bin", binMessageNoEnvelope));
channel.Dispatchers.Add(new MessageDispatcher("binenv", binMessageWithEnvelope));
server.NetworkServer.RegisterServerMessage(binMessageNoEnvelope);
server.NetworkServer.RegisterServerMessage(binMessageWithEnvelope);
I still have one question about enveloped messages.
I am using multiple envelopes for the same endpoint. I understand the receiving end can automatically choose the correct implementation. But how do I select the envelope when I am sending the data. Will the response be in the same envelope or will the server (answering side) choose the envelope based on some own rule?