public class AppendableVec extends Vec
Vec.CollectDomain, Vec.CollectDomainFast, Vec.VectorGroup, Vec.Writer| Modifier and Type | Field and Description |
|---|---|
int |
_chunkOff |
long[] |
_espc |
static byte |
ENUM |
static byte |
NA |
static byte |
NUMBER |
static byte |
STRING |
static byte |
TIME |
static byte |
UUID |
KEY_PREFIX_LEN, PERCENTILES, T_BAD, T_ENUM, T_NUM, T_STR, T_TIME, T_TIMELAST, T_UUID, TYPE_STR| Constructor and Description |
|---|
AppendableVec(Key key) |
AppendableVec(Key key,
long[] espc,
int chunkOff) |
| Modifier and Type | Method and Description |
|---|---|
long |
byteSize()
Size of compressed vector data.
|
protected long |
chunk2StartElem(int cidx)
Convert a chunk-index into a starting row #.
|
NewChunk |
chunkForChunkIdx(int cidx)
The Chunk for a chunk#.
|
Value |
chunkIdx(int cidx)
Get a Chunk's Value by index.
|
Vec |
close(Futures fs) |
static Vec[] |
closeAll(AppendableVec[] avs) |
static Vec[] |
closeAll(AppendableVec[] avs,
Futures fs) |
long |
length()
Number of elements in the vector; returned as a
long instead of
an int because Vecs support more than 2^32 elements. |
int |
nChunks()
Number of chunks, returned as an
int - Chunk count is limited by
the max size of a Java long[]. |
protected boolean |
readable()
Default read/write behavior for Vecs.
|
void |
reduce(AppendableVec nv) |
void |
setSubRange(AppendableVec av)
Add AV build over sub-range of this vec (used e.g.
|
void |
setTypes(byte[] ts) |
boolean |
shouldBeEnum() |
java.lang.String |
toString()
Pretty print the Vec:
[#elems, min/mean/max]{chunks,...} |
protected boolean |
writable()
Default read/write behavior for Vecs.
|
adaptTo, align, at, at16h, at16l, at8, atStr, base, bins, cardinality, checksum_impl, chunkForRow, chunkKey, chunkKey, domain, equals, factor, get_espc, get_type_str, get_type, getVecKey, group, hashCode, isBad, isBinary, isConst, isEnum, isInt, isNA, isNumeric, isString, isTime, isUUID, lazy_bins, makeCon, makeCon, makeCon, makeCon, makeCon, makeCon, makeCons, makeCopy, makeCopy, makeRand, makeRepSeq, makeSeq, makeSeq, makeVec, makeVec, makeZero, makeZero, makeZero, makeZero, makeZeros, makeZeros, max, maxs, mean, min, mins, naCnt, newKey, ninfs, nzCnt, open, pctiles, pinfs, postWrite, preWriting, remove_impl, set, set, set, set, setDomain, sigma, sparseRatio, startRollupStats, startRollupStats, stride, toByteArray, toDoubleArray, toEnum, toInt, toStringVecclone, frozenType, read_impl, read, readExternal, readJSON_impl, readJSON, toJsonString, write_impl, write, writeExternal, writeHTML_impl, writeHTML, writeJSON_impl, writeJSONpublic long[] _espc
public static final byte NA
public static final byte ENUM
public static final byte NUMBER
public static final byte TIME
public static final byte UUID
public static final byte STRING
public int _chunkOff
public AppendableVec(Key key)
public AppendableVec(Key key, long[] espc, int chunkOff)
public void setTypes(byte[] ts)
public static Vec[] closeAll(AppendableVec[] avs)
public static Vec[] closeAll(AppendableVec[] avs, Futures fs)
public void setSubRange(AppendableVec av)
av - public boolean shouldBeEnum()
public void reduce(AppendableVec nv)
protected boolean readable()
Vecprotected boolean writable()
Vecpublic NewChunk chunkForChunkIdx(int cidx)
VecchunkForChunkIdx in class Vecpublic Value chunkIdx(int cidx)
VecDKV.get(). Warning: this pulls the data locally; using this call
on every Chunk index on the same node will probably trigger an OOM!public long length()
Veclong instead of
an int because Vecs support more than 2^32 elements. Overridden
by subclasses that compute length in an alternative way, such as
file-backed Vecs.public int nChunks()
Vecint - Chunk count is limited by
the max size of a Java long[]. Overridden by subclasses that
compute chunks in an alternative way, such as file-backed Vecs.protected long chunk2StartElem(int cidx)
Vecpublic long byteSize()
Vec