no.nhn.schemas.reg.hprv2.WSEksportFormat Maven / Gradle / Ivy
package no.nhn.schemas.reg.hprv2;
import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
import javax.xml.bind.annotation.XmlElement;
import javax.xml.bind.annotation.XmlType;
import org.jvnet.jaxb2_commons.lang.Equals;
import org.jvnet.jaxb2_commons.lang.EqualsStrategy;
import org.jvnet.jaxb2_commons.lang.HashCode;
import org.jvnet.jaxb2_commons.lang.HashCodeStrategy;
import org.jvnet.jaxb2_commons.lang.JAXBEqualsStrategy;
import org.jvnet.jaxb2_commons.lang.JAXBHashCodeStrategy;
import org.jvnet.jaxb2_commons.locator.ObjectLocator;
import org.jvnet.jaxb2_commons.locator.util.LocatorUtils;
/**
* Java class for EksportFormat complex type.
*
*
The following schema fragment specifies the expected content contained within this class.
*
*
* <complexType name="EksportFormat">
* <complexContent>
* <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
* <sequence>
* <element name="Type" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/>
* <element name="Versjon" type="{http://www.w3.org/2001/XMLSchema}int" minOccurs="0"/>
* </sequence>
* </restriction>
* </complexContent>
* </complexType>
*
*
*
*/
@XmlAccessorType(XmlAccessType.FIELD)
@XmlType(name = "EksportFormat", propOrder = {
"type",
"versjon"
})
public class WSEksportFormat
implements Equals, HashCode
{
@XmlElement(name = "Type", nillable = true)
protected String type;
@XmlElement(name = "Versjon")
protected Integer versjon;
/**
* Gets the value of the type property.
*
* @return
* possible object is
* {@link String }
*
*/
public String getType() {
return type;
}
/**
* Sets the value of the type property.
*
* @param value
* allowed object is
* {@link String }
*
*/
public void setType(String value) {
this.type = value;
}
/**
* Gets the value of the versjon property.
*
* @return
* possible object is
* {@link Integer }
*
*/
public Integer getVersjon() {
return versjon;
}
/**
* Sets the value of the versjon property.
*
* @param value
* allowed object is
* {@link Integer }
*
*/
public void setVersjon(Integer value) {
this.versjon = value;
}
public int hashCode(ObjectLocator locator, HashCodeStrategy strategy) {
int currentHashCode = 1;
{
String theType;
theType = this.getType();
currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "type", theType), currentHashCode, theType);
}
{
Integer theVersjon;
theVersjon = this.getVersjon();
currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "versjon", theVersjon), currentHashCode, theVersjon);
}
return currentHashCode;
}
public int hashCode() {
final HashCodeStrategy strategy = JAXBHashCodeStrategy.INSTANCE;
return this.hashCode(null, strategy);
}
public boolean equals(ObjectLocator thisLocator, ObjectLocator thatLocator, Object object, EqualsStrategy strategy) {
if (!(object instanceof WSEksportFormat)) {
return false;
}
if (this == object) {
return true;
}
final WSEksportFormat that = ((WSEksportFormat) object);
{
String lhsType;
lhsType = this.getType();
String rhsType;
rhsType = that.getType();
if (!strategy.equals(LocatorUtils.property(thisLocator, "type", lhsType), LocatorUtils.property(thatLocator, "type", rhsType), lhsType, rhsType)) {
return false;
}
}
{
Integer lhsVersjon;
lhsVersjon = this.getVersjon();
Integer rhsVersjon;
rhsVersjon = that.getVersjon();
if (!strategy.equals(LocatorUtils.property(thisLocator, "versjon", lhsVersjon), LocatorUtils.property(thatLocator, "versjon", rhsVersjon), lhsVersjon, rhsVersjon)) {
return false;
}
}
return true;
}
public boolean equals(Object object) {
final EqualsStrategy strategy = JAXBEqualsStrategy.INSTANCE;
return equals(null, null, object, strategy);
}
public WSEksportFormat withType(String value) {
setType(value);
return this;
}
public WSEksportFormat withVersjon(Integer value) {
setVersjon(value);
return this;
}
}