-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
b5b31a8
commit 46fde97
Showing
10 changed files
with
272 additions
and
83 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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,19 +1,24 @@ | ||
using Vasconcellos.Common.Results.Enums; | ||
using System; | ||
using Vasconcellos.Common.Results.Enums; | ||
|
||
namespace Vasconcellos.Common.Results.Domain | ||
{ | ||
public class Error | ||
{ | ||
public Error(string code, string message, ErrorType type = ErrorType.BadDomain) | ||
public Error(string code, string message, ErrorStatus errorStatus = ErrorStatus.BadDomain) | ||
{ | ||
Code = code; | ||
Message = message; | ||
Type = type; | ||
ErrorStatus = errorStatus; | ||
Created = DateTime.UtcNow; | ||
} | ||
|
||
public string Code { get; } | ||
public string Message { get; } | ||
public ErrorType Type { get; } | ||
public ErrorStatus ErrorStatus { get; } | ||
|
||
private DateTime Created { get; } | ||
public DateTime GetCreationDate() => Created; | ||
} | ||
} | ||
|
Oops, something went wrong.