-
Notifications
You must be signed in to change notification settings - Fork 27
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #36 from RockLib/error
Add error event to receiver interface
- Loading branch information
Showing
5 changed files
with
62 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
using System; | ||
|
||
namespace RockLib.Messaging | ||
{ | ||
/// <summary> | ||
/// Provides data for the <see cref="IReceiver.Error"/> event. | ||
/// </summary> | ||
public class ErrorEventArgs : EventArgs | ||
{ | ||
/// <summary> | ||
/// Initializes a new instance of the <see cref="ErrorEventArgs"/> class. | ||
/// </summary> | ||
/// <param name="message">A message the describes the error.</param> | ||
/// <param name="exception">The exception responsible for the error.</param> | ||
public ErrorEventArgs(string message, Exception exception) | ||
{ | ||
Message = message; | ||
Exception = exception; | ||
} | ||
|
||
/// <summary> | ||
/// Gets the message that describes the error. | ||
/// </summary> | ||
public string Message { get; } | ||
|
||
/// <summary> | ||
/// Gets the exception responsible for the error. | ||
/// </summary> | ||
public Exception Exception { get; } | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters