SHAPER  9.12.0
ModelAPI_Filter Class Referenceabstract
Inheritance diagram for ModelAPI_Filter:
Inheritance graph

Public Member Functions

virtual const std::string & name () const =0
 Returns name of the filter to represent it in GUI. More...
 
virtual bool isSupported (GeomAPI_Shape::ShapeType theType) const =0
 Returns true if the given shape type is supported. More...
 
virtual bool isOk (const GeomShapePtr &theShape, const ResultPtr &theResult, const ModelAPI_FiltersArgs &theArgs) const =0
 This method should contain the filter logic. More...
 
virtual bool isMultiple () const
 Returns True if the filter can be used several times within one filtering. More...
 
virtual std::string xmlRepresentation () const
 Returns XML string which represents GUI of the filter By default it returns nothing (no GUI) More...
 
virtual void initAttributes (ModelAPI_FiltersArgs &)
 Initializes arguments of a filter. More...
 
virtual std::string xmlFromFile (const std::string &theConfigFile) const
 Returns XML string which represents GUI of the filter by reading corresponding XML file. More...
 

Member Function Documentation

◆ name()

◆ isSupported()

◆ isOk()

virtual bool ModelAPI_Filter::isOk ( const GeomShapePtr &  theShape,
const ResultPtr &  theResult,
const ModelAPI_FiltersArgs theArgs 
) const
pure virtual

This method should contain the filter logic.

It returns true if the given shape is accepted by the filter.

Parameters
theShapethe given shape
theResultparent result of the shape to be checked
theArgsarguments of the filter

Implemented in FiltersPlugin_OnShapeName, FiltersPlugin_ExternalFaces, FiltersPlugin_VolumeSize, FiltersPlugin_VerticalFace, FiltersPlugin_RelativeToSolid, FiltersPlugin_OppositeToEdge, FiltersPlugin_OnPlaneSide, FiltersPlugin_OnPlane, FiltersPlugin_OnLine, FiltersPlugin_OnGeometry, FiltersPlugin_HorizontalFace, FiltersPlugin_FeatureEdges, FiltersPlugin_FaceSize, FiltersPlugin_EdgeSize, FiltersPlugin_ContinuousFaces, and FiltersPlugin_BelongsTo.

◆ isMultiple()

virtual bool ModelAPI_Filter::isMultiple ( ) const
inlinevirtual

Returns True if the filter can be used several times within one filtering.

Reimplemented in FiltersPlugin_RelativeToSolid, FiltersPlugin_OnPlaneSide, FiltersPlugin_OnPlane, and FiltersPlugin_OnLine.

◆ xmlRepresentation()

virtual std::string ModelAPI_Filter::xmlRepresentation ( ) const
inlinevirtual

◆ initAttributes()

◆ xmlFromFile()

std::string ModelAPI_Filter::xmlFromFile ( const std::string &  theConfigFile) const
virtual

Returns XML string which represents GUI of the filter by reading corresponding XML file.