void InvokeNewMessageRecieved(string Message) { ReceiveCloudToDeviceMessageAsync(); if (NewMessageRecieved != null) { NewMessageRecieved.Invoke(this, Message); } }
private bool ReadChatCommand(IrcLocalUser user, IrcMessageEventArgs eventArgs) { var line = eventArgs.Text; if (line.Length > 1) { var userMessage = new UserMessage(eventArgs.Source.Name, line); NewMessageRecieved?.Invoke(this, new NewMessageEventArgs(userMessage, user) { }); return(true); } return(false); }
private void SendTheMessageToRemoteHost(string host, string message) { var e = new NewMessageRecievedEventHandlerArgs(message); NewMessageRecieved?.Invoke(typeof(SpectraWayNLogTarget), e); }
internal void RecieveNewMessage(Message message) { NewMessageRecieved?.Invoke( this, new RecievedMessageEventArgs(message, RemoteEndPoint)); }