Class WorkspaceEntry

java.lang.Object
io.agentscope.harness.agent.sandbox.layout.WorkspaceEntry
Direct Known Subclasses:
BindMountEntry, DirEntry, FileEntry, GitRepoEntry, LocalDirEntry, LocalFileEntry, WorkspaceProjectionEntry

public abstract class WorkspaceEntry extends Object
Base class for entries in a 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.

  • Constructor Details

    • WorkspaceEntry

      public WorkspaceEntry()
  • Method Details

    • isEphemeral

      public boolean isEphemeral()
      Returns whether this entry is ephemeral.

      Ephemeral entries are always re-applied on session resume regardless of whether a snapshot exists. They are suitable for dynamic configuration that should not be snapshotted.

      Returns:
      true if this entry is ephemeral
    • setEphemeral

      public void setEphemeral(boolean ephemeral)
      Sets whether this entry is ephemeral.
      Parameters:
      ephemeral - true to mark as ephemeral