When using LightInject, how can you use access the Container instance in contexts other than initial registration/bootstrapping? I followed LightInject's getting started guide and google around, but didn't find anything like that.
For reference, I present how this is achieved in two other IoC frameworks.
Ninject
When using Ninject so I'm used to having the IKernel type automatically bound to the Kernel (Container on LighInject), so a class with a constructor like this:
public MyClass(IKernel kernel)
{
var myInstance = kernel.Get<IMyType>();
}
will be able to use kernel to retrieve instances.
SimpleIoC
When using SimpleIoC, the framework that comes with MvvmLight, you can use a static property (SimpleIoC.Default) to achieve the same purpose:
var myInstance = SimpleIoc.Default.GetInstance<IMyType>();