Select to view content in your preferred language

How to get graphics from group layer?

244
0
04-13-2022 11:08 PM
YogeshSwami
Emerging Contributor

I am using arcgis in my angular project.

I am creating a feature layer using url:

const myLayer: any = new FeatureLayer({url:'myurl'});
Then i make a group layer like:
const myGroupLayer= new GroupLayer(this.getGroupLayer('title', true, [myLayer]));
getGroupLayer = (gtitle: any, active: boolean, layerArray: any) => {
        const obj: any = {
            title: gtitle,
            visible: active,
            visibilityMode: "exclusive",
            layers: layerArray,
            opacity: 0.75,
        };
        return obj;
    }
 
After this I add this to my map:
const webmap = new WebMap({
            basemap: "topo-vector",
            ground: "world-elevation",
            layers: [myGroupLayer]
        });
 
Now my doubt is that how can I get graphics individually from my myGroupLayer?
Can anyone please help me with this?
0 Kudos
0 Replies