Ejemplo n.º 1
0
 /// <summary>Initializes a new instance of the <see cref="RpcFailureException"></see> class with a specified error message and a reference to the inner exception that is the cause of this exception.</summary>
 /// <param name="message">The error message that explains the reason for the exception.</param>
 /// <param name="innerException">The exception that is the cause of the current exception, or a null reference (Nothing in Visual Basic) if no inner exception is specified.</param>
 public RpcFailureException(RpcFailure failure, string message, Exception innerException) : base(message, innerException)
 {
     this.Failure = failure;
 }
Ejemplo n.º 2
0
 /// <summary>Initializes a new instance of the <see cref="RpcFailureException"></see> class.</summary>
 public RpcFailureException(RpcFailure failure) : base($"RPC failure '{failure}' has occured.")
 {
     this.Failure = failure;
 }
Ejemplo n.º 3
0
 /// <summary>Initializes a new instance of the <see cref="RpcFailureException"></see> class with a specified error message.</summary>
 /// <param name="message">The message that describes the error.</param>
 public RpcFailureException(RpcFailure failure, string message) : base(message)
 {
     this.Failure = failure;
 }
Ejemplo n.º 4
0
 /// <summary>
 /// Creates a new result for the given command ID after failed execution, using
 /// the given failure reason.
 /// </summary>
 public static RpcCommandResult FromFailure(ulong commandID, RpcFailure failure) =>
 new RpcCommandResult(commandID)
 {
     Failure = failure
 };