Salome HOME
Copyrights update 2015.
[tools/siman.git] / Workspace / Siman-Common / src / org / splat / service / ServiceLocatorImpl.java
1 /*****************************************************************************
2  * Company         OPEN CASCADE
3  * Application     SIMAN
4  * File            $Id$ 
5  * Creation date   19.10.2012
6  * @author         $Author$
7  * @version        $Revision$
8  * @copyright      OPEN CASCADE 2012-2015
9  *****************************************************************************/
10
11 package org.splat.service; 
12
13 /**
14  * The service locator implementaion. This is a singleton class for providing access to business services.
15  *
16  * @author <a href="mailto:roman.kozlov@opencascade.com">Roman Kozlov (RKV)</a>
17  */
18 @Deprecated
19 public final class ServiceLocatorImpl implements ServiceLocator {
20
21         /**
22          * The Locator instance.
23          */
24         static private ServiceLocator theInstance = new ServiceLocatorImpl();
25
26         /**
27          * Get the locator instance.
28          * @return the locator instance
29          */
30         public static ServiceLocator getInstance() {
31                 return theInstance;
32         }
33         
34         /**
35          * Private constructor because this is a singleton class.
36          */
37         private ServiceLocatorImpl() {
38         }
39
40         /**
41          * Injected study service.
42          */
43         private StudyService _studyService;
44         /**
45          * Injected user service.
46          */
47         private UserService _userService;
48         /**
49          * Injected publication service.
50          */
51         private PublicationService _publicationService;
52
53         /**
54          * Get the studyService.
55          * @return the studyService
56          */
57         public StudyService getStudyService() {
58                 return _studyService;
59         }
60
61         /**
62          * Set the studyService.
63          * @param studyService the studyService to set
64          */
65         public void setStudyService(final StudyService studyService) {
66                 _studyService = studyService;
67         }
68
69         /**
70          * Get the userService.
71          * @return the userService
72          */
73         public UserService getUserService() {
74                 return _userService;
75         }
76
77         /**
78          * Set the userService.
79          * @param userService the userService to set
80          */
81         public void setUserService(final UserService userService) {
82                 _userService = userService;
83         }
84
85         /**
86          * Get the publicationService.
87          * @return the publicationService
88          */
89         public PublicationService getPublicationService() {
90                 return _publicationService;
91         }
92
93         /**
94          * Set the publicationService.
95          * @param publicationService the publicationService to set
96          */
97         public void setPublicationService(final PublicationService publicationService) {
98                 _publicationService = publicationService;
99         }
100 }