Click or drag to resize

RhinoDocPurge Method (PurgeFilter)

Purges unused table objects from this document, the same way the Purge command does.

Namespace:  Rhino
Assembly:  RhinoCommon (in RhinoCommon.dll)
Syntax
public PurgeStatistics Purge(
	PurgeFilter filter
)

Parameters

filter
Type: RhinoPurgeFilter
The document table object types to purge.

Return Value

Type: PurgeStatistics
What was purged.
Remarks
The order in which the table object types are purged matters, and purging one type can make another type purgeable, so this purges everything filter asks for in a single operation.
Examples
var stats = doc.Purge(PurgeFilter.Layers | PurgeFilter.Materials);
RhinoApp.WriteLine($"Purged {stats.PurgedCount(PurgeFilter.Layers)} layers.");
See Also