new Aggregation(name, level)
Constructor.
Extends:
Parameters:
| Name | Type | Description |
|---|---|---|
name |
string | the unique name for this precision |
level |
number | a relative aggregation level value |
Extends
Members
-
level
-
Get the aggregate level value.
This is an alias for module:util~ComparableEnum#value.
-
name
-
Get the enum name.
- Inherited From:
- Overrides:
-
value
-
Get the comparable value.
- Inherited From:
- Overrides:
Methods
-
<static> enumValues()
-
Get the module:domain~Aggregations values.
-
compareTo(other)
-
Compare two ComparableEnum objects based on their
valuevalues.Parameters:
Name Type Description otherComparableEnum the object to compare to
- Inherited From:
- Overrides:
Returns:
-1ifthis.valueis less thanother.value,1ifthis.valueis greater thanother.value,0otherwise (when the values are equal)- Type
- number
-
equals(value)
-
Test if a string is equal to this enum's name.
As long as enum values are consistently obtained from the module:util~Enum.enumValues array then enum instances can be compared with
===. If unsure, this method can be used to compare string values instead.If
valueis passed as an actual Enum instance, then if that enum is the same class as this enum it'snameis compared to this instance'sname.Parameters:
Name Type Description valuestring | Enum the value to test
- Inherited From:
- Overrides:
Returns:
trueifvalueis the same as this instance'snamevalue- Type
- boolean