• JMap.Layer.getLayerTree

    Returns project's layer tree.

    The layer tree is an array of tree element.

    A tree element is a layer group or a layer.

    A layer group contains layer and/or other layer group, and has a negative id.

    A layer has a positive id.

    If no project is loaded, returns an empty array.

    Returns JLayerTree

    Example

    // returns the entire layer tree of the project
    JMap.Layer.getLayerTree()