X-Git-Url: http://git.salome-platform.org/gitweb/?p=modules%2Fsmesh.git;a=blobdiff_plain;f=src%2FSMESHUtils%2FSMESH_TypeDefs.hxx;h=f523fdd53071ae786b005336c7ae5c8ede43191c;hp=9fbc5b076ade419dc7c865af26091a5a74b79c3b;hb=09bc0414c91ebabb67c7fe200549044a1854e199;hpb=6d3cec2c3838c5e4742b93f04d43733a0c3b08f9 diff --git a/src/SMESHUtils/SMESH_TypeDefs.hxx b/src/SMESHUtils/SMESH_TypeDefs.hxx index 9fbc5b076..f523fdd53 100644 --- a/src/SMESHUtils/SMESH_TypeDefs.hxx +++ b/src/SMESHUtils/SMESH_TypeDefs.hxx @@ -185,6 +185,21 @@ struct SMESH_TNodeXYZ : public gp_XYZ }; typedef SMESH_TNodeXYZ SMESH_NodeXYZ; +// -------------------------------------------------------------------------------- +// SMESH_Hasher provide methods needed to put mesh data to NCollection maps + +struct SMESH_Hasher +{ + static Standard_Integer HashCode(const SMDS_MeshElement* e, const Standard_Integer upper) + { + return ::HashCode( e->GetID(), upper ); + } + static Standard_Boolean IsEqual( const SMDS_MeshElement* e1, const SMDS_MeshElement* e2 ) + { + return ( e1 == e2 ); + } +}; + //-------------------------------------------------- /*! * \brief Data of a node generated on FACE boundary