Class SelectionResult
The result of a SelectAsync(String, CancellationToken) operation
Inherited Members
Namespace:FubarDev.WebDavServer.FileSystem
Assembly:FubarDev.WebDavServer.dll
Syntax
public class SelectionResultProperties
| Improve this Doc View SourceCollection
Gets the collection of the search result.
Declaration
[NotNull]
public ICollection Collection { get; }Property Value
| Type | Description | 
|---|---|
| ICollection | 
Remarks
When ResultType is FoundCollection, this is the found collection. When ResultType is FoundDocument, this is the parent collection. Otherwise, this is the last found collection.
Document
Gets the found document
Declaration
[CanBeNull]
public IDocument Document { get; }Property Value
| Type | Description | 
|---|---|
| IDocument | 
Remarks
This property is only valid when ResultType is FoundDocument.
FullPath
Gets the full root-relative path of the element that was searched
Declaration
[NotNull]
public Uri FullPath { get; }Property Value
| Type | Description | 
|---|---|
| Uri | 
IsMissing
Gets a value indicating whether there was a missing path part?
Declaration
public bool IsMissing { get; }Property Value
| Type | Description | 
|---|---|
| Boolean | 
MissingNames
Gets the collection of missing child elements
Declaration
[NotNull]
[ItemNotNull]
public IReadOnlyCollection<string> MissingNames { get; }Property Value
| Type | Description | 
|---|---|
| IReadOnlyCollection<String> | 
Remarks
This is only valid, when IsMissing is true.
ResultType
Gets the type of the result
Declaration
public SelectionResultType ResultType { get; }Property Value
| Type | Description | 
|---|---|
| SelectionResultType | 
TargetEntry
Gets the found target entry
Declaration
[NotNull]
public IEntry TargetEntry { get; }Property Value
| Type | Description | 
|---|---|
| IEntry | 
Remarks
This is only valid when IsMissing is false.
TargetFileSystem
Gets the file system of the found element or the last found collection
Declaration
[NotNull]
public IFileSystem TargetFileSystem { get; }Property Value
| Type | Description | 
|---|---|
| IFileSystem | 
Methods
| Improve this Doc View SourceCreate(ICollection)
Creates a selection result for a found collection
Declaration
[NotNull]
public static SelectionResult Create([NotNull] ICollection collection)Parameters
| Type | Name | Description | 
|---|---|---|
| ICollection | collection | The found collection | 
Returns
| Type | Description | 
|---|---|
| SelectionResult | The created selection result | 
Create(ICollection, IDocument)
Creates a selection result for a found document
Declaration
[NotNull]
public static SelectionResult Create([NotNull] ICollection collection, [NotNull] IDocument document)Parameters
| Type | Name | Description | 
|---|---|---|
| ICollection | collection | The parent collection | 
| IDocument | document | The found document | 
Returns
| Type | Description | 
|---|---|
| SelectionResult | The created selection result | 
CreateMissingCollection(ICollection, IReadOnlyCollection<String>)
Creates a selection for a missing collection
Declaration
[NotNull]
public static SelectionResult CreateMissingCollection([NotNull] ICollection collection, [NotNull, ItemNotNull] IReadOnlyCollection<string> pathEntries)Parameters
| Type | Name | Description | 
|---|---|---|
| ICollection | collection | The last found collection | 
| IReadOnlyCollection<String> | pathEntries | The missing path elements | 
Returns
| Type | Description | 
|---|---|
| SelectionResult | The created selection result | 
CreateMissingDocumentOrCollection(ICollection, IReadOnlyCollection<String>)
Creates a selection for a missing document or collection
Declaration
[NotNull]
public static SelectionResult CreateMissingDocumentOrCollection([NotNull] ICollection collection, [NotNull, ItemNotNull] IReadOnlyCollection<string> pathEntries)Parameters
| Type | Name | Description | 
|---|---|---|
| ICollection | collection | The last found collection | 
| IReadOnlyCollection<String> | pathEntries | The missing path elements | 
Returns
| Type | Description | 
|---|---|
| SelectionResult | The created selection result |