1 // Copyright (C) 2004 CEA
3 // This library is free software; you can redistribute it and/or
4 // modify it under the terms of the GNU Lesser General Public
5 // License as published by the Free Software Foundation; either
6 // version 2.1 of the License.
8 // This library is distributed in the hope that it will be useful,
9 // but WITHOUT ANY WARRANTY; without even the implied warranty of
10 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
11 // Lesser General Public License for more details.
13 // You should have received a copy of the GNU Lesser General Public
14 // License along with this library; if not, write to the Free Software
15 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
17 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
21 // File : SMESH_Group.idl
22 // Author : Sergey ANIKIN, OCC
26 #ifndef _SMESH_GROUP_IDL_
27 #define _SMESH_GROUP_IDL_
29 #include "SALOME_Exception.idl"
30 #include "SALOME_GenericObj.idl"
32 #include "SMESH_Mesh.idl"
39 * SMESH_Group: base interface of group object
41 interface SMESH_GroupBase : SALOME::GenericObj, SMESH_IDSource
46 void SetName( in string name );
54 * Returns group type (type of elements in the group)
56 ElementType GetType();
59 * Returns the number of elements in the group
64 * Returns true if the group does not contain any elements
69 * returns true if the group contains an element with ID == <elem_id>
71 boolean Contains( in long elem_id );
74 * Returns ID of an element at position <elem_index>
76 long GetID( in long elem_index );
79 * Returns a sequence of all element IDs in the group
81 long_array GetListOfID();
84 * Returns the mesh object this group belongs to
89 * Sets group color number
91 void SetColorNumber( in long color );
94 * Returns group color number
96 long GetColorNumber();
100 * SMESH_Group: interface of group object
102 interface SMESH_Group : SMESH_GroupBase
105 * Clears the group's contents
110 * Adds elements to the group
112 long Add( in long_array elem_ids );
113 long AddByPredicate( in Predicate thePredicate );
116 * Removes elements from the group
118 long Remove( in long_array elem_ids );
119 long RemoveByPredicate( in Predicate thePredicate );
123 * SMESH_Group: interface of group object linked to geometry
125 interface SMESH_GroupOnGeom : SMESH_GroupBase
127 GEOM::GEOM_Object GetShape();