Beispiel #1
0
        public void Send(string message)
        {
            var     msg      = APIHelpers.DeserializeResponse(message);
            dynamic response = null;

            if (msg.action == "subscribe")
            {
                // Fake subscription success
                response = new { status = APIHelpers.GetEnumDescription(DataSiftMessageStatus.Success), hash = msg.hash };
            }

            MessageReceived(this, new WebSocket4Net.MessageReceivedEventArgs(JsonConvert.SerializeObject(response)));
        }