Exemple #1
0
 /// <summary>
 /// Raises the <see cref="CommandSent"/> event with passed data.
 /// </summary>
 /// <param name="message">NMDC-message that represents the <paramref name="command"/>.</param>
 /// <param name="command">Sent command.</param>
 private void OnCommandSent(string message, NmdcCommand command)
 {
     CommandSent?.Invoke(this, new NmdcCommandTransferredArgs(DateTime.Now, message, command));
 }
 /// <summary>
 /// Initializes a new instance of the <see cref="NmdcCommandTransferredArgs"/> class to the specified time,
 /// message and command.
 /// </summary>
 /// <param name="time">The time when the command was received or sent.</param>
 /// <param name="message">In case of the <see cref="NmdcHubConnection.CommandReceived"/> event - original NMDC-message
 /// the <see cref="Command"/> was constructed from; in case of the <see cref="NmdcHubConnection.CommandSent"/> event -
 /// NMDC-message that represents the <see cref="Command"/>.</param>
 /// <param name="command">The command was received or sent via an instance of the <see cref="NmdcHubConnection"/> class.</param>
 public NmdcCommandTransferredArgs(DateTime time, string message, NmdcCommand command)
 {
     Time    = time;
     Message = message;
     Command = command;
 }
Exemple #3
0
 /// <summary>
 /// Raises the <see cref="CommandSent"/> event with passed data.
 /// </summary>
 /// <param name="message">NMDC-message that represents the <paramref name="command"/>.</param>
 /// <param name="command">Sent command.</param>
 private void OnCommandSent(string message, NmdcCommand command)
 {
     CommandSent?.Invoke(this, new NmdcCommandTransferredArgs(DateTime.Now, message, command));
 }