1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16 package org.kuali.rice.location.impl.config;
17
18 import org.kuali.rice.core.api.config.module.RunMode;
19 import org.kuali.rice.core.framework.config.module.ModuleConfigurer;
20 import org.kuali.rice.location.api.LocationConstants;
21
22 import java.util.ArrayList;
23 import java.util.Arrays;
24 import java.util.List;
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40 public class LocationConfigurer extends ModuleConfigurer {
41
42 public LocationConfigurer() {
43 super(LocationConstants.Namespaces.MODULE_NAME);
44 setValidRunModes(Arrays.asList(RunMode.REMOTE, RunMode.LOCAL));
45 }
46
47 @Override
48 public List<String> getPrimarySpringFiles() {
49 LOG.info("LocationConfigurer:getPrimarySpringFiles: getRunMode => " + getRunMode());
50 List<String> springFileLocations = new ArrayList<String>();
51 if (RunMode.REMOTE == getRunMode()) {
52 springFileLocations.add(getDefaultConfigPackagePath() + "LocationRemoteSpringBeans.xml");
53 } else if (RunMode.LOCAL == getRunMode()) {
54 springFileLocations.add(getDefaultConfigPackagePath() + "LocationLocalSpringBeans.xml");
55 }
56 return springFileLocations;
57 }
58
59 }