Google Earth Enterprise Database Layers

193 views
Skip to first unread message

jpdm

unread,
Jun 26, 2009, 1:11:31 PM6/26/09
to KML Developer Support - Google Earth Plug-in
We have a Earth Enterprise server and we have been able to access it
through the Earth Plugin API. My question is how can you get access
to the different layers available? Or how do I get a list of the
available layers?

Thanks.

fraser (Earth API Guru)

unread,
Jun 26, 2009, 5:27:10 PM6/26/09
to KML Developer Support - Google Earth Plug-in
Hi,

I belive you should contact the enterprise support team for advice
with this...

However AFAIK you would just use the standard api to add and remove
layers.
For example, to show/hide the building layer.
-----------------------------------------------------------------------
ge.getLayerRoot().enableLayerById(ge.LAYER_BUILDINGS, true); //show
ge.getLayerRoot().enableLayerById(ge.LAYER_BUILDINGS, false); //hide
-----------------------------------------------------------------------

You can see a list of the current available layers in the GEPlugin Api
refrence.
http://code.google.com/apis/earth/documentation/reference/interface_g_e_plugin.html#
Look under "Enums and Constants."

To date they are:
LAYER_TERRAIN
LAYER_ROADS
LAYER_BUILDINGS
LAYER_BUILDINGS_LOW_RESOLUTION New!
LAYER_BORDERS

Regards,

F

Roman N

unread,
Jun 28, 2009, 1:07:43 AM6/28/09
to KML Developer Support - Google Earth Plug-in
Hi,

Actually LAYER_xx won't work in the Enterprise version because those
layer IDs probably don't exist in your database.

Enumerating layers is possible via the KmlLayerRoot interface
(ge.getLayerRoot())... for details, check with Enterprise support, as
there should be a demo for this available through them.

Thanks,
Roman


On Jun 26, 2:27 pm, fraser (Earth API Guru) wrote:
> Hi,
>
> I belive you should contact the enterprise support team for advice
> with this...
>
> However AFAIK you would just use the standard api to add and remove
> layers.
> For example, to show/hide the building layer.
> -----------------------------------------------------------------------
> ge.getLayerRoot().enableLayerById(ge.LAYER_BUILDINGS, true); //show
> ge.getLayerRoot().enableLayerById(ge.LAYER_BUILDINGS, false); //hide
> -----------------------------------------------------------------------
>
> You can see a list of the current available layers in the GEPlugin Api
> refrence.http://code.google.com/apis/earth/documentation/reference/interface_g...

jpdm

unread,
Jun 29, 2009, 9:28:09 AM6/29/09
to KML Developer Support - Google Earth Plug-in
Thanks for the responses.
I was able to find a function call that returns the available layers
through JSON.
The command is http://earth_server/default_ge/query?request=Json
It returns the following

{
isAuthenticated : false,
layers :
[
{
description : "",
id : "f0382bce-625e-11de-9585-a75818dc0987",
isEnabled : true,
isExpandable : false,
isInitiallyOn : true,
isVisible : true,
label : "Imagery",
lookAt : "none"
}
,
{
description : "",
id : "ad59978a-6262-11de-a6ce-a75818dc0987",
isEnabled : true,
isExpandable : true,
isInitiallyOn : false,
isVisible : true,
label : "california_roads",
lookAt : "none"
}

]
,
searchTabs :
[

]
,
serverUrl : "http://earth_server/default_ge"
}
Reply all
Reply to author
Forward
0 new messages