Xeption 2.8.0
dotnet add package Xeption --version 2.8.0
NuGet\Install-Package Xeption -Version 2.8.0
<PackageReference Include="Xeption" Version="2.8.0" />
paket add Xeption --version 2.8.0
#r "nuget: Xeption, 2.8.0"
// Install Xeption as a Cake Addin #addin nuget:?package=Xeption&version=2.8.0 // Install Xeption as a Cake Tool #tool nuget:?package=Xeption&version=2.8.0
Xeption
A Better Exception for .NET
This simple library is engineered to expose a new API for the standard .NET Exception
model, allowing you to insert a list of values against a key in the Data
property of that very exception.
The Purpose
This library allows .NET engineers to easily collect errors for any given flow or attribute before throwing an exception.
This new API simplifies the process of appending and allows access to the Data
aspect of any exception to collect errors at any time.
The key value implementation for the Data
attribute should simplify the way engineers represent errors related to the same issue, attribute, or value, such as validation errors, without any additional workaround code.
Standard-Promise
A Standard complaint system's most important fulfillment aspect is contributing to people, its evolution, and its principles. An organization that systematically honors an environment of learning, training, and sharing knowledge is an organization that learns from the past, makes calculated risks for the future, and brings everyone within it up to speed on the current state of things as honestly, rapidly, and efficiently as possible.
We believe that everyone has the right to privacy and will never do anything that could violate that right. We are committed to writing ethical and responsible software and will always strive to use our skills, coding, and systems for the good. These beliefs will help ensure that our software(s) are safe and secure and that it will never be used to harm or collect personal data for malicious purposes.
As a promise to you, the Standard Community upholds these values.
How to Use
To use Xeption, all you need to do is inherit the Xeption
model to your local Exception models as follows:
Setup
public class MyLocalException: Xeption
{
// ...
}
Adding Values
To add values to your Xeption
inheriting class, you must call .UpsertDataList(key, value)
API to add more values to the dictionary as follows:
var myLocalException = new MyLocalException();
myLocalException.UpsertDataList(key: "MyKey", value: "MyValue");
Throwing If Contains Errors
Xeption also allows the ability to throw the local exception if the data dictionary contains values. You can call that API from your local instance as follows:
myLocalException.ThrowIfContainsErrors();
Native APIs
Xeption will maintain the native APIs for the Exception
native class.
var xeption = new Xeption();
var xeptionWithMessage = new Xeption(message: "Some Message");
var xeptionWithInnerException = new Xeption(
message: "Some Message",
innerException: someInnerException);
If you have any suggestions, comments, or questions, please feel free to contact me at:
Important Notice
Special thanks to all the contributors, and a very special thanks to Mr. Hassan Habib and Mr. Christo du Toit for their continued dedication.
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | net5.0 was computed. net5.0-windows was computed. net6.0 was computed. net6.0-android was computed. net6.0-ios was computed. net6.0-maccatalyst was computed. net6.0-macos was computed. net6.0-tvos was computed. net6.0-windows was computed. net7.0 was computed. net7.0-android was computed. net7.0-ios was computed. net7.0-maccatalyst was computed. net7.0-macos was computed. net7.0-tvos was computed. net7.0-windows was computed. net8.0 was computed. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. |
.NET Core | netcoreapp2.0 was computed. netcoreapp2.1 was computed. netcoreapp2.2 was computed. netcoreapp3.0 was computed. netcoreapp3.1 was computed. |
.NET Standard | netstandard2.0 is compatible. netstandard2.1 is compatible. |
.NET Framework | net461 was computed. net462 was computed. net463 was computed. net47 was computed. net471 was computed. net472 was computed. net48 was computed. net481 was computed. |
MonoAndroid | monoandroid was computed. |
MonoMac | monomac was computed. |
MonoTouch | monotouch was computed. |
Tizen | tizen40 was computed. tizen60 was computed. |
Xamarin.iOS | xamarinios was computed. |
Xamarin.Mac | xamarinmac was computed. |
Xamarin.TVOS | xamarintvos was computed. |
Xamarin.WatchOS | xamarinwatchos was computed. |
-
.NETStandard 2.0
- DeepCloner (>= 0.10.4)
- FluentAssertions (>= 6.5.1)
- System.Linq (>= 4.3.0)
-
.NETStandard 2.1
- DeepCloner (>= 0.10.4)
- FluentAssertions (>= 6.5.1)
- System.Linq (>= 4.3.0)
NuGet packages (24)
Showing the top 5 NuGet packages that depend on Xeption:
Package | Downloads |
---|---|
RESTFulSense
RESTFul Integration w/ Love <3 |
|
ADotNet
ADotNet is a dot net library to help engineers develop their build and release pipelines in C# without having to use YAML or any other technology. |
|
RESTFulSense.WebAssembly
RESTFul Integration w/ Love <3 |
|
NEL.MESH
.NET Client To Send And Recieve MESH messages |
|
Standardly.Core
A Template Engine For Generating Standard Compliant Code |
GitHub repositories (3)
Showing the top 3 popular GitHub repositories that depend on Xeption:
Repository | Stars |
---|---|
hassanhabib/OtripleS
This is an open source schooling system, dedicated to provide a better experience for schools needing a management and communication and tutoring system all in one place. This project is aiming toward directing all the software development funds and hours to families in need, the idea of the project is to allow schools to use the system as long as the software funds in the school are directed towards financially disadvantaged families and students.
|
|
hassanhabib/RESTFulSense
A RESTFul operations client that serializes responses and throws meaningful exceptions for >= 400 status codes.
|
|
OData/OData.Neo
|
Version | Downloads | Last updated |
---|---|---|
2.8.0 | 12,058 | 7/25/2024 |
2.6.0 | 39,415 | 10/11/2023 |
2.5.0 | 209,956 | 10/26/2022 |
2.4.0 | 28,858 | 6/15/2022 |
2.3.0 | 920 | 6/6/2022 |
2.2.0 | 4,958 | 3/8/2022 |
2.1.0 | 442 | 3/8/2022 |
2.0.0 | 416 | 3/7/2022 |
1.7.0 | 26,640 | 11/12/2021 |
1.6.0 | 22,463 | 9/9/2021 |
1.5.0 | 383 | 9/8/2021 |
1.4.0 | 377 | 9/8/2021 |
1.3.0 | 3,122 | 9/6/2021 |
1.2.0 | 355 | 9/5/2021 |
1.1.0 | 367 | 9/5/2021 |
1.0.0 | 419 | 9/5/2021 |
Addition of a SameExceptionAs overload that can provide detail on differences.
Aggregate exception support.