RedisListModification

play.api.cache.redis.RedisList.RedisListModification

Attributes

Graph
Supertypes
class Object
trait Matchable
class Any

Members list

Value members

Abstract methods

def clear(): Result[RedisListModification]

Helper method of slice. Wiping the whole collection

Helper method of slice. Wiping the whole collection

Attributes

Returns

this object to chain commands

Attributes

Returns

RedisList object with Redis API

def slice(from: Long, end: Long): Result[RedisListModification]

Trim an existing list so that it will contain only the specified range of elements specified. Both start and stop are zero-based indexes, where 0 is the first element of the list (the head), 1 the next element and so on.

Trim an existing list so that it will contain only the specified range of elements specified. Both start and stop are zero-based indexes, where 0 is the first element of the list (the head), 1 the next element and so on.

For example: LTRIM foobar 0 2 will modify the list stored at foobar so that only the first three elements of the list will remain.

start and end can also be negative numbers indicating offsets from the end of the list, where -1 is the last element of the list, -2 the penultimate element and so on.

Out of range indexes will not produce an error: if start is larger than the end of the list, or start > end, the result will be an empty list (which causes key to be removed). If end is larger than the end of the list, Redis will treat it like the last element of the list.

Value parameters

end

index of the last element included

from

initial index

Attributes

Returns

this object to chain commands

Concrete methods

def drop(n: Long): Result[RedisListModification]

Helper method of slice. For more details see that method.

Helper method of slice. For more details see that method.

Value parameters

n

ignore initial N elements

Attributes

Returns

this object to chain commands

def take(n: Long): Result[RedisListModification]

Helper method of slice. For more details see that method.

Helper method of slice. For more details see that method.

Value parameters

n

takes initial N elements

Attributes

Returns

this object to chain commands