1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19 package org.springframework.extensions.surf.support;
20
21 import org.springframework.context.ApplicationContext;
22 import org.springframework.context.ApplicationContextAware;
23 import org.springframework.extensions.config.WebFrameworkConfigElement;
24 import org.springframework.extensions.surf.WebFrameworkManager;
25 import org.springframework.extensions.surf.WebFrameworkServiceRegistry;
26 import org.springframework.extensions.surf.resource.ResourceService;
27
28
29
30
31
32
33 public abstract class BaseFactory implements ApplicationContextAware
34 {
35 private ApplicationContext applicationContext;
36 private WebFrameworkServiceRegistry webFrameworkServiceRegistry = null;
37
38
39
40
41 public void setApplicationContext(ApplicationContext applicationContext)
42 {
43 this.applicationContext = applicationContext;
44 }
45
46
47
48
49
50
51 public ApplicationContext getApplicationContext()
52 {
53 return this.applicationContext;
54 }
55
56
57
58
59
60
61 public void setServiceRegistry(WebFrameworkServiceRegistry webFrameworkServiceRegistry)
62 {
63 this.webFrameworkServiceRegistry = webFrameworkServiceRegistry;
64 }
65
66
67
68
69
70
71 public WebFrameworkServiceRegistry getServiceRegistry()
72 {
73 return this.webFrameworkServiceRegistry;
74 }
75
76
77
78
79
80
81 public WebFrameworkConfigElement getWebFrameworkConfiguration()
82 {
83 return this.getServiceRegistry().getWebFrameworkConfiguration();
84 }
85
86
87
88
89
90
91 public WebFrameworkManager getWebFrameworkManager()
92 {
93 return this.getServiceRegistry().getWebFrameworkManager();
94 }
95
96
97
98
99
100
101 public ResourceService getResourceService()
102 {
103 return this.getServiceRegistry().getResourceService();
104 }
105
106 }