1 27 package org.objectweb.jonas_rar.deployment.xml; 28 29 import org.objectweb.jonas_lib.deployment.xml.AbsElement; 30 import org.objectweb.jonas_lib.deployment.xml.JLinkedList; 31 36 37 public class Resourceadapter extends AbsElement { 38 39 42 private String resourceadapterClass = null; 43 44 47 private String managedconnectionfactoryClass = null; 48 49 52 private String connectionfactoryInterface = null; 53 54 57 private String connectionfactoryImplClass = null; 58 59 62 private String connectionInterface = null; 63 64 67 private String connectionImplClass = null; 68 69 72 private String transactionSupport = null; 73 74 77 private JLinkedList configPropertyList = null; 78 79 82 private JLinkedList authenticationMechanismList = null; 83 84 87 private OutboundResourceadapter outboundResourceadapter = null; 88 89 92 private InboundResourceadapter inboundResourceadapter = null; 93 94 97 private JLinkedList adminobjectList = null; 98 99 102 private String reauthenticationSupport = null; 103 104 107 private JLinkedList securityPermissionList = null; 108 109 110 113 public Resourceadapter() { 114 super(); 115 configPropertyList = new JLinkedList("config-property"); 116 authenticationMechanismList = new JLinkedList("authentication-mechanism"); 117 adminobjectList = new JLinkedList("adminobject"); 118 securityPermissionList = new JLinkedList("security-permission"); 119 } 120 121 125 public String getResourceadapterClass() { 126 return resourceadapterClass; 127 } 128 129 133 public void setResourceadapterClass(String resourceadapterClass) { 134 this.resourceadapterClass = resourceadapterClass; 135 } 136 137 141 public String getManagedconnectionfactoryClass() { 142 return managedconnectionfactoryClass; 143 } 144 145 149 public void setManagedconnectionfactoryClass(String managedconnectionfactoryClass) { 150 this.managedconnectionfactoryClass = managedconnectionfactoryClass; 151 } 152 153 157 public String getConnectionfactoryInterface() { 158 return connectionfactoryInterface; 159 } 160 161 165 public void setConnectionfactoryInterface(String connectionfactoryInterface) { 166 this.connectionfactoryInterface = connectionfactoryInterface; 167 } 168 169 173 public String getConnectionfactoryImplClass() { 174 return connectionfactoryImplClass; 175 } 176 177 181 public void setConnectionfactoryImplClass(String connectionfactoryImplClass) { 182 this.connectionfactoryImplClass = connectionfactoryImplClass; 183 } 184 185 189 public String getConnectionInterface() { 190 return connectionInterface; 191 } 192 193 197 public void setConnectionInterface(String connectionInterface) { 198 this.connectionInterface = connectionInterface; 199 } 200 201 205 public String getConnectionImplClass() { 206 return connectionImplClass; 207 } 208 209 213 public void setConnectionImplClass(String connectionImplClass) { 214 this.connectionImplClass = connectionImplClass; 215 } 216 217 221 public String getTransactionSupport() { 222 return transactionSupport; 223 } 224 225 229 public void setTransactionSupport(String transactionSupport) { 230 this.transactionSupport = transactionSupport; 231 } 232 233 237 public JLinkedList getConfigPropertyList() { 238 return configPropertyList; 239 } 240 241 245 public void setConfigPropertyList(JLinkedList configPropertyList) { 246 this.configPropertyList = configPropertyList; 247 } 248 249 253 public void addConfigProperty(ConfigProperty configProperty) { 254 configPropertyList.add(configProperty); 255 } 256 257 261 public JLinkedList getAuthenticationMechanismList() { 262 return authenticationMechanismList; 263 } 264 265 269 public void setAuthenticationMechanismList(JLinkedList authenticationMechanismList) { 270 this.authenticationMechanismList = authenticationMechanismList; 271 } 272 273 277 public void addAuthenticationMechanism(AuthenticationMechanism authenticationMechanism) { 278 authenticationMechanismList.add(authenticationMechanism); 279 } 280 281 285 public OutboundResourceadapter getOutboundResourceadapter() { 286 return outboundResourceadapter; 287 } 288 289 293 public void setOutboundResourceadapter(OutboundResourceadapter outboundResourceadapter) { 294 this.outboundResourceadapter = outboundResourceadapter; 295 } 296 297 301 public InboundResourceadapter getInboundResourceadapter() { 302 return inboundResourceadapter; 303 } 304 305 309 public void setInboundResourceadapter(InboundResourceadapter inboundResourceadapter) { 310 this.inboundResourceadapter = inboundResourceadapter; 311 } 312 313 317 public JLinkedList getAdminobjectList() { 318 return adminobjectList; 319 } 320 321 325 public void setAdminobjectList(JLinkedList adminobjectList) { 326 this.adminobjectList = adminobjectList; 327 } 328 329 333 public void addAdminobject(Adminobject adminobject) { 334 adminobjectList.add(adminobject); 335 } 336 337 341 public String getReauthenticationSupport() { 342 return reauthenticationSupport; 343 } 344 345 349 public void setReauthenticationSupport(String reauthenticationSupport) { 350 this.reauthenticationSupport = reauthenticationSupport; 351 } 352 353 357 public JLinkedList getSecurityPermissionList() { 358 return securityPermissionList; 359 } 360 361 365 public void setSecurityPermissionList(JLinkedList securityPermissionList) { 366 this.securityPermissionList = securityPermissionList; 367 } 368 369 373 public void addSecurityPermission(SecurityPermission securityPermission) { 374 securityPermissionList.add(securityPermission); 375 } 376 377 382 public String toXML(int indent) { 383 StringBuffer sb = new StringBuffer (); 384 sb.append(indent(indent)); 385 sb.append("<resourceadapter>\n"); 386 387 indent += 2; 388 389 sb.append(xmlElement(resourceadapterClass, "resourceadapter-class", indent)); 391 sb.append(configPropertyList.toXML(indent)); 393 if (outboundResourceadapter != null) { 395 sb.append(outboundResourceadapter.toXML(indent)); 396 } 397 if (inboundResourceadapter != null) { 399 sb.append(inboundResourceadapter.toXML(indent)); 400 } 401 sb.append(adminobjectList.toXML(indent)); 403 sb.append(securityPermissionList.toXML(indent)); 405 indent -= 2; 406 sb.append(indent(indent)); 407 sb.append("</resourceadapter>\n"); 408 409 return sb.toString(); 410 } 411 } 412 | Popular Tags |