Proxier 1.3.25
See the version list below for details.
dotnet add package Proxier --version 1.3.25
NuGet\Install-Package Proxier -Version 1.3.25
<PackageReference Include="Proxier" Version="1.3.25" />
paket add Proxier --version 1.3.25
#r "nuget: Proxier, 1.3.25"
// Install Proxier as a Cake Addin #addin nuget:?package=Proxier&version=1.3.25 // Install Proxier as a Cake Tool #tool nuget:?package=Proxier&version=1.3.25
<div align="center"> <a href="https://github.com/MahApps/MahApps.Metro"> <img alt="MahApps.Metro" width="200" heigth="200" src="https://image.flaticon.com/icons/svg/51/51650.svg"> </a> <h1>Proxier</h1>
Introduction âšī¸
Have you ever had a class that is generated during the build process or at runtime but you need to add attributes to it? This is the solution! You can add attributes and even properties to classes at runtime by defining an extension class!
Features
- đąâđ¤ Out of the box support for Ninject!
- đ 0 configuration time, just start using.
- âšī¸ Semantic extensions, easy to use.
- .NET Core support
Code Samples âī¸
Say that you are using NSwag to generate swagger based classes, but they change a lot and you are worried that you forget to add some attributes to it and decide to use this library:
First you'll install the NuGet package
Install-Package Proxier
Then you'll create a extension class like so:
public class MyClassExtension : AttributeMapper<MyClass> {
public MyClassExtension(){
//Here you can add any class attributes, properties attributes and even properties!
AddPropertyAttribute(u => u.Business, () => new MyAttribute());
AddProperty("MyProperty", typeof(string));
AddClassAttribute(() => new MyAttribute());
}
}
and then these properties will be added to a static mapper list, the Mapper.TypesOverrides
with all the current extensions. To convert a object from the "MyClass" type to the injected type you would call:
typeof(MyClass).GetInjectedType();
To get a injected object you can use:
var InjectedMyClassObject = MyClassObject.GetInjectedObject();
Note that you can convert the inject object back to the original type by calling
InjectedMyClassObject.CopyTo(MyClassObject);
and all the common properties will be overriden by the ones on the injected type.
Dependency Injection
You can pass a Kernel to the Mapper initializer like this:
Mapper.InitializeMapperClasses(MyNinjectKernel);
and use the default [Inject]
attribute from Ninject to get properties inside the extension class which in turn can add those into its current extended type.
Built With đ§
- AttributeBuilder - Used to generate attributes, converted to .NET Standard
License đ
This project is licensed under the MIT License - see the LICENSE.md file for details
This documentation is incomplete and may change overtime.
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 was computed. |
.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
- AttributeBuilder.Standard (>= 1.3.25)
- Microsoft.Extensions.DependencyModel (>= 2.0.4)
- Ninject (>= 3.3.4)
- System.Linq (>= 4.3.0)
- System.Linq.Expressions (>= 4.3.0)
- System.Reflection.Emit (>= 4.3.0)
- System.Reflection.Emit.ILGeneration (>= 4.3.0)
- System.Reflection.Primitives (>= 4.3.0)
- System.Runtime (>= 4.3.0)
- System.Runtime.Loader (>= 4.3.0)
NuGet packages (1)
Showing the top 1 NuGet packages that depend on Proxier:
Package | Downloads |
---|---|
WpfMaterialForms
Dynamically generated forms and dialogs in WPF |
GitHub repositories (1)
Showing the top 1 popular GitHub repositories that depend on Proxier:
Repository | Stars |
---|---|
WPF-Forge/Forge.Forms
Dynamically generated forms and dialogs in WPF
|
Version | Downloads | Last updated |
---|---|---|
1.7.3 | 4,833 | 11/13/2020 |
1.7.2 | 15,183 | 9/24/2019 |
1.7.1 | 579 | 9/24/2019 |
1.7.0 | 777 | 7/15/2019 |
1.6.27 | 852 | 4/26/2019 |
1.6.26 | 670 | 4/26/2019 |
1.6.25 | 739 | 2/4/2019 |
1.6.24 | 755 | 12/31/2018 |
1.6.23 | 771 | 9/25/2018 |
1.6.22 | 753 | 9/25/2018 |
1.6.21 | 751 | 9/25/2018 |
1.6.20 | 1,112 | 7/12/2018 |
1.6.19 | 880 | 6/4/2018 |
1.6.18 | 1,012 | 6/1/2018 |
1.6.17 | 986 | 6/1/2018 |
1.6.16 | 987 | 5/28/2018 |
1.6.15 | 1,015 | 5/27/2018 |
1.6.14 | 973 | 5/27/2018 |
1.6.13 | 941 | 5/27/2018 |
1.6.12 | 926 | 5/18/2018 |
1.6.11 | 1,011 | 5/13/2018 |
1.6.10 | 996 | 5/13/2018 |
1.6.9 | 942 | 5/11/2018 |
1.6.8 | 861 | 5/11/2018 |
1.6.7 | 876 | 5/11/2018 |
1.6.6 | 981 | 5/11/2018 |
1.6.5 | 948 | 5/11/2018 |
1.6.4 | 945 | 5/11/2018 |
1.6.3 | 961 | 5/7/2018 |
1.6.1 | 1,073 | 5/4/2018 |
1.6.0 | 1,025 | 5/4/2018 |
1.5.16 | 1,017 | 5/4/2018 |
1.5.15 | 1,022 | 5/4/2018 |
1.5.8 | 1,057 | 3/21/2018 |
1.5.7 | 1,176 | 1/23/2018 |
1.5.6 | 1,186 | 1/19/2018 |
1.5.5 | 968 | 1/18/2018 |
1.5.4 | 1,012 | 1/18/2018 |
1.5.2 | 1,015 | 1/18/2018 |
1.5.1 | 972 | 1/14/2018 |
1.4.7 | 870 | 1/12/2018 |
1.4.6 | 1,114 | 1/12/2018 |
1.4.5 | 1,080 | 1/12/2018 |
1.4.4 | 1,067 | 1/12/2018 |
1.4.3 | 977 | 1/12/2018 |
1.4.2 | 966 | 1/12/2018 |
1.3.42 | 984 | 1/12/2018 |
1.3.37 | 891 | 1/12/2018 |
1.3.36 | 993 | 1/12/2018 |
1.3.35 | 948 | 1/12/2018 |
1.3.34 | 962 | 1/11/2018 |
1.3.31 | 858 | 1/11/2018 |
1.3.30 | 878 | 1/11/2018 |
1.3.29 | 960 | 1/11/2018 |
1.3.28 | 1,011 | 1/11/2018 |
1.3.27 | 1,071 | 1/9/2018 |
1.3.26 | 1,028 | 1/5/2018 |
1.3.25 | 1,222 | 1/2/2018 |
1.3.24 | 957 | 1/2/2018 |
1.3.22 | 1,056 | 1/2/2018 |
1.3.21 | 948 | 1/2/2018 |
1.3.19 | 1,028 | 1/2/2018 |
1.3.18 | 1,065 | 12/28/2017 |
1.3.17 | 2,114 | 12/28/2017 |
1.3.14 | 1,075 | 12/28/2017 |
1.3.13 | 1,031 | 12/28/2017 |
1.3.12 | 1,086 | 12/28/2017 |
1.3.11 | 1,000 | 12/28/2017 |
1.3.10 | 1,172 | 12/27/2017 |
1.3.9 | 1,070 | 12/27/2017 |
1.3.8 | 1,067 | 12/26/2017 |
1.3.7 | 1,041 | 12/26/2017 |
1.2.0 | 1,030 | 12/26/2017 |
1.1.0-CI-20171226-221311 | 858 | 12/26/2017 |
1.1.0-CI-20171226-194624 | 852 | 12/26/2017 |
1.1.0-CI-20171226-193711 | 899 | 12/26/2017 |
1.1.0-CI-20171226-192301 | 879 | 12/26/2017 |
1.0.0 | 1,121 | 12/26/2017 |
1.0.0-CI-20171226-190923 | 795 | 12/26/2017 |
1.0.0-CI-20171226-190646 | 820 | 12/26/2017 |
1.0.0-CI-20171226-185857 | 836 | 12/26/2017 |
1.0.0-CI-20171226-101027 | 776 | 12/26/2017 |
1.0.0-CI-20171226-100435 | 924 | 12/26/2017 |
1.0.0-CI-20171226-010925 | 797 | 12/26/2017 |
1.0.0-CI-20171226-001129 | 830 | 12/26/2017 |
1.0.0-CI-20171226-000814 | 821 | 12/26/2017 |
1.0.0-CI-20171225-234201 | 846 | 12/25/2017 |
1.0.0-CI-20171225-233342 | 830 | 12/25/2017 |
1.0.0-CI-20171225-152215 | 822 | 12/25/2017 |
1.0.0-CI-20171225-151907 | 778 | 12/25/2017 |
1.0.0-CI-20171224-230634 | 804 | 12/24/2017 |
1.0.0-CI-20171224-224940 | 750 | 12/24/2017 |
1.0.0-CI-20171224-160349 | 839 | 12/24/2017 |
1.0.0-CI-20171224-155718 | 830 | 12/24/2017 |
1.0.0-CI-20171224-145609 | 755 | 12/24/2017 |
1.0.0-CI-20171224-021301 | 802 | 12/24/2017 |
1.0.0-CI-20171224-020847 | 797 | 12/24/2017 |
1.0.0-CI-20171224-014607 | 813 | 12/24/2017 |
1.0.0-CI-20171224-014310 | 835 | 12/24/2017 |
1.0.0-CI-20171223-203607 | 943 | 12/23/2017 |
1.0.0-CI-20171223-203454 | 813 | 12/23/2017 |
1.0.0-CI-20171223-203212 | 829 | 12/23/2017 |
Initial release