public void OnMessageSent(MessageEventArgs messageEventArgs) { var action = MessageSent; if (action != null) action(this, messageEventArgs); }