TestimoX

API Reference

Class

LocalFileWorkspace

Namespace ComputerX.FileSystem
Assembly ComputerX
Modifiers sealed

Provides constrained local browse, copy, and download-planning operations over allowed filesystem roots.

Inheritance

  • Object
  • LocalFileWorkspace

Constructors

LocalFileWorkspace 2 overloads
public LocalFileWorkspace(IEnumerable<String> allowedRoots = null) #

Creates a new workspace using the provided allowed roots, or the system drive when none are specified.

Parameters

allowedRoots System.Collections.Generic.IEnumerable{System.String} = null optionalposition: 0
Explicit allowed roots. When null or empty, the system drive root is used.
LocalFileWorkspace(ComputerX.FileSystem.LocalFileWorkspaceOptions allowedRoots) #

Creates a new workspace using explicit options for allowed roots and fallback behavior.

Parameters

allowedRoots ComputerX.FileSystem.LocalFileWorkspaceOptions required

Methods

public FileWorkspaceBrowseResult Browse(String path) #
Returns: FileWorkspaceBrowseResult

Browses the workspace roots or a specific allowed directory path.

Parameters

path System.String requiredposition: 0
public FileWorkspaceCopyResult Copy(FileWorkspaceCopyRequest request) #
Returns: FileWorkspaceCopyResult

Copies an allowed file or directory within the workspace.

Parameters

request ComputerX.FileSystem.FileWorkspaceCopyRequest requiredposition: 0
public static LocalFileWorkspace ForAllReadyDrives() #
Returns: LocalFileWorkspace

Creates a workspace that exposes every ready drive on the current machine.

public static LocalFileWorkspace ForExplicitRoots(IEnumerable<String> allowedRoots) #
Returns: LocalFileWorkspace

Creates a workspace that exposes only the provided explicit roots.

Parameters

allowedRoots System.Collections.Generic.IEnumerable{System.String} requiredposition: 0
public static LocalFileWorkspace ForSystemDrive() #
Returns: LocalFileWorkspace

Creates a workspace that exposes only the current system drive.

ResolveAllowedRoots 2 overloads
public static String[] ResolveAllowedRoots(IEnumerable<String> configuredRoots) #
Returns: String[]

Normalizes configured roots or falls back to the system drive when no roots are provided.

Parameters

configuredRoots System.Collections.Generic.IEnumerable{System.String} requiredposition: 0
public static String[] ResolveAllowedRoots(IEnumerable<String> configuredRoots, FileWorkspaceRootFallback fallback) #
Returns: String[]

Normalizes configured roots or falls back according to the requested strategy.

Parameters

configuredRoots System.Collections.Generic.IEnumerable{System.String} requiredposition: 0
fallback ComputerX.FileSystem.FileWorkspaceRootFallback requiredposition: 1
public Boolean TryPrepareDownload(String path, out FileWorkspaceDownloadPlan descriptor, out String error) #
Returns: Boolean

Attempts to build a download/export plan for an allowed file or directory.

Parameters

path System.String requiredposition: 0
descriptor ComputerX.FileSystem.FileWorkspaceDownloadPlan@ requiredposition: 1
error System.String@ requiredposition: 2

Properties

public IReadOnlyList<String> AllowedRoots { get; } #

Gets the normalized allowed roots for the workspace.