1.Topics‎ > ‎Architecture‎ > ‎Patterns‎ > ‎a.Design Patterns‎ > ‎B.Creational Patterns‎ > ‎

E.Service locator pattern

  1. Summary 
    1. This pattern is obsolete and suggested pattern is IOC Containers like Unity.
    2. Helps to find dependency object instances at run time and implement IOC.
    3. C# provides IServiceProvider  interface to support this.
    4. Old projects that are using Service Locator Patterns can use Common Service Locator Library to integrate with Unity or other like frameworks.
  2. References
    1. http://msdn.microsoft.com/en-us/library/ff921142.aspx
    2. http://www.codeproject.com/Articles/18464/A-Basic-Introduction-On-Service-Locator-Pattern
  3. Related Concepts
    1. Dependency Injection
    2. Inversion of Control Pattern
  4. Discussion 
    1. ServiceLocator and Unity – Be Careful