InMemorySetCollection
public class InMemorySetCollection extends SetCollection
源码Source
io/agentscope/runtime/common/collections/InMemorySetCollection.java:27–62In 记忆设置集合,承载智能体的部署、调度与服务化运行。位于 io.agentscope.runtime.common.collections 包,继承自 SetCollection。核心成员包括 add、remove、contains、clear、toList、InMemorySetCollection。
In-memory implementation of the SetCollection interface.
构造器摘要Constructor Summary
| 构造器Constructor | 说明Description |
|---|---|
public InMemorySetCollection() | 初始化 `InMemorySetCollection` 实例。 Creates a new instance. |
方法摘要Method Summary
| 方法Method | 说明Description |
|---|---|
public boolean add(String value) | 设置添加。 Performs the add operation. |
public void remove(String value) | 设置移除。 Performs the remove operation. |
public boolean contains(String value) | 设置该参数。 Performs the contains operation. |
public void clear() | 清空或重置内部状态。 Clears or resets internal state. |
public List<String> toList() | 返回到列表。 Returns the to list. |
构造器详情Constructor Detail
InMemorySetCollection
public InMemorySetCollection()
初始化 InMemorySetCollection 实例。
Creates a new instance.
源码Source
io/agentscope/runtime/common/collections/InMemorySetCollection.java:30–32方法详情Method Detail
add
public boolean add(String value)
设置添加。
Performs the add operation.
参数Parameters
| 名称Name | 类型Type | 说明Description |
|---|---|---|
value | String | 值(类型 `String`)。The value. |
boolean返回布尔值,表示判断结果。Returns a boolean result.
源码Source
io/agentscope/runtime/common/collections/InMemorySetCollection.java:34–41remove
public void remove(String value)
设置移除。
Performs the remove operation.
参数Parameters
| 名称Name | 类型Type | 说明Description |
|---|---|---|
value | String | 值(类型 `String`)。The value. |
源码Source
io/agentscope/runtime/common/collections/InMemorySetCollection.java:43–46contains
public boolean contains(String value)
设置该参数。
Performs the contains operation.
参数Parameters
| 名称Name | 类型Type | 说明Description |
|---|---|---|
value | String | 值(类型 `String`)。The value. |
boolean返回布尔值,表示判断结果。Returns a boolean result.
源码Source
io/agentscope/runtime/common/collections/InMemorySetCollection.java:48–51clear
public void clear()
清空或重置内部状态。
Clears or resets internal state.
源码Source
io/agentscope/runtime/common/collections/InMemorySetCollection.java:53–56toList
public List<String> toList()
返回到列表。
Returns the to list.
List<String>返回列出。Returns list.
源码Source
io/agentscope/runtime/common/collections/InMemorySetCollection.java:58–61