include :: ObjectRange |
This assumes the values in the range have a valid strict weak ordering (have valid semantics for the < operator). While ObjectRange mixes in Enumerable, this method overrides the default version of include, and is way more efficient (it uses a maximum of two comparisons).
Examples
$R(1, 10).include(5) // -> true
$R('a', 'h').include('x') // -> false
$R(1, 10).include(10) // -> true
$R(1, 10, true).include(10) // -> false
|
Prototype API 1.5.0 - prototypejs.org