new Layers(Specifies)
Creates a collection of layers for the gauge control.
Parameters:
Name | Type | Description |
---|---|---|
Specifies |
Gauge | an object of Gauge type |
Methods
Add(key) → {Layer}
The Add() method creates and adds/gets a Layer object to the collection and returns a reference to the newly created object.
Parameters:
Name | Type | Description |
---|---|---|
key |
any | Specifies the layer's key (ignored if missing) |
Returns:
Returns an object of Layer type
- Type
- Layer
Clear()
The Clear() method removes all layers within the collection
GetCount() → {number}
The GetCount() method specifies the number of layers.
Returns:
Indicates the number of layers
- Type
- number
GetValue() → {number}
The GetValue() method specifies the control's value. Generally, the control's value gets the value (offset or its rotation angle) of the layer based on the OnDrag property.
Returns:
Returns the control's value.
- Type
- number
Item(key) → {Layer}
The Item() method returns a specific Layer of the Layers collection
Parameters:
Name | Type | Description |
---|---|---|
key |
any | Specifies a integer expression that indicates the index of the layer to be requested, or any other value that indicates the key of the layer (layer's key or back). |
Returns:
Returns an object of Layer type associated with the giving index/key
- Type
- Layer
Load(value)
The Load() method loads the layers from a string-representation
Parameters:
Name | Type | Description |
---|---|---|
value |
string | Specifies the string-representation to get the control's layers from |
Remove(key)
The Remove() method removes a specific member from the Layers collection.
Parameters:
Name | Type | Description |
---|---|---|
key |
any | Specifies a integer expression that specifies the index of the layer to be removed, or any other value to specify the key of the layer to be removed. |
Save() → {string}
The Save() method saves the layers into a string-representation
Returns:
Returns the string-representation of the control's layers
- Type
- string
SetCount(value)
The GetCount() method specifies the number of layers.
Parameters:
Name | Type | Description |
---|---|---|
value |
number | Specifies the number of layers |
SetValue(value)
The SetValue() method changes the control's value.
Parameters:
Name | Type | Description |
---|---|---|
value |
number | Specifies the index or the key of the layer whose value determines the control's Value property. |
forEach(mask)
The forEach() method enumerates the layers that matches the mask (visible/selectable)
Parameters:
Name | Type | Description |
---|---|---|
mask |
number | Specifies the type or order of the layers to get enumerated as follows (Gauge.ViewableLObjEnum type):
|