org.openestate.is24.restapi.xml.topplacement.Topplacement Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of OpenEstate-IS24-REST Show documentation
Show all versions of OpenEstate-IS24-REST Show documentation
OpenEstate-IS24-REST is a client library for the REST-Webservice of ImmobilienScout24.de written in Java.
package org.openestate.is24.restapi.xml.topplacement;
import java.io.Serializable;
import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
import javax.xml.bind.annotation.XmlAttribute;
import javax.xml.bind.annotation.XmlType;
import org.jvnet.jaxb2_commons.lang.CopyStrategy2;
import org.jvnet.jaxb2_commons.lang.CopyTo2;
import org.jvnet.jaxb2_commons.lang.Equals2;
import org.jvnet.jaxb2_commons.lang.EqualsStrategy2;
import org.jvnet.jaxb2_commons.lang.JAXBCopyStrategy;
import org.jvnet.jaxb2_commons.lang.JAXBEqualsStrategy;
import org.jvnet.jaxb2_commons.lang.JAXBToStringStrategy;
import org.jvnet.jaxb2_commons.lang.ToString2;
import org.jvnet.jaxb2_commons.lang.ToStringStrategy2;
import org.jvnet.jaxb2_commons.locator.ObjectLocator;
import org.jvnet.jaxb2_commons.locator.util.LocatorUtils;
import org.openestate.is24.restapi.xml.common.DateRange;
/**
* Topplacement
*
* Java class for Topplacement complex type.
*
*
The following schema fragment specifies the expected content contained within this class.
*
*
* <complexType name="Topplacement">
* <complexContent>
* <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
* <sequence>
* <element name="messageCode" type="{http://www.w3.org/2001/XMLSchema}string" maxOccurs="0" minOccurs="0"/>
* <element name="message" type="{http://www.w3.org/2001/XMLSchema}string" maxOccurs="0" minOccurs="0"/>
* <element name="servicePeriod" type="{http://rest.immobilienscout24.de/schema/common/1.0}DateRange" minOccurs="0"/>
* <element name="externalId" type="{http://www.w3.org/2001/XMLSchema}string" maxOccurs="0" minOccurs="0"/>
* </sequence>
* <attribute name="realestateid" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
* <attribute name="voucher" type="{http://www.w3.org/2001/XMLSchema}string" />
* </restriction>
* </complexContent>
* </complexType>
*
*
*
*/
@XmlAccessorType(XmlAccessType.FIELD)
@XmlType(name = "Topplacement", propOrder = {
"servicePeriod"
})
public class Topplacement implements Serializable, Cloneable, CopyTo2, Equals2, ToString2
{
protected DateRange servicePeriod;
@XmlAttribute(name = "realestateid", required = true)
protected String realestateid;
@XmlAttribute(name = "voucher")
protected String voucher;
/**
* Gets the value of the servicePeriod property.
*
* @return
* possible object is
* {@link DateRange }
*
*/
public DateRange getServicePeriod() {
return servicePeriod;
}
/**
* Sets the value of the servicePeriod property.
*
* @param value
* allowed object is
* {@link DateRange }
*
*/
public void setServicePeriod(DateRange value) {
this.servicePeriod = value;
}
/**
* Gets the value of the realestateid property.
*
* @return
* possible object is
* {@link String }
*
*/
public String getRealestateid() {
return realestateid;
}
/**
* Sets the value of the realestateid property.
*
* @param value
* allowed object is
* {@link String }
*
*/
public void setRealestateid(String value) {
this.realestateid = value;
}
/**
* Gets the value of the voucher property.
*
* @return
* possible object is
* {@link String }
*
*/
public String getVoucher() {
return voucher;
}
/**
* Sets the value of the voucher property.
*
* @param value
* allowed object is
* {@link String }
*
*/
public void setVoucher(String value) {
this.voucher = value;
}
public String toString() {
final ToStringStrategy2 strategy = JAXBToStringStrategy.INSTANCE;
final StringBuilder buffer = new StringBuilder();
append(null, buffer, strategy);
return buffer.toString();
}
public StringBuilder append(ObjectLocator locator, StringBuilder buffer, ToStringStrategy2 strategy) {
strategy.appendStart(locator, this, buffer);
appendFields(locator, buffer, strategy);
strategy.appendEnd(locator, this, buffer);
return buffer;
}
public StringBuilder appendFields(ObjectLocator locator, StringBuilder buffer, ToStringStrategy2 strategy) {
{
DateRange theServicePeriod;
theServicePeriod = this.getServicePeriod();
strategy.appendField(locator, this, "servicePeriod", buffer, theServicePeriod, (this.servicePeriod!= null));
}
{
String theRealestateid;
theRealestateid = this.getRealestateid();
strategy.appendField(locator, this, "realestateid", buffer, theRealestateid, (this.realestateid!= null));
}
{
String theVoucher;
theVoucher = this.getVoucher();
strategy.appendField(locator, this, "voucher", buffer, theVoucher, (this.voucher!= null));
}
return buffer;
}
public Object clone() {
return copyTo(createNewInstance());
}
public Object copyTo(Object target) {
final CopyStrategy2 strategy = JAXBCopyStrategy.INSTANCE;
return copyTo(null, target, strategy);
}
public Object copyTo(ObjectLocator locator, Object target, CopyStrategy2 strategy) {
final Object draftCopy = ((target == null)?createNewInstance():target);
if (draftCopy instanceof Topplacement) {
final Topplacement copy = ((Topplacement) draftCopy);
{
Boolean servicePeriodShouldBeCopiedAndSet = strategy.shouldBeCopiedAndSet(locator, (this.servicePeriod!= null));
if (servicePeriodShouldBeCopiedAndSet == Boolean.TRUE) {
DateRange sourceServicePeriod;
sourceServicePeriod = this.getServicePeriod();
DateRange copyServicePeriod = ((DateRange) strategy.copy(LocatorUtils.property(locator, "servicePeriod", sourceServicePeriod), sourceServicePeriod, (this.servicePeriod!= null)));
copy.setServicePeriod(copyServicePeriod);
} else {
if (servicePeriodShouldBeCopiedAndSet == Boolean.FALSE) {
copy.servicePeriod = null;
}
}
}
{
Boolean realestateidShouldBeCopiedAndSet = strategy.shouldBeCopiedAndSet(locator, (this.realestateid!= null));
if (realestateidShouldBeCopiedAndSet == Boolean.TRUE) {
String sourceRealestateid;
sourceRealestateid = this.getRealestateid();
String copyRealestateid = ((String) strategy.copy(LocatorUtils.property(locator, "realestateid", sourceRealestateid), sourceRealestateid, (this.realestateid!= null)));
copy.setRealestateid(copyRealestateid);
} else {
if (realestateidShouldBeCopiedAndSet == Boolean.FALSE) {
copy.realestateid = null;
}
}
}
{
Boolean voucherShouldBeCopiedAndSet = strategy.shouldBeCopiedAndSet(locator, (this.voucher!= null));
if (voucherShouldBeCopiedAndSet == Boolean.TRUE) {
String sourceVoucher;
sourceVoucher = this.getVoucher();
String copyVoucher = ((String) strategy.copy(LocatorUtils.property(locator, "voucher", sourceVoucher), sourceVoucher, (this.voucher!= null)));
copy.setVoucher(copyVoucher);
} else {
if (voucherShouldBeCopiedAndSet == Boolean.FALSE) {
copy.voucher = null;
}
}
}
}
return draftCopy;
}
public Object createNewInstance() {
return new Topplacement();
}
public boolean equals(ObjectLocator thisLocator, ObjectLocator thatLocator, Object object, EqualsStrategy2 strategy) {
if ((object == null)||(this.getClass()!= object.getClass())) {
return false;
}
if (this == object) {
return true;
}
final Topplacement that = ((Topplacement) object);
{
DateRange lhsServicePeriod;
lhsServicePeriod = this.getServicePeriod();
DateRange rhsServicePeriod;
rhsServicePeriod = that.getServicePeriod();
if (!strategy.equals(LocatorUtils.property(thisLocator, "servicePeriod", lhsServicePeriod), LocatorUtils.property(thatLocator, "servicePeriod", rhsServicePeriod), lhsServicePeriod, rhsServicePeriod, (this.servicePeriod!= null), (that.servicePeriod!= null))) {
return false;
}
}
{
String lhsRealestateid;
lhsRealestateid = this.getRealestateid();
String rhsRealestateid;
rhsRealestateid = that.getRealestateid();
if (!strategy.equals(LocatorUtils.property(thisLocator, "realestateid", lhsRealestateid), LocatorUtils.property(thatLocator, "realestateid", rhsRealestateid), lhsRealestateid, rhsRealestateid, (this.realestateid!= null), (that.realestateid!= null))) {
return false;
}
}
{
String lhsVoucher;
lhsVoucher = this.getVoucher();
String rhsVoucher;
rhsVoucher = that.getVoucher();
if (!strategy.equals(LocatorUtils.property(thisLocator, "voucher", lhsVoucher), LocatorUtils.property(thatLocator, "voucher", rhsVoucher), lhsVoucher, rhsVoucher, (this.voucher!= null), (that.voucher!= null))) {
return false;
}
}
return true;
}
public boolean equals(Object object) {
final EqualsStrategy2 strategy = JAXBEqualsStrategy.INSTANCE;
return equals(null, null, object, strategy);
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy