Adds a range-specific value.
Adds a range-specific value. The rangeStart and rangeEnd parameters must be of the same length.
the inclusive start of the range
the inclusive end of the range
the data to be stored for this range
an updated instance of [this]
Retrieves the value stored under the longest range matching.
Retrieves the value stored under the longest range matching.
the number to match prefixes against
This class stores data belonging to decimal number ranges. This can be used inside dial plans. Ranges with more than 2 permutations are compressed automatically. When querying this the value of the longest matching path will be returned. So if there are the ranges 1 and 11-13 when querying with 12, the later's value will be returned. This is as it holds the longer prefix (2 digits instead of 1).
Example usage: