FilteredWorksetCollector
Description:
This class is used to search, filter and iterate through a set of worksets.
This class is used to search, filter and iterate through a set of worksets.
Remarks:
Developers can assign a condition to filter the worksets that are returned. If no condition is applied, it attempts to access all the worksets in the document.
The collector will reset if you call another method to extract worksets. Thus, if you have previously obtained an iterator, it will be stopped and traverse no more worksets if you call another method to extract worksets.
Inheritance Hierarchy:
System.Object
Autodesk.Revit.DB.FilteredWorksetCollector
System.Object
Autodesk.Revit.DB.FilteredWorksetCollector
public class FilteredWorksetCollector : IEnumerable<Workset>,
IDisposable
| Name | Return Type | Description |
|---|---|---|
| FilteredWorksetCollector(Document) | None | Constructs a new FilteredWorksetCollector that will search and filter the set of worksets in a document. |
| Name | Return Type | Description |
|---|---|---|
| Dispose() | None | Releases all resources used by the |
| FirstWorksetId() | WorksetId | Returns the id of the first workset to pass the filter(s). |
| FirstWorkset() | The first workset. | Returns the first workset to pass the filter(s). |
| GetBasicIEnumerator() | IEnumerator | Returns an enumerator that iterates through a collection. |
| GetEnumerator() | IEnumerator<Workset> | Returns an enumerator that iterates through a collection. |
| GetWorksetIdIterator() | FilteredWorksetIdIterator | Returns a FilteredWorksetIdIterator to the worksets passing the current filter. |
| GetWorksetIterator() | FilteredWorksetIterator | Returns a FilteredWorksetIterator to the worksets passing the current filter. |
| OfKind(WorksetKind) | FilteredWorksetCollector | Applies a WorksetKindFilter to the collector. |
| ToWorksetIds() | ICollection<WorksetId> | Returns the complete set of workset ids that pass the filter(s). |
| ToWorksets() | IList<Workset> | Returns the complete set of worksets that pass the filter(s). |
| WherePasses(WorksetFilter) | FilteredWorksetCollector | Applies a workset filter to the collector. |
| Name | Return Type | Description |
|---|---|---|
| IsValidObject | bool | Specifies whether the .NET object represents a valid Revit entity. |