1 /*****************************************************************************
5 * Creation date 19.10.2012
8 * @copyright OPEN CASCADE 2012
9 *****************************************************************************/
11 package org.splat.service;
14 * The service locator implementaion. This is a singleton class for providing access to business services.
16 * @author <a href="mailto:roman.kozlov@opencascade.com">Roman Kozlov (RKV)</a>
19 public class ServiceLocatorImpl implements ServiceLocator {
22 * The Locator instance.
24 static ServiceLocator theInstance;
27 * Get the locator instance.
28 * @return the locator instance
30 public static ServiceLocator getInstance() {
31 if (theInstance == null) {
32 theInstance = new ServiceLocatorImpl();
38 * Private constructor because this is a singleton class.
40 private ServiceLocatorImpl() {
44 * Injected study service.
46 private StudyService _studyService;
49 * Get the studyService.
50 * @return the studyService
52 public StudyService getStudyService() {
57 * Set the studyService.
58 * @param studyService the studyService to set
60 public void setStudyService(StudyService studyService) {
61 _studyService = studyService;