All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.finra.herd.model.api.xml.EmrClusterDefinitionInstanceFleet Maven / Gradle / Ivy

Go to download

This project contains the model API classes. This contains the herd XSD and generates Java POJO's from them. These classes are used for incoming and outgoing calls into the system (e.g. via REST).

There is a newer version: 0.160.0
Show newest version

package org.finra.herd.model.api.xml;

import java.io.Serializable;
import java.util.List;
import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
import javax.xml.bind.annotation.XmlElement;
import javax.xml.bind.annotation.XmlElementWrapper;
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.HashCode2;
import org.jvnet.jaxb2_commons.lang.HashCodeStrategy2;
import org.jvnet.jaxb2_commons.lang.JAXBCopyStrategy;
import org.jvnet.jaxb2_commons.lang.JAXBEqualsStrategy;
import org.jvnet.jaxb2_commons.lang.JAXBHashCodeStrategy;
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;


/**
 * 

Java class for emrClusterDefinitionInstanceFleet complex type. * *

The following schema fragment specifies the expected content contained within this class. * *

 * <complexType name="emrClusterDefinitionInstanceFleet">
 *   <complexContent>
 *     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
 *       <all>
 *         <element name="name" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/>
 *         <element name="instanceFleetType" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/>
 *         <element name="targetOnDemandCapacity" type="{http://www.w3.org/2001/XMLSchema}int" minOccurs="0"/>
 *         <element name="targetSpotCapacity" type="{http://www.w3.org/2001/XMLSchema}int" minOccurs="0"/>
 *         <element name="instanceTypeConfigs" type="{}emrClusterDefinitionInstanceTypeConfigs" minOccurs="0"/>
 *         <element name="launchSpecifications" type="{}emrClusterDefinitionLaunchSpecifications" minOccurs="0"/>
 *       </all>
 *     </restriction>
 *   </complexContent>
 * </complexType>
 * 
* * */ @XmlAccessorType(XmlAccessType.FIELD) @XmlType(name = "emrClusterDefinitionInstanceFleet", propOrder = { }) public class EmrClusterDefinitionInstanceFleet implements Serializable, Cloneable, CopyTo2, Equals2, HashCode2, ToString2 { private final static long serialVersionUID = -1L; protected String name; protected String instanceFleetType; protected Integer targetOnDemandCapacity; protected Integer targetSpotCapacity; @XmlElementWrapper @XmlElement(name = "instanceTypeConfig") protected List instanceTypeConfigs; protected EmrClusterDefinitionLaunchSpecifications launchSpecifications; /** * Default no-arg constructor * */ public EmrClusterDefinitionInstanceFleet() { super(); } /** * Fully-initialising value constructor * */ public EmrClusterDefinitionInstanceFleet(final String name, final String instanceFleetType, final Integer targetOnDemandCapacity, final Integer targetSpotCapacity, final List instanceTypeConfigs, final EmrClusterDefinitionLaunchSpecifications launchSpecifications) { this.name = name; this.instanceFleetType = instanceFleetType; this.targetOnDemandCapacity = targetOnDemandCapacity; this.targetSpotCapacity = targetSpotCapacity; this.instanceTypeConfigs = instanceTypeConfigs; this.launchSpecifications = launchSpecifications; } /** * 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 instanceFleetType property. * * @return * possible object is * {@link String } * */ public String getInstanceFleetType() { return instanceFleetType; } /** * Sets the value of the instanceFleetType property. * * @param value * allowed object is * {@link String } * */ public void setInstanceFleetType(String value) { this.instanceFleetType = value; } /** * Gets the value of the targetOnDemandCapacity property. * * @return * possible object is * {@link Integer } * */ public Integer getTargetOnDemandCapacity() { return targetOnDemandCapacity; } /** * Sets the value of the targetOnDemandCapacity property. * * @param value * allowed object is * {@link Integer } * */ public void setTargetOnDemandCapacity(Integer value) { this.targetOnDemandCapacity = value; } /** * Gets the value of the targetSpotCapacity property. * * @return * possible object is * {@link Integer } * */ public Integer getTargetSpotCapacity() { return targetSpotCapacity; } /** * Sets the value of the targetSpotCapacity property. * * @param value * allowed object is * {@link Integer } * */ public void setTargetSpotCapacity(Integer value) { this.targetSpotCapacity = value; } /** * Gets the value of the launchSpecifications property. * * @return * possible object is * {@link EmrClusterDefinitionLaunchSpecifications } * */ public EmrClusterDefinitionLaunchSpecifications getLaunchSpecifications() { return launchSpecifications; } /** * Sets the value of the launchSpecifications property. * * @param value * allowed object is * {@link EmrClusterDefinitionLaunchSpecifications } * */ public void setLaunchSpecifications(EmrClusterDefinitionLaunchSpecifications value) { this.launchSpecifications = value; } public List getInstanceTypeConfigs() { return instanceTypeConfigs; } public void setInstanceTypeConfigs(List instanceTypeConfigs) { this.instanceTypeConfigs = instanceTypeConfigs; } 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) { { String theName; theName = this.getName(); strategy.appendField(locator, this, "name", buffer, theName, (this.name!= null)); } { String theInstanceFleetType; theInstanceFleetType = this.getInstanceFleetType(); strategy.appendField(locator, this, "instanceFleetType", buffer, theInstanceFleetType, (this.instanceFleetType!= null)); } { Integer theTargetOnDemandCapacity; theTargetOnDemandCapacity = this.getTargetOnDemandCapacity(); strategy.appendField(locator, this, "targetOnDemandCapacity", buffer, theTargetOnDemandCapacity, (this.targetOnDemandCapacity!= null)); } { Integer theTargetSpotCapacity; theTargetSpotCapacity = this.getTargetSpotCapacity(); strategy.appendField(locator, this, "targetSpotCapacity", buffer, theTargetSpotCapacity, (this.targetSpotCapacity!= null)); } { List theInstanceTypeConfigs; theInstanceTypeConfigs = ((this.instanceTypeConfigs!= null)?this.getInstanceTypeConfigs():null); strategy.appendField(locator, this, "instanceTypeConfigs", buffer, theInstanceTypeConfigs, (this.instanceTypeConfigs!= null)); } { EmrClusterDefinitionLaunchSpecifications theLaunchSpecifications; theLaunchSpecifications = this.getLaunchSpecifications(); strategy.appendField(locator, this, "launchSpecifications", buffer, theLaunchSpecifications, (this.launchSpecifications!= null)); } return buffer; } 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 EmrClusterDefinitionInstanceFleet that = ((EmrClusterDefinitionInstanceFleet) object); { 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, (this.name!= null), (that.name!= null))) { return false; } } { String lhsInstanceFleetType; lhsInstanceFleetType = this.getInstanceFleetType(); String rhsInstanceFleetType; rhsInstanceFleetType = that.getInstanceFleetType(); if (!strategy.equals(LocatorUtils.property(thisLocator, "instanceFleetType", lhsInstanceFleetType), LocatorUtils.property(thatLocator, "instanceFleetType", rhsInstanceFleetType), lhsInstanceFleetType, rhsInstanceFleetType, (this.instanceFleetType!= null), (that.instanceFleetType!= null))) { return false; } } { Integer lhsTargetOnDemandCapacity; lhsTargetOnDemandCapacity = this.getTargetOnDemandCapacity(); Integer rhsTargetOnDemandCapacity; rhsTargetOnDemandCapacity = that.getTargetOnDemandCapacity(); if (!strategy.equals(LocatorUtils.property(thisLocator, "targetOnDemandCapacity", lhsTargetOnDemandCapacity), LocatorUtils.property(thatLocator, "targetOnDemandCapacity", rhsTargetOnDemandCapacity), lhsTargetOnDemandCapacity, rhsTargetOnDemandCapacity, (this.targetOnDemandCapacity!= null), (that.targetOnDemandCapacity!= null))) { return false; } } { Integer lhsTargetSpotCapacity; lhsTargetSpotCapacity = this.getTargetSpotCapacity(); Integer rhsTargetSpotCapacity; rhsTargetSpotCapacity = that.getTargetSpotCapacity(); if (!strategy.equals(LocatorUtils.property(thisLocator, "targetSpotCapacity", lhsTargetSpotCapacity), LocatorUtils.property(thatLocator, "targetSpotCapacity", rhsTargetSpotCapacity), lhsTargetSpotCapacity, rhsTargetSpotCapacity, (this.targetSpotCapacity!= null), (that.targetSpotCapacity!= null))) { return false; } } { List lhsInstanceTypeConfigs; lhsInstanceTypeConfigs = ((this.instanceTypeConfigs!= null)?this.getInstanceTypeConfigs():null); List rhsInstanceTypeConfigs; rhsInstanceTypeConfigs = ((that.instanceTypeConfigs!= null)?that.getInstanceTypeConfigs():null); if (!strategy.equals(LocatorUtils.property(thisLocator, "instanceTypeConfigs", lhsInstanceTypeConfigs), LocatorUtils.property(thatLocator, "instanceTypeConfigs", rhsInstanceTypeConfigs), lhsInstanceTypeConfigs, rhsInstanceTypeConfigs, (this.instanceTypeConfigs!= null), (that.instanceTypeConfigs!= null))) { return false; } } { EmrClusterDefinitionLaunchSpecifications lhsLaunchSpecifications; lhsLaunchSpecifications = this.getLaunchSpecifications(); EmrClusterDefinitionLaunchSpecifications rhsLaunchSpecifications; rhsLaunchSpecifications = that.getLaunchSpecifications(); if (!strategy.equals(LocatorUtils.property(thisLocator, "launchSpecifications", lhsLaunchSpecifications), LocatorUtils.property(thatLocator, "launchSpecifications", rhsLaunchSpecifications), lhsLaunchSpecifications, rhsLaunchSpecifications, (this.launchSpecifications!= null), (that.launchSpecifications!= null))) { return false; } } return true; } public boolean equals(Object object) { final EqualsStrategy2 strategy = JAXBEqualsStrategy.INSTANCE; return equals(null, null, object, strategy); } public int hashCode(ObjectLocator locator, HashCodeStrategy2 strategy) { int currentHashCode = 1; { String theName; theName = this.getName(); currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "name", theName), currentHashCode, theName, (this.name!= null)); } { String theInstanceFleetType; theInstanceFleetType = this.getInstanceFleetType(); currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "instanceFleetType", theInstanceFleetType), currentHashCode, theInstanceFleetType, (this.instanceFleetType!= null)); } { Integer theTargetOnDemandCapacity; theTargetOnDemandCapacity = this.getTargetOnDemandCapacity(); currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "targetOnDemandCapacity", theTargetOnDemandCapacity), currentHashCode, theTargetOnDemandCapacity, (this.targetOnDemandCapacity!= null)); } { Integer theTargetSpotCapacity; theTargetSpotCapacity = this.getTargetSpotCapacity(); currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "targetSpotCapacity", theTargetSpotCapacity), currentHashCode, theTargetSpotCapacity, (this.targetSpotCapacity!= null)); } { List theInstanceTypeConfigs; theInstanceTypeConfigs = ((this.instanceTypeConfigs!= null)?this.getInstanceTypeConfigs():null); currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "instanceTypeConfigs", theInstanceTypeConfigs), currentHashCode, theInstanceTypeConfigs, (this.instanceTypeConfigs!= null)); } { EmrClusterDefinitionLaunchSpecifications theLaunchSpecifications; theLaunchSpecifications = this.getLaunchSpecifications(); currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "launchSpecifications", theLaunchSpecifications), currentHashCode, theLaunchSpecifications, (this.launchSpecifications!= null)); } return currentHashCode; } public int hashCode() { final HashCodeStrategy2 strategy = JAXBHashCodeStrategy.INSTANCE; return this.hashCode(null, strategy); } 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 EmrClusterDefinitionInstanceFleet) { final EmrClusterDefinitionInstanceFleet copy = ((EmrClusterDefinitionInstanceFleet) draftCopy); { Boolean nameShouldBeCopiedAndSet = strategy.shouldBeCopiedAndSet(locator, (this.name!= null)); if (nameShouldBeCopiedAndSet == Boolean.TRUE) { String sourceName; sourceName = this.getName(); String copyName = ((String) strategy.copy(LocatorUtils.property(locator, "name", sourceName), sourceName, (this.name!= null))); copy.setName(copyName); } else { if (nameShouldBeCopiedAndSet == Boolean.FALSE) { copy.name = null; } } } { Boolean instanceFleetTypeShouldBeCopiedAndSet = strategy.shouldBeCopiedAndSet(locator, (this.instanceFleetType!= null)); if (instanceFleetTypeShouldBeCopiedAndSet == Boolean.TRUE) { String sourceInstanceFleetType; sourceInstanceFleetType = this.getInstanceFleetType(); String copyInstanceFleetType = ((String) strategy.copy(LocatorUtils.property(locator, "instanceFleetType", sourceInstanceFleetType), sourceInstanceFleetType, (this.instanceFleetType!= null))); copy.setInstanceFleetType(copyInstanceFleetType); } else { if (instanceFleetTypeShouldBeCopiedAndSet == Boolean.FALSE) { copy.instanceFleetType = null; } } } { Boolean targetOnDemandCapacityShouldBeCopiedAndSet = strategy.shouldBeCopiedAndSet(locator, (this.targetOnDemandCapacity!= null)); if (targetOnDemandCapacityShouldBeCopiedAndSet == Boolean.TRUE) { Integer sourceTargetOnDemandCapacity; sourceTargetOnDemandCapacity = this.getTargetOnDemandCapacity(); Integer copyTargetOnDemandCapacity = ((Integer) strategy.copy(LocatorUtils.property(locator, "targetOnDemandCapacity", sourceTargetOnDemandCapacity), sourceTargetOnDemandCapacity, (this.targetOnDemandCapacity!= null))); copy.setTargetOnDemandCapacity(copyTargetOnDemandCapacity); } else { if (targetOnDemandCapacityShouldBeCopiedAndSet == Boolean.FALSE) { copy.targetOnDemandCapacity = null; } } } { Boolean targetSpotCapacityShouldBeCopiedAndSet = strategy.shouldBeCopiedAndSet(locator, (this.targetSpotCapacity!= null)); if (targetSpotCapacityShouldBeCopiedAndSet == Boolean.TRUE) { Integer sourceTargetSpotCapacity; sourceTargetSpotCapacity = this.getTargetSpotCapacity(); Integer copyTargetSpotCapacity = ((Integer) strategy.copy(LocatorUtils.property(locator, "targetSpotCapacity", sourceTargetSpotCapacity), sourceTargetSpotCapacity, (this.targetSpotCapacity!= null))); copy.setTargetSpotCapacity(copyTargetSpotCapacity); } else { if (targetSpotCapacityShouldBeCopiedAndSet == Boolean.FALSE) { copy.targetSpotCapacity = null; } } } { Boolean instanceTypeConfigsShouldBeCopiedAndSet = strategy.shouldBeCopiedAndSet(locator, (this.instanceTypeConfigs!= null)); if (instanceTypeConfigsShouldBeCopiedAndSet == Boolean.TRUE) { List sourceInstanceTypeConfigs; sourceInstanceTypeConfigs = ((this.instanceTypeConfigs!= null)?this.getInstanceTypeConfigs():null); @SuppressWarnings("unchecked") List copyInstanceTypeConfigs = ((List ) strategy.copy(LocatorUtils.property(locator, "instanceTypeConfigs", sourceInstanceTypeConfigs), sourceInstanceTypeConfigs, (this.instanceTypeConfigs!= null))); copy.instanceTypeConfigs = null; if (copyInstanceTypeConfigs!= null) { copy.setInstanceTypeConfigs(copyInstanceTypeConfigs); } } else { if (instanceTypeConfigsShouldBeCopiedAndSet == Boolean.FALSE) { copy.instanceTypeConfigs = null; } } } { Boolean launchSpecificationsShouldBeCopiedAndSet = strategy.shouldBeCopiedAndSet(locator, (this.launchSpecifications!= null)); if (launchSpecificationsShouldBeCopiedAndSet == Boolean.TRUE) { EmrClusterDefinitionLaunchSpecifications sourceLaunchSpecifications; sourceLaunchSpecifications = this.getLaunchSpecifications(); EmrClusterDefinitionLaunchSpecifications copyLaunchSpecifications = ((EmrClusterDefinitionLaunchSpecifications) strategy.copy(LocatorUtils.property(locator, "launchSpecifications", sourceLaunchSpecifications), sourceLaunchSpecifications, (this.launchSpecifications!= null))); copy.setLaunchSpecifications(copyLaunchSpecifications); } else { if (launchSpecificationsShouldBeCopiedAndSet == Boolean.FALSE) { copy.launchSpecifications = null; } } } } return draftCopy; } public Object createNewInstance() { return new EmrClusterDefinitionInstanceFleet(); } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy