/src/SampleLibrary/SampleStronglyTypedFactory.cs

http://github.com/philiplaureano/LinFu · C# · 18 lines · 15 code · 3 blank · 0 comment · 0 complexity · e97b46f4146f872551c8b599ca069d71 MD5 · raw file

  1. using LinFu.IoC.Configuration;
  2. using LinFu.IoC.Interfaces;
  3. namespace SampleLibrary
  4. {
  5. [Factory(typeof (ISampleService))]
  6. public class SampleStronglyTypedFactory : IFactory<ISampleService>
  7. {
  8. #region IFactory<ISampleService> Members
  9. public ISampleService CreateInstance(IContainer container)
  10. {
  11. return new SampleClass();
  12. }
  13. #endregion
  14. }
  15. }