de.micromata.opengis.kml.v_2_2_0
Class Region

java.lang.Object
  extended by de.micromata.opengis.kml.v_2_2_0.AbstractObject
      extended by de.micromata.opengis.kml.v_2_2_0.Region
All Implemented Interfaces:
java.lang.Cloneable

public class Region
extends AbstractObject
implements java.lang.Cloneable

A region contains a bounding box () that describes an area of interest defined by geographic coordinates and altitudes. In addition, a Region contains an LOD (level of detail) extent () that defines a validity range of the associated Region in terms of projected screen size. A Region is said to be "active" when the bounding box is within the user's view and the LOD requirements are met. Objects associated with a Region are drawn only when the Region is active. When the is onRegion, the Link or Icon is loaded only when the Region is active. See the "Topics in KML" page on Regions for more details. In a Container or NetworkLink hierarchy, this calculation uses the Region that is the closest ancestor in the hierarchy.

Features and geometry associated with a Region are drawn only when the Region is active. See .

Syntax:
<Region id="ID"> 
   <LatLonAltBox> 
     <north></north>                            <!-- required; kml:angle90 -->
     <south></south>                            <!-- required; kml:angle90 --> 
     <east></east>                              <!-- required; kml:angle180 -->
     <west></west>                              <!-- required; kml:angle180 -->
     <minAltitude>0</minAltitude>               <!-- float -->
     <maxAltitude>0</maxAltitude>               <!-- float -->
     <altitudeMode>clampToGround</altitudeMode> 
         <!-- kml:altitudeModeEnum: clampToGround, relativeToGround, or absolute -->
         <!-- or, substitute gx:altitudeMode: clampToSeaFloor, relativeToSeaFloor --> 
   </LatLonAltBox> 
   <Lod>
     <minLodPixels>0</minLodPixels>             <!-- float -->
     <maxLodPixels>-1</maxLodPixels>            <!-- float -->
     <minFadeExtent>0</minFadeExtent>           <!-- float --> 
     <maxFadeExtent>0</maxFadeExtent>           <!-- float -->
   </Lod>
 </Region> 
Extends:


Field Summary
protected  LatLonAltBox latLonAltBox
          (required)
protected  Lod lod
          
protected  java.util.List<AbstractObject> regionObjectExtension
          
protected  java.util.List<java.lang.Object> regionSimpleExtension
           
 
Fields inherited from class de.micromata.opengis.kml.v_2_2_0.AbstractObject
id, objectSimpleExtension, targetId
 
Constructor Summary
Region()
           
 
Method Summary
 Region addToObjectSimpleExtension(java.lang.Object objectSimpleExtension)
          add a value to the objectSimpleExtension property collection
 Region addToRegionObjectExtension(AbstractObject regionObjectExtension)
          add a value to the regionObjectExtension property collection
 Region addToRegionSimpleExtension(java.lang.Object regionSimpleExtension)
          add a value to the regionSimpleExtension property collection
 Region clone()
           
 LatLonAltBox createAndSetLatLonAltBox()
          Creates a new instance of LatLonAltBox and set it to latLonAltBox.
 Lod createAndSetLod()
          Creates a new instance of Lod and set it to lod.
 boolean equals(java.lang.Object obj)
           
 LatLonAltBox getLatLonAltBox()
           
 Lod getLod()
           
 java.util.List<AbstractObject> getRegionObjectExtension()
           
 java.util.List<java.lang.Object> getRegionSimpleExtension()
           
 int hashCode()
           
 void setLatLonAltBox(LatLonAltBox value)
           
 void setLod(Lod value)
           
 void setObjectSimpleExtension(java.util.List<java.lang.Object> objectSimpleExtension)
           
 void setRegionObjectExtension(java.util.List<AbstractObject> regionObjectExtension)
           
 void setRegionSimpleExtension(java.util.List<java.lang.Object> regionSimpleExtension)
           
 Region withId(java.lang.String id)
          fluent setter
 Region withLatLonAltBox(LatLonAltBox latLonAltBox)
          fluent setter
 Region withLod(Lod lod)
          fluent setter
 Region withObjectSimpleExtension(java.util.List<java.lang.Object> objectSimpleExtension)
          fluent setter
 Region withRegionObjectExtension(java.util.List<AbstractObject> regionObjectExtension)
          fluent setter
 Region withRegionSimpleExtension(java.util.List<java.lang.Object> regionSimpleExtension)
          fluent setter
 Region withTargetId(java.lang.String targetId)
          fluent setter
 
Methods inherited from class de.micromata.opengis.kml.v_2_2_0.AbstractObject
getId, getObjectSimpleExtension, getTargetId, setId, setTargetId
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

latLonAltBox

protected LatLonAltBox latLonAltBox
(required)

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


lod

protected Lod lod

(required) Measurement in screen pixels that represents the minimum limit of the visibility range for a given Region. Google Earth calculates the size of the Region when projected onto screen space. Then it computes the square root of the Region's area (if, for example, the Region is square and the viewpoint is directly above the Region, and the Region is not tilted, this measurement is equal to the width of the projected Region). If this measurement falls within the limits defined by and (and if the is in view), the Region is active. If this limit is not reached, the associated geometry is considered to be too far from the user's viewpoint to be drawn. Measurement in screen pixels that represents the maximum limit of the visibility range for a given Region. A value of −1, the default, indicates "active to infinite size." Distance over which the geometry fades, from fully opaque to fully transparent. This ramp value, expressed in screen pixels, is applied at the minimum end of the LOD (visibility) limits. Distance over which the geometry fades, from fully transparent to fully opaque. This ramp value, expressed in screen pixels, is applied at the maximum end of the LOD (visibility) limits.


regionSimpleExtension

protected java.util.List<java.lang.Object> regionSimpleExtension

regionObjectExtension

protected java.util.List<AbstractObject> regionObjectExtension

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 mechanism is to be used.

Syntax:
<!-- abstract element; do not create -->
 <!-- Object id="ID" targetId="NCName" -->
 <!-- /Object> -->

Constructor Detail

Region

public Region()
Method Detail

getLatLonAltBox

public LatLonAltBox getLatLonAltBox()
Returns:
possible object is LatLonAltBox
See Also:
latLonAltBox

setLatLonAltBox

public void setLatLonAltBox(LatLonAltBox value)
Parameters:
value - allowed object is LatLonAltBox
See Also:
latLonAltBox

getLod

public Lod getLod()
Returns:
possible object is Lod
See Also:
lod

setLod

public void setLod(Lod value)
Parameters:
value - allowed object is Lod
See Also:
lod

getRegionSimpleExtension

public java.util.List<java.lang.Object> getRegionSimpleExtension()
See Also:
regionSimpleExtension

getRegionObjectExtension

public java.util.List<AbstractObject> getRegionObjectExtension()
See Also:
regionObjectExtension

hashCode

public int hashCode()
Overrides:
hashCode in class AbstractObject

equals

public boolean equals(java.lang.Object obj)
Overrides:
equals in class AbstractObject

createAndSetLatLonAltBox

public LatLonAltBox createAndSetLatLonAltBox()
Creates a new instance of LatLonAltBox and set it to latLonAltBox. This method is a short version for: LatLonAltBox latLonAltBox = new LatLonAltBox(); this.setLatLonAltBox(latLonAltBox);


createAndSetLod

public Lod createAndSetLod()
Creates a new instance of Lod and set it to lod. This method is a short version for: Lod lod = new Lod(); this.setLod(lod);


setRegionSimpleExtension

public void setRegionSimpleExtension(java.util.List<java.lang.Object> regionSimpleExtension)
Parameters:
regionSimpleExtension -
See Also:
regionSimpleExtension

addToRegionSimpleExtension

public Region addToRegionSimpleExtension(java.lang.Object regionSimpleExtension)
add a value to the regionSimpleExtension property collection

Parameters:
regionSimpleExtension - Objects of the following type are allowed in the list: Object
Returns:
true (as general contract of Collection.add).

setRegionObjectExtension

public void setRegionObjectExtension(java.util.List<AbstractObject> regionObjectExtension)
Parameters:
regionObjectExtension -
See Also:
regionObjectExtension

addToRegionObjectExtension

public Region addToRegionObjectExtension(AbstractObject regionObjectExtension)
add a value to the regionObjectExtension property collection

Parameters:
regionObjectExtension - Objects of the following type are allowed in the list: AbstractObject
Returns:
true (as general contract of Collection.add).

setObjectSimpleExtension

public void setObjectSimpleExtension(java.util.List<java.lang.Object> objectSimpleExtension)
Overrides:
setObjectSimpleExtension in class AbstractObject
See Also:
objectSimpleExtension

addToObjectSimpleExtension

public Region addToObjectSimpleExtension(java.lang.Object objectSimpleExtension)
Description copied from class: AbstractObject
add a value to the objectSimpleExtension property collection

Overrides:
addToObjectSimpleExtension in class AbstractObject
Parameters:
objectSimpleExtension - Objects of the following type are allowed in the list: Object
Returns:
true (as general contract of Collection.add).

withLatLonAltBox

public Region withLatLonAltBox(LatLonAltBox latLonAltBox)
fluent setter

Parameters:
latLonAltBox - required parameter
See Also:
setLatLonAltBox(LatLonAltBox)

withLod

public Region withLod(Lod lod)
fluent setter

Parameters:
lod - required parameter
See Also:
setLod(Lod)

withRegionSimpleExtension

public Region withRegionSimpleExtension(java.util.List<java.lang.Object> regionSimpleExtension)
fluent setter

Parameters:
regionSimpleExtension - required parameter
See Also:
#setRegionSimpleExtension(List)

withRegionObjectExtension

public Region withRegionObjectExtension(java.util.List<AbstractObject> regionObjectExtension)
fluent setter

Parameters:
regionObjectExtension - required parameter
See Also:
#setRegionObjectExtension(List)

withObjectSimpleExtension

public Region withObjectSimpleExtension(java.util.List<java.lang.Object> objectSimpleExtension)
Description copied from class: AbstractObject
fluent setter

Overrides:
withObjectSimpleExtension in class AbstractObject
Parameters:
objectSimpleExtension - required parameter
See Also:
#setObjectSimpleExtension(List)

withId

public Region withId(java.lang.String id)
Description copied from class: AbstractObject
fluent setter

Overrides:
withId in class AbstractObject
Parameters:
id - required parameter
See Also:
AbstractObject.setId(String)

withTargetId

public Region withTargetId(java.lang.String targetId)
Description copied from class: AbstractObject
fluent setter

Overrides:
withTargetId in class AbstractObject
Parameters:
targetId - required parameter
See Also:
AbstractObject.setTargetId(String)

clone

public Region clone()
Overrides:
clone in class AbstractObject