25개 이상의 토픽을 선택하실 수 없습니다. Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

20 lines
663 B

  1. using System;
  2. namespace MQTTnet.Extensions.ManagedClient
  3. {
  4. public class ApplicationMessageProcessedEventArgs : EventArgs
  5. {
  6. public ApplicationMessageProcessedEventArgs(ManagedMqttApplicationMessage applicationMessage, Exception exception)
  7. {
  8. ApplicationMessage = applicationMessage ?? throw new ArgumentNullException(nameof(applicationMessage));
  9. Exception = exception;
  10. }
  11. public ManagedMqttApplicationMessage ApplicationMessage { get; }
  12. public Exception Exception { get; }
  13. public bool HasFailed => Exception != null;
  14. public bool HasSucceeded => Exception == null;
  15. }
  16. }