- java.lang.Object
-
- com.pervasive.datarush.sequences.TokenSequences
-
public class TokenSequences extends Object
Utilities for working with arrays of tokens.
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static MutableScalarTokenSequenceallocateList(ScalarTokenType type, int initialCapacity)Creates aMutableTokenSequencefor tokens of the specified scalar type.static MutableScalarTokenSequenceallocateList(ScalarTokenType type, int initialCapacity, DataRepresentation representation)Creates aMutableTokenSequencefor tokens of the specified scalar type.static MutableTokenSequenceallocateList(TokenType type, int initialCapacity)Creates aMutableTokenSequencefor tokens of the specified type.static MutableTokenSequenceallocateList(TokenType type, int initialCapacity, DataRepresentation representation)Creates aMutableTokenSequencefor tokens of the specified type.static MutableBinaryTokenSequencebinaryList(int capacity, DataRepresentation representation)Creates aMutableBinaryTokenSequencewith the specified capacity, optionally optimized for sparse data.static MutableBooleanTokenSequencebooleanList(int capacity, DataRepresentation representation)Creates aMutableBooleanTokenSequencewith the specified capacity, optionally optimized for sparse data.static MutableCharTokenSequencecharList(int capacity, DataRepresentation representation)Creates aMutableCharTokenSequencewith the specified capacity, optionally optimized for sparse data.static MutableDateTokenSequencedateList(int capacity, DataRepresentation representation)Creates aMutableDateTokenSequencewith the specified capacity, optionally optimized for sparse data.static MutableDoubleTokenSequencedoubleList(int capacity, DataRepresentation representation)Creates aMutableDoubleTokenSequencewith the specified capacity, optionally optimized for sparse data.static MutableDurationTokenSequencedurationList(int capacity, DataRepresentation representation)Creates aMutableDurationTokenSequencewith the specified capacity, optionally optimized for sparse data.static MutableFloatTokenSequencefloatList(int capacity, DataRepresentation representation)Creates aMutableFloatTokenSequencewith the specified capacity, optionally optimized for sparse data.static MutableIntTokenSequenceintList(int capacity, DataRepresentation representation)Creates aMutableIntTokenSequencewith the specified capacity, optionally optimized for sparse data.static MutableIp4AddressTokenSequenceip4AddressList(int capacity, DataRepresentation representation)Creates aMutableIp4AddressTokenSequencewith the specified capacity, optionally optimized for sparse data.static MutableIp6AddressTokenSequenceip6AddressList(int capacity, DataRepresentation representation)Creates aMutableIp6AddressTokenSequencewith the specified capacity, optionally optimized for sparse data.static MutableLongTokenSequencelongList(int capacity, DataRepresentation representation)Creates aMutableLongTokenSequencewith the specified capacity, optionally optimized for sparse data.static MutableMoneyTokenSequencemoneyList(int capacity, DataRepresentation representation)Creates aMutableMoneyTokenSequencewith the specified capacity, optionally optimized for sparse data.static MutableNumericTokenSequencenumericList(int capacity, DataRepresentation representation)Creates aMutableNumericTokenSequencewith the specified capacity, optionally optimized for sparse data.static <O> MutableObjectTokenSequence<O>objectList(ObjectTokenType<O> type, int capacity, DataRepresentation representation)Creates aMutableObjectTokenSequencewith the specified capacity, optionally optimized for sparse data.static MutablePeriodTokenSequenceperiodList(int capacity, DataRepresentation representation)Creates aMutablePeriodTokenSequencewith the specified capacity, optionally optimized for sparse data.static MutableRecordTokenSequencerecordList(RecordTokenType type, int capacity, DataRepresentation representation)Creates aMutableRecordTokenSequencewith the specified capacity, optionally optimized for sparse data.static MutableStringTokenSequencestringList(int capacity, DataRepresentation representation)Creates aMutableStringTokenSequencewith the specified capacity, optionally optimized for sparse data.static MutableTimeTokenSequencetimeList(int capacity, DataRepresentation representation)Creates aMutableTimeTokenSequencewith the specified capacity, optionally optimized for sparse data.static MutableTimestampTokenSequencetimestampList(int capacity, DataRepresentation representation)Creates aMutableTimestampTokenSequencewith the specified capacity, optionally optimized for sparse data.
-
-
-
Method Detail
-
binaryList
public static MutableBinaryTokenSequence binaryList(int capacity, DataRepresentation representation)
Creates aMutableBinaryTokenSequencewith the specified capacity, optionally optimized for sparse data.- Parameters:
capacity- the initial capacityrepresentation- the data representation- Returns:
- the newly created token sequence.
-
booleanList
public static MutableBooleanTokenSequence booleanList(int capacity, DataRepresentation representation)
Creates aMutableBooleanTokenSequencewith the specified capacity, optionally optimized for sparse data.- Parameters:
capacity- the initial capacityrepresentation- the data representation- Returns:
- the newly created token sequence.
-
charList
public static MutableCharTokenSequence charList(int capacity, DataRepresentation representation)
Creates aMutableCharTokenSequencewith the specified capacity, optionally optimized for sparse data.- Parameters:
capacity- the initial capacityrepresentation- the data representation- Returns:
- the newly created token sequence.
-
durationList
public static MutableDurationTokenSequence durationList(int capacity, DataRepresentation representation)
Creates aMutableDurationTokenSequencewith the specified capacity, optionally optimized for sparse data.- Parameters:
capacity- the initial capacityrepresentation- the data representation- Returns:
- the newly created token sequence.
-
dateList
public static MutableDateTokenSequence dateList(int capacity, DataRepresentation representation)
Creates aMutableDateTokenSequencewith the specified capacity, optionally optimized for sparse data.- Parameters:
capacity- the initial capacityrepresentation- the data representation- Returns:
- the newly created token sequence.
-
doubleList
public static MutableDoubleTokenSequence doubleList(int capacity, DataRepresentation representation)
Creates aMutableDoubleTokenSequencewith the specified capacity, optionally optimized for sparse data.- Parameters:
capacity- the initial capacityrepresentation- the data representation- Returns:
- the newly created token sequence.
-
floatList
public static MutableFloatTokenSequence floatList(int capacity, DataRepresentation representation)
Creates aMutableFloatTokenSequencewith the specified capacity, optionally optimized for sparse data.- Parameters:
capacity- the initial capacityrepresentation- the data representation- Returns:
- the newly created token sequence.
-
intList
public static MutableIntTokenSequence intList(int capacity, DataRepresentation representation)
Creates aMutableIntTokenSequencewith the specified capacity, optionally optimized for sparse data.- Parameters:
capacity- the initial capacityrepresentation- the data representation- Returns:
- the newly created token sequence.
-
ip4AddressList
public static MutableIp4AddressTokenSequence ip4AddressList(int capacity, DataRepresentation representation)
Creates aMutableIp4AddressTokenSequencewith the specified capacity, optionally optimized for sparse data.- Parameters:
capacity- the initial capacityrepresentation- the data representation- Returns:
- the newly created token sequence.
-
ip6AddressList
public static MutableIp6AddressTokenSequence ip6AddressList(int capacity, DataRepresentation representation)
Creates aMutableIp6AddressTokenSequencewith the specified capacity, optionally optimized for sparse data.- Parameters:
capacity- the initial capacityrepresentation- the data representation- Returns:
- the newly created token sequence.
-
longList
public static MutableLongTokenSequence longList(int capacity, DataRepresentation representation)
Creates aMutableLongTokenSequencewith the specified capacity, optionally optimized for sparse data.- Parameters:
capacity- the initial capacityrepresentation- the data representation- Returns:
- the newly created token sequence.
-
moneyList
public static MutableMoneyTokenSequence moneyList(int capacity, DataRepresentation representation)
Creates aMutableMoneyTokenSequencewith the specified capacity, optionally optimized for sparse data.- Parameters:
capacity- the initial capacityrepresentation- the data representation- Returns:
- the newly created token sequence.
-
numericList
public static MutableNumericTokenSequence numericList(int capacity, DataRepresentation representation)
Creates aMutableNumericTokenSequencewith the specified capacity, optionally optimized for sparse data.- Parameters:
capacity- the initial capacityrepresentation- the data representation- Returns:
- the newly created token sequence.
-
objectList
public static <O> MutableObjectTokenSequence<O> objectList(ObjectTokenType<O> type, int capacity, DataRepresentation representation)
Creates aMutableObjectTokenSequencewith the specified capacity, optionally optimized for sparse data.- Type Parameters:
O- the type of the elements of the sequence- Parameters:
type- the object typecapacity- the initial capacityrepresentation- the data representation- Returns:
- the newly created token sequence.
-
periodList
public static MutablePeriodTokenSequence periodList(int capacity, DataRepresentation representation)
Creates aMutablePeriodTokenSequencewith the specified capacity, optionally optimized for sparse data.- Parameters:
capacity- the initial capacityrepresentation- the data representation- Returns:
- the newly created token sequence.
-
stringList
public static MutableStringTokenSequence stringList(int capacity, DataRepresentation representation)
Creates aMutableStringTokenSequencewith the specified capacity, optionally optimized for sparse data.- Parameters:
capacity- the initial capacityrepresentation- the data representation- Returns:
- the newly created token sequence.
-
timeList
public static MutableTimeTokenSequence timeList(int capacity, DataRepresentation representation)
Creates aMutableTimeTokenSequencewith the specified capacity, optionally optimized for sparse data.- Parameters:
capacity- the initial capacityrepresentation- the data representation- Returns:
- the newly created token sequence.
-
timestampList
public static MutableTimestampTokenSequence timestampList(int capacity, DataRepresentation representation)
Creates aMutableTimestampTokenSequencewith the specified capacity, optionally optimized for sparse data.- Parameters:
capacity- the initial capacityrepresentation- the data representation- Returns:
- the newly created token sequence.
-
recordList
public static MutableRecordTokenSequence recordList(RecordTokenType type, int capacity, DataRepresentation representation)
Creates aMutableRecordTokenSequencewith the specified capacity, optionally optimized for sparse data.- Parameters:
type- the record typecapacity- the initial capacityrepresentation- the data representation- Returns:
- the newly created token sequence.
-
allocateList
public static MutableTokenSequence allocateList(TokenType type, int initialCapacity)
Creates aMutableTokenSequencefor tokens of the specified type.- Parameters:
type- the data type of tokens in the arrayinitialCapacity- the initial capacity of the array- Returns:
- a
TokenArrayof the appropriate type
-
allocateList
public static MutableScalarTokenSequence allocateList(ScalarTokenType type, int initialCapacity)
Creates aMutableTokenSequencefor tokens of the specified scalar type.- Parameters:
type- the data type of tokens in the arrayinitialCapacity- the initial capacity of the array- Returns:
- a
TokenArrayof the appropriate type
-
allocateList
public static MutableTokenSequence allocateList(TokenType type, int initialCapacity, DataRepresentation representation)
Creates aMutableTokenSequencefor tokens of the specified type.- Parameters:
type- the data type of tokens in the arrayinitialCapacity- the initial capacity of the arrayrepresentation- the data representation- Returns:
- a
TokenArrayof the appropriate type
-
allocateList
public static MutableScalarTokenSequence allocateList(ScalarTokenType type, int initialCapacity, DataRepresentation representation)
Creates aMutableTokenSequencefor tokens of the specified scalar type.- Parameters:
type- the data type of tokens in the arrayinitialCapacity- the initial capacity of the arrayrepresentation- the data representation- Returns:
- a
TokenArrayof the appropriate type
-
-