Class VirtualList<E>
java.lang.Object
com.aerospike.mapper.tools.virtuallist.BaseVirtualList<E>
com.aerospike.mapper.tools.virtuallist.VirtualList<E>
- All Implemented Interfaces:
IVirtualList<E>
-
Constructor Summary
ConstructorsConstructorDescriptionVirtualList(@NotNull IAeroMapper mapper, @NotNull Class<?> owningClazz, @NotNull Object key, @NotNull String binName, @NotNull Class<E> clazz) VirtualList(@NotNull IAeroMapper mapper, @NotNull Object object, @NotNull String binName, @NotNull Class<E> clazz) -
Method Summary
Modifier and TypeMethodDescriptionlongAppend a new element at the end of the virtual list.longAppend a new element at the end of the virtual list.beginMulti(com.aerospike.client.policy.WritePolicy writePolicy) voidclear()Remove all the items in the virtual list.get(int index) Get an element from the virtual list at a specific index.get(com.aerospike.client.policy.Policy policy, int index) Get an element from the virtual list at a specific index.getByIndexRange(int index, int count, ReturnType returnResultsOfType) Get "count" items starting at specified index.getByIndexRange(int index, ReturnType returnResultsOfType) Get items starting at specified index to the end of virtual list.getByIndexRange(com.aerospike.client.policy.WritePolicy writePolicy, int index, int count, ReturnType returnResultsOfType) Get "count" items starting at specified index.getByIndexRange(com.aerospike.client.policy.WritePolicy writePolicy, int index, ReturnType returnResultsOfType) Get items starting at specified index to the end of virtual list.getByKey(com.aerospike.client.policy.WritePolicy writePolicy, Object key, ReturnType returnResultsOfType) Get items from the list matching the specified key.getByKey(Object key, ReturnType returnResultsOfType) Get items from the list matching the specified key.getByKeyRange(com.aerospike.client.policy.WritePolicy writePolicy, Object startKey, Object endKey, ReturnType returnResultsOfType) Get items from the list matching the specified key range.getByKeyRange(Object startKey, Object endKey, ReturnType returnResultsOfType) Get items from the list matching the specified key range.getByRank(int rank, ReturnType returnResultsOfType) Get items identified by rank.getByRank(com.aerospike.client.policy.WritePolicy writePolicy, int rank, ReturnType returnResultsOfType) Get items identified by rank.getByRankRange(int rank, int count, ReturnType returnResultsOfType) Get "count" items starting at specified rank to the last ranked item.getByRankRange(int rank, ReturnType returnResultsOfType) Get items starting at specified rank to the last ranked item.getByRankRange(com.aerospike.client.policy.WritePolicy writePolicy, int rank, int count, ReturnType returnResultsOfType) Get "count" items starting at specified rank to the last ranked item.getByRankRange(com.aerospike.client.policy.WritePolicy writePolicy, int rank, ReturnType returnResultsOfType) Get items starting at specified rank to the last ranked item.getByValue(com.aerospike.client.policy.WritePolicy writePolicy, Object value, ReturnType returnResultsOfType) Get items from the list matching the specified value.getByValue(Object value, ReturnType returnResultsOfType) Get items from the list matching the specified value.getByValueList(com.aerospike.client.policy.WritePolicy writePolicy, List<Object> values, ReturnType returnResultsOfType) Get items from the list matching the specified list of values.getByValueList(List<Object> values, ReturnType returnResultsOfType) Get items from the list matching the specified list of values.getByValueRange(com.aerospike.client.policy.WritePolicy writePolicy, Object startValue, Object endValue, ReturnType returnResultsOfType) Get items from the list matching the specified value.getByValueRange(Object startValue, Object endValue, ReturnType returnResultsOfType) Get items from the list matching the specified value.getByValueRelativeRankRange(com.aerospike.client.policy.WritePolicy writePolicy, Object value, int rank, int count, ReturnType returnResultsOfType) Get items nearest to value and greater by relative rank with a count limit.getByValueRelativeRankRange(com.aerospike.client.policy.WritePolicy writePolicy, Object value, int rank, ReturnType returnResultsOfType) Get items nearest to value and greater by relative rank.getByValueRelativeRankRange(Object value, int rank, int count, ReturnType returnResultsOfType) Get items nearest to value and greater by relative rank with a count limit.getByValueRelativeRankRange(Object value, int rank, ReturnType returnResultsOfType) Get items nearest to value and greater by relative rank.removeByIndex(int index, ReturnType returnResultsOfType) Remove item identified by index and returns removed data.removeByIndex(com.aerospike.client.policy.WritePolicy writePolicy, int index, ReturnType returnResultsOfType) Remove item identified by index and returns removed data.removeByIndexRange(int index, int count, ReturnType returnResultsOfType) Remove "count" items starting at specified index and returns removed data.removeByIndexRange(int index, ReturnType returnResultsOfType) Remove items starting at specified index to the end of list and returns removed data.removeByIndexRange(com.aerospike.client.policy.WritePolicy writePolicy, int index, int count, ReturnType returnResultsOfType) Remove "count" items starting at specified index and returns removed data.removeByIndexRange(com.aerospike.client.policy.WritePolicy writePolicy, int index, ReturnType returnResultsOfType) Remove items starting at specified index to the end of list and returns removed data.removeByKey(com.aerospike.client.policy.WritePolicy writePolicy, Object key, ReturnType returnResultsOfType) Remove items from the list matching the specified key.removeByKey(Object key, ReturnType returnResultsOfType) Remove items from the list matching the specified key.removeByKeyRange(com.aerospike.client.policy.WritePolicy writePolicy, Object startKey, Object endKey, ReturnType returnResultsOfType) Remove items from the list matching the specified key.removeByKeyRange(Object startKey, Object endKey, ReturnType returnResultsOfType) Remove items from the list matching the specified key.removeByRank(int rank, ReturnType returnResultsOfType) Remove item identified by rank and returns removed data.removeByRank(com.aerospike.client.policy.WritePolicy writePolicy, int rank, ReturnType returnResultsOfType) Remove item identified by rank and returns removed data.removeByRankRange(int rank, int count, ReturnType returnResultsOfType) Remove "count" items starting at specified rank and returns removed data.removeByRankRange(int rank, ReturnType returnResultsOfType) Remove items starting at specified rank to the last ranked item and returns removed data.removeByRankRange(com.aerospike.client.policy.WritePolicy writePolicy, int rank, int count, ReturnType returnResultsOfType) Remove "count" items starting at specified rank and returns removed data.removeByRankRange(com.aerospike.client.policy.WritePolicy writePolicy, int rank, ReturnType returnResultsOfType) Remove items starting at specified rank to the last ranked item and returns removed data.removeByValue(com.aerospike.client.policy.WritePolicy writePolicy, Object value, ReturnType returnResultsOfType) Remove items identified by value and returns the removed data.removeByValue(Object value, ReturnType returnResultsOfType) Remove items identified by value and returns the removed data.removeByValueList(com.aerospike.client.policy.WritePolicy writePolicy, List<Object> values, ReturnType returnResultsOfType) Remove items identified by list of values and returns the removed data.removeByValueList(List<Object> values, ReturnType returnResultsOfType) Remove items identified by list of values and returns the removed data.removeByValueRange(com.aerospike.client.policy.WritePolicy writePolicy, Object startValue, Object endValue, ReturnType returnResultsOfType) Remove items from the list matching the specified value.removeByValueRange(Object startValue, Object endValue, ReturnType returnResultsOfType) Remove items from the list matching the specified value.removeByValueRelativeRankRange(com.aerospike.client.policy.WritePolicy writePolicy, Object value, int rank, int count, ReturnType returnResultsOfType) Remove items nearest to value and greater by relative rank with a count limit.removeByValueRelativeRankRange(com.aerospike.client.policy.WritePolicy writePolicy, Object value, int rank, ReturnType returnResultsOfType) Remove items nearest to value and greater by relative rank.removeByValueRelativeRankRange(Object value, int rank, int count, ReturnType returnResultsOfType) Remove items nearest to value and greater by relative rank with a count limit.removeByValueRelativeRankRange(Object value, int rank, ReturnType returnResultsOfType) Remove items nearest to value and greater by relative rank.longsize(com.aerospike.client.policy.Policy policy) Get the size of the virtual list (number of elements)
-
Constructor Details
-
VirtualList
-
VirtualList
public VirtualList(@NotNull @NotNull IAeroMapper mapper, @NotNull @NotNull Object object, @NotNull @NotNull String binName, @NotNull @NotNull Class<E> clazz)
-
-
Method Details
-
changeKey
-
beginMultiOperation
-
beginMulti
-
getByValue
Description copied from interface:IVirtualListGet items from the list matching the specified value.- Specified by:
getByValuein interfaceIVirtualList<E>- Parameters:
value- The value to get.returnResultsOfType- Type to return.- Returns:
- A list of the records which match the given value.
-
getByValue
public List<E> getByValue(com.aerospike.client.policy.WritePolicy writePolicy, Object value, ReturnType returnResultsOfType) Description copied from interface:IVirtualListGet items from the list matching the specified value.- Specified by:
getByValuein interfaceIVirtualList<E>- Parameters:
writePolicy- An Aerospike write policy to use for the operate() operation.value- The value to get.returnResultsOfType- Type to return.- Returns:
- A list of the records which match the given value.
-
getByValueRange
Description copied from interface:IVirtualListGet items from the list matching the specified value. If the list is mapped to a MAP in Aerospike, the start value and end value will dictate the range of values to get, inclusive of the start, exclusive of the end. If the list is mapped to a LIST in Aerospike however, the start and end range represent values to get from the list.- Specified by:
getByValueRangein interfaceIVirtualList<E>- Parameters:
startValue- Start value of the range to get.endValue- End value of the range to get.returnResultsOfType- Type to return.- Returns:
- A list of the records which match the given value range.
-
getByValueRange
public List<E> getByValueRange(com.aerospike.client.policy.WritePolicy writePolicy, Object startValue, Object endValue, ReturnType returnResultsOfType) Description copied from interface:IVirtualListGet items from the list matching the specified value. If the list is mapped to a MAP in Aerospike, the start value and end value will dictate the range of values to get, inclusive of the start, exclusive of the end. If the list is mapped to a LIST in Aerospike however, the start and end range represent values to get from the list.- Specified by:
getByValueRangein interfaceIVirtualList<E>- Parameters:
writePolicy- An Aerospike write policy to use for the operate() operation.startValue- Start value of the range to get.endValue- End value of the range to get.returnResultsOfType- Type to return.- Returns:
- A list of the records which match the given value range.
-
getByValueList
Description copied from interface:IVirtualListGet items from the list matching the specified list of values.- Specified by:
getByValueListin interfaceIVirtualList<E>- Parameters:
values- The list of values to get.returnResultsOfType- Type to return.- Returns:
- A list of the records which match the given list of values.
-
getByValueList
public List<E> getByValueList(com.aerospike.client.policy.WritePolicy writePolicy, List<Object> values, ReturnType returnResultsOfType) Description copied from interface:IVirtualListGet items from the list matching the specified list of values.- Specified by:
getByValueListin interfaceIVirtualList<E>- Parameters:
writePolicy- An Aerospike write policy to use for the operate() operation.values- The list of values to get.returnResultsOfType- Type to return.- Returns:
- A list of the records which match the given list of values.
-
getByValueRelativeRankRange
Description copied from interface:IVirtualListGet items nearest to value and greater by relative rank.- Specified by:
getByValueRelativeRankRangein interfaceIVirtualList<E>- Parameters:
value- The value to base the relative rank range calculation on.rank- The relative rank.returnResultsOfType- Type to return.- Returns:
- A list of records that matches the given value and rank.
-
getByValueRelativeRankRange
public List<E> getByValueRelativeRankRange(com.aerospike.client.policy.WritePolicy writePolicy, Object value, int rank, ReturnType returnResultsOfType) Description copied from interface:IVirtualListGet items nearest to value and greater by relative rank.- Specified by:
getByValueRelativeRankRangein interfaceIVirtualList<E>- Parameters:
writePolicy- An Aerospike write policy to use for the operate() operation.value- The value to base the relative rank range calculation on.rank- The relative rank.returnResultsOfType- Type to return.- Returns:
- A list of records that matches the given value and rank.
-
getByValueRelativeRankRange
public List<E> getByValueRelativeRankRange(Object value, int rank, int count, ReturnType returnResultsOfType) Description copied from interface:IVirtualListGet items nearest to value and greater by relative rank with a count limit.- Specified by:
getByValueRelativeRankRangein interfaceIVirtualList<E>- Parameters:
value- The value to base the relative rank range calculation on.rank- The relative rank.count- The count limit.returnResultsOfType- Type to return.- Returns:
- A list of records that matches the given value, rank and count.
-
getByValueRelativeRankRange
public List<E> getByValueRelativeRankRange(com.aerospike.client.policy.WritePolicy writePolicy, Object value, int rank, int count, ReturnType returnResultsOfType) Description copied from interface:IVirtualListGet items nearest to value and greater by relative rank with a count limit.- Specified by:
getByValueRelativeRankRangein interfaceIVirtualList<E>- Parameters:
writePolicy- An Aerospike write policy to use for the operate() operation.value- The value to base the relative rank range calculation on.rank- The relative rank.count- The count limit.returnResultsOfType- Type to return.- Returns:
- A list of records that matches the given value, rank and count.
-
getByIndexRange
Description copied from interface:IVirtualListGet items starting at specified index to the end of virtual list.- Specified by:
getByIndexRangein interfaceIVirtualList<E>- Parameters:
index- The start index to get items from to the end of the virtual list.returnResultsOfType- Type to return.- Returns:
- A list of the records which match the given index.
-
getByIndexRange
public List<E> getByIndexRange(com.aerospike.client.policy.WritePolicy writePolicy, int index, ReturnType returnResultsOfType) Description copied from interface:IVirtualListGet items starting at specified index to the end of virtual list.- Specified by:
getByIndexRangein interfaceIVirtualList<E>- Parameters:
writePolicy- An Aerospike write policy to use for the operate() operation.index- The start index to get items from to the end of the virtual list.returnResultsOfType- Type to return.- Returns:
- A list of the records which match the given index.
-
getByIndexRange
Description copied from interface:IVirtualListGet "count" items starting at specified index.- Specified by:
getByIndexRangein interfaceIVirtualList<E>- Parameters:
index- The start index to get the "count" items from.returnResultsOfType- Type to return.- Returns:
- A list of the records which match the given index and count.
-
getByIndexRange
public List<E> getByIndexRange(com.aerospike.client.policy.WritePolicy writePolicy, int index, int count, ReturnType returnResultsOfType) Description copied from interface:IVirtualListGet "count" items starting at specified index.- Specified by:
getByIndexRangein interfaceIVirtualList<E>- Parameters:
writePolicy- An Aerospike write policy to use for the operate() operation.index- The start index to get the "count" items from.returnResultsOfType- Type to return.- Returns:
- A list of the records which match the given index and count.
-
getByRank
Description copied from interface:IVirtualListGet items identified by rank.- Specified by:
getByRankin interfaceIVirtualList<E>- Parameters:
rank- The rank.returnResultsOfType- Type to return.- Returns:
- A list of the records which match the given rank.
-
getByRank
public List<E> getByRank(com.aerospike.client.policy.WritePolicy writePolicy, int rank, ReturnType returnResultsOfType) Description copied from interface:IVirtualListGet items identified by rank.- Specified by:
getByRankin interfaceIVirtualList<E>- Parameters:
writePolicy- An Aerospike write policy to use for the operate() operation.rank- The rank.returnResultsOfType- Type to return.- Returns:
- A list of the records which match the given rank.
-
getByRankRange
Description copied from interface:IVirtualListGet items starting at specified rank to the last ranked item.- Specified by:
getByRankRangein interfaceIVirtualList<E>- Parameters:
rank- The starting rank.returnResultsOfType- Type to return.- Returns:
- A list of the records which match the given rank.
-
getByRankRange
public List<E> getByRankRange(com.aerospike.client.policy.WritePolicy writePolicy, int rank, ReturnType returnResultsOfType) Description copied from interface:IVirtualListGet items starting at specified rank to the last ranked item.- Specified by:
getByRankRangein interfaceIVirtualList<E>- Parameters:
writePolicy- An Aerospike write policy to use for the operate() operation.rank- The starting rank.returnResultsOfType- Type to return.- Returns:
- A list of the records which match the given rank.
-
getByRankRange
Description copied from interface:IVirtualListGet "count" items starting at specified rank to the last ranked item.- Specified by:
getByRankRangein interfaceIVirtualList<E>- Parameters:
rank- The starting rank.returnResultsOfType- Type to return.- Returns:
- A list of the records which match the given rank and count.
-
getByRankRange
public List<E> getByRankRange(com.aerospike.client.policy.WritePolicy writePolicy, int rank, int count, ReturnType returnResultsOfType) Description copied from interface:IVirtualListGet "count" items starting at specified rank to the last ranked item.- Specified by:
getByRankRangein interfaceIVirtualList<E>- Parameters:
writePolicy- An Aerospike write policy to use for the operate() operation.rank- The starting rank.returnResultsOfType- Type to return.- Returns:
- A list of the records which match the given rank and count.
-
getByKey
Description copied from interface:IVirtualListGet items from the list matching the specified key. If the list is mapped to a MAP in Aerospike, It will get the matching key. If the list is mapped to a LIST in Aerospike however, it will get the matching value.- Specified by:
getByKeyin interfaceIVirtualList<E>- Parameters:
key- Key to get.returnResultsOfType- Type to return.- Returns:
- A list of the records which match the given key range.
-
getByKey
public List<E> getByKey(com.aerospike.client.policy.WritePolicy writePolicy, Object key, ReturnType returnResultsOfType) Description copied from interface:IVirtualListGet items from the list matching the specified key. If the list is mapped to a MAP in Aerospike, It will get the matching key. If the list is mapped to a LIST in Aerospike however, it will get the matching value.- Specified by:
getByKeyin interfaceIVirtualList<E>- Parameters:
writePolicy- An Aerospike write policy to use for the operate() operation.key- Key to get.returnResultsOfType- Type to return.- Returns:
- A list of the records which match the given key range.
-
getByKeyRange
Description copied from interface:IVirtualListGet items from the list matching the specified key range. If the list is mapped to a MAP in Aerospike, the start key and end key will dictate the range of keys to get, inclusive of the start, exclusive of the end. If the list is mapped to a LIST in Aerospike however, the start and end range represent values to get from the list.- Specified by:
getByKeyRangein interfaceIVirtualList<E>- Parameters:
startKey- Start key of the range to get.endKey- End key of the range to get.returnResultsOfType- Type to return.- Returns:
- A list of the records which match the given key range.
-
getByKeyRange
public List<E> getByKeyRange(com.aerospike.client.policy.WritePolicy writePolicy, Object startKey, Object endKey, ReturnType returnResultsOfType) Description copied from interface:IVirtualListGet items from the list matching the specified key range. If the list is mapped to a MAP in Aerospike, the start key and end key will dictate the range of keys to get, inclusive of the start, exclusive of the end. If the list is mapped to a LIST in Aerospike however, the start and end range represent values to get from the list.- Specified by:
getByKeyRangein interfaceIVirtualList<E>- Parameters:
writePolicy- An Aerospike write policy to use for the operate() operation.startKey- Start key of the range to get.endKey- End key of the range to get.returnResultsOfType- Type to return.- Returns:
- A list of the records which match the given key range.
-
removeByKey
Description copied from interface:IVirtualListRemove items from the list matching the specified key. If the list is mapped to a MAP in Aerospike, the key will dictate the map key to be removed. If the list is mapped to a LIST in Aerospike however, the given key will use as the value to remove from the list.- Specified by:
removeByKeyin interfaceIVirtualList<E>- Parameters:
key- Key to remove.returnResultsOfType- Type to return.- Returns:
- A list of the records which have been removed from the database if returnResults is true, null otherwise.
-
removeByKey
public List<E> removeByKey(com.aerospike.client.policy.WritePolicy writePolicy, Object key, ReturnType returnResultsOfType) Description copied from interface:IVirtualListRemove items from the list matching the specified key. If the list is mapped to a MAP in Aerospike, the key will dictate the map key to be removed. If the list is mapped to a LIST in Aerospike however, the given key will use as the value to remove from the list.- Specified by:
removeByKeyin interfaceIVirtualList<E>- Parameters:
writePolicy- An Aerospike write policy to use for the operate() operation.key- Key to remove.returnResultsOfType- Type to return.- Returns:
- A list of the records which have been removed from the database if returnResults is true, null otherwise.
-
removeByValue
Description copied from interface:IVirtualListRemove items identified by value and returns the removed data.- Specified by:
removeByValuein interfaceIVirtualList<E>- Parameters:
value- The value to base the items to remove on.returnResultsOfType- Type to return.- Returns:
- A list of the records which have been removed from the database if returnResults is true, null otherwise.
-
removeByValue
public List<E> removeByValue(com.aerospike.client.policy.WritePolicy writePolicy, Object value, ReturnType returnResultsOfType) Description copied from interface:IVirtualListRemove items identified by value and returns the removed data.- Specified by:
removeByValuein interfaceIVirtualList<E>- Parameters:
writePolicy- An Aerospike write policy to use for the operate() operation.value- The value to base the items to remove on.returnResultsOfType- Type to return.- Returns:
- A list of the records which have been removed from the database if returnResults is true, null otherwise.
-
removeByValueList
Description copied from interface:IVirtualListRemove items identified by list of values and returns the removed data.- Specified by:
removeByValueListin interfaceIVirtualList<E>- Parameters:
values- The list of values to base the items to remove on.returnResultsOfType- Type to return.- Returns:
- A list of the records which have been removed from the database if returnResults is true, null otherwise.
-
removeByValueList
public List<E> removeByValueList(com.aerospike.client.policy.WritePolicy writePolicy, List<Object> values, ReturnType returnResultsOfType) Description copied from interface:IVirtualListRemove items identified by list of values and returns the removed data.- Specified by:
removeByValueListin interfaceIVirtualList<E>- Parameters:
writePolicy- An Aerospike write policy to use for the operate() operation.values- The list of values to base the items to remove on.returnResultsOfType- Type to return.- Returns:
- A list of the records which have been removed from the database if returnResults is true, null otherwise.
-
removeByValueRange
public List<E> removeByValueRange(Object startValue, Object endValue, ReturnType returnResultsOfType) Description copied from interface:IVirtualListRemove items from the list matching the specified value. If the list is mapped to a MAP in Aerospike, the start value and end value will dictate the range of values to be removed, inclusive of the start, exclusive of the end. If the list is mapped to a LIST in Aerospike however, the start and end range represent values to removed from the list.- Specified by:
removeByValueRangein interfaceIVirtualList<E>- Parameters:
startValue- Start value of the range to remove.endValue- End value of the range to remove.returnResultsOfType- Type to return.- Returns:
- A list of the records which have been removed from the database if returnResults is true, null otherwise.
-
removeByValueRange
public List<E> removeByValueRange(com.aerospike.client.policy.WritePolicy writePolicy, Object startValue, Object endValue, ReturnType returnResultsOfType) Description copied from interface:IVirtualListRemove items from the list matching the specified value. If the list is mapped to a MAP in Aerospike, the start value and end value will dictate the range of values to be removed, inclusive of the start, exclusive of the end. If the list is mapped to a LIST in Aerospike however, the start and end range represent values to be removed from the list.- Specified by:
removeByValueRangein interfaceIVirtualList<E>- Parameters:
writePolicy- An Aerospike write policy to use for the operate() operation.startValue- Start value of the range to remove.endValue- End value of the range to remove.returnResultsOfType- Type to return.- Returns:
- A list of the records which have been removed from the database if returnResults is true, null otherwise.
-
removeByValueRelativeRankRange
public List<E> removeByValueRelativeRankRange(Object value, int rank, ReturnType returnResultsOfType) Description copied from interface:IVirtualListRemove items nearest to value and greater by relative rank.- Specified by:
removeByValueRelativeRankRangein interfaceIVirtualList<E>- Parameters:
value- The value to base the items to remove on.rank- The rank.returnResultsOfType- Type to return.- Returns:
- A list of the records which have been removed from the database if returnResults is true, null otherwise.
-
removeByValueRelativeRankRange
public List<E> removeByValueRelativeRankRange(com.aerospike.client.policy.WritePolicy writePolicy, Object value, int rank, ReturnType returnResultsOfType) Description copied from interface:IVirtualListRemove items nearest to value and greater by relative rank.- Specified by:
removeByValueRelativeRankRangein interfaceIVirtualList<E>- Parameters:
writePolicy- An Aerospike write policy to use for the operate() operation.value- The value to base the items to remove on.rank- The rank.returnResultsOfType- Type to return.- Returns:
- A list of the records which have been removed from the database if returnResults is true, null otherwise.
-
removeByValueRelativeRankRange
public List<E> removeByValueRelativeRankRange(Object value, int rank, int count, ReturnType returnResultsOfType) Description copied from interface:IVirtualListRemove items nearest to value and greater by relative rank with a count limit.- Specified by:
removeByValueRelativeRankRangein interfaceIVirtualList<E>- Parameters:
value- The value to base the items to remove on.rank- The rank.count- The count limit.returnResultsOfType- Type to return.- Returns:
- A list of the records which have been removed from the database if returnResults is true, null otherwise.
-
removeByValueRelativeRankRange
public List<E> removeByValueRelativeRankRange(com.aerospike.client.policy.WritePolicy writePolicy, Object value, int rank, int count, ReturnType returnResultsOfType) Description copied from interface:IVirtualListRemove items nearest to value and greater by relative rank with a count limit.- Specified by:
removeByValueRelativeRankRangein interfaceIVirtualList<E>- Parameters:
writePolicy- An Aerospike write policy to use for the operate() operation.value- The value to base the items to remove on.rank- The rank.count- The count limit.returnResultsOfType- Type to return.- Returns:
- A list of the records which have been removed from the database if returnResults is true, null otherwise.
-
removeByIndex
Description copied from interface:IVirtualListRemove item identified by index and returns removed data.- Specified by:
removeByIndexin interfaceIVirtualList<E>- Parameters:
index- The index to remove the item from.returnResultsOfType- Type to return.- Returns:
- A list of the records which have been removed from the database if returnResults is true, null otherwise.
-
removeByIndex
public List<E> removeByIndex(com.aerospike.client.policy.WritePolicy writePolicy, int index, ReturnType returnResultsOfType) Description copied from interface:IVirtualListRemove item identified by index and returns removed data.- Specified by:
removeByIndexin interfaceIVirtualList<E>- Parameters:
writePolicy- An Aerospike write policy to use for the operate() operation.index- The index to remove the item from.returnResultsOfType- Type to return.- Returns:
- A list of the records which have been removed from the database if returnResults is true, null otherwise.
-
removeByIndexRange
Description copied from interface:IVirtualListRemove items starting at specified index to the end of list and returns removed data.- Specified by:
removeByIndexRangein interfaceIVirtualList<E>- Parameters:
index- The start index to remove the item from.returnResultsOfType- Type to return.- Returns:
- A list of the records which have been removed from the database if returnResults is true, null otherwise.
-
removeByIndexRange
public List<E> removeByIndexRange(com.aerospike.client.policy.WritePolicy writePolicy, int index, ReturnType returnResultsOfType) Description copied from interface:IVirtualListRemove items starting at specified index to the end of list and returns removed data.- Specified by:
removeByIndexRangein interfaceIVirtualList<E>- Parameters:
writePolicy- An Aerospike write policy to use for the operate() operation.index- The start index to remove the item from.returnResultsOfType- Type to return.- Returns:
- A list of the records which have been removed from the database if returnResults is true, null otherwise.
-
removeByIndexRange
Description copied from interface:IVirtualListRemove "count" items starting at specified index and returns removed data.- Specified by:
removeByIndexRangein interfaceIVirtualList<E>- Parameters:
index- The start index to remove the item from.count- The count limit.returnResultsOfType- Type to return.- Returns:
- A list of the records which have been removed from the database if returnResults is true, null otherwise.
-
removeByIndexRange
public List<E> removeByIndexRange(com.aerospike.client.policy.WritePolicy writePolicy, int index, int count, ReturnType returnResultsOfType) Description copied from interface:IVirtualListRemove "count" items starting at specified index and returns removed data.- Specified by:
removeByIndexRangein interfaceIVirtualList<E>- Parameters:
writePolicy- An Aerospike write policy to use for the operate() operation.index- The start index to remove the item from.count- The count limit.returnResultsOfType- Type to return.- Returns:
- A list of the records which have been removed from the database if returnResults is true, null otherwise.
-
removeByRank
Description copied from interface:IVirtualListRemove item identified by rank and returns removed data.- Specified by:
removeByRankin interfaceIVirtualList<E>- Parameters:
rank- The rank.returnResultsOfType- Type to return.- Returns:
- A list of the records which have been removed from the database if returnResults is true, null otherwise.
-
removeByRank
public List<E> removeByRank(com.aerospike.client.policy.WritePolicy writePolicy, int rank, ReturnType returnResultsOfType) Description copied from interface:IVirtualListRemove item identified by rank and returns removed data.- Specified by:
removeByRankin interfaceIVirtualList<E>- Parameters:
writePolicy- An Aerospike write policy to use for the operate() operation.rank- The rank.returnResultsOfType- Type to return.- Returns:
- A list of the records which have been removed from the database if returnResults is true, null otherwise.
-
removeByRankRange
Description copied from interface:IVirtualListRemove items starting at specified rank to the last ranked item and returns removed data.- Specified by:
removeByRankRangein interfaceIVirtualList<E>- Parameters:
rank- The starting rank.returnResultsOfType- Type to return.- Returns:
- A list of the records which have been removed from the database if returnResults is true, null otherwise.
-
removeByRankRange
public List<E> removeByRankRange(com.aerospike.client.policy.WritePolicy writePolicy, int rank, ReturnType returnResultsOfType) Description copied from interface:IVirtualListRemove items starting at specified rank to the last ranked item and returns removed data.- Specified by:
removeByRankRangein interfaceIVirtualList<E>- Parameters:
writePolicy- An Aerospike write policy to use for the operate() operation.rank- The starting rank.returnResultsOfType- Type to return.- Returns:
- A list of the records which have been removed from the database if returnResults is true, null otherwise.
-
removeByRankRange
Description copied from interface:IVirtualListRemove "count" items starting at specified rank and returns removed data.- Specified by:
removeByRankRangein interfaceIVirtualList<E>- Parameters:
rank- The starting rank.count- The count limit.returnResultsOfType- Type to return.- Returns:
- A list of the records which have been removed from the database if returnResults is true, null otherwise.
-
removeByRankRange
public List<E> removeByRankRange(com.aerospike.client.policy.WritePolicy writePolicy, int rank, int count, ReturnType returnResultsOfType) Description copied from interface:IVirtualListRemove "count" items starting at specified rank and returns removed data.- Specified by:
removeByRankRangein interfaceIVirtualList<E>- Parameters:
writePolicy- An Aerospike write policy to use for the operate() operation.rank- The starting rank.count- The count limit.returnResultsOfType- Type to return.- Returns:
- A list of the records which have been removed from the database if returnResults is true, null otherwise.
-
removeByKeyRange
Description copied from interface:IVirtualListRemove items from the list matching the specified key. If the list is mapped to a MAP in Aerospike, the start key and end key will dictate the range of keys to be removed, inclusive of the start, exclusive of the end. If the list is mapped to a LIST in Aerospike however, the start and end range represent values to be removed from the list.- Specified by:
removeByKeyRangein interfaceIVirtualList<E>- Parameters:
startKey- Start key of the range to remove.endKey- End key of the range to remove.returnResultsOfType- Type to return.- Returns:
- The result of the method is a list of the records which have been removed from the database if returnResults is true, null otherwise.
-
removeByKeyRange
public List<E> removeByKeyRange(com.aerospike.client.policy.WritePolicy writePolicy, Object startKey, Object endKey, ReturnType returnResultsOfType) Description copied from interface:IVirtualListRemove items from the list matching the specified key. If the list is mapped to a MAP in Aerospike, the start key and end key will dictate the range of keys to be removed, inclusive of the start, exclusive of the end. If the list is mapped to a LIST in Aerospike however, the start and end range represent values to be removed from the list.- Specified by:
removeByKeyRangein interfaceIVirtualList<E>- Parameters:
writePolicy- An Aerospike write policy to use for the operate() operation.startKey- Start key of the range to remove.endKey- End key of the range to remove.returnResultsOfType- Type to return.- Returns:
- The result of the method is a list of the records which have been removed from the database if returnResults is true, null otherwise.
-
append
Description copied from interface:IVirtualListAppend a new element at the end of the virtual list.- Specified by:
appendin interfaceIVirtualList<E>- Parameters:
element- The given element to append.- Returns:
- The list size.
-
append
Description copied from interface:IVirtualListAppend a new element at the end of the virtual list.- Specified by:
appendin interfaceIVirtualList<E>- Parameters:
writePolicy- An Aerospike write policy to use for the operate() operation.element- The given element to append.- Returns:
- The size of the list. If the record is not found, this method returns -1.
-
get
Description copied from interface:IVirtualListGet an element from the virtual list at a specific index.- Specified by:
getin interfaceIVirtualList<E>- Parameters:
index- The index to get the item from.- Returns:
- The element to get from the virtual list.
-
get
Description copied from interface:IVirtualListGet an element from the virtual list at a specific index.- Specified by:
getin interfaceIVirtualList<E>- Parameters:
policy- - The policy to use for the operate() operation.index- The index to get the item from.- Returns:
- The element to get from the virtual list.
-
size
public long size(com.aerospike.client.policy.Policy policy) Description copied from interface:IVirtualListGet the size of the virtual list (number of elements)- Specified by:
sizein interfaceIVirtualList<E>- Parameters:
policy- - The policy to use for the operate() operation.- Returns:
- The size of the list. If the record is not found, this method returns -1.
-
clear
public void clear()Description copied from interface:IVirtualListRemove all the items in the virtual list.- Specified by:
clearin interfaceIVirtualList<E>
-