#include "SMESH_Comment.hxx"
#include "SMESH_TypeDefs.hxx"
+#include <smIdType.hxx>
+
#include <gp_XYZ.hxx>
#include <cgnslib.h>
}
SMDS_MeshElement* add_NGON(cgsize_t* ids, SMESHDS_Mesh* mesh, int ID)
{
- vector<int> idVec( ids[0] );
+ vector<smIdType> idVec( ids[0] );
for ( int i = 0; i < ids[0]; ++i )
- idVec[ i ] = (int) ids[ i + 1];
- return mesh->AddPolygonalFaceWithID( idVec, ID );
+ idVec[ i ] = (smIdType) ids[ i + 1];
+ return mesh->AddPolygonalFaceWithID( idVec, ToIdType(ID) );
}
typedef SMDS_MeshElement* (* PAddElemFun) (cgsize_t* ids, SMESHDS_Mesh* mesh, int ID);
#include "MED_Utilities.hxx"
#include <NCollection_Map.hxx>
+#include <smIdType.hxx>
#include "utilities.h"
// Reading pre information about all MED cells
//--------------------------------------------
- typedef MED::TVector<int> TNodeIds;
+ typedef MED::TVector<smIdType> TNodeIds;
bool takeNumbers = true; // initially we trust the numbers from file
MED::TEntityInfo aEntityInfo = aMed->GetEntityInfo(aMeshInfo, eNOD);
MED::TEntityInfo::iterator anEntityIter = aEntityInfo.begin();
EBooleen anIsElemNum = takeNumbers ? aPolygoneInfo->IsElemNum() : eFAUX;
typedef SMDS_MeshFace* (SMESHDS_Mesh::* FAddPolyWithID)
- (const std::vector<int> & nodes_ids, const int ID);
+ (const std::vector<smIdType> & nodes_ids, const smIdType ID);
typedef SMDS_MeshFace* (SMESHDS_Mesh::* FAddPolygon)
(const std::vector<const SMDS_MeshNode*> & nodes);
#endif
if ( anIsElemNum ) {
TInt anElemId = aPolygoneInfo->GetElemNum( iElem );
- anElement = (myMesh->*addPolyWithID)( aNodeIds, anElemId );
+ anElement = (myMesh->*addPolyWithID)( aNodeIds, ToIdType(anElemId) );
}
if ( !anElement ) {
aNodes.resize( aNbConn );
#endif
if(anIsElemNum){
TInt anElemId = aPolyedreInfo->GetElemNum(iElem);
- anElement = myMesh->AddPolyhedralVolumeWithID(aNodeIds,aQuantities,anElemId);
+ anElement = myMesh->AddPolyhedralVolumeWithID(aNodeIds,aQuantities,ToIdType(anElemId));
}
if(!anElement){
vector<const SMDS_MeshNode*> aNodes(aNbNodes);
{
smIdType newNbCells = NbUsedElements();
smIdType maxCellID = GetMaxID();
- smIdType newNbChunks = newNbCells / theChunkSize + bool ( newNbCells % theChunkSize );
+ int newNbChunks = newNbCells / theChunkSize + bool ( newNbCells % theChunkSize );
theVtkIDsNewToOld.resize( newNbCells );
// in the chunks. So we remove holes and report relocation in theVtkIDsOldToNew:
// theVtkIDsOldToNew[ old VtkID ] = new VtkID
- smIdType oldNbNodes = myMesh->GetGrid()->GetNumberOfPoints();
- smIdType newNbNodes = NbUsedElements();
- smIdType newNbChunks = newNbNodes / theChunkSize + bool ( newNbNodes % theChunkSize );
+ int oldNbNodes = myMesh->GetGrid()->GetNumberOfPoints();
+ int newNbNodes = NbUsedElements();
+ int newNbChunks = newNbNodes / theChunkSize + bool ( newNbNodes % theChunkSize );
smIdType maxNodeID = GetMaxID();
theVtkIDsOldToNew.resize( oldNbNodes, -1 );
*/
//================================================================================
-int SMDS_NodeFactory::GetShapeDim( smIdType shapeID ) const
+int SMDS_NodeFactory::GetShapeDim( int shapeID ) const
{
return shapeID < (int)myShapeDim.size() ? myShapeDim[ shapeID ] : theDefaultShapeDim;
}
*/
//================================================================================
-void SMDS_NodeFactory::SetShapeDim( smIdType shapeID, int dim )
+void SMDS_NodeFactory::SetShapeDim( int shapeID, int dim )
{
- if ( shapeID >= (smIdType)myShapeDim.size() )
+ if ( shapeID >= (int)myShapeDim.size() )
myShapeDim.resize( shapeID + 10, theDefaultShapeDim );
myShapeDim[ shapeID ] = dim;
}
}
else if ( it != mySubIDRanges.mySet.rbegin() )
{
- smIdType nbNodes = (it-1)->my1st;
+ int nbNodes = (it-1)->my1st;
myPositions.resize( nbNodes * 2 );
std::vector<TParam> newPos( myPositions.begin(), myPositions.end() );
myPositions.swap( newPos );
const SMDS_MeshElement* FindElement( const smIdType id ) const;
//! Return a number of used elements
- smIdType NbUsedElements() const { return myNbUsedElements; }
+ int NbUsedElements() const { return myNbUsedElements; }
//! Return an iterator on all element filtered using a given filter.
// nbElemsToReturn is used to optimize by stopping the iteration as soon as
void SetNbShapes( size_t nbShapes );
//! Return a dimension of a shape
- int GetShapeDim( smIdType shapeID ) const;
+ int GetShapeDim( int shapeID ) const;
//! Set a dimension of a shape
- void SetShapeDim( smIdType shapeID, int dim );
+ void SetShapeDim( int shapeID, int dim );
//! De-allocate all nodes
virtual void Clear();
static bool IsUsed( const _UsedRange& r ) { return r.myValue; }
//! Return index of an element in the chunk
- smIdType Index( const SMDS_MeshElement* e ) const { return e - myElements; }
+ int Index( const SMDS_MeshElement* e ) const { return e - myElements; }
//! Return ID of the 1st element in the chunk
int Get1stID() const { return my1stID; }
SMDS_MeshFace* SMDS_Mesh::AddPolygonalFaceWithID (const std::vector<smIdType> & nodes_ids,
const smIdType ID)
{
- smIdType nbNodes = nodes_ids.size();
+ int nbNodes = nodes_ids.size();
std::vector<const SMDS_MeshNode*> nodes (nbNodes);
- for (smIdType i = 0; i < nbNodes; i++) {
+ for (int i = 0; i < nbNodes; i++) {
nodes[i] = myNodeFactory->FindNode( nodes_ids[i] );
if (!nodes[i]) return NULL;
}
const std::vector<int> & quantities,
const smIdType ID)
{
- smIdType nbNodes = nodes_ids.size();
+ int nbNodes = nodes_ids.size();
std::vector<const SMDS_MeshNode*> nodes (nbNodes);
- for (smIdType i = 0; i < nbNodes; i++) {
+ for (int i = 0; i < nbNodes; i++) {
nodes[i] = myNodeFactory->FindNode(nodes_ids[i]);
if (!nodes[i]) return NULL;
}
bool SMDS_Mesh::ChangeElementNodes(const SMDS_MeshElement * element,
const SMDS_MeshNode * nodes[],
- const smIdType nbnodes)
+ const int nbnodes)
{
// keep current nodes of element
std::set<const SMDS_MeshNode*> oldNodes( element->begin_nodes(), element->end_nodes() );
void SMDS_Mesh::updateInverseElements( const SMDS_MeshElement * element,
const SMDS_MeshNode* const* nodes,
- const smIdType nbnodes,
+ const int nbnodes,
std::set<const SMDS_MeshNode*>& oldNodes )
{
if ( GetGrid()->HasLinks() ) // update InverseElements
std::set<const SMDS_MeshNode*>::iterator it;
// AddInverseElement to new nodes
- for ( smIdType i = 0; i < nbnodes; i++ )
+ for ( int i = 0; i < nbnodes; i++ )
{
it = oldNodes.find( nodes[i] );
if ( it == oldNodes.end() )
///////////////////////////////////////////////////////////////////////////////
/// Return the number of nodes
///////////////////////////////////////////////////////////////////////////////
-smIdType SMDS_Mesh::NbNodes() const
+int SMDS_Mesh::NbNodes() const
{
return myInfo.NbNodes();
}
///////////////////////////////////////////////////////////////////////////////
/// Return the number of elements
///////////////////////////////////////////////////////////////////////////////
-smIdType SMDS_Mesh::NbElements() const
+int SMDS_Mesh::NbElements() const
{
return myInfo.NbElements();
}
///////////////////////////////////////////////////////////////////////////////
/// Return the number of 0D elements
///////////////////////////////////////////////////////////////////////////////
-smIdType SMDS_Mesh::Nb0DElements() const
+int SMDS_Mesh::Nb0DElements() const
{
return myInfo.Nb0DElements();
}
///////////////////////////////////////////////////////////////////////////////
/// Return the number of 0D elements
///////////////////////////////////////////////////////////////////////////////
-smIdType SMDS_Mesh::NbBalls() const
+int SMDS_Mesh::NbBalls() const
{
return myInfo.NbBalls();
}
///////////////////////////////////////////////////////////////////////////////
/// Return the number of edges (including construction edges)
///////////////////////////////////////////////////////////////////////////////
-smIdType SMDS_Mesh::NbEdges() const
+int SMDS_Mesh::NbEdges() const
{
return myInfo.NbEdges();
}
///////////////////////////////////////////////////////////////////////////////
/// Return the number of faces (including construction faces)
///////////////////////////////////////////////////////////////////////////////
-smIdType SMDS_Mesh::NbFaces() const
+int SMDS_Mesh::NbFaces() const
{
return myInfo.NbFaces();
}
///////////////////////////////////////////////////////////////////////////////
/// Return the number of volumes
///////////////////////////////////////////////////////////////////////////////
-smIdType SMDS_Mesh::NbVolumes() const
+int SMDS_Mesh::NbVolumes() const
{
return myInfo.NbVolumes();
}
/// Return the number of child mesh of this mesh.
/// Note that the tree structure of SMDS_Mesh is unused in SMESH
///////////////////////////////////////////////////////////////////////////////
-smIdType SMDS_Mesh::NbSubMesh() const
+int SMDS_Mesh::NbSubMesh() const
{
return myChildren.size();
}
SMDS_ElemIteratorPtr SMDS_Mesh::elementGeomIterator(SMDSAbs_GeometryType type) const
{
- smIdType nbElems = myCellFactory->CompactChangePointers() ? -1 : myInfo.NbElements( type );
+ int nbElems = myCellFactory->CompactChangePointers() ? -1 : myInfo.NbElements( type );
return myCellFactory->GetIterator< SMDS_ElemIterator >( new SMDS_MeshElement::GeomFilter( type ),
nbElems);
}
{
return myNodeFactory->GetIterator< SMDS_ElemIterator >( new SMDS_MeshElement::NonNullFilter );
}
- smIdType nbElems = myCellFactory->CompactChangePointers() ? -1 : myInfo.NbElements( type );
+ int nbElems = myCellFactory->CompactChangePointers() ? -1 : myInfo.NbElements( type );
return myCellFactory->GetIterator<SMDS_ElemIterator>( new SMDS_MeshElement::EntityFilter( type ),
nbElems);
}
return myNodeFactory->GetIterator< TIterator >( new SMDS_MeshElement::NonNullFilter );
default:
- smIdType nbElems = myCellFactory->CompactChangePointers() ? -1 : myInfo.NbElements( type );
+ int nbElems = myCellFactory->CompactChangePointers() ? -1 : myInfo.NbElements( type );
return myCellFactory->GetIterator< TIterator >( new SMDS_MeshElement::TypeFilter( type ),
nbElems);
}
SMDS_EdgeIteratorPtr SMDS_Mesh::edgesIterator() const
{
typedef SMDS_EdgeIterator TIterator;
- smIdType nbElems = myCellFactory->CompactChangePointers() ? -1 : myInfo.NbEdges();
+ int nbElems = myCellFactory->CompactChangePointers() ? -1 : myInfo.NbEdges();
return myCellFactory->GetIterator< TIterator >( new SMDS_MeshElement::TypeFilter( SMDSAbs_Edge ),
nbElems);
}
SMDS_FaceIteratorPtr SMDS_Mesh::facesIterator() const
{
typedef SMDS_FaceIterator TIterator;
- smIdType nbElems = myCellFactory->CompactChangePointers() ? -1 : myInfo.NbFaces();
+ int nbElems = myCellFactory->CompactChangePointers() ? -1 : myInfo.NbFaces();
return myCellFactory->GetIterator< TIterator >( new SMDS_MeshElement::TypeFilter( SMDSAbs_Face ),
nbElems);
}
SMDS_VolumeIteratorPtr SMDS_Mesh::volumesIterator() const
{
typedef SMDS_VolumeIterator TIterator;
- smIdType nbElems = myCellFactory->CompactChangePointers() ? -1 : myInfo.NbVolumes();
+ int nbElems = myCellFactory->CompactChangePointers() ? -1 : myInfo.NbVolumes();
return
myCellFactory->GetIterator< TIterator >( new SMDS_MeshElement::TypeFilter( SMDSAbs_Volume ),
nbElems );
///////////////////////////////////////////////////////////////////////////////
static std::set<const SMDS_MeshElement*> * getFinitElements(const SMDS_MeshElement * element)
{
- smIdType numberOfSets=element->NbNodes();
+ int numberOfSets=element->NbNodes();
std::set<const SMDS_MeshElement*> *initSet = new std::set<const SMDS_MeshElement*>[numberOfSets];
SMDS_NodeIteratorPtr itNodes = element->nodeIterator();
myCellFactory->Compact( idCellsNewToOld );
// make VTK IDs correspond to SMDS IDs
- smIdType newNodeSize = myNodeFactory->NbUsedElements();
- smIdType newCellSize = myCellFactory->NbUsedElements();
+ int newNodeSize = myNodeFactory->NbUsedElements();
+ int newCellSize = myCellFactory->NbUsedElements();
myGrid->compactGrid( idNodesOldToNew, newNodeSize, idCellsNewToOld, newCellSize );
if ( idsChange && !myElemHolders.empty() )
bool ChangeElementNodes(const SMDS_MeshElement * elem,
const SMDS_MeshNode * nodes[],
- const smIdType nbnodes);
+ const int nbnodes);
bool ChangePolyhedronNodes(const SMDS_MeshElement * elem,
const std::vector<const SMDS_MeshNode*>& nodes,
const std::vector<int>& quantities);
const SMDS_MeshInfo& GetMeshInfo() const { return myInfo; }
- virtual smIdType NbNodes() const;
- virtual smIdType NbElements() const;
- virtual smIdType Nb0DElements() const;
- virtual smIdType NbBalls() const;
- virtual smIdType NbEdges() const;
- virtual smIdType NbFaces() const;
- virtual smIdType NbVolumes() const;
- virtual smIdType NbSubMesh() const;
+ virtual int NbNodes() const;
+ virtual int NbElements() const;
+ virtual int Nb0DElements() const;
+ virtual int NbBalls() const;
+ virtual int NbEdges() const;
+ virtual int NbFaces() const;
+ virtual int NbVolumes() const;
+ virtual int NbSubMesh() const;
virtual ~SMDS_Mesh();
void updateInverseElements( const SMDS_MeshElement * element,
const SMDS_MeshNode* const* nodes,
- const smIdType nbnodes,
+ const int nbnodes,
std::set<const SMDS_MeshNode*>& oldNodes );
void setNbShapes( size_t nbShapes );
#include "SMESH_TryCatch.hxx" // include after OCCT headers!
+#include <smIdType.hxx>
+
#define cast2Node(elem) static_cast<const SMDS_MeshNode*>( elem )
using namespace std;
long GetLinkID (const SMDS_MeshNode * n1,
const SMDS_MeshNode * n2) const
{
- return ( Min(n1->GetID(),n2->GetID()) * myMaxID + Max(n1->GetID(),n2->GetID()));
+ return ( Min(FromIdType<int>(n1->GetID()),FromIdType<int>(n2->GetID())) * myMaxID + Max(FromIdType<int>(n1->GetID()),FromIdType<int>(n2->GetID())));
}
bool GetNodes (const long theLinkID,
#include "SALOME_LifeCycleCORBA.hxx"
#include <SALOMEconfig.h>
+#include <smIdType.hxx>
#include CORBA_SERVER_HEADER(SALOME_Component)
#include CORBA_SERVER_HEADER(SALOME_Exception)
CORBA::Long anIndexId = 0, aNbElems = theSeq[theId].number;
for (CORBA::Long anElemId = 0; anElemId < aNbElems; anElemId++) {
- int aFaceId = anIndexes[anIndexId++];
+ smIdType aFaceId = anIndexes[anIndexId++];
int aNbNodes = anIndexes[anIndexId++];
- std::vector<int> nodes_ids (aNbNodes);
+ std::vector<smIdType> nodes_ids (aNbNodes);
for (int i = 0; i < aNbNodes; i++) {
nodes_ids[i] = anIndexes[anIndexId++];
}
CORBA::Long anIndexId = 0, aNbElems = theSeq[theId].number;
for (CORBA::Long anElemId = 0; anElemId < aNbElems; anElemId++) {
- int aFaceId = anIndexes[anIndexId++];
+ smIdType aFaceId = anIndexes[anIndexId++];
int aNbNodes = anIndexes[anIndexId++];
- std::vector<int> nodes_ids (aNbNodes);
+ std::vector<smIdType> nodes_ids (aNbNodes);
for (int i = 0; i < aNbNodes; i++) {
nodes_ids[i] = anIndexes[anIndexId++];
}
CORBA::Long anIndexId = 0, aNbElems = theSeq[theId].number;
for (CORBA::Long anElemId = 0; anElemId < aNbElems; anElemId++) {
- int aFaceId = anIndexes[anIndexId++];
+ smIdType aFaceId = anIndexes[anIndexId++];
int aNbNodes = anIndexes[anIndexId++];
- std::vector<int> nodes_ids (aNbNodes);
+ std::vector<smIdType> nodes_ids (aNbNodes);
for (int i = 0; i < aNbNodes; i++) {
nodes_ids[i] = anIndexes[anIndexId++];
}
//function : AddPolygonalFace
//purpose :
//=======================================================================
-void SMESHDS_Command::AddPolygonalFace (const int ElementID,
- const std::vector<int>& nodes_ids)
+void SMESHDS_Command::AddPolygonalFace (const smIdType ElementID,
+ const std::vector<smIdType>& nodes_ids)
{
if ( myType != SMESHDS_AddPolygon) {
MESSAGE("SMESHDS_Command::AddPolygonalFace : Bad Type");
//function : AddQuadPolygonalFace
//purpose :
//=======================================================================
-void SMESHDS_Command::AddQuadPolygonalFace (const int ElementID,
- const std::vector<int>& nodes_ids)
+void SMESHDS_Command::AddQuadPolygonalFace (const smIdType ElementID,
+ const std::vector<smIdType>& nodes_ids)
{
if ( myType != SMESHDS_AddQuadPolygon) {
MESSAGE("SMESHDS_Command::AddQuadraticPolygonalFace : Bad Type");
//function : AddPolyhedralVolume
//purpose :
//=======================================================================
-void SMESHDS_Command::AddPolyhedralVolume (const int ElementID,
- const std::vector<int>& nodes_ids,
- const std::vector<int>& quantities)
+void SMESHDS_Command::AddPolyhedralVolume (const smIdType ElementID,
+ const std::vector<smIdType>& nodes_ids,
+ const std::vector<int>& quantities)
{
if ( myType != SMESHDS_AddPolyhedron) {
MESSAGE("SMESHDS_Command::AddPolyhedralVolume : Bad Type");
#include "SMESH_SMESHDS.hxx"
#include "SMESHDS_CommandType.hxx"
+#include <smIdType.hxx>
#include <list>
#include <vector>
void AddVolume(int NewVolID, int idnode1, int idnode2, int idnode3,
int idnode4, int idnode5, int idnode6, int idnode7, int idnode8,
int idnode9, int idnode10, int idnode11, int idnode12);
- void AddPolygonalFace (const int ElementID,
- const std::vector<int>& nodes_ids);
- void AddQuadPolygonalFace (const int ElementID,
- const std::vector<int>& nodes_ids);
- void AddPolyhedralVolume (const int ElementID,
- const std::vector<int>& nodes_ids,
+ void AddPolygonalFace (const smIdType ElementID,
+ const std::vector<smIdType>& nodes_ids);
+ void AddQuadPolygonalFace (const smIdType ElementID,
+ const std::vector<smIdType>& nodes_ids);
+ void AddPolyhedralVolume (const smIdType ElementID,
+ const std::vector<smIdType>& nodes_ids,
const std::vector<int>& quantities);
void AddBall(int NewBallID, int node, double diameter);
// special methods for quadratic elements
//purpose :
//=======================================================================
SMDS_MeshVolume* SMESHDS_Mesh::AddPolyhedralVolumeWithID (const std::vector<smIdType>& nodes_ids,
- const std::vector<smIdType>& quantities,
+ const std::vector<int>& quantities,
const smIdType ID)
{
SMDS_MeshVolume *anElem = SMDS_Mesh::AddPolyhedralVolumeWithID(nodes_ids, quantities, ID);
//function : AddPolygonalFace
//purpose :
//=======================================================================
-void SMESHDS_Script::AddPolygonalFace (int NewFaceID, const std::vector<int>& nodes_ids)
+void SMESHDS_Script::AddPolygonalFace (smIdType NewFaceID, const std::vector<smIdType>& nodes_ids)
{
if(myIsEmbeddedMode){
myIsModified = true;
//function : AddQuadPolygonalFace
//purpose :
//=======================================================================
-void SMESHDS_Script::AddQuadPolygonalFace(int NewFaceID, const std::vector<int>& nodes_ids)
+void SMESHDS_Script::AddQuadPolygonalFace(smIdType NewFaceID, const std::vector<smIdType>& nodes_ids)
{
if(myIsEmbeddedMode){
myIsModified = true;
//function : AddPolyhedralVolume
//purpose :
//=======================================================================
-void SMESHDS_Script::AddPolyhedralVolume (int NewID,
- const std::vector<int>& nodes_ids,
- const std::vector<int>& quantities)
+void SMESHDS_Script::AddPolyhedralVolume (smIdType NewID,
+ const std::vector<smIdType>& nodes_ids,
+ const std::vector<int>& quantities)
{
if(myIsEmbeddedMode){
myIsModified = true;
#include "SMESHDS_Command.hxx"
+#include <smIdType.hxx>
+
#include <list>
#include <vector>
int idnode4, int idnode5, int idnode6, int idnode7, int idnode8,
int idnode9, int idnode10, int idnode11, int idnode12);
- void AddPolygonalFace (const int NewFaceID,
- const std::vector<int>& nodes_ids);
- void AddQuadPolygonalFace (const int NewFaceID,
- const std::vector<int>& nodes_ids);
- void AddPolyhedralVolume (const int NewVolID,
- const std::vector<int>& nodes_ids,
+ void AddPolygonalFace (const smIdType NewFaceID,
+ const std::vector<smIdType>& nodes_ids);
+ void AddQuadPolygonalFace (const smIdType NewFaceID,
+ const std::vector<smIdType>& nodes_ids);
+ void AddPolyhedralVolume (const smIdType NewVolID,
+ const std::vector<smIdType>& nodes_ids,
const std::vector<int>& quantities);
void AddBall(int NewBallID, int node, double diameter);
static Standard_Integer HashCode(const CutFace& f, const Standard_Integer upper)
{
- return ::HashCode( f.myInitFace->GetID(), upper );
+ return ::HashCode( (int)(f.myInitFace->GetID()), upper );
}
static Standard_Boolean IsEqual(const CutFace& f1, const CutFace& f2 )
{
#include "SMDS_SetIterator.hxx"
#include "SMDS_MeshNode.hxx"
+#include <smIdType.hxx>
+
#include <gp_XYZ.hxx>
#include <gp_XY.hxx>
// methods for usage of SMESH_TLink as a hasher in NCollection maps
static int HashCode(const SMESH_TLink& link, int aLimit)
{
- return ::HashCode( link.node1()->GetID() + link.node2()->GetID(), aLimit );
+ return ::HashCode( FromIdType<int>(link.node1()->GetID() + link.node2()->GetID()), aLimit );
}
static Standard_Boolean IsEqual(const SMESH_TLink& l1, const SMESH_TLink& l2)
{
{
static Standard_Integer HashCode(const SMDS_MeshElement* e, const Standard_Integer upper)
{
- return ::HashCode( e->GetID(), upper );
+ return ::HashCode( FromIdType<int>(e->GetID()), upper );
}
static Standard_Boolean IsEqual( const SMDS_MeshElement* e1, const SMDS_MeshElement* e2 )
{
#include "SMESHDS_Mesh.hxx"
#include "SMESH_TypeDefs.hxx"
+#include <smIdType.hxx>
#include <SALOMEconfig.h>
#include CORBA_SERVER_HEADER(SMESH_Mesh)
virtual const SMDS_MeshElement *FindElement(int IDelem) const;
virtual bool HasNumerationHoles();
- virtual int MaxNodeID() const;
- virtual int MinNodeID() const;
- virtual int MaxElementID() const;
- virtual int MinElementID() const;
+ virtual smIdType MaxNodeID() const;
+ virtual smIdType MinNodeID() const;
+ virtual smIdType MaxElementID() const;
+ virtual smIdType MinElementID() const;
private:
TIDSortedElemSet _elements[ SMDSAbs_NbElementTypes ];
MaxElementID() != NbElements() );
}
// -------------------------------------------------------------------------------------
-int SMESH_MeshPartDS::MaxNodeID() const
+smIdType SMESH_MeshPartDS::MaxNodeID() const
{
if ( _meshDS ) return _meshDS->MaxNodeID();
return NbNodes() == 0 ? 0 : (*_elements[ SMDSAbs_Node ].rbegin())->GetID();
}
// -------------------------------------------------------------------------------------
-int SMESH_MeshPartDS::MinNodeID() const
+smIdType SMESH_MeshPartDS::MinNodeID() const
{
if ( _meshDS ) return _meshDS->MinNodeID();
return NbNodes() == 0 ? 0 : (*_elements[ SMDSAbs_Node ].begin())->GetID();
}
// -------------------------------------------------------------------------------------
-int SMESH_MeshPartDS::MaxElementID() const
+smIdType SMESH_MeshPartDS::MaxElementID() const
{
if ( _meshDS ) return _meshDS->MaxElementID();
int maxID = 0;
return maxID;
}
// -------------------------------------------------------------------------------------
-int SMESH_MeshPartDS::MinElementID() const
+smIdType SMESH_MeshPartDS::MinElementID() const
{
if ( _meshDS ) return _meshDS->MinElementID();
int minID = 0;