com.cisco.oss.foundation.configuration.xml.jaxb.ParameterOverride Maven / Gradle / Ivy
//
// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.4
// See http://java.sun.com/xml/jaxb
// Any modifications to this file will be lost upon recompilation of the source schema.
// Generated on: 2014.06.05 at 10:11:28 AM EDT
//
package com.cisco.oss.foundation.configuration.xml.jaxb;
import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
import javax.xml.bind.annotation.XmlAttribute;
import javax.xml.bind.annotation.XmlElement;
import javax.xml.bind.annotation.XmlType;
import org.jvnet.jaxb2_commons.lang.CopyStrategy;
import org.jvnet.jaxb2_commons.lang.CopyTo;
import org.jvnet.jaxb2_commons.lang.Equals;
import org.jvnet.jaxb2_commons.lang.EqualsStrategy;
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.ToString;
import org.jvnet.jaxb2_commons.lang.ToStringStrategy;
import org.jvnet.jaxb2_commons.locator.ObjectLocator;
import org.jvnet.jaxb2_commons.locator.util.LocatorUtils;
/**
* Java class for ParameterOverride complex type.
*
*
The following schema fragment specifies the expected content contained within this class.
*
*
* <complexType name="ParameterOverride">
* <complexContent>
* <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
* <sequence>
* <element name="InstallDefault" type="{}ParameterValue"/>
* </sequence>
* <attribute name="name" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
* <attribute name="instantiationLevel" use="required" type="{}HierarchyLevel" />
* </restriction>
* </complexContent>
* </complexType>
*
*
*
*/
@XmlAccessorType(XmlAccessType.FIELD)
@XmlType(name = "ParameterOverride", propOrder = {
"installDefault"
})
public class ParameterOverride
implements Cloneable, CopyTo, Equals, ToString
{
@XmlElement(name = "InstallDefault", required = true)
protected ParameterValue installDefault;
@XmlAttribute(name = "name", required = true)
protected String name;
@XmlAttribute(name = "instantiationLevel", required = true)
protected HierarchyLevel instantiationLevel;
/**
* Gets the value of the installDefault property.
*
* @return
* possible object is
* {@link ParameterValue }
*
*/
public ParameterValue getInstallDefault() {
return installDefault;
}
/**
* Sets the value of the installDefault property.
*
* @param value
* allowed object is
* {@link ParameterValue }
*
*/
public void setInstallDefault(ParameterValue value) {
this.installDefault = value;
}
/**
* Gets the value of the name property.
*
* @return
* possible object is
* {@link String }
*
*/
public String getName() {
return name;
}
/**
* Sets the value of the name property.
*
* @param value
* allowed object is
* {@link String }
*
*/
public void setName(String value) {
this.name = value;
}
/**
* Gets the value of the instantiationLevel property.
*
* @return
* possible object is
* {@link HierarchyLevel }
*
*/
public HierarchyLevel getInstantiationLevel() {
return instantiationLevel;
}
/**
* Sets the value of the instantiationLevel property.
*
* @param value
* allowed object is
* {@link HierarchyLevel }
*
*/
public void setInstantiationLevel(HierarchyLevel value) {
this.instantiationLevel = value;
}
public String toString() {
final ToStringStrategy strategy = JAXBToStringStrategy.INSTANCE;
final StringBuilder buffer = new StringBuilder();
append(null, buffer, strategy);
return buffer.toString();
}
public StringBuilder append(ObjectLocator locator, StringBuilder buffer, ToStringStrategy strategy) {
strategy.appendStart(locator, this, buffer);
appendFields(locator, buffer, strategy);
strategy.appendEnd(locator, this, buffer);
return buffer;
}
public StringBuilder appendFields(ObjectLocator locator, StringBuilder buffer, ToStringStrategy strategy) {
{
ParameterValue theInstallDefault;
theInstallDefault = this.getInstallDefault();
strategy.appendField(locator, this, "installDefault", buffer, theInstallDefault);
}
{
String theName;
theName = this.getName();
strategy.appendField(locator, this, "name", buffer, theName);
}
{
HierarchyLevel theInstantiationLevel;
theInstantiationLevel = this.getInstantiationLevel();
strategy.appendField(locator, this, "instantiationLevel", buffer, theInstantiationLevel);
}
return buffer;
}
public Object clone() {
return copyTo(createNewInstance());
}
public Object copyTo(Object target) {
final CopyStrategy strategy = JAXBCopyStrategy.INSTANCE;
return copyTo(null, target, strategy);
}
public Object copyTo(ObjectLocator locator, Object target, CopyStrategy strategy) {
final Object draftCopy = ((target == null)?createNewInstance():target);
if (draftCopy instanceof ParameterOverride) {
final ParameterOverride copy = ((ParameterOverride) draftCopy);
if (this.installDefault!= null) {
ParameterValue sourceInstallDefault;
sourceInstallDefault = this.getInstallDefault();
ParameterValue copyInstallDefault = ((ParameterValue) strategy.copy(LocatorUtils.property(locator, "installDefault", sourceInstallDefault), sourceInstallDefault));
copy.setInstallDefault(copyInstallDefault);
} else {
copy.installDefault = null;
}
if (this.name!= null) {
String sourceName;
sourceName = this.getName();
String copyName = ((String) strategy.copy(LocatorUtils.property(locator, "name", sourceName), sourceName));
copy.setName(copyName);
} else {
copy.name = null;
}
if (this.instantiationLevel!= null) {
HierarchyLevel sourceInstantiationLevel;
sourceInstantiationLevel = this.getInstantiationLevel();
HierarchyLevel copyInstantiationLevel = ((HierarchyLevel) strategy.copy(LocatorUtils.property(locator, "instantiationLevel", sourceInstantiationLevel), sourceInstantiationLevel));
copy.setInstantiationLevel(copyInstantiationLevel);
} else {
copy.instantiationLevel = null;
}
}
return draftCopy;
}
public Object createNewInstance() {
return new ParameterOverride();
}
public boolean equals(ObjectLocator thisLocator, ObjectLocator thatLocator, Object object, EqualsStrategy strategy) {
if (!(object instanceof ParameterOverride)) {
return false;
}
if (this == object) {
return true;
}
final ParameterOverride that = ((ParameterOverride) object);
{
ParameterValue lhsInstallDefault;
lhsInstallDefault = this.getInstallDefault();
ParameterValue rhsInstallDefault;
rhsInstallDefault = that.getInstallDefault();
if (!strategy.equals(LocatorUtils.property(thisLocator, "installDefault", lhsInstallDefault), LocatorUtils.property(thatLocator, "installDefault", rhsInstallDefault), lhsInstallDefault, rhsInstallDefault)) {
return false;
}
}
{
String lhsName;
lhsName = this.getName();
String rhsName;
rhsName = that.getName();
if (!strategy.equals(LocatorUtils.property(thisLocator, "name", lhsName), LocatorUtils.property(thatLocator, "name", rhsName), lhsName, rhsName)) {
return false;
}
}
{
HierarchyLevel lhsInstantiationLevel;
lhsInstantiationLevel = this.getInstantiationLevel();
HierarchyLevel rhsInstantiationLevel;
rhsInstantiationLevel = that.getInstantiationLevel();
if (!strategy.equals(LocatorUtils.property(thisLocator, "instantiationLevel", lhsInstantiationLevel), LocatorUtils.property(thatLocator, "instantiationLevel", rhsInstantiationLevel), lhsInstantiationLevel, rhsInstantiationLevel)) {
return false;
}
}
return true;
}
public boolean equals(Object object) {
final EqualsStrategy strategy = JAXBEqualsStrategy.INSTANCE;
return equals(null, null, object, strategy);
}
}