GithubHelp home page GithubHelp logo

mjfreelancing / alloverit Goto Github PK

View Code? Open in Web Editor NEW
0.0 3.0 2.0 29.24 MB

A suite of libraries aimed at providing a simplified and consistent approach to cross-cutting and functional concerns.

License: MIT License

C# 99.91% Batchfile 0.02% Vim Snippet 0.07%

alloverit's Introduction

Overview

AllOverIt began as a single nuget package of the same name in 2015. Since then, the library has broadened and deepened in functionality, resulting in a comprehensive set of dedicated nuget packages that encompass a number of different domains.

Refer to the Change Log for an overview of what has recently changed.

Refer to the online Documentation for comprehensive usage information.

A summary for each of the available packages is provided below.

AllOverIt

This general-purpose package contains a diverse range of classes and utility functions, intended to tackle a wide array of commonly encountered issues.

Key areas of concern include threading, tasks, generic caching, event (message) aggregation, expression and reflection utilities, plugin contexts, enriched enums, pipelines, value objects, specifications, and dozens of extensions.

NuGet NuGet


AllOverIt.AspNetCore

This package provides useful ASP.NET Core utilities such as custom model binding for AllOverIt based enriched enum types, and arrays of values in a query string.

NuGet NuGet


AllOverIt.Assertion

This package contains a useful collection of pre- and post-condition assertion extension methods, and a fluent-like approach to throwing exceptions based on a given condition or custom predicate.

NuGet NuGet


AllOverIt.Aws.AppSync.Client

This package contains AWS AppSync GraphQL and Subscription clients with support for serialization using Newtonsoft or System.Text, including serialization of AllOverIt based enriched enums.

NuGet NuGet


AllOverIt.Aws.Cdk.AppSync

This package greatly simplifies the generation of AWS Graphql schemas, including their associated mapping and resolver configuration, using a code-first approach.

NuGet NuGet


AllOverIt.Cryptography

This package provides byte-array and stream-based interfaces for encryption algorithms such as AES, RSA and an RSA-AES hybrid. It also includes useful extension methods that greatly simplifies the encryption and decryption between byte-arrays, streams, plain text and base64 encoded versions of plain text and cipher text.

NuGet NuGet


AllOverIt.Csv

Using CsvHelper to perform the actual writing of CSV content, this package provides a configuration based serializer that can export data using a model with fixed columns as well as dynamic columns derived from complex or array type properties.

NuGet NuGet


AllOverIt.DependencyInjection

This package provides useful dependency injection related utilities such as registering and resolving 'named' services, auto service discovery and registration via a service registrar, and service decoration.

NuGet NuGet


AllOverIt.EntityFrameworkCore

This package provides EntityFramework Core utilities such as a database migration helper and a value converter for AllOverIt based enriched enum types.

NuGet NuGet


AllOverIt.EntityFrameworkCore.Diagrams

In conjunction with D2, this package will generate entity relationship diagrams for an EntityFramework Core DbContext.

NuGet NuGet


AllOverIt.EntityFrameworkCore.Pagination

Using AllOverIt.Pagination as the basis for advanced keyset-based pagination, this package provides additional extensions for use with EntityFramework Core.

NuGet NuGet


AllOverIt.Evaluator

This package contains a highly-extendable mathematical expression compiler and evaluator that includes constant, mutable, delegate, and lazily evaluated variables, offers implicit and explicit variable lookup, and supports custom arithmetic operators and operations.

NuGet NuGet


AllOverIt.Filtering

This package adds comprehensive filtering support to any IQueryable with built-in provision for operations such as Contains, StartsWith, EndsWith, In, NotIn, EqualTo, NotEqualTo, GreaterThan, LessThan, GreaterThanOrEqual, and LessThanOrEqual.

It's also possible to create a custom predicate based on a Specification and there are options such as ignoring default (null) filter values and parameterizing query inputs that makes it ideal for use with EntityFramework Core.

NuGet NuGet


AllOverIt.Fixture

This package contains a base fixture class with numerous helper methods to assist with scaffolding unit tests. Utilizes AutoFixture to do most of the hard work.

NuGet NuGet


AllOverIt.Fixture.FakeItEasy

This package extends AllOverIt.Fixture to support FakeItEasy integration.

NuGet NuGet


AllOverIt.GenericHost

This package contains generic host helpers and convenience methods for setting up console applications that support dependency injection.

NuGet NuGet


AllOverIt.Logging

This package contains extension methods to provide additional logging functionality.

NuGet NuGet

AllOverIt.Logging.Testing

This package contains helper methods that assist with asserting logger calls.

NuGet NuGet

AllOverIt.Mapping

This package contains an object mapper that is mostly configuration free, but also capable of property exclusion, aliasing, null replacement, value conversion, and deep copying.

NuGet NuGet


AllOverIt.Pagination

An advanced keyset-based pagination package that uses a fluent-style builder to create queries that cater for forward and backward navigation for any given deterministic base query.

Each page of results includes a 'continuation token' for the current, next, and previous page. These tokens can be used at a later time to navigate to the same location within the dataset, thereby somewhat overcoming the inability of random access traditionally associated with keyset-based navigation.

NuGet NuGet


AllOverIt.Pipes

This package provides support for communication over anonymous pipes using StreamReader and StreamWriter, and strongly-typed message-based communication over named pipes using a binary serializer.

The named pipes can use the binary serializer from AllOverIt.Serialization.Binary or you can create your own.

NuGet NuGet


AllOverIt.Reactive

This package contains utility extensions for use with System.Reactive.

NuGet NuGet


AllOverIt.ReactiveUI

This package contains utility extensions for use with ReactiveUI.

NuGet NuGet


AllOverIt.ReactiveUI.Wpf

This package contains utility extensions for use with ReactiveUI and WPF.

NuGet NuGet


AllOverIt.Serialization.Binary

This package provides enhanced support for binary serialization. Complex object graphs, lists, dictionaries and nullable values can all be dynamically serialized using reflection-based readers and writers or, for greater performance, a custom serializer per object within the graph.

NuGet NuGet


AllOverIt.Serialization.Json.Abstractions

This package contains JSON serialization abstractions.

NuGet NuGet


AllOverIt.Serialization.Json.NewtonSoft

This package contains a wrapper for Newtonsoft JSON serialization based on AllOverIt.Serialization.Json.Abstractions.

NuGet NuGet


AllOverIt.Serialization.Json.SystemText

This package contains a wrapper for System.Text JSON serialization based on AllOverIt.Serialization.Json.Abstractions.

NuGet NuGet


AllOverIt.Serilog

This package contains general-purpose Serilog sinks and enrichers.

NuGet NuGet

AllOverIt.Validation

This package contains additional validators and extensions for use with FluentValidation. It includes an invoker that will select, and invoke, a registered validator based on a provided model.

Synchronous and Asynchronous validation is supported, along with extensions that make it easier to pass context information into a validator to keep it stateless.

Also available is a validation registrar that makes it possible to auto-register all validators within the same assembly. Validators can also be filtered based on a predicate.

NuGet NuGet


AllOverIt.Validation.Options

This package contains Microsoft.Extensions.Options validation using FluentValidation.

NuGet NuGet


AllOverIt.Wpf

This package contains general purpose WPF utilities.

NuGet NuGet


AllOverIt.Wpf.Controls

This package contains useful WPF controls.

NuGet NuGet


alloverit's People

Contributors

mjfreelancing avatar

Watchers

 avatar  avatar  avatar

alloverit's Issues

AllOverIt.EntityFrameworkCore.Diagrams Does Not Work With The .NET Options Pattern

Describe the bug
.NET uses the Options Pattern to provide configuration.

The D2ErdGenerator constructor requires an "ErdOptions" class. However, it does not accept an IOptions<ErdOptions> or similar. This means that it cannot be instantiated by dependency injection without hacks.

To Reproduce
Steps to reproduce the behavior:

  • Add the AllOverIt.EntityFrameworkCore.Diagrams package.
  • Use the default options: builder.Services.Configure<ErdOptions>(options => {});
  • Register the service builder.Services.AddSingleton(D2ErdGenerator)();
  • Add an endpoint app.MapGet("/DbDiagram", (D2ErdGenerator generator, MyDbContext dbContext) => generator.Generate(dbContext));

Expected behavior
The ERD string is generated.

** Actual behavior**
Crashes.

Additional context
This can be hacked around with the following: builder.Services.AddTransient( serviceProvider => serviceProvider.GetRequiredService<IOptions<ErdOptions>>().Value );

AllOverIt.Extensions.DoubleExtensions remove Epsilon

At current, the DoubleExtensions class has a defined constant const double Epsilon = 1E-07.
I propose removing it to use the build-in double.Epsilon, then adding overloads to allow for custom variance, which seems to be the more modern approach in many other libraries.

This old post on StackOverflow describes that:

The System.Double type can represent values accurate to up to 15 digits. So a simple first order estimate if a double value x is equal to some constant is to use an epsilon of constant * 1E-15

Another post on the same thread suggests their own implementation, should you wish to keep a default variance:

/// <summary>
/// smallest such that 1.0+EpsilonD != 1.0
/// </summary>
public const double EpsilonD = 2.2204460492503131e-016;

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.