1
2
3
4
5
6
7
8 package it.imolinfo.jbi4corba.webservice.generator;
9 import it.imolinfo.jbi4corba.Logger;
10 import it.imolinfo.jbi4corba.LoggerFactory;
11 import it.imolinfo.jbi4corba.jbi.Messages;
12
13 import java.util.Properties;
14
15
16
17
18
19
20
21 public class WSDLDescriptor {
22
23 private final String corbaServiceName;
24
25 private final String localizationType;
26
27 private final String namespace;
28
29 private final String endpointName;
30
31 private Properties orbProperties;
32
33 private boolean persistentConsumer=false;
34
35
36 private static final Logger LOG =
37 LoggerFactory.getLogger(WSDLDescriptor.class);
38 private static final Messages MESSAGES =
39 Messages.getMessages(WSDLDescriptor.class);
40
41
42
43
44
45
46
47
48 public WSDLDescriptor(String corbaServiceName, String localizationType,
49 String namespace, String endpointName) {
50 if (corbaServiceName == null) {
51 String msg=MESSAGES.getString("CRB000567_Corba_Service_Name_null");
52 LOG.error(msg);
53 throw new NullPointerException(msg);
54 }
55 if (localizationType == null) {
56 String msg=MESSAGES.getString("CRB000568_Localization_Type_null");
57 LOG.error(msg);
58 throw new NullPointerException(msg);
59 }
60 if (namespace == null) {
61 String msg=MESSAGES.getString("CRB000569_Namespace_null");
62 LOG.error(msg);
63 throw new NullPointerException(msg);
64 }
65 if (endpointName == null) {
66 String msg=MESSAGES.getString("CRB000570_Endpoint_name_null");
67 LOG.error(msg);
68 throw new NullPointerException(msg);
69 }
70
71 this.corbaServiceName = corbaServiceName;
72 this.localizationType = localizationType;
73 this.namespace = namespace;
74 this.endpointName = endpointName;
75 }
76
77
78
79
80
81 public String getCorbaServiceName() {
82 return corbaServiceName;
83 }
84
85
86
87
88
89 public String getLocalizationType() {
90 return localizationType;
91 }
92
93
94
95
96
97 public String getEndpointName() {
98 return endpointName;
99 }
100
101
102
103
104
105 public String getNamespace() {
106 return namespace;
107 }
108
109
110
111
112
113 public Properties getOrbProperties() {
114 if (orbProperties == null) {
115 orbProperties = new Properties();
116 }
117 return orbProperties;
118 }
119
120
121
122
123
124 public void setOrbProperties(Properties orbProperties) {
125 this.orbProperties = orbProperties;
126 }
127
128
129
130
131 public boolean isPersistentConsumer() {
132 return persistentConsumer;
133 }
134
135
136
137
138 public void setPersistentConsumer(boolean persistentConsumer) {
139 this.persistentConsumer = persistentConsumer;
140 }
141 }