001// 002// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.10-b140310.1920 003// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a> 004// Any modifications to this file will be lost upon recompilation of the source schema. 005// Generated on: 2015.06.22 at 09:54:13 AM CEST 006// 007 008 009package org.apache.activemq.schema.core; 010 011import java.util.ArrayList; 012import java.util.HashMap; 013import java.util.List; 014import java.util.Map; 015import javax.xml.bind.JAXBElement; 016import javax.xml.bind.annotation.XmlAccessType; 017import javax.xml.bind.annotation.XmlAccessorType; 018import javax.xml.bind.annotation.XmlAnyAttribute; 019import javax.xml.bind.annotation.XmlAnyElement; 020import javax.xml.bind.annotation.XmlAttribute; 021import javax.xml.bind.annotation.XmlElementRef; 022import javax.xml.bind.annotation.XmlID; 023import javax.xml.bind.annotation.XmlRootElement; 024import javax.xml.bind.annotation.XmlSchemaType; 025import javax.xml.bind.annotation.XmlType; 026import javax.xml.bind.annotation.adapters.CollapsedStringAdapter; 027import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter; 028import javax.xml.namespace.QName; 029import org.jvnet.jaxb2_commons.lang.Equals; 030import org.jvnet.jaxb2_commons.lang.EqualsStrategy; 031import org.jvnet.jaxb2_commons.lang.HashCode; 032import org.jvnet.jaxb2_commons.lang.HashCodeStrategy; 033import org.jvnet.jaxb2_commons.lang.JAXBHashCodeStrategy; 034import org.jvnet.jaxb2_commons.lang.JAXBToStringStrategy; 035import org.jvnet.jaxb2_commons.lang.ToString; 036import org.jvnet.jaxb2_commons.lang.ToStringStrategy; 037import org.jvnet.jaxb2_commons.locator.ObjectLocator; 038import org.jvnet.jaxb2_commons.locator.util.LocatorUtils; 039 040 041/** 042 * <p>Java class for anonymous complex type. 043 * 044 * <p>The following schema fragment specifies the expected content contained within this class. 045 * 046 * <pre> 047 * <complexType> 048 * <complexContent> 049 * <restriction base="{http://www.w3.org/2001/XMLSchema}anyType"> 050 * <choice maxOccurs="unbounded" minOccurs="0"> 051 * <choice> 052 * <element name="portMapping" minOccurs="0"> 053 * <complexType> 054 * <complexContent> 055 * <restriction base="{http://www.w3.org/2001/XMLSchema}anyType"> 056 * <sequence minOccurs="0"> 057 * <any maxOccurs="unbounded" minOccurs="0"/> 058 * </sequence> 059 * </restriction> 060 * </complexContent> 061 * </complexType> 062 * </element> 063 * <any namespace='##other' maxOccurs="unbounded" minOccurs="0"/> 064 * </choice> 065 * </choice> 066 * <attribute name="clusterClientUriQuery" type="{http://www.w3.org/2001/XMLSchema}string" /> 067 * <attribute name="portMapping" type="{http://www.w3.org/2001/XMLSchema}string" /> 068 * <attribute name="publishedHostStrategy" type="{http://www.w3.org/2001/XMLSchema}string" /> 069 * <attribute name="id" type="{http://www.w3.org/2001/XMLSchema}ID" /> 070 * <anyAttribute processContents='lax' namespace='##other'/> 071 * </restriction> 072 * </complexContent> 073 * </complexType> 074 * </pre> 075 * 076 * 077 */ 078@XmlAccessorType(XmlAccessType.FIELD) 079@XmlType(name = "", propOrder = { 080 "portMappingOrAny" 081}) 082@XmlRootElement(name = "publishedAddressPolicy") 083public class DtoPublishedAddressPolicy 084 implements Equals, HashCode, ToString 085{ 086 087 @XmlElementRef(name = "portMapping", namespace = "http://activemq.apache.org/schema/core", type = JAXBElement.class, required = false) 088 @XmlAnyElement(lax = true) 089 protected List<Object> portMappingOrAny; 090 @XmlAttribute(name = "clusterClientUriQuery") 091 protected String clusterClientUriQuery; 092 @XmlAttribute(name = "portMapping") 093 protected String portMapping; 094 @XmlAttribute(name = "publishedHostStrategy") 095 protected String publishedHostStrategy; 096 @XmlAttribute(name = "id") 097 @XmlJavaTypeAdapter(CollapsedStringAdapter.class) 098 @XmlID 099 @XmlSchemaType(name = "ID") 100 protected String id; 101 @XmlAnyAttribute 102 private Map<QName, String> otherAttributes = new HashMap<QName, String>(); 103 104 /** 105 * Gets the value of the portMappingOrAny property. 106 * 107 * <p> 108 * This accessor method returns a reference to the live list, 109 * not a snapshot. Therefore any modification you make to the 110 * returned list will be present inside the JAXB object. 111 * This is why there is not a <CODE>set</CODE> method for the portMappingOrAny property. 112 * 113 * <p> 114 * For example, to add a new item, do as follows: 115 * <pre> 116 * getPortMappingOrAny().add(newItem); 117 * </pre> 118 * 119 * 120 * <p> 121 * Objects of the following type(s) are allowed in the list 122 * {@link Object } 123 * {@link JAXBElement }{@code <}{@link DtoPublishedAddressPolicy.PortMapping }{@code >} 124 * 125 * 126 */ 127 public List<Object> getPortMappingOrAny() { 128 if (portMappingOrAny == null) { 129 portMappingOrAny = new ArrayList<Object>(); 130 } 131 return this.portMappingOrAny; 132 } 133 134 /** 135 * Gets the value of the clusterClientUriQuery property. 136 * 137 * @return 138 * possible object is 139 * {@link String } 140 * 141 */ 142 public String getClusterClientUriQuery() { 143 return clusterClientUriQuery; 144 } 145 146 /** 147 * Sets the value of the clusterClientUriQuery property. 148 * 149 * @param value 150 * allowed object is 151 * {@link String } 152 * 153 */ 154 public void setClusterClientUriQuery(String value) { 155 this.clusterClientUriQuery = value; 156 } 157 158 /** 159 * Gets the value of the portMapping property. 160 * 161 * @return 162 * possible object is 163 * {@link String } 164 * 165 */ 166 public String getPortMapping() { 167 return portMapping; 168 } 169 170 /** 171 * Sets the value of the portMapping property. 172 * 173 * @param value 174 * allowed object is 175 * {@link String } 176 * 177 */ 178 public void setPortMapping(String value) { 179 this.portMapping = value; 180 } 181 182 /** 183 * Gets the value of the publishedHostStrategy property. 184 * 185 * @return 186 * possible object is 187 * {@link String } 188 * 189 */ 190 public String getPublishedHostStrategy() { 191 return publishedHostStrategy; 192 } 193 194 /** 195 * Sets the value of the publishedHostStrategy property. 196 * 197 * @param value 198 * allowed object is 199 * {@link String } 200 * 201 */ 202 public void setPublishedHostStrategy(String value) { 203 this.publishedHostStrategy = value; 204 } 205 206 /** 207 * Gets the value of the id property. 208 * 209 * @return 210 * possible object is 211 * {@link String } 212 * 213 */ 214 public String getId() { 215 return id; 216 } 217 218 /** 219 * Sets the value of the id property. 220 * 221 * @param value 222 * allowed object is 223 * {@link String } 224 * 225 */ 226 public void setId(String value) { 227 this.id = value; 228 } 229 230 /** 231 * Gets a map that contains attributes that aren't bound to any typed property on this class. 232 * 233 * <p> 234 * the map is keyed by the name of the attribute and 235 * the value is the string value of the attribute. 236 * 237 * the map returned by this method is live, and you can add new attribute 238 * by updating the map directly. Because of this design, there's no setter. 239 * 240 * 241 * @return 242 * always non-null 243 */ 244 public Map<QName, String> getOtherAttributes() { 245 return otherAttributes; 246 } 247 248 public String toString() { 249 final ToStringStrategy strategy = JAXBToStringStrategy.INSTANCE; 250 final StringBuilder buffer = new StringBuilder(); 251 append(null, buffer, strategy); 252 return buffer.toString(); 253 } 254 255 public StringBuilder append(ObjectLocator locator, StringBuilder buffer, ToStringStrategy strategy) { 256 strategy.appendStart(locator, this, buffer); 257 appendFields(locator, buffer, strategy); 258 strategy.appendEnd(locator, this, buffer); 259 return buffer; 260 } 261 262 public StringBuilder appendFields(ObjectLocator locator, StringBuilder buffer, ToStringStrategy strategy) { 263 { 264 List<Object> thePortMappingOrAny; 265 thePortMappingOrAny = (((this.portMappingOrAny!= null)&&(!this.portMappingOrAny.isEmpty()))?this.getPortMappingOrAny():null); 266 strategy.appendField(locator, this, "portMappingOrAny", buffer, thePortMappingOrAny); 267 } 268 { 269 String theClusterClientUriQuery; 270 theClusterClientUriQuery = this.getClusterClientUriQuery(); 271 strategy.appendField(locator, this, "clusterClientUriQuery", buffer, theClusterClientUriQuery); 272 } 273 { 274 String thePortMapping; 275 thePortMapping = this.getPortMapping(); 276 strategy.appendField(locator, this, "portMapping", buffer, thePortMapping); 277 } 278 { 279 String thePublishedHostStrategy; 280 thePublishedHostStrategy = this.getPublishedHostStrategy(); 281 strategy.appendField(locator, this, "publishedHostStrategy", buffer, thePublishedHostStrategy); 282 } 283 { 284 String theId; 285 theId = this.getId(); 286 strategy.appendField(locator, this, "id", buffer, theId); 287 } 288 return buffer; 289 } 290 291 public int hashCode(ObjectLocator locator, HashCodeStrategy strategy) { 292 int currentHashCode = 1; 293 { 294 List<Object> thePortMappingOrAny; 295 thePortMappingOrAny = (((this.portMappingOrAny!= null)&&(!this.portMappingOrAny.isEmpty()))?this.getPortMappingOrAny():null); 296 currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "portMappingOrAny", thePortMappingOrAny), currentHashCode, thePortMappingOrAny); 297 } 298 { 299 String theClusterClientUriQuery; 300 theClusterClientUriQuery = this.getClusterClientUriQuery(); 301 currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "clusterClientUriQuery", theClusterClientUriQuery), currentHashCode, theClusterClientUriQuery); 302 } 303 { 304 String thePortMapping; 305 thePortMapping = this.getPortMapping(); 306 currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "portMapping", thePortMapping), currentHashCode, thePortMapping); 307 } 308 { 309 String thePublishedHostStrategy; 310 thePublishedHostStrategy = this.getPublishedHostStrategy(); 311 currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "publishedHostStrategy", thePublishedHostStrategy), currentHashCode, thePublishedHostStrategy); 312 } 313 { 314 String theId; 315 theId = this.getId(); 316 currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "id", theId), currentHashCode, theId); 317 } 318 return currentHashCode; 319 } 320 321 public int hashCode() { 322 final HashCodeStrategy strategy = JAXBHashCodeStrategy.INSTANCE; 323 return this.hashCode(null, strategy); 324 } 325 326 public boolean equals(ObjectLocator thisLocator, ObjectLocator thatLocator, Object object, EqualsStrategy strategy) { 327 if (!(object instanceof DtoPublishedAddressPolicy)) { 328 return false; 329 } 330 if (this == object) { 331 return true; 332 } 333 final DtoPublishedAddressPolicy that = ((DtoPublishedAddressPolicy) object); 334 { 335 List<Object> lhsPortMappingOrAny; 336 lhsPortMappingOrAny = (((this.portMappingOrAny!= null)&&(!this.portMappingOrAny.isEmpty()))?this.getPortMappingOrAny():null); 337 List<Object> rhsPortMappingOrAny; 338 rhsPortMappingOrAny = (((that.portMappingOrAny!= null)&&(!that.portMappingOrAny.isEmpty()))?that.getPortMappingOrAny():null); 339 if (!strategy.equals(LocatorUtils.property(thisLocator, "portMappingOrAny", lhsPortMappingOrAny), LocatorUtils.property(thatLocator, "portMappingOrAny", rhsPortMappingOrAny), lhsPortMappingOrAny, rhsPortMappingOrAny)) { 340 return false; 341 } 342 } 343 { 344 String lhsClusterClientUriQuery; 345 lhsClusterClientUriQuery = this.getClusterClientUriQuery(); 346 String rhsClusterClientUriQuery; 347 rhsClusterClientUriQuery = that.getClusterClientUriQuery(); 348 if (!strategy.equals(LocatorUtils.property(thisLocator, "clusterClientUriQuery", lhsClusterClientUriQuery), LocatorUtils.property(thatLocator, "clusterClientUriQuery", rhsClusterClientUriQuery), lhsClusterClientUriQuery, rhsClusterClientUriQuery)) { 349 return false; 350 } 351 } 352 { 353 String lhsPortMapping; 354 lhsPortMapping = this.getPortMapping(); 355 String rhsPortMapping; 356 rhsPortMapping = that.getPortMapping(); 357 if (!strategy.equals(LocatorUtils.property(thisLocator, "portMapping", lhsPortMapping), LocatorUtils.property(thatLocator, "portMapping", rhsPortMapping), lhsPortMapping, rhsPortMapping)) { 358 return false; 359 } 360 } 361 { 362 String lhsPublishedHostStrategy; 363 lhsPublishedHostStrategy = this.getPublishedHostStrategy(); 364 String rhsPublishedHostStrategy; 365 rhsPublishedHostStrategy = that.getPublishedHostStrategy(); 366 if (!strategy.equals(LocatorUtils.property(thisLocator, "publishedHostStrategy", lhsPublishedHostStrategy), LocatorUtils.property(thatLocator, "publishedHostStrategy", rhsPublishedHostStrategy), lhsPublishedHostStrategy, rhsPublishedHostStrategy)) { 367 return false; 368 } 369 } 370 { 371 String lhsId; 372 lhsId = this.getId(); 373 String rhsId; 374 rhsId = that.getId(); 375 if (!strategy.equals(LocatorUtils.property(thisLocator, "id", lhsId), LocatorUtils.property(thatLocator, "id", rhsId), lhsId, rhsId)) { 376 return false; 377 } 378 } 379 return true; 380 } 381 382 public boolean equals(Object object) { 383 final EqualsStrategy strategy = new org.apache.activemq.plugin.jaxb2_commons.ElementAwareEqualsStrategy(); 384 return equals(null, null, object, strategy); 385 } 386 387 388 /** 389 * <p>Java class for anonymous complex type. 390 * 391 * <p>The following schema fragment specifies the expected content contained within this class. 392 * 393 * <pre> 394 * <complexType> 395 * <complexContent> 396 * <restriction base="{http://www.w3.org/2001/XMLSchema}anyType"> 397 * <sequence minOccurs="0"> 398 * <any maxOccurs="unbounded" minOccurs="0"/> 399 * </sequence> 400 * </restriction> 401 * </complexContent> 402 * </complexType> 403 * </pre> 404 * 405 * 406 */ 407 @XmlAccessorType(XmlAccessType.FIELD) 408 @XmlType(name = "", propOrder = { 409 "any" 410 }) 411 public static class PortMapping 412 implements Equals, HashCode, ToString 413 { 414 415 @XmlAnyElement(lax = true) 416 protected List<Object> any; 417 418 /** 419 * Gets the value of the any property. 420 * 421 * <p> 422 * This accessor method returns a reference to the live list, 423 * not a snapshot. Therefore any modification you make to the 424 * returned list will be present inside the JAXB object. 425 * This is why there is not a <CODE>set</CODE> method for the any property. 426 * 427 * <p> 428 * For example, to add a new item, do as follows: 429 * <pre> 430 * getAny().add(newItem); 431 * </pre> 432 * 433 * 434 * <p> 435 * Objects of the following type(s) are allowed in the list 436 * {@link Object } 437 * 438 * 439 */ 440 public List<Object> getAny() { 441 if (any == null) { 442 any = new ArrayList<Object>(); 443 } 444 return this.any; 445 } 446 447 public String toString() { 448 final ToStringStrategy strategy = JAXBToStringStrategy.INSTANCE; 449 final StringBuilder buffer = new StringBuilder(); 450 append(null, buffer, strategy); 451 return buffer.toString(); 452 } 453 454 public StringBuilder append(ObjectLocator locator, StringBuilder buffer, ToStringStrategy strategy) { 455 strategy.appendStart(locator, this, buffer); 456 appendFields(locator, buffer, strategy); 457 strategy.appendEnd(locator, this, buffer); 458 return buffer; 459 } 460 461 public StringBuilder appendFields(ObjectLocator locator, StringBuilder buffer, ToStringStrategy strategy) { 462 { 463 List<Object> theAny; 464 theAny = (((this.any!= null)&&(!this.any.isEmpty()))?this.getAny():null); 465 strategy.appendField(locator, this, "any", buffer, theAny); 466 } 467 return buffer; 468 } 469 470 public int hashCode(ObjectLocator locator, HashCodeStrategy strategy) { 471 int currentHashCode = 1; 472 { 473 List<Object> theAny; 474 theAny = (((this.any!= null)&&(!this.any.isEmpty()))?this.getAny():null); 475 currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "any", theAny), currentHashCode, theAny); 476 } 477 return currentHashCode; 478 } 479 480 public int hashCode() { 481 final HashCodeStrategy strategy = JAXBHashCodeStrategy.INSTANCE; 482 return this.hashCode(null, strategy); 483 } 484 485 public boolean equals(ObjectLocator thisLocator, ObjectLocator thatLocator, Object object, EqualsStrategy strategy) { 486 if (!(object instanceof DtoPublishedAddressPolicy.PortMapping)) { 487 return false; 488 } 489 if (this == object) { 490 return true; 491 } 492 final DtoPublishedAddressPolicy.PortMapping that = ((DtoPublishedAddressPolicy.PortMapping) object); 493 { 494 List<Object> lhsAny; 495 lhsAny = (((this.any!= null)&&(!this.any.isEmpty()))?this.getAny():null); 496 List<Object> rhsAny; 497 rhsAny = (((that.any!= null)&&(!that.any.isEmpty()))?that.getAny():null); 498 if (!strategy.equals(LocatorUtils.property(thisLocator, "any", lhsAny), LocatorUtils.property(thatLocator, "any", rhsAny), lhsAny, rhsAny)) { 499 return false; 500 } 501 } 502 return true; 503 } 504 505 public boolean equals(Object object) { 506 final EqualsStrategy strategy = new org.apache.activemq.plugin.jaxb2_commons.ElementAwareEqualsStrategy(); 507 return equals(null, null, object, strategy); 508 } 509 510 } 511 512}