Skip to content

boulaajaj/Cauldron

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Cauldron Logo

Cauldron C# Toolkit

Documentation

Wiki

https://github.com/Capgemini/Cauldron/wiki

.NET 4.6.1

https://Capgemini.github.io/Cauldron/win32/

.NET Standard 2.0

https://Capgemini.github.io/Cauldron/netstandard/

UWP

https://Capgemini.github.io/Cauldron/uwp/

What you require to run this project in Visual Studio

Nuget Packages

Assembly Description NuGet
Cauldron.Activator The activator is a simple and very fast dependency injection framework. It is based on attributes and does not require any configuration files for configuration. It also supports using static methods as component constructor. NuGet
Cauldron.Consoles Cauldron.Consoles is a Cauldron.Core based parameter parser which supports grouping of parameters in execution groups. It is also supports localization and has a nice parameter table :) NuGet
Cauldron.Core Cauldron Core is the core toolkit assembly that the Cauldron Toolkit builds upon NuGet
Cauldron.Core.Collections Contains usefull collections and collection extensions. NuGet
Cauldron.Core.Comparing Provides usefull extensions and methods regarding comparing NuGet
Cauldron.Core.Diagnostics Provides a set of methods that help debug code or output errors in compiled dlls. NuGet
Cauldron.Core.Disposable Implementation of IDisposable NuGet
Cauldron.Core.Extensions Provides usefull extension methods NuGet
Cauldron.Core.Extensions.Compression Provides System.IO.Compression.GZipStream extension methods for System.IO.Stream, System.IO.FileInfo, byte array and System.String NuGet
Cauldron.Core.Extensions.Convertions Provides extension methods regarding common convertions. NuGet
Cauldron.Core.Extensions.IO Provides extensions methods for FileInfo, DirectoryInfo and other IO operations NuGet
Cauldron.Core.Formatters Contains the following formatter implementations:
- ByteSizeFormatter
- MetricUnitFormatter
NuGet
Cauldron.Core.Interceptors A collection of interceptor implementations. NuGet
Cauldron.Core.JavaProperties Provides a class that can read and write Java property files. NuGet
Cauldron.Core.MathExtensions Provides additional functions that are missing from System.Math NuGet
Cauldron.Core.Net A collection of usefull methods regarding networks NuGet
Cauldron.Core.Randomizer Provides a randomizer that is cryptographically secure NuGet
Cauldron.Core.Reflection This package adds:
- Usefull extension methods to the existing System.Reflection.
- A expression base activator which is a lot faster than System.Activator.
- Enum DisplayName attribute
- addtional meta-data to an enum
- Assemblies static class
- A "wrapper" for Assembly but applied on all loaded Assemblies
NuGet
Cauldron.Core.Threading Provides useful helpers regarding threading NuGet
Cauldron.Core.Yaml A YAML deserializer NuGet
Cauldron.Cryptography Contains typical implementations for AES, RSA and RSA-AES encryptions. It also contains extensions that helps working with SecureString. NuGet
Cauldron.Interception.Fody Fody add-in that provides method, property, field and constructor interception. Supports Net45, NetStandard2.0 and UWP. NuGet
Cauldron.Localization A simple localization implementation that can work with different sources. NuGet
Cauldron.Win32.Extension.Impersonation Provides an extension for PrincipalContext to impersonate a user. NuGet
Cauldron.Win32.Extension.IO Provides extension methods with Windows specific functionalities like GetShortPath and IsNetworkPath NuGet
Cauldron.Win32.Interceptors A collection of interceptor implementations. NuGet
Cauldron.Win32.MonitorInfo Provides properties and methods for getting information about the monitor NuGet
Cauldron.Win32.Net Provides usefull implementations regarding network. NuGet
Cauldron.Win32.Threading A wrapper for the System.Windows.Threading.Dispatcher unify the usage for UWP and Win32. NuGet
Cauldron.Win32.UserInformation Consolidates methods for getting user information (profile picture, email address, home directory ect.) to a single class. NuGet
Cauldron.Win32.WindowsService Creating Windows Services is now a cake walk. This implementation can also handle localized service name and description. NuGet
Cauldron.Win32.WPF A simple MVVM framework that heavily uses IL-weaving based on Fody. NuGet
Cauldron.Win32.WPF.Interactivity Behaviours and Action for Cauldron.XAML NuGet
Cauldron.Win32.WPF.ParameterPassing Handles passing of parameters to running instance(s) of an application. NuGet
Cauldron.Win32.WPF.Theme.VSDark Visual Studio dark theme for Cauldron WPF NuGet
Cauldron.Win32.WPF.Theme.VSLight Visual Studio dark theme for Cauldron WPF NuGet
Cauldron.Win32.WPF.Validation Validation Framework for Cauldron.Win32.WPF NuGet

Release Notes

2.1.0

Bugfix

  • Capgemini.Cauldron.Core: Invalid chars in filenames generated by the serializer fixed.
  • Cauldron.Interception.Fody: A bug in AssignMethod that causes methods that are assigned and are in the base class not being recognized fixed.
  • Cauldron.Interception.Fody: A bug in AssignMethod that causes methods that are assigned to filed not being recognized fixed.
  • Cauldron.Interception.Fody: A bug that caused void methods to jump directly to the end of the method before executing the last OpCodes fixed.
  • Capgemini.Cauldron.Core.Comparing: EnclosedIn extension bug solved

2.0.37-beta

Bugfix

  • Cauldron.Interception.Fody: Bug in the auto implementation of RaiseIsChanged event.

2.0.35-beta

Added

  • Capgemini.Cauldron.Win32.WPF.Theme.VSLight: Beta release.
  • Capgemini.Cauldron.Win32.WPF.Theme.VSDark: Beta release.

Change

  • Capgemini.Cauldron.Core.JavaProperties: Moved from Cauldron.Core to it own assembly / package

2.0.32-beta

Change

  • Capgemini.Cauldron.Core: Reference to Cauldron.Core.Extensions.Convertions removed
  • Capgemini.Cauldron.Core: KeyRawValueDictionary moved to Cauldron.Core.Collections
  • Capgemini.Cauldron.Core.Collections: Reference to Cauldron.Core.Extensions.Convertions added
  • Capgemini.Cauldron.Core.Collections: KeyRawValueDictionary moved to Cauldron.Core.Collections

Bugfix

  • Cauldron.Interception.Fody: Missing Assemblies added to the Nuget package.
  • Capgemini.Cauldron.Core.Reflection: Issues with loading some assemblies... They are skiped now.

2.0.31-beta

Bugfix

  • Cauldron.Interception.Fody: AssignMethodAttribute assigned methods lack of import and failed during weaving.

2.0.30-beta

Change

  • Capgemini.Cauldron.Win32.WPF.ParameterPassing: Change COPYDATASTRUCT data to unicode.
  • Capgemini.Cauldron.Activator: ComponentConstructorAttribute now accepts internal ctors
  • Capgemini.Cauldron.Core.Extensions: Concat<T%gt;(this T[][] arrays) renamed to Flatten<T%gt;(this T[][] arrays)
  • Cauldron.Interception.Fody: DoNotInterceptAttribute removed... Replaced by the InterceptionRuleAttribute instead. See documentation for more details.
  • Cauldron.Interception.Fody: Interceptor OnException return type changed to bool to be able to create interceptors that swallow exceptions.
  • Cauldron.Interception.Fody: Getting rid of useless casts in created code.
  • Capgemini.Cauldron.Win32.Interceptors: InterceptorRule added to RegistryClassAttribute
  • Capgemini.Cauldron.Core.Extensions.Convertions: Reference to Cauldron.Core.Reflection removed.
  • Capgemini.Cauldron.Core.Comparing: Comparer code replaced by patterns and also cache added.
  • Capgemini.Cauldron.Core.Comparing: Reference to Cauldron.Core.Reflection removed.

Added

  • Cauldron.Interception.Fody: Support for properties without backing fields added.
  • Cauldron.Interception.Fody: Support for assembly-wide attribute decorating added.
  • Cauldron.Interception.Fody: Simple interceptors without try catch added.

Bugfix

  • Cauldron.Interception.Fody: MethodInterceptors in Async methods are now weaved correctly.
  • Cauldron.Interception.Fody: ModuleMain entry point interceptor fixed. Waever throwed exception during weaving.

2.0.29

Added

  • Capgemini.Cauldron.Win32.Interceptors: RegistryAttribute added

2.0.28

Bugfix

  • Cauldron.Interception.Fody: AssignMethodAttribute decorated field types were not imported.

Change

  • Cauldron.Interception.Fody: {CtorArgument:} placeholder now accepts parameter names besides index.
  • Cauldron.Interception.Fody: AssignMethodAttribute now falls back to 'is assignable' if the return type of a method does not match.

2.0.27

Change

  • Capgemini.Cauldron.Core.Diagnostics: Net461 DLLs removed because it causes a lot of issues on mixed solutions (NetCore and Net461)
  • Cauldron.Interception.Fody: AssignMethodAttribute now allowing parameters.
  • Cauldron.Interception.Fody: AssignMethodAttribute can now throw an error if the associated method is not found.
  • Cauldron.Interception.Fody: AssignMethodAttribute now supports constructor defined placeholders.

Bugfix

  • Cauldron.Interception.Fody: Fixed a bug that caused some methods to return null if Code-Optimization is on.

2.0.26

Change

  • Capgemini.Cauldron.Core.Randomizer: Net461 DLLs removed because it causes a lot of issues on mixed solutions (NetCore and Net461)
  • Capgemini.Cauldron.Core.Interceptors: PropertyOnSetAttribute added

Added

  • Capgemini.Cauldron.Core.Diagnostics: Added assemblies for NET45 and NET461
  • Cauldron.Interception.Fody: New interceptor extension added - AssignMethodAttribute
  • Capgemini.Cauldron.Win32.Interceptors: ExecutionTimeAttribute added
  • Capgemini.Cauldron.Win32.Interceptors: PropertyOnSetAttribute added

2.0.25

Added

  • Capgemini.Cauldron.Win32.WPF: OnActivationProtocol added to ApplicationBase
  • Capgemini.Cauldron.Win32.WPF: RegisterUrlProtocols added to ApplicationBase
  • Cauldron.Interception.Fody: System.Xml.Serialization.XmlIgnoreAttribute will be added to all Cauldron created properties if the type System.Xml.Serialization.XmlIgnoreAttribute exist.
  • Capgemini.Cauldron.Win32.Interceptors: Dependency to NLog added
  • Capgemini.Cauldron.Win32.Interceptors: PerformanceLoggerAttribute added
  • Capgemini.Cauldron.Win32.Interceptors: ExceptionLoggerAttribute added

Change

  • Capgemini.Cauldron.Win32.WPF: ParameterPassing in ApplicationBase now uses Environment.Exit(0) after passing the params to other instances.
  • Capgemini.Cauldron.Core.Interceptors: Dependency to NLog removed
  • Capgemini.Cauldron.Core.Interceptors: PerformanceLoggerAttribute removed
  • Capgemini.Cauldron.Core.Interceptors: ExceptionLoggerAttribute removed
  • Capgemini.Cauldron.Win32.WPF.ParameterPassing: Will now also invoke the callback delegate if there are no instances of the program running.
  • Capgemini.Cauldron.Win32.Net: Elevated Urlprotocol now also passes the uri
  • Capgemini.Cauldron.Win32.Net: Urlprotocol now registers url with icon 0 instead of 1

Bugfix

  • Cauldron.Interception.Fody: NonSerializedAttribute was implemented as a custom attribute... Now correctly implemented.

2.0.22

Change

  • Capgemini.Cauldron.Win32.UserInformation: Added a fallback if the user's account picture file was not found.
  • Capgemini.Cauldron.Win32.WPF.ParameterPassing: Now uses the NET461 assembly version of the randomizer.
  • Cauldron.Interception.Fody: Some info and error messages changed to be more informative.

Added

  • Capgemini.Cauldron.Core.Randomizer: Added assemblies for NET45 and NET461
  • Cauldron.Interception.Fody: Real support for Net45 added - The weaver itself still requires an installed Net461.
  • Cauldron.Interception.Fody: NonSerializedAttribute or IgnoreDataMemberAttribute or JsonIgnoreAttribute added to all Cauldron created fields and properties (Only if these attributes are referenced in the project).

Bugfix

  • Cauldron.Interception.Fody: In some cases if the weaver tries to retrieved information from referenced assemblies, a BadImageFormatException occures. Fixed.

2.0.21

Added

  • Capgemini.Cauldron.Win32.UserInformation: WTSClientName added to User and CurrentUser. WTSClientName returns the Windows Terminal Session client name.
  • Capgemini.Cauldron.Core.Extensions: PadOrCut extension method added. It allows to pad chars or cut the string to a specific length.
  • Capgemini.Cauldron.Core.Extensions.IO: FileInfo extension - Rename added

2.0.20

Added

  • Cauldron.Interception.Fody: Constructor interceptor added.

2.0.19

Bugfix

  • Capgemini.Cauldron.Win32.WPF: Several issues with the dispatcher fixed.
  • Capgemini.Cauldron.Win32.WPF: Navigator was not able to find the correct view in some cases.
  • Capgemini.Cauldron.Win32.WPF: ObjectToVisibilityConverter logic was inverted.
  • Capgemini.Cauldron.Win32.WPF: Bugs in MessageDialog that caused the strings not to be localized correctly fixed
  • Capgemini.Cauldron.Win32.WPF: Fixes an issue where the SplashScreen can be removed from MainView and causes the application to exit
  • Capgemini.Cauldron.Core.Threading: BUG!!!! ... Dispatcher was using BeginInvoke instead of InvokeAsync
  • Capgemini.Cauldron.Win32.WPF.Interactivity: The "Localized" attached property will not continue loading if in design mode to avoid those weird errors in the WPF editor
  • Capgemini.Cauldron.Localization: Added a Contains method to Locale.
  • Capgemini.Cauldron.Activator: CreateFirst always returned null in some cases... This is fixed.
  • Cauldron.Interception.Fody: A bug was in "cleaning" fixed that caused local variables to be removed although they were still in use.
  • Cauldron.Interception.Fody: Fixed a bug that caused the weaver to weav types that does not exist and then throws exceptions.
  • Cauldron.Interception.Fody: Sort of fixed the issue that jumping to errors on async methods did not work.
  • Capgemini.Cauldron.Core.Reflection: A bug in Assemblies that causes the Custom assembly resolution to be invoked before all assemblies are added to the collection fixed.

Change

  • Capgemini.Cauldron.Win32.WPF: XAML resources loading order can now be changed by adding a dash and a numeric suffix to the file name. e.g. Style-01.xaml.
  • Capgemini.Cauldron.Core.Reflection: Now Costura compatible.

Added

  • Capgemini.Cauldron.Win32.WPF.Interactivity: New property added to 'Localized': 'LocalizedText'
  • Cauldron.Interception.Fody: Allowing non auto-properties to be intercepted.

2.0.18

Bugfix

  • Cauldron.Interception.Fody: If PropertyChanged.Fody weaved before Cauldron then Cauldron has removed the implementation for the particular property. This is now fixed.
  • Cauldron.Interception.Fody: Fixed a bug that caused try-catches to be malformed if the modified method was empty.
  • Cauldron.Interception.Fody: Fixed the weaver for the IChangeAwareViewModel interface.

Added

  • Cauldron.Interception.Fody: IPropertyInitializer added. This interface forces an interceptor to be loaded on type init instead of the first call.

2.0.16

Added

  • Capgemini.Cauldron.Win32.WPF: The ViewAttribute now accepts a string as view name/type.
  • Capgemini.Cauldron.Win32.WPF: OnIsLoadingChanged added to ViewModelBase.
  • Capgemini.Cauldron.Win32.WPF: Message unsubsribe added to dispose of ViewModelBase.
  • Capgemini.Cauldron.Win32.WPF: RegisterChildren attribute added.
  • Cauldron.Interception.Fody: Sequence points added.
  • Capgemini.Cauldron.Core.Extensions.IO: GetUniqueDirectoryName and GetUniqueFilename added.

Change

  • Capgemini.Cauldron.Win32.WPF: Renamed IMessageDialog.ShowException to IMessageDialog.ShowExceptionAsync

Bugfix

  • Cauldron.Interception.Fody: Bug from yesterday regarding ComponentAttribute still occured on nested private classes. Now fixed.

2.0.13

Added

  • Capgemini.Cauldron.Win32.WPF: Several information from ApplicationInfo added as static resources.
  • Capgemini.Cauldron.Win32.WPF: IViewAware interface added.
  • Capgemini.Cauldron.Activator: CreateFirst method added to the Factory. This will auto-pick the implementation with the highest priority if multiple implementations are available.
  • Cauldron.Interception.Fody: Weaves an initializer for xaml resources to be able to auto-load them.

Bugfix

  • Capgemini.Cauldron.Win32.WPF: Now picks the correct Window implementaion.
  • Capgemini.Cauldron.Win32.WPF: Bug regarding auto-selection of views in the navigator fixed.
  • Capgemini.Cauldron.Win32.WPF: Bug in CauldronTemplateSelector regarding view orientation fixed.
  • Capgemini.Cauldron.Win32.WPF: Fixed a bug that caused the application to crash if there are no IMultiValueConverter in the application.
  • Cauldron.Interception.Fody: The weaving of the auto-ComponentAttribute attributed types caused an error in some cases if the type is not public.
  • Cauldron.Interception.Fody: Interceptors that uses ISyncRoot interface was not correctly weaved. This caused the object initialization to be weaved in the .cctor even though it is not static.
  • Cauldron.Interception.Fody: Useless method cache removed from weaver.

Change

  • Cauldron.Interception.Fody: TimedCacheAttribute namespace change also reflected to weaver.
  • Capgemini.Cauldron.Win32.Interceptors: TimedCacheAttribute namespace changed to Cauldron.Core.Interceptors.

Old Release Notes

2.0.0 betas

  • NetCore and Desktop libraries combined to NetStandard 2.0
  • Cauldron.XAML renamed to Cauldron.Win32.WPF
  • UWP libraries are combined together to a single library
  • Win32 specific libraries has now the following nomenclature: Cauldron.Win32.*
  • DispatcherEx is now injectable. It uses the new UnitTest aware Factory resolver to inject either the dummy dispatcher or the real deal.
  • ComparerUtils renamed to Comparer

1.2.8

  • Breaking changes: Reorganisation of the XAML libraries
  • Skinning added (Skins from first version of Cauldron re-added)
  • The App class (which inherits from ApplicationBase) is now recognized as Splashscreen if it has assigned a view. The OnPreload method is only called if a view is assigned if the navigation-mode is not SinglePage.
  • Bug fixes in Interception.Fody
    • Properties as constructors now works as expected
    • ComponentConstructor attributes are now no longer removed after weaving
  • Locale class can now be injected without causing an error during Assembly verification
  • Singleton<> base class component construtor attribute removed, because it is redundant and causes errors.
  • NetCore versions of Cauldron.Interception, Cauldron.Core and Cauldron.Activator are now part of the NuGet package again.
  • Password scoring now works a bit better
  • Inline text for TextBlock fixed
  • XAML.Validation is now awaitable
  • Module OnLoad "interceptor" added
  • Bug fixes - see Incidents

1.2.7 (1.2.0 to 1.2.6 betas)

  • NetCore Dlls droped from package due to issues with Fody - This will be back as soon as NetCore and Fody works a lot better
  • Types with the component attribute get a hard-coded CreateInstance method. The Factory will use this method to create an instance of the type. This should give the factory an instancing performance almost on par with the new keyword.
  • Types that inherits or implements the following classes or interfaces are considered as components and will also recieve a CreateInstance method: ResourceDictionary, IValueConverter, INotifyPropertyChanged, FrameworkElement
  • ComponentConstructor Attribute
    • Now also accepts static Properties as Component constructor
    • New Property added: Priority; This is used by the Factory to order the result of CreateMany. 0 is lowest; uint.Max is highest.
  • Breaking changes in Assemblies class. Some methods and properties were removed without replacement.
  • Method and Property interceptor can now be used to intercept all methods and properties in a class. Excluded method can be attributed by the DoNotIntercept attribute.
  • CreateObject<> renamed to CreateType, which fits more to what it does.
  • Locale class redesigned for more performance
  • Localization source implementations now requires a component attribute
  • Basic implementation base classes added for ILocalizationSource
  • XML serialization/deserialization in Serializer class replaced by much faster JSON.NET
  • Breaking changes in Factory - The performance of the Factory was boosted with the following drawbacks
    • IFactoryInitializeComponent interface removed - Factory does not support this anymore
    • IFactoryExtension removed - The Factory is not extensible anymore :( ... To Resolve ambigousity the IFactoryResolver can be use instead.
    • This is the current performance of the factory
      Factory performance
  • Upgraded to the newest version of Fody
  • Minor bug fixes

1.1.4

  • Inject attribute default paramaters are now "params"
  • Assemblies class now throws a better error message if an Assembly cannot be loaded
  • Better error message in Inject attribute
  • Errors in Cauldron.Interception.Fody copy method fixed 1 2
  • TimedCache attribute key generation fixed. bBlock now works- Bug fix for anonymous type to interface convertion

1.1.1

  • Several minor bug fixes
  • TimedCacheAttribute now supports async methods
  • Unused variables are now removed from the method's local varible list

1.1.0

  • Cauldron.Interception is now using Cecilator
  • MethodOf, FieldOf, ChildOf removed
  • New Interceptor added: TimedCacheAttribute - Caches Methods using MemoryCache
  • Several Bug fixes - See issues section

1.0.8

  • CreateObject moved to Cauldron.Core
  • Performance boost to CreateInstance
  • IEquatable<> interface added to User class
  • Minor bugs fixed
  • Bug fixed that caused Cauldron.Interception.dll to be referenced with copy local set to false.

1.0.7

  • Bug fix in Cauldron.Interception.Fody regarding nested classes and generic classes and methods
  • References of the Nuget packages updated

1.0.6

  • Inject attribute from Cauldron.Injection moved to Cauldron.Activator
    • InjectAttribute is now based on Cauldron.Interception
  • Cauldron property interceptors setters can deal with IEnumerables if target property implements the IEnumerable<> interface
  • Experimental ChildTypeOf method added.
  • Cauldron.Activator has now an extension that can create types from interfaces.
    • CreateObject extension removed from Cauldron.Dynamic
  • Cauldron.Injection removed
  • Fody add-in weaver bugs fixed
  • Nuget packages fixed

1.0.5

  • Reference to Fody
  • Method, fields and property interceptor added
    • Try Catch Finally implementation
    • Method, property and field interceptors with SemaphoreSlim implementation
    • methodof and fieldof implementations in Cauldron.Core.Reflection
  • Cauldron.IEnumerableExtensions removed

1.0.4

  • .NET Standard 1.6 added to NuGet package
  • Missing resources in UWP packages added

1.0.3

  • Behaviour of As<> Extension changed. It will use implicit and explicit operators if casting did not work.
  • string Replace(string,char[],char) extension method added.
  • Examples added to the following methods
    • ExtensionsDirectoryServices.Impersonate
    • ConsoleUtils.WriteTable
    • AsyncHelper.NullGuard
  • Extensions.IsDerivedFrom removed
  • Extension.LowerFirstCharacter optimized
  • Cauldron.XAML.Interactivity.TextBoxHeader removed
  • Reference to Cauldron.UWP.XAML.Potions in Cauldron.UWP.XAML removed
  • Several minor bug fixes

1.0.2

  • ByteSizeFormatter moved to Cauldron.Core.Formatters
  • MetricUnitFormatter added -> key is metric -> .ToStringEx("metric") or "{0:metric}"
  • ByteSizeFormatter key changed from B to byte -> .ToStringEx("byte") or "{0:byte}"
  • ToStringEx extension method added
  • Java property file reader / writer added
  • NavigationFrame now always retrieve the View in the following order (on UWP and Desktop)
    • Defined in ViewAttribute
      • Variants such as Mobile, Desktop, Xbox, Iot, Landscape, Portrait
    • DataTemplate
      • Variants such as Mobile, Desktop, Xbox, Iot, Landscape, Portrait
    • Type (View Type) By Name
  • New method added in ApplicationBase to be able to load additional assemblies before initializing XAML / WPF
  • Several minor fixes

Packages

No packages published

Languages

  • C# 99.8%
  • Other 0.2%