Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/ipjohnson/Grace

Grace is a feature rich dependency injection container library
https://github.com/ipjohnson/Grace

c-sharp dependency-injection ioc-container

Last synced: about 2 months ago
JSON representation

Grace is a feature rich dependency injection container library

Awesome Lists containing this project

README

        

# Grace

[![Build status](https://ci.appveyor.com/api/projects/status/rpgdoopau4hh1ltn?svg=true)](https://ci.appveyor.com/project/ipjohnson/grace) [![Coverage Status](https://coveralls.io/repos/github/ipjohnson/Grace/badge.svg)](https://coveralls.io/github/ipjohnson/Grace) [![Stack Overflow](https://img.shields.io/badge/StackOverflow-QnA-green.svg)](http://stackoverflow.com/questions/tagged/grace-ioc)

Grace is a feature-rich dependency injection container designed with ease of use and performance in mind.

```csharp
using Grace.DependencyInjection;

var container = new DependencyInjectionContainer();

container.Configure(c => c.Export().As());

var basicService = container.Locate();
```

It's as easy as create, configure, and locate.

Getting Grace
=====

[NuGet](http://www.nuget.org/packages/Grace/) package supports .Net 4.5 and .Net Standard 1.0.

[Getting Started](https://github.com/ipjohnson/Grace/wiki/Getting-Started) - A getting started guide for Grace as well as documentation for more complex topics

Features in Grace
=====

* Fluent interface or Attributes for configuration allowing for maximum flexibility
* Supports child containers and light weight lifetime scopes
* Contextual binding support (similar to NInject)
* IDisposable objects created by the container will be tracked and disposed by the container unless configured otherwise.
* Performance characteristics that make it one of the fastest containers available. ([Benchmarks](http://www.palmmedia.de/blog/2011/8/30/ioc-container-benchmark-performance-comparison))
* Supports special types
* IEnumerable<T> - supports resolving collections as IEnumerable<T> as well as most other types of collections List<T>, ReadOnlyCollection<T>, T[] and any collection that implements ICollection<T>
* Func<T> - supports resolving Func