PrjMarkDirectoryAsPlaceholder function (projectedfslib.h)

Converts an existing directory to a directory placeholder.

Syntax

HRESULT PrjMarkDirectoryAsPlaceholder(
  [in]           PCWSTR                             rootPathName,
  [in, optional] PCWSTR                             targetPathName,
  [in, optional] const PRJ_PLACEHOLDER_VERSION_INFO *versionInfo,
  [in]           const GUID                         *virtualizationInstanceID
);

Parameters

[in] rootPathName

A null-terminated Unicode string specifying the full path to the virtualization root.

[in, optional] targetPathName

A null-terminated Unicode string specifying the full path to the directory to convert to a placeholder.

If this parameter is not specified or is an empty string, then this means the caller wants to designate rootPathName as the virtualization root. The provider only needs to do this one time, upon establishing a new virtualization instance.

[in, optional] versionInfo

Optional version information for the target placeholder. The provider chooses what information to put in the PRJ_PLACEHOLDER_VERSION_INFO structure. If not specified, the placeholder gets zeros for its version information.

[in] virtualizationInstanceID

A value that identifies the virtualization instance.

Return value

HRESULT_FROM_WIN32(ERROR_REPARSE_POINT_ENCOUNTERED) typically means the directory at targetPathName has a reparse point on it. HRESULT_FROM_WIN32(ERROR_DIRECTORY) typically means the targetPathName does not specify a directory.

Remarks

The provider must use this API to designate the virtualization root before calling PrjStartVirtualizing.

Requirements

Requirement Value
Minimum supported client Windows 10, version 1809 [desktop apps only]
Minimum supported server Windows Server [desktop apps only]
Target Platform Windows
Header projectedfslib.h