public interface Index extends Serializable
Modifier and Type | Method and Description |
---|---|
MutableSparseVector |
convertArrayToVector(double[] values)
This method is used to convert arrays to sparse arrays.
|
long |
getId(int idx)
Get the key for an index.
|
LongList |
getIds()
Get the list of IDs.
|
int |
getIndex(long id)
Get the index of an id.
|
int |
getObjectCount()
Get the number of ID in the index.
|
int getIndex(long id)
id
- The id to query.long getId(int idx)
idx
- The index of the ID to retrieve.int getObjectCount()
LongList getIds()
MutableSparseVector convertArrayToVector(double[] values)
values
- A array of double value.Copyright © 2013 GroupLens Research. All Rights Reserved.