Skip to content

Commit ce3946c

Browse files
authored
Merge pull request #51 from erikma/dev/erikmav/sortOrderDocs
Clarify doc/XML comments with information about enumeration sort order
2 parents 2f7e988 + 144dab4 commit ce3946c

File tree

2 files changed

+24
-0
lines changed

2 files changed

+24
-0
lines changed

ProjectedFSLib.Managed.API/IDirectoryEnumerationResults.h

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,13 @@ public interface class IDirectoryEnumerationResults
3636
/// provider returns <c>HResult.InsufficientBuffer</c> from the <c>GetDirectoryEnumerationCallback</c>
3737
/// method.
3838
/// </para>
39+
/// <para>
40+
/// IMPORTANT: File and directory names passed to this method must be in the sort
41+
/// specified by <c>PrjFileNameCompare</c>
42+
/// (see https://docs.microsoft.com/en-us/windows/win32/api/projectedfslib/nf-projectedfslib-prjfilenamecompare ),
43+
/// or else names can be duplicated or missing from the enumeration results presented to the
44+
/// process enumerating the filesystem.
45+
/// </para>
3946
/// </remarks>
4047
/// <param name="fileName">The name of the file or directory.</param>
4148
/// <param name="fileSize">The size of the file.</param>
@@ -69,6 +76,13 @@ public interface class IDirectoryEnumerationResults
6976
/// provider returns <c>HResult.InsufficientBuffer</c> from the <c>GetDirectoryEnumerationCallback</c>
7077
/// method.
7178
/// </para>
79+
/// <para>
80+
/// IMPORTANT: File and directory names passed to this method must be in the sort
81+
/// specified by <c>PrjFileNameCompare</c>
82+
/// (see https://docs.microsoft.com/en-us/windows/win32/api/projectedfslib/nf-projectedfslib-prjfilenamecompare ),
83+
/// or else names can be duplicated or missing from the enumeration results presented to the
84+
/// process enumerating the filesystem.
85+
/// </para>
7286
/// </remarks>
7387
/// <param name="fileName">The name of the file or directory.</param>
7488
/// <param name="fileSize">The size of the file.</param>

ProjectedFSLib.Managed.API/IRequiredCallbacks.h

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,11 @@ public interface class IRequiredCallbacks {
8787
/// <para>If no entries match the search expression specified in <paramref name="filterFileName"/>,
8888
/// or if all the entries in the directory were added in a previous invocation of this callback,
8989
/// the provider must return <see cref="HResult::Ok"/>.</para>
90+
/// <para>IMPORTANT: The provider must ensure file and directory names returned from this
91+
/// callback are in the sort order specified by <c>PrjFileNameCompare</c>
92+
/// (see https://docs.microsoft.com/en-us/windows/win32/api/projectedfslib/nf-projectedfslib-prjfilenamecompare ),
93+
/// or else names can be duplicated or missing from the enumeration results presented to the
94+
/// process enumerating the filesystem.</para>
9095
/// </remarks>
9196
/// <param name="commandId">
9297
/// <para>A value that uniquely identifies an invocation of the callback.</para>
@@ -119,6 +124,11 @@ public interface class IRequiredCallbacks {
119124
/// <para>If the provider returns <see cref="HResult::Pending"/> from this method, then it must pass
120125
/// this value to <c>ProjFS.VirtualizationInstance.CompleteCommand</c> to provide the
121126
/// enumeration results.</para>
127+
/// <para>IMPORTANT: File and directory names passed to this parameter must be in the sort
128+
/// order specified by <c>PrjFileNameCompare</c>
129+
/// (see https://docs.microsoft.com/en-us/windows/win32/api/projectedfslib/nf-projectedfslib-prjfilenamecompare ),
130+
/// or else names can be duplicated or missing from the enumeration results presented to the
131+
/// process enumerating the filesystem.</para>
122132
/// </param>
123133
/// <returns>
124134
/// <para><see cref="HResult::Ok"/> if the provider successfully completes the operation.</para>

0 commit comments

Comments
 (0)