public class RedisList extends Object
| 构造器和说明 |
|---|
RedisList(RedisClient client,
String listName) |
| 限定符和类型 | 方法和说明 |
|---|---|
boolean |
add(String element)
添加项
|
boolean |
addAll(Collection<? extends String> elements)
添加一个集合里的项
|
void |
clear()
清空
|
String |
get(int index)
获取某个位置的项
|
List<String> |
getAll()
获取所有项
|
List<String> |
getRange(int fromIndex,
int toIndex)
获取某个位置区间的项
|
boolean |
remove(String element)
移除项
|
boolean |
removeAll(Collection<? extends String> c)
移除一个集合里的项
|
String |
removeAt(int index)
移除某个位置的项
|
void |
set(int index,
String newValue)
设置项的值
|
long |
size()
大小
|
public RedisList(RedisClient client, String listName)
public boolean remove(String element)
public String removeAt(int index)
public boolean removeAll(Collection<? extends String> c)
public String get(int index)
public void set(int index,
String newValue)
public boolean add(String element)
public boolean addAll(Collection<? extends String> elements)
public long size()
public void clear()
Copyright © 2022. All rights reserved.