public class RangeFactory extends Object
Modifier and Type | Field and Description |
---|---|
static Range |
ALL
The interval that matches the entire list it is applied to.
|
static Range |
FIRST
The interval that matches just the first element of the list it is applied to.
|
static Range |
LAST
The interval that matches just the last element of the list it is applied to.
|
Constructor and Description |
---|
RangeFactory() |
Modifier and Type | Method and Description |
---|---|
static Range |
createAllRange()
Creates a new Range which matches all the elements of the list it is applied to.
|
static Range |
createHeadRange(int size)
Creates a new Range starting from 0 and having the specified size.
|
static Range |
createRange(int start,
int size) |
static Range |
createTailRange(int size)
Creates a new Range starting from the end of the list it is applied to and having the specified size.
|
static Range |
getALL()
Helper method for accessing
ALL static field in velocity |
static Range |
getFIRST()
Helper method for accessing
FIRST static field in velocity |
static Range |
getLAST()
Helper method for accessing
LAST static field in velocity |
public static final Range ALL
public static final Range FIRST
public static final Range LAST
public static Range createRange(int start, int size)
Range(int, int)
public static Range createAllRange()
public static Range createHeadRange(int size)
size
elements of the list it is applied to.size
- The size of the intervalpublic static Range createTailRange(int size)
size
elements of the list.size
- The size of the intervalCopyright © 2004–2022 XWiki. All rights reserved.