12345678910111213141516171819202122232425262728 |
- namespace Wayne.Lib
- {
- /// <summary>
- /// Factory to create ServiceContainer.
- /// </summary>
- public static class ServiceContainerFactory
- {
- /// <summary>
- /// Creates new service container.
- /// </summary>
- /// <returns>New service container.</returns>
- public static IServiceContainer Create()
- {
- return new ServiceContainer();
- }
- /// <summary>
- /// Creates new service container with a parent service locator from where the newly created service container
- /// can look for services if it does not find them in its own container.
- /// </summary>
- /// <param name="parentServiceLocator">Parent service container.</param>
- /// <returns>New service container.</returns>
- public static IServiceContainer Create(IServiceLocator parentServiceLocator)
- {
- return new ServiceContainer(parentServiceLocator);
- }
- }
- }
|