public class KMLLayer extends Layer
Modifier and Type | Class and Description |
---|---|
static class |
KMLLayer.FeatureInfo |
static class |
KMLLayer.LinkInfo |
static class |
KMLLayer.Options |
Modifier and Type | Method and Description |
---|---|
void |
addRefreshHandler(RefreshHandler handler)
Set the refresh event handler.
|
static boolean |
assertLoaded()
Check that the esri.layers.KMLLayer has been loaded
|
static KMLLayer |
create(java.lang.String url)
Creates a new KMLLayer object.
|
static KMLLayer |
create(java.lang.String url,
KMLLayer.Options options)
Creates a new KMLLayer object.
|
com.google.gwt.core.client.JavaScriptObject |
getFeature(KMLLayer.FeatureInfo featureInfo)
Get the KML feature identified by the input feature info.
|
KMLFolder |
getFeatureAsFolder(KMLLayer.FeatureInfo featureInfo)
Get the KML feature identified by the input feature info.
|
KMLGroundOverlay |
getFeatureAsGroundOverlay(KMLLayer.FeatureInfo featureInfo)
Get the KML feature identified by the input feature info.
|
KMLLayer |
getFeatureAsNetworkLink(KMLLayer.FeatureInfo featureInfo)
Get the KML feature identified by the input feature info.
|
Graphic |
getFeatureAsPlacemark(KMLLayer.FeatureInfo featureInfo)
Get the KML feature identified by the input feature info.
|
com.google.gwt.core.client.JsArray<KMLLayer.FeatureInfo> |
getFeatureInfos()
An array of objects that describe top-level KML features ids and their types.
|
com.google.gwt.core.client.JsArray<KMLFolder> |
getFolders()
An array of KMLFolder objects that describe the folders and nested folders defined
in the KML file.
|
com.google.gwt.core.client.JsArray<Layer> |
getLayers()
Get an array of map layers that were created to draw placemarks, ground and screen overlays.
|
KMLLayer.LinkInfo |
getLinkInfo()
A link info object with properties that describe the network link.
|
java.lang.String |
getName()
The name of the layer if specified in the KML file.
|
int |
getVisibility()
The initial visibility of the layer.
|
void |
setFolderVisibility(KMLFolder folder,
boolean isVisible)
Set the visibility for the specified folder.
|
addErrorHandler, addLoadHandler, addOpacityChangeHandler, addUpdateEndHandler, addUpdateHandler, addUpdateStartHandler, addVisibilityChangeHandler, getCredential, getId, getOpacity, getUrl, hide, isloaded, isVisible, setOpacity, setVisibility, show
public static KMLLayer create(java.lang.String url)
url
- - The url for a .kml or .kmz file.public static KMLLayer create(java.lang.String url, KMLLayer.Options options)
url
- - The url for a .kml or .kmz file.options
- - Optional parameters.public static boolean assertLoaded()
public final com.google.gwt.core.client.JsArray<KMLLayer.FeatureInfo> getFeatureInfos()
public final com.google.gwt.core.client.JsArray<KMLFolder> getFolders()
public final KMLLayer.LinkInfo getLinkInfo()
public final java.lang.String getName()
public final int getVisibility()
public final com.google.gwt.core.client.JavaScriptObject getFeature(KMLLayer.FeatureInfo featureInfo)
featureInfo
- - Feature info for the kml feature.public final Graphic getFeatureAsPlacemark(KMLLayer.FeatureInfo featureInfo)
featureInfo
- - Feature info for the kml feature.public final KMLGroundOverlay getFeatureAsGroundOverlay(KMLLayer.FeatureInfo featureInfo)
featureInfo
- - Feature info for the kml feature.public final KMLLayer getFeatureAsNetworkLink(KMLLayer.FeatureInfo featureInfo)
featureInfo
- - Feature info for the kml feature.public final KMLFolder getFeatureAsFolder(KMLLayer.FeatureInfo featureInfo)
featureInfo
- - Feature info for the kml feature.public final com.google.gwt.core.client.JsArray<Layer> getLayers()
public final void setFolderVisibility(KMLFolder folder, boolean isVisible)
folder
- - A KML folder.isVisible
- - The visibility of the folder and all kml features within the folder.public final void addRefreshHandler(RefreshHandler handler)
handler
- - Fired after the layer is refreshed. If the layer represents a network link it is automatically refreshed
based on the network link parameters defined in the linkInfo property. Layers can be explicitly refreshed by calling the
refresh method.