Skip to content

einari/Yggdrasil

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

34 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Yggdrasil

A simple IoC container for Windows 8.x and Windows Phone 8.1 RT Store apps

http://en.wikipedia.org/wiki/Yggdrasil

http://nuget.org/packages/Yggdrasil/

Getting Started

Lets imagine you have an interface

public interface ISomething
{
}

Then you have an implementation sitting in the same namespace

public class Something : ISomething
{
}

In your App class, you can simply do the following :

sealed partial class App : Application
{
    public App()
    {
        var container = Yggdrasil.ContainerContext.Current;
        var instance = container.Get<ISomething>();
    }
}

Yggdrasil uses conventions to resolve the relationship between the ISomething and the Something by simply assuming that the two are related by name by removing the I in the interface.

About

A simple IoC container for WinRT Windows Store apps

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published