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

de.micromata.opengis.kml.v_2_2_0.LatLonAltBox Maven / Gradle / Ivy

Go to download

This is JavaAPIforKMml, Micromata's library for use with applications that want to parse, generate and operate on KML. It is an implementation of the OGC KML 2.2 standard. It is written entirely in Java and makes heavy use of JAXB.

There is a newer version: 3.0.4
Show newest version

package de.micromata.opengis.kml.v_2_2_0;

import de.micromata.opengis.kml.v_2_2_0.annotations.Obvious;
import jakarta.xml.bind.annotation.*;

import java.util.ArrayList;
import java.util.List;


/**
 * {@code }(required)
 * 

* A bounding box that describes an area of interest defined by geographic coordinates * and altitudes. Default values and required fields are as follows: *

* * * */ @XmlAccessorType(XmlAccessType.FIELD) @XmlType(name = "LatLonAltBoxType", propOrder = { "minAltitude", "maxAltitude", "altitudeMode", "latLonAltBoxSimpleExtension", "latLonAltBoxObjectExtension" }) @XmlRootElement(name = "LatLonAltBox", namespace = "http://www.opengis.net/kml/2.2") public class LatLonAltBox extends AbstractLatLonBox implements Cloneable { /** * {@code } *

* Specified in meters (and is affected by the altitude mode specification). *

* * * */ @XmlElement(defaultValue = "0.0") protected double minAltitude; /** * {@code } *

* Specified in meters (and is affected by the altitude mode specification). *

* * * */ @XmlElement(defaultValue = "0.0") protected double maxAltitude; /** * AltitudeMode *

* clampToGround, relativeToGround, absolute *

* * See Also: * See LookAt and {@code } * * * */ @XmlElement(defaultValue = "clampToGround") protected AltitudeMode altitudeMode; @XmlElement(name = "LatLonAltBoxSimpleExtensionGroup") @XmlSchemaType(name = "anySimpleType") protected List latLonAltBoxSimpleExtension; /** * {@code } *

* This is an abstract base class and cannot be used directly in a KML file. It provides * the id attribute, which allows unique identification of a KML element, and the targetId * attribute, which is used to reference objects that have already been loaded into * Google Earth. The id attribute must be assigned if the Update mechanism is to * be used. *

* * Syntax: *
<!-- abstract element; do not create -->
     * <!-- Object id="ID" targetId="NCName" -->
     * <!-- /Object> -->
* * * */ @XmlElement(name = "LatLonAltBoxObjectExtensionGroup") protected List latLonAltBoxObjectExtension; public LatLonAltBox() { super(); } /** * * * @return * possible object is * {@link Double} * */ public double getMinAltitude() { return minAltitude; } /** * * * @param value * allowed object is * {@link Double} * */ public void setMinAltitude(double value) { this.minAltitude = value; } /** * * * @return * possible object is * {@link Double} * */ public double getMaxAltitude() { return maxAltitude; } /** * * * @param value * allowed object is * {@link Double} * */ public void setMaxAltitude(double value) { this.maxAltitude = value; } /** * * * @return * possible object is * {@code <}{@link Object}{@code >} * {@code <}{@link de.micromata.opengis.kml.v_2_2_0.AltitudeMode}{@code >} * * */ public AltitudeMode getAltitudeMode() { return altitudeMode; } /** * * * @param value * allowed object is * {@code <}{@link Object}{@code >} * {@code <}{@link de.micromata.opengis.kml.v_2_2_0.AltitudeMode}{@code >} * * */ public void setAltitudeMode(AltitudeMode value) { this.altitudeMode = value; } /** * * */ public List getLatLonAltBoxSimpleExtension() { if (latLonAltBoxSimpleExtension == null) { latLonAltBoxSimpleExtension = new ArrayList(); } return this.latLonAltBoxSimpleExtension; } /** * * */ public List getLatLonAltBoxObjectExtension() { if (latLonAltBoxObjectExtension == null) { latLonAltBoxObjectExtension = new ArrayList(); } return this.latLonAltBoxObjectExtension; } @Override public int hashCode() { final int prime = 31; int result = super.hashCode(); long temp; temp = Double.doubleToLongBits(minAltitude); result = ((prime*result)+((int)(temp^(temp >>>(32))))); temp = Double.doubleToLongBits(maxAltitude); result = ((prime*result)+((int)(temp^(temp >>>(32))))); result = ((prime*result)+((altitudeMode == null)? 0 :altitudeMode.hashCode())); result = ((prime*result)+((latLonAltBoxSimpleExtension == null)? 0 :latLonAltBoxSimpleExtension.hashCode())); result = ((prime*result)+((latLonAltBoxObjectExtension == null)? 0 :latLonAltBoxObjectExtension.hashCode())); return result; } @Override public boolean equals(Object obj) { if (this == obj) { return true; } if (obj == null) { return false; } if (super.equals(obj) == false) { return false; } if ((obj instanceof LatLonAltBox) == false) { return false; } LatLonAltBox other = ((LatLonAltBox) obj); if (minAltitude!= other.minAltitude) { return false; } if (maxAltitude!= other.maxAltitude) { return false; } if (altitudeMode == null) { if (other.altitudeMode!= null) { return false; } } else { if (altitudeMode.equals(other.altitudeMode) == false) { return false; } } if (latLonAltBoxSimpleExtension == null) { if (other.latLonAltBoxSimpleExtension!= null) { return false; } } else { if (latLonAltBoxSimpleExtension.equals(other.latLonAltBoxSimpleExtension) == false) { return false; } } if (latLonAltBoxObjectExtension == null) { if (other.latLonAltBoxObjectExtension!= null) { return false; } } else { if (latLonAltBoxObjectExtension.equals(other.latLonAltBoxObjectExtension) == false) { return false; } } return true; } /** * * * @param latLonAltBoxSimpleExtension * Objects of the following type are allowed in the list: {@link Object} */ public void setLatLonAltBoxSimpleExtension(final List latLonAltBoxSimpleExtension) { this.latLonAltBoxSimpleExtension = latLonAltBoxSimpleExtension; } /** * add a value to the latLonAltBoxSimpleExtension property collection * * @param latLonAltBoxSimpleExtension * Objects of the following type are allowed in the list: {@link Object} * @return * true (as general contract of Collection.add). */ public LatLonAltBox addToLatLonAltBoxSimpleExtension(final Object latLonAltBoxSimpleExtension) { this.getLatLonAltBoxSimpleExtension().add(latLonAltBoxSimpleExtension); return this; } /** * * * @param latLonAltBoxObjectExtension * Objects of the following type are allowed in the list: {@link AbstractObject} */ public void setLatLonAltBoxObjectExtension(final List latLonAltBoxObjectExtension) { this.latLonAltBoxObjectExtension = latLonAltBoxObjectExtension; } /** * add a value to the latLonAltBoxObjectExtension property collection * * @param latLonAltBoxObjectExtension * Objects of the following type are allowed in the list: {@link AbstractObject} * @return * true (as general contract of Collection.add). */ public LatLonAltBox addToLatLonAltBoxObjectExtension(final AbstractObject latLonAltBoxObjectExtension) { this.getLatLonAltBoxObjectExtension().add(latLonAltBoxObjectExtension); return this; } /** * * */ @Obvious @Override public void setObjectSimpleExtension(final List objectSimpleExtension) { super.setObjectSimpleExtension(objectSimpleExtension); } @Obvious @Override public LatLonAltBox addToObjectSimpleExtension(final Object objectSimpleExtension) { super.getObjectSimpleExtension().add(objectSimpleExtension); return this; } /** * * */ @Obvious @Override public void setAbstractLatLonBoxSimpleExtension(final List abstractLatLonBoxSimpleExtension) { super.setAbstractLatLonBoxSimpleExtension(abstractLatLonBoxSimpleExtension); } @Obvious @Override public LatLonAltBox addToAbstractLatLonBoxSimpleExtension(final Object abstractLatLonBoxSimpleExtension) { super.getAbstractLatLonBoxSimpleExtension().add(abstractLatLonBoxSimpleExtension); return this; } /** * * */ @Obvious @Override public void setAbstractLatLonBoxObjectExtension(final List abstractLatLonBoxObjectExtension) { super.setAbstractLatLonBoxObjectExtension(abstractLatLonBoxObjectExtension); } @Obvious @Override public LatLonAltBox addToAbstractLatLonBoxObjectExtension(final AbstractObject abstractLatLonBoxObjectExtension) { super.getAbstractLatLonBoxObjectExtension().add(abstractLatLonBoxObjectExtension); return this; } /** * fluent setter * * * @param minAltitude * required parameter */ public LatLonAltBox withMinAltitude(final double minAltitude) { this.setMinAltitude(minAltitude); return this; } /** * fluent setter * * * @param maxAltitude * required parameter */ public LatLonAltBox withMaxAltitude(final double maxAltitude) { this.setMaxAltitude(maxAltitude); return this; } /** * fluent setter * * * @param altitudeMode * required parameter */ public LatLonAltBox withAltitudeMode(final AltitudeMode altitudeMode) { this.setAltitudeMode(altitudeMode); return this; } /** * fluent setter * * * @param latLonAltBoxSimpleExtension * required parameter */ public LatLonAltBox withLatLonAltBoxSimpleExtension(final List latLonAltBoxSimpleExtension) { this.setLatLonAltBoxSimpleExtension(latLonAltBoxSimpleExtension); return this; } /** * fluent setter * * * @param latLonAltBoxObjectExtension * required parameter */ public LatLonAltBox withLatLonAltBoxObjectExtension(final List latLonAltBoxObjectExtension) { this.setLatLonAltBoxObjectExtension(latLonAltBoxObjectExtension); return this; } @Obvious @Override public LatLonAltBox withObjectSimpleExtension(final List objectSimpleExtension) { super.withObjectSimpleExtension(objectSimpleExtension); return this; } @Obvious @Override public LatLonAltBox withId(final String id) { super.withId(id); return this; } @Obvious @Override public LatLonAltBox withTargetId(final String targetId) { super.withTargetId(targetId); return this; } @Obvious @Override public LatLonAltBox withNorth(final double north) { super.withNorth(north); return this; } @Obvious @Override public LatLonAltBox withSouth(final double south) { super.withSouth(south); return this; } @Obvious @Override public LatLonAltBox withEast(final double east) { super.withEast(east); return this; } @Obvious @Override public LatLonAltBox withWest(final double west) { super.withWest(west); return this; } @Obvious @Override public LatLonAltBox withAbstractLatLonBoxSimpleExtension(final List abstractLatLonBoxSimpleExtension) { super.withAbstractLatLonBoxSimpleExtension(abstractLatLonBoxSimpleExtension); return this; } @Obvious @Override public LatLonAltBox withAbstractLatLonBoxObjectExtension(final List abstractLatLonBoxObjectExtension) { super.withAbstractLatLonBoxObjectExtension(abstractLatLonBoxObjectExtension); return this; } @Override public LatLonAltBox clone() { LatLonAltBox copy; copy = ((LatLonAltBox) super.clone()); copy.latLonAltBoxSimpleExtension = new ArrayList((getLatLonAltBoxSimpleExtension().size())); for (Object iter: latLonAltBoxSimpleExtension) { copy.latLonAltBoxSimpleExtension.add(iter); } copy.latLonAltBoxObjectExtension = new ArrayList((getLatLonAltBoxObjectExtension().size())); for (AbstractObject iter: latLonAltBoxObjectExtension) { copy.latLonAltBoxObjectExtension.add(iter.clone()); } return copy; } }