- //! Returns Feature object by the given Model index.
- //! Returns 0 if the given index is not index of a feature
- FeaturePtr feature(const QModelIndex& theIndex) const;
+ /// Returns the item flags for the given index.
+ /// \param theIndex a model index
+ Qt::ItemFlags flags(const QModelIndex& theIndex) const;
+
+ //! Returns an object by the given Model index.
+ //! Returns 0 if the given index is not index of an object
+ ObjectPtr object(const QModelIndex& theIndex) const;
+
+ //! Returns index of the object
+ //! \param theObject object to find
+ QModelIndex objectIndex(const ObjectPtr theObject) const;
+
+ //! Returns QModelIndex which corresponds to the given part
+ //! If the object is not found then index is not valid
+ //! \param thePart a part for analysis
+ QModelIndex partIndex(const ResultPartPtr& thePart) const;