WorkspaceEntry
@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "type") @JsonSubTypes({ @JsonSubTypes.Type(value = FileEntry.class, name = "file"), @JsonSubTypes.Type(value = DirEntry.class, name = "dir"), @JsonSubTypes.Type(value = LocalFileEntry.class, name = "local_file"), @JsonSubTypes.Type(value = LocalDirEntry.class, name = "local_dir"), @JsonSubTypes.Type(value = GitRepoEntry.class, name = "git_repo"), @JsonSubTypes.Type(value = WorkspaceProjectionEntry.class, name = "workspace_projection"), @JsonSubTypes.Type(value = BindMountEntry.class, name = "bind_mount"), }) public abstract class WorkspaceEntry
源码Source
io/agentscope/harness/agent/sandbox/layout/WorkspaceEntry.java:32–66条目 inio.agentscope.harness.agent.sandbox.WorkspaceSpec的基类。位于 io.agentscope.harness.agent.sandbox.layout 包。核心成员包括 isEphemeral、setEphemeral。
Base class for entries in a io.agentscope.harness.agent.sandbox.WorkspaceSpec.
Each entry describes a single file or directory that should be present in the sandbox workspace at startup. Entries can be materialized from inline content, local host files, or remote sources.
When ephemeral is true, this entry is always re-applied on every sandbox
start, even when a snapshot exists. Non-ephemeral entries are persisted inside the snapshot
and restored with the workspace.
方法摘要Method Summary
| 方法Method | 说明Description |
|---|---|
public boolean isEphemeral() | 判断是否 `isEphemeral`。 Returns whether this entry is ephemeral. |
public void setEphemeral(boolean ephemeral) | 设置 `setEphemeral`。 Sets whether this entry is ephemeral. |
方法详情Method Detail
isEphemeral
public boolean isEphemeral()
判断是否 isEphemeral。
Returns whether this entry is ephemeral.
boolean返回布尔值,表示判断结果。true if this entry is ephemeral
源码Source
io/agentscope/harness/agent/sandbox/layout/WorkspaceEntry.java:54–56setEphemeral
public void setEphemeral(boolean ephemeral)
设置 setEphemeral。
Sets whether this entry is ephemeral.
参数Parameters
| 名称Name | 类型Type | 说明Description |
|---|---|---|
ephemeral | boolean | ephemeral(类型 `boolean`)。true to mark as ephemeral |
源码Source
io/agentscope/harness/agent/sandbox/layout/WorkspaceEntry.java:63–65