AcDbBasicFilter Class

Land Desktop Development ARX CPP SDK

Links
AcDbBasicFilter Class
 

Filters objects (entities) in the current drawing based on layer, feature-class, and block criteria.  

Filters are constructed with "*" as the default filtering value, indicating that all entities are to be filtered. Other valid values are "" (an empty string) to ignore entities during filtering, and NULL (a null filter) to exclude any entities returned by the filter set. The default AcDbBasicFilter object is constructed with * as the value for the Layers, FeatureClasses, and Blocks filtering criteria, and so will filter out classified blocks from all layers. The following table shows how to set entity-filtering criteria for various filtering scenarios. (Note that these scenarios do not include objects on frozen, locked, or off layers unless you have set the layer status mask with SetLayerStatusMask()).

To select 
Layers

 

FeatureClasses

 

Blocks

 

All objects from all layers 
"" 
"" 
All classified objects from all layers 
"" 
All blocks (inserts) from all layers 
"" 
Classified blocks from all layers 
Classified objects from specified layers 
Layer1,Layer5 
"" 
Blocks from specified layers 
Layer1,Layer5 
"" 
Specified classified objects from all layers 
Road,Lake 
"" 
Specified blocks from all layers 
"" 
Block1,Block5 
Specified classified objects and specified blocks from all layers 
Road,Lake 
Block1,Block5 
Specified classified objects from specified layers 
Layer1,Layer5 
Road,Lake 
"" 
Specified blocks from specified layers 
Layer1,Layer5 
"" 
Block1,Block5 
Specified classified objects and specified blocks from specified layers 
Layer1,Layer5 
Road,Lake 
Block1,Block5 
All objects from all layers except classified objects 
NULL 
"" 
All objects from all layers except blocks 
"" 
NULL 
All objects from all layers except classified objects and blocks 
NULL 
NULL 
All objects from specified layers except classified objects 
Layer1,Layer5 
NULL 
"" 
All objects from specified layers except blocks 
Layer1,Layer5 
"" 
NULL 

 

 

To use multiple filters, see the class AcDbObjectFilterGroup.

class AcDbBasicFilter : public AcDbObjectFilter;
File

AcDbObjectFilter.h

Enumerates the types of layer-status filters. 
Destroys an instance of this class. 
Constructs an instance of this class with the default value filter values set to "*" to filter all entities. 
Constructs an instance of this class by using the specified layer, feature-class, and block filtering criteria. 
Adds a block to the list of blocks on which to filter objects. 
Adds a feature class to the list of feature classes on which to filter objects. 
Adds a layer to the list of layers on which to filter objects. 
Retrieves the block(s) on which to filter. The block filter is defined with SetBlocks() (twoforms). 
Retrieves the feature class(es) on which to filter. The feature-class filter is defined with SetFeatureClasses() (twoforms). 
Filters objects on the current drawing based on the layer, feature-class, and block criteria.
A filtering criterion can take the following values: "*" - (Default) Filters all entities that reside on layers with normal layer status. Unless SetLayerStatusMask()has been called with specific layer mask settings, all objects on layers which are not frozen, off, or locked are considered in the filtering process. "" (empty string) - Indicates that a particular filter is to be ignored during the filtering process. NULL - Indicates that particular filtered entities are to be excluded from the filtered set. A name - The name of... more 
Retrieves the layer(s) on which to filter. The layer filter is defined with SetLayers() (twoforms). NULL and empty strings ("") are invalid values. 
Determines whether the layer status mask has been set by using SetLayerStatusMask(). A nonzero return value indicates that objects on layers which are frozen, locked, or off are to be considered in the filtering process. A zero return value indicates that no layer mask is set and filtering will be applied to objects with normal layer status. 
Clears the filter list of blocks. 
Clears the filter list of feature classes. 
Clears the list of filter layers. 
Sets the block filters. See also Blocks(). 
Sets the blocks on which to filter objects. See also Blocks(). 
 
Sets the feature classes on which to filter objects. See also FeatureClasses(). 
Sets the layers on which to filter objects. NULL and empty strings ("") are invalid values. See also Layers(). 
Sets the layers on which to filter objects. See also Layers(). 
Sets the layer-status filter criterion that specifies whether objects on frozen, locked, or off layers are filtered. Use LayerStatusMask()to determine whether the layer-status filter is set. 
Created with a commercial version of Doc-O-Matic. In order to make this message disappear you need to register this software. If you have problems registering this software please contact us at [email protected].