Class: esri/core/Handles
Inheritance: Handles Accessor
Since: ArcGIS API for JavaScript 4.7

This class helps manage a group of handles.

Property Overview

Any properties can be set, retrieved or listened to. See the Working with Properties topic.
NameTypeSummaryClass
String

The name of the class.

more details
more detailsAccessor

Property Details

declaredClassStringreadonly inherited
Since: ArcGIS API for JavaScript 4.7

The name of the class. The declared class name is formatted as esri.folder.className.

Method Overview

NameReturn TypeSummaryClass

Adds a group of handles.

more details
more detailsHandles
Boolean

Returns true if a group exists for the provided key, false otherwise.

more details
more detailsHandles

Removes a group of handles.

more details
more detailsHandles

Removes all handles.

more details
more detailsHandles

Method Details

add(handles, key)

Adds a group of handles.

Parameters:

An array or collection handles to group.

key *
optional

group handle key

Example:
let handles = new Handles();

handles.add(handle); // added to the default group
handles.add([handle1, handle2]); // added to the default group
handles.add(handle, "handle-group");
handles.add([handle1, handle2], "other-handle-group");
has(key){Boolean}

Returns true if a group exists for the provided key, false otherwise.

Parameter:
key *

group handle key

Returns:
TypeDescription
Boolean
remove(key)

Removes a group of handles.

Parameter:
key *
optional

A group key or an array or collection of group keys to remove.

Example:
let handles = new Handles();

handles.remove(); // removes handles from default group
handles.remove("handle-group");
handles.remove("other-handle-group");
removeAll()

Removes all handles.

API Reference search results

NameTypeModule
Loading...
="detail-name">
removeAll()

Removes all handles.

API Reference search results

NameTypeModule
Loading...
Feedback on this topic?