/examples/ioc/PropertyInjectionSample/CarLibrary2/Person.cs

http://github.com/philiplaureano/LinFu · C# · 44 lines · 39 code · 5 blank · 0 comment · 0 complexity · fe2470477575fdd435d038b39f15076b MD5 · raw file

  1. using System;
  2. using System.Collections.Generic;
  3. using System.Text;
  4. using LinFu.IoC;
  5. using LinFu.IoC.Configuration;
  6. using LinFu.IoC.Interfaces;
  7. namespace CarLibrary2
  8. {
  9. [Implements(typeof(IPerson), LifecycleType.OncePerRequest)]
  10. public class Person : IPerson
  11. {
  12. private string _name;
  13. private int _age;
  14. #region IPerson Members
  15. public string Name
  16. {
  17. get
  18. {
  19. return _name;
  20. }
  21. set
  22. {
  23. _name = value;
  24. }
  25. }
  26. public int Age
  27. {
  28. get
  29. {
  30. return _age;
  31. }
  32. set
  33. {
  34. _age = value;
  35. }
  36. }
  37. #endregion
  38. }
  39. }