a6f72be0b6660b57c0b098f7cfe879a4cd1de99f
[sdc/sdc-workflow-designer.git] /
1 /**
2  * Copyright 2018 ZTE Corporation.
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  *     http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16 package org.onap.sdc.workflowdesigner.config;
17
18 import org.onap.sdc.workflowdesigner.SDCServiceProxyInfo;
19 import org.onap.sdc.workflowdesigner.ActivitySpecServiceProxyInfo;
20
21 /**
22  * 
23  */
24 public class AppConfig {
25   private static AdapterType adapterType;
26   
27   private static SDCServiceProxyInfo sdcServiceProxy;
28
29   private static ActivitySpecServiceProxyInfo activitySpecServiceProxy;
30   
31   private AppConfig() {}
32
33   /**
34    * @return the adapterType
35    */
36   public static AdapterType getAdapterType() {
37     return adapterType;
38   }
39
40   /**
41    * @param adapterType the adapterType to set
42    */
43   public static void setAdapterType(AdapterType adapterType) {
44     AppConfig.adapterType = adapterType;
45   }
46
47   /**
48    * @param sdcServiceProxy
49    */
50   public static void setSdcServiceProxy(SDCServiceProxyInfo sdcServiceProxy) {
51     AppConfig.sdcServiceProxy = sdcServiceProxy;
52   }
53
54   /**
55    * @return the sdcServiceProxy
56    */
57   public static SDCServiceProxyInfo getSdcServiceProxy() {
58     return sdcServiceProxy;
59   }
60
61   /**
62    * @return
63    */
64   public static boolean isSDCAdapter() {
65     return adapterType.equals(AdapterType.SDC);
66   }
67
68   /**
69    * @param activitySpecServiceProxy
70    */
71   public static void setActivitySpecServiceProxy(ActivitySpecServiceProxyInfo activitySpecServiceProxy) {
72     AppConfig.activitySpecServiceProxy = activitySpecServiceProxy;
73   }
74
75   /**
76    * @return the activitySpecServiceProxy
77    */
78   public static ActivitySpecServiceProxyInfo getActivitySpecServiceProxy() {
79     return activitySpecServiceProxy;
80   }
81 }