public final class Ip6AddressTokenList extends AbstractScalarTokenSequence implements MutableIp6AddressTokenSequence
MutableIp6AddressTokenSequence
.TokenTypeConstant.IP6ADDRESS
Constructor and Description |
---|
Ip6AddressTokenList(int initialCapacity)
Creates an empty array of ip6address tokens
|
Modifier and Type | Method and Description |
---|---|
void |
append(byte[] value)
Appends the specified ip6address value to this sequence.
|
void |
append(byte[] value,
int count)
Appends the specified ip6address value to this sequence
multiple times.
|
void |
append(long[] value) |
void |
fill(int start,
int length,
byte[] value)
Sets the tokens in the specified subsequence to the given ip6address value.
|
void |
fillValue(int start,
int length,
TokenValued value)
Sets the tokens in the specified subsequence to the given value.
|
byte[] |
getAddress(int i)
Gets the value of the specified token as
a raw IPv6 address value.
|
Inet6Address |
getInetAddress(int i)
Gets the value of the specified token as
an Inet6Address value.
|
Ip6AddressValued |
getToken(int index)
Gets the value at the specified position.
|
Ip6AddressSettable |
getTokenSetter(int index)
Returns a mutator for the given index.
|
ScalarTokenType |
getType()
Gets the data type of the tokens in the sequence.
|
void |
getValues(int index,
long[][] values,
boolean[] nullFlags,
int offset,
int length)
Gets the values and null indicators for a range of tokens.
|
boolean |
isZero(int index)
Indicates whether the specified token has a zero value.
|
Ip6AddressValuedIterator |
newValueIterator()
Creates an iterator over the non-null values of this sequence.
|
void |
set(int index,
byte[] value)
Sets the token at the specified position to the given raw ip6address value.
|
void |
set(int index,
Inet4Address value)
Sets the token at the specified position to the given Inet4Address value.
|
void |
set(int index,
Inet6Address value)
Sets the token at the specified position to the given Inet6Address value.
|
void |
set(int index,
long[] value)
Sets the token at the specified position to the given raw ip6address
value as a pair of longs.
|
void |
setNull(int index)
Sets the token at the specified position to be null valued.
|
void |
setNull(int start,
int length)
Sets the tokens in the specified subsequence to be null valued.
|
void |
setValue(int index,
TokenValued value)
Sets the token at the specified position to the given value.
|
void |
setValues(int start,
TokenSequence values,
int offset,
int length)
Sets the tokens in the specified subsequence of the array
to the corresponding values from a subsequence of the given source
sequence.
|
void |
setZero(int index)
Sets the token at the specified position to be zero valued.
|
void |
setZero(int start,
int length)
Sets the tokens in the specified subsequence to be zero valued.
|
append, append, append, append, appendNull, appendNull, appendZero, appendZero, capacity, compareElement, compareElements, ensureCanonical, getElementComparator, getModificationCount, hashCode, isNull, isNull, map, remaining, reset, size, toString, toString
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
ensureCanonical, getModificationCount
isNull
appendNull, appendNull, appendZero, appendZero, reset
compareElement, compareElements, getElementComparator, hashCode, isNull, size, toString
append, append, append, append
public Ip6AddressTokenList(int initialCapacity)
initialCapacity
- the initial capacity.public ScalarTokenType getType()
ScalarTokenSequence
getType
in interface ScalarTokenSequence
getType
in interface ScalarTyped
getType
in interface TokenTyped
public byte[] getAddress(int i)
Ip6AddressTokenSequence
A copy of the value is returned.
getAddress
in interface Ip6AddressTokenSequence
i
- the position of the token in the sequencenull
is returned.public Inet6Address getInetAddress(int i)
Ip6AddressTokenSequence
getInetAddress
in interface Ip6AddressTokenSequence
i
- the position of the token in the sequencenull
is returned.public Ip6AddressValued getToken(int index)
TokenSequence
getToken
in interface Ip6AddressTokenSequence
getToken
in interface ScalarTokenSequence
getToken
in interface TokenSequence
index
- the index of the tokenpublic Ip6AddressSettable getTokenSetter(int index)
MutableTokenSequence
getTokenSetter
in interface MutableTokenSequence
getTokenSetter
in interface MutableIp6AddressTokenSequence
getTokenSetter
in interface MutableScalarTokenSequence
index
- the positionpublic void getValues(int index, long[][] values, boolean[] nullFlags, int offset, int length)
Ip6AddressTokenSequence
References to the values of the tokens are returned. Modifying these references modify the values of the tokens in the sequence.
getValues
in interface Ip6AddressTokenSequence
index
- the starting index of the rangevalues
- an array into which to place element valuesnullFlags
- an array into which to place null indicator valuesoffset
- the starting offset into the target arrays. That is,
elements[offset]
and nulls[offset]
will get the
value and null indicator respectively of the token at position
start
, and so on.length
- number of tokens to getpublic void setNull(int index)
MutableTokenSequence
setNull
in interface MutableTokenSequence
index
- the position of the token in the arraypublic void setNull(int start, int length)
MutableTokenSequence
setNull
in interface MutableTokenSequence
start
- the starting index of the subsequence in the arraylength
- the length of the subsequencepublic void setZero(int index)
MutableTokenSequence
setZero
in interface MutableTokenSequence
index
- the position of the token in the arraypublic void setZero(int start, int length)
MutableTokenSequence
setZero
in interface MutableTokenSequence
start
- the starting index of the subsequence in the arraylength
- the length of the subsequencepublic final boolean isZero(int index)
ScalarTokenSequence
isZero
in interface ScalarTokenSequence
index
- the index of the tokentrue
if the element is zero,
false
otherwisepublic Ip6AddressValuedIterator newValueIterator()
TokenSequence
newValueIterator
in interface Ip6AddressTokenSequence
newValueIterator
in interface ScalarTokenSequence
newValueIterator
in interface TokenSequence
public void fill(int start, int length, byte[] value)
start
- the starting index of the subsequence in the arraylength
- the length of the subsequencevalue
- the raw ip6address value to which to set the tokenspublic void setValue(int index, TokenValued value)
MutableTokenSequence
setValue
in interface MutableTokenSequence
index
- the position of the token in the arrayvalue
- the value to which to set the token. This value
must be of an appropriate type for the array.public void fillValue(int start, int length, TokenValued value)
MutableTokenSequence
fillValue
in interface MutableTokenSequence
start
- the starting index of the subsequence in the arraylength
- the length of the subsequencevalue
- the value to which to set the tokens. This value
must be of an appropriate type for the arraypublic void setValues(int start, TokenSequence values, int offset, int length)
MutableTokenSequence
setValues
in interface MutableTokenSequence
start
- the starting index of the subsequence in the arrayvalues
- the source sequence. This sequence must be
of an appropriate type for the array.offset
- the starting index in the source sequence.
Corresponding values will be taken relative to this position.
That is, the value of the token at position offset
in
values
will be assigned to the token at position
start
, and so on.length
- the number of tokens to copypublic void append(long[] value)
public void append(byte[] value)
MutableIp6AddressTokenSequence
append
in interface MutableIp6AddressTokenSequence
value
- the value to append. If null
,
this is equivalent to appendNull()
.public void append(byte[] value, int count)
MutableIp6AddressTokenSequence
append
in interface MutableIp6AddressTokenSequence
value
- the value to append. If null
,
this is equivalent to appendNull(count)
.count
- the number of copies to append.public void set(int index, long[] value)
MutableIp6AddressTokenSequence
set
in interface MutableIp6AddressTokenSequence
index
- the position of the token in the arrayvalue
- the ip6address as a pair of longs to which to set the token.
Passing null
is equivalent to calling setNull(index)
.public void set(int index, byte[] value)
MutableIp6AddressTokenSequence
The input array is copied to prevent later modification of the value that is set.
set
in interface MutableIp6AddressTokenSequence
index
- the position of the token in the arrayvalue
- the raw ip4address value to which to set the token.
Passing null
is equivalent to calling setNull(index)
.public void set(int index, Inet4Address value)
MutableIp6AddressTokenSequence
set
in interface MutableIp6AddressTokenSequence
index
- the position of the token in the arrayvalue
- the Inet6Address value to which to set the token.
Passing null
is equivalent to calling setNull(index)
.public void set(int index, Inet6Address value)
MutableIp6AddressTokenSequence
set
in interface MutableIp6AddressTokenSequence
index
- the position of the token in the arrayvalue
- the Inet6Address value to which to set the token.
Passing null
is equivalent to calling setNull(index)
.Copyright © 2020 Actian Corporation. All rights reserved.