1 // File: ModelAPI_AttributeSelectionList.h
2 // Created: 22 Oct 2014
3 // Author: Mikhail PONIKAROV
5 #ifndef ModelAPI_AttributeSelectionList_H_
6 #define ModelAPI_AttributeSelectionList_H_
8 #include "ModelAPI_AttributeSelection.h"
9 #include <ModelAPI_Result.h>
11 /**\class ModelAPI_AttributeSelectionList
13 * \brief Attribute that contains list of references to the sub-shapes with
14 * possibility to manage them.
17 class ModelAPI_AttributeSelectionList : public ModelAPI_Attribute
20 /// Adds the new reference to the end of the list
22 const ResultPtr& theContext, const boost::shared_ptr<GeomAPI_Shape>& theSubShape) = 0;
24 /// Returns the number ofselection attributes in the list
25 virtual int size() = 0;
27 virtual int selectionType() = 0;
29 virtual void setSelectionType(int) = 0;
31 /// Returns the attribute selection by the index (zero based)
32 virtual boost::shared_ptr<ModelAPI_AttributeSelection> value(const int theIndex) = 0;
34 /// Returns all attributes
35 virtual void clear() = 0;
37 /// Returns the type of this class of attributes
38 static std::string type()
40 return "SelectionList";
43 /// Returns the type of this class of attributes, not static method
44 virtual std::string attributeType()
49 /// To virtually destroy the fields of successors
50 virtual ~ModelAPI_AttributeSelectionList()
55 /// Objects are created for features automatically
56 MODELAPI_EXPORT ModelAPI_AttributeSelectionList()
61 //! Pointer on double attribute
62 typedef boost::shared_ptr<ModelAPI_AttributeSelectionList> AttributeSelectionListPtr;