//
// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.4
// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>
// 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;
/**
* <p>Java class for ParameterType complex type.
*
* <p>The following schema fragment specifies the expected content contained within this class.
*
* <pre>
* <complexType name="ParameterType">
* <complexContent>
* <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
* <sequence>
* <element name="StructureDefinition" type="{}StructureDefinition" minOccurs="0"/>
* </sequence>
* <attribute name="name" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
* <attribute name="type" use="required" type="{}ParameterKind" />
* <attribute name="description" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
* <attribute name="isArray" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" />
* <attribute name="required" type="{http://www.w3.org/2001/XMLSchema}boolean" default="true" />
* <attribute name="hidden" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" />
* <attribute name="readOnly" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" />
* <attribute name="advanced" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" />
* <attribute name="requiresRestart" type="{http://www.w3.org/2001/XMLSchema}boolean" default="false" />
* <attribute name="unit" type="{http://www.w3.org/2001/XMLSchema}string" />
* </restriction>
* </complexContent>
* </complexType>
* </pre>
*
*
*/
@XmlAccessorType(XmlAccessType.FIELD)
@XmlType(name = "ParameterType", propOrder = {
"structureDefinition"
})
public class ParameterType
implements Cloneable, CopyTo, Equals, ToString
{
@XmlElement(name = "StructureDefinition")
protected StructureDefinition structureDefinition;
@XmlAttribute(name = "name", required = true)
protected String name;
@XmlAttribute(name = "type", required = true)
protected ParameterKind type;
@XmlAttribute(name = "description", required = true)
protected String description;
@XmlAttribute(name = "isArray")
protected Boolean isArray;
@XmlAttribute(name = "required")
protected Boolean required;
@XmlAttribute(name = "hidden")
protected Boolean hidden;
@XmlAttribute(name = "readOnly")
protected Boolean readOnly;
@XmlAttribute(name = "advanced")
protected Boolean advanced;
@XmlAttribute(name = "requiresRestart")
protected Boolean requiresRestart;
@XmlAttribute(name = "unit")
protected String unit;
/**
* Gets the value of the structureDefinition property.
*
* @return
* possible object is
* {@link StructureDefinition }
*
*/
public StructureDefinition getStructureDefinition() {
return structureDefinition;
}
/**
* Sets the value of the structureDefinition property.
*
* @param value
* allowed object is
* {@link StructureDefinition }
*
*/
public void setStructureDefinition(StructureDefinition value) {
this.structureDefinition = 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 type property.
*
* @return
* possible object is
* {@link ParameterKind }
*
*/
public ParameterKind getType() {
return type;
}
/**
* Sets the value of the type property.
*
* @param value
* allowed object is
* {@link ParameterKind }
*
*/
public void setType(ParameterKind value) {
this.type = value;
}
/**
* Gets the value of the description property.
*
* @return
* possible object is
* {@link String }
*
*/
public String getDescription() {
return description;
}
/**
* Sets the value of the description property.
*
* @param value
* allowed object is
* {@link String }
*
*/
public void setDescription(String value) {
this.description = value;
}
/**
* Gets the value of the isArray property.
*
* @return
* possible object is
* {@link Boolean }
*
*/
public boolean isIsArray() {
if (isArray == null) {
return false;
} else {
return isArray;
}
}
/**
* Sets the value of the isArray property.
*
* @param value
* allowed object is
* {@link Boolean }
*
*/
public void setIsArray(Boolean value) {
this.isArray = value;
}
/**
* Gets the value of the required property.
*
* @return
* possible object is
* {@link Boolean }
*
*/
public boolean isRequired() {
if (required == null) {
return true;
} else {
return required;
}
}
/**
* Sets the value of the required property.
*
* @param value
* allowed object is
* {@link Boolean }
*
*/
public void setRequired(Boolean value) {
this.required = value;
}
/**
* Gets the value of the hidden property.
*
* @return
* possible object is
* {@link Boolean }
*
*/
public boolean isHidden() {
if (hidden == null) {
return false;
} else {
return hidden;
}
}
/**
* Sets the value of the hidden property.
*
* @param value
* allowed object is
* {@link Boolean }
*
*/
public void setHidden(Boolean value) {
this.hidden = value;
}
/**
* Gets the value of the readOnly property.
*
* @return
* possible object is
* {@link Boolean }
*
*/
public boolean isReadOnly() {
if (readOnly == null) {
return false;
} else {
return readOnly;
}
}
/**
* Sets the value of the readOnly property.
*
* @param value
* allowed object is
* {@link Boolean }
*
*/
public void setReadOnly(Boolean value) {
this.readOnly = value;
}
/**
* Gets the value of the advanced property.
*
* @return
* possible object is
* {@link Boolean }
*
*/
public boolean isAdvanced() {
if (advanced == null) {
return false;
} else {
return advanced;
}
}
/**
* Sets the value of the advanced property.
*
* @param value
* allowed object is
* {@link Boolean }
*
*/
public void setAdvanced(Boolean value) {
this.advanced = value;
}
/**
* Gets the value of the requiresRestart property.
*
* @return
* possible object is
* {@link Boolean }
*
*/
public boolean isRequiresRestart() {
if (requiresRestart == null) {
return false;
} else {
return requiresRestart;
}
}
/**
* Sets the value of the requiresRestart property.
*
* @param value
* allowed object is
* {@link Boolean }
*
*/
public void setRequiresRestart(Boolean value) {
this.requiresRestart = value;
}
/**
* Gets the value of the unit property.
*
* @return
* possible object is
* {@link String }
*
*/
public String getUnit() {
return unit;
}
/**
* Sets the value of the unit property.
*
* @param value
* allowed object is
* {@link String }
*
*/
public void setUnit(String value) {
this.unit = 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) {
{
StructureDefinition theStructureDefinition;
theStructureDefinition = this.getStructureDefinition();
strategy.appendField(locator, this, "structureDefinition", buffer, theStructureDefinition);
}
{
String theName;
theName = this.getName();
strategy.appendField(locator, this, "name", buffer, theName);
}
{
ParameterKind theType;
theType = this.getType();
strategy.appendField(locator, this, "type", buffer, theType);
}
{
String theDescription;
theDescription = this.getDescription();
strategy.appendField(locator, this, "description", buffer, theDescription);
}
{
boolean theIsArray;
theIsArray = ((this.isArray!= null)?this.isIsArray():false);
strategy.appendField(locator, this, "isArray", buffer, theIsArray);
}
{
boolean theRequired;
theRequired = ((this.required!= null)?this.isRequired():false);
strategy.appendField(locator, this, "required", buffer, theRequired);
}
{
boolean theHidden;
theHidden = ((this.hidden!= null)?this.isHidden():false);
strategy.appendField(locator, this, "hidden", buffer, theHidden);
}
{
boolean theReadOnly;
theReadOnly = ((this.readOnly!= null)?this.isReadOnly():false);
strategy.appendField(locator, this, "readOnly", buffer, theReadOnly);
}
{
boolean theAdvanced;
theAdvanced = ((this.advanced!= null)?this.isAdvanced():false);
strategy.appendField(locator, this, "advanced", buffer, theAdvanced);
}
{
boolean theRequiresRestart;
theRequiresRestart = ((this.requiresRestart!= null)?this.isRequiresRestart():false);
strategy.appendField(locator, this, "requiresRestart", buffer, theRequiresRestart);
}
{
String theUnit;
theUnit = this.getUnit();
strategy.appendField(locator, this, "unit", buffer, theUnit);
}
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 ParameterType) {
final ParameterType copy = ((ParameterType) draftCopy);
if (this.structureDefinition!= null) {
StructureDefinition sourceStructureDefinition;
sourceStructureDefinition = this.getStructureDefinition();
StructureDefinition copyStructureDefinition = ((StructureDefinition) strategy.copy(LocatorUtils.property(locator, "structureDefinition", sourceStructureDefinition), sourceStructureDefinition));
copy.setStructureDefinition(copyStructureDefinition);
} else {
copy.structureDefinition = 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.type!= null) {
ParameterKind sourceType;
sourceType = this.getType();
ParameterKind copyType = ((ParameterKind) strategy.copy(LocatorUtils.property(locator, "type", sourceType), sourceType));
copy.setType(copyType);
} else {
copy.type = null;
}
if (this.description!= null) {
String sourceDescription;
sourceDescription = this.getDescription();
String copyDescription = ((String) strategy.copy(LocatorUtils.property(locator, "description", sourceDescription), sourceDescription));
copy.setDescription(copyDescription);
} else {
copy.description = null;
}
if (this.isArray!= null) {
boolean sourceIsArray;
sourceIsArray = ((this.isArray!= null)?this.isIsArray():false);
boolean copyIsArray = strategy.copy(LocatorUtils.property(locator, "isArray", sourceIsArray), sourceIsArray);
copy.setIsArray(copyIsArray);
} else {
copy.isArray = null;
}
if (this.required!= null) {
boolean sourceRequired;
sourceRequired = ((this.required!= null)?this.isRequired():false);
boolean copyRequired = strategy.copy(LocatorUtils.property(locator, "required", sourceRequired), sourceRequired);
copy.setRequired(copyRequired);
} else {
copy.required = null;
}
if (this.hidden!= null) {
boolean sourceHidden;
sourceHidden = ((this.hidden!= null)?this.isHidden():false);
boolean copyHidden = strategy.copy(LocatorUtils.property(locator, "hidden", sourceHidden), sourceHidden);
copy.setHidden(copyHidden);
} else {
copy.hidden = null;
}
if (this.readOnly!= null) {
boolean sourceReadOnly;
sourceReadOnly = ((this.readOnly!= null)?this.isReadOnly():false);
boolean copyReadOnly = strategy.copy(LocatorUtils.property(locator, "readOnly", sourceReadOnly), sourceReadOnly);
copy.setReadOnly(copyReadOnly);
} else {
copy.readOnly = null;
}
if (this.advanced!= null) {
boolean sourceAdvanced;
sourceAdvanced = ((this.advanced!= null)?this.isAdvanced():false);
boolean copyAdvanced = strategy.copy(LocatorUtils.property(locator, "advanced", sourceAdvanced), sourceAdvanced);
copy.setAdvanced(copyAdvanced);
} else {
copy.advanced = null;
}
if (this.requiresRestart!= null) {
boolean sourceRequiresRestart;
sourceRequiresRestart = ((this.requiresRestart!= null)?this.isRequiresRestart():false);
boolean copyRequiresRestart = strategy.copy(LocatorUtils.property(locator, "requiresRestart", sourceRequiresRestart), sourceRequiresRestart);
copy.setRequiresRestart(copyRequiresRestart);
} else {
copy.requiresRestart = null;
}
if (this.unit!= null) {
String sourceUnit;
sourceUnit = this.getUnit();
String copyUnit = ((String) strategy.copy(LocatorUtils.property(locator, "unit", sourceUnit), sourceUnit));
copy.setUnit(copyUnit);
} else {
copy.unit = null;
}
}
return draftCopy;
}
public Object createNewInstance() {
return new ParameterType();
}
public boolean equals(ObjectLocator thisLocator, ObjectLocator thatLocator, Object object, EqualsStrategy strategy) {
if (!(object instanceof ParameterType)) {
return false;
}
if (this == object) {
return true;
}
final ParameterType that = ((ParameterType) object);
{
StructureDefinition lhsStructureDefinition;
lhsStructureDefinition = this.getStructureDefinition();
StructureDefinition rhsStructureDefinition;
rhsStructureDefinition = that.getStructureDefinition();
if (!strategy.equals(LocatorUtils.property(thisLocator, "structureDefinition", lhsStructureDefinition), LocatorUtils.property(thatLocator, "structureDefinition", rhsStructureDefinition), lhsStructureDefinition, rhsStructureDefinition)) {
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;
}
}
{
ParameterKind lhsType;
lhsType = this.getType();
ParameterKind rhsType;
rhsType = that.getType();
if (!strategy.equals(LocatorUtils.property(thisLocator, "type", lhsType), LocatorUtils.property(thatLocator, "type", rhsType), lhsType, rhsType)) {
return false;
}
}
{
String lhsDescription;
lhsDescription = this.getDescription();
String rhsDescription;
rhsDescription = that.getDescription();
if (!strategy.equals(LocatorUtils.property(thisLocator, "description", lhsDescription), LocatorUtils.property(thatLocator, "description", rhsDescription), lhsDescription, rhsDescription)) {
return false;
}
}
{
boolean lhsIsArray;
lhsIsArray = ((this.isArray!= null)?this.isIsArray():false);
boolean rhsIsArray;
rhsIsArray = ((that.isArray!= null)?that.isIsArray():false);
if (!strategy.equals(LocatorUtils.property(thisLocator, "isArray", lhsIsArray), LocatorUtils.property(thatLocator, "isArray", rhsIsArray), lhsIsArray, rhsIsArray)) {
return false;
}
}
{
boolean lhsRequired;
lhsRequired = ((this.required!= null)?this.isRequired():false);
boolean rhsRequired;
rhsRequired = ((that.required!= null)?that.isRequired():false);
if (!strategy.equals(LocatorUtils.property(thisLocator, "required", lhsRequired), LocatorUtils.property(thatLocator, "required", rhsRequired), lhsRequired, rhsRequired)) {
return false;
}
}
{
boolean lhsHidden;
lhsHidden = ((this.hidden!= null)?this.isHidden():false);
boolean rhsHidden;
rhsHidden = ((that.hidden!= null)?that.isHidden():false);
if (!strategy.equals(LocatorUtils.property(thisLocator, "hidden", lhsHidden), LocatorUtils.property(thatLocator, "hidden", rhsHidden), lhsHidden, rhsHidden)) {
return false;
}
}
{
boolean lhsReadOnly;
lhsReadOnly = ((this.readOnly!= null)?this.isReadOnly():false);
boolean rhsReadOnly;
rhsReadOnly = ((that.readOnly!= null)?that.isReadOnly():false);
if (!strategy.equals(LocatorUtils.property(thisLocator, "readOnly", lhsReadOnly), LocatorUtils.property(thatLocator, "readOnly", rhsReadOnly), lhsReadOnly, rhsReadOnly)) {
return false;
}
}
{
boolean lhsAdvanced;
lhsAdvanced = ((this.advanced!= null)?this.isAdvanced():false);
boolean rhsAdvanced;
rhsAdvanced = ((that.advanced!= null)?that.isAdvanced():false);
if (!strategy.equals(LocatorUtils.property(thisLocator, "advanced", lhsAdvanced), LocatorUtils.property(thatLocator, "advanced", rhsAdvanced), lhsAdvanced, rhsAdvanced)) {
return false;
}
}
{
boolean lhsRequiresRestart;
lhsRequiresRestart = ((this.requiresRestart!= null)?this.isRequiresRestart():false);
boolean rhsRequiresRestart;
rhsRequiresRestart = ((that.requiresRestart!= null)?that.isRequiresRestart():false);
if (!strategy.equals(LocatorUtils.property(thisLocator, "requiresRestart", lhsRequiresRestart), LocatorUtils.property(thatLocator, "requiresRestart", rhsRequiresRestart), lhsRequiresRestart, rhsRequiresRestart)) {
return false;
}
}
{
String lhsUnit;
lhsUnit = this.getUnit();
String rhsUnit;
rhsUnit = that.getUnit();
if (!strategy.equals(LocatorUtils.property(thisLocator, "unit", lhsUnit), LocatorUtils.property(thatLocator, "unit", rhsUnit), lhsUnit, rhsUnit)) {
return false;
}
}
return true;
}
public boolean equals(Object object) {
final EqualsStrategy strategy = JAXBEqualsStrategy.INSTANCE;
return equals(null, null, object, strategy);
}
}