A Rich Slice object, containing a sequence of slice expressions
A Rich Slice object, containing a sequence of slice expressions
import io.radanalytics.silex.util.richslice._ RichSlice(1) // selects element(1) RichSlice(2, 3, 5 to 11) // selects elements 2, 3 and 5 through 11 RichSlice(9 to 0 by -1) // selects first 10 elements in reverse order RichSlice(20 to * by 2) // selects elements 20 to end, by 2s
Provides rich slice methods on Scala Seq types
One slice in a rich slice expression list
Internal mechanism to support use of '*' in rich slice expressions as a wildcard index
Internal mechanism to support use of '*' in rich slice expressions as a wildcard index
When '*' is used in place of a numeric index, it matches all indices up to or after a bound.
When '*' is used in place of a numeric index, it matches all indices up to or after a bound.
import io.radanalytics.silex.util.richslice._ data.richSlice(* to 5) // selects elements 0 through 5 data.richSlice(5 to *) // selects elmeents 5 up to end of data data.richSlice(*) // selects all data data.richSlice(* by -1) // selects data in reverse order
Factory methods for instantiating RichSlice objects
Factory methods for instantiating RichSlice objects
import io.radanalytics.silex.util.richslice._ RichSlice(1) // selects element(1) RichSlice(2, 3, 5 to 11) // selects elements 2, 3 and 5 through 11 RichSlice(9 to 0 by -1) // selects first 10 elements in reverse order RichSlice(20 to * by 2) // selects elements 20 to end, by 2s
Implicit conversions from rich slice expressions to Slice objects
Internal mechanism to support use of '*' in rich slice expressions as a wildcard index