Salome HOME
Update copyrights 2014.
[modules/smesh.git] / src / SMDS / SMDS_MeshEdge.cxx
index cbb448286ed7224851c619f6807fdd06a0e0ff78..c1fa7dacce76044c78755d27ad3268f768781c8c 100644 (file)
@@ -1,53 +1,30 @@
-using namespace std;
-// File:       SMDS_MeshEdge.cxx
-// Created:    Wed Jan 23 17:02:20 2002
-// Author:     Jean-Michel BOULCOURT
-//             <jmb@coulox.paris1.matra-dtv.fr>
-
-
-#include "SMDS_MeshEdge.ixx"
-
-//=======================================================================
-//function : SMDS_MeshEdge
-//purpose  : 
-//=======================================================================
-
-SMDS_MeshEdge::SMDS_MeshEdge(const Standard_Integer ID,
-                            const Standard_Integer idnode1, 
-                            const Standard_Integer idnode2) :
-SMDS_MeshElement(ID,2,SMDSAbs_Edge)
+// Copyright (C) 2010-2014  CEA/DEN, EDF R&D, OPEN CASCADE
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License, or (at your option) any later version.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+//
+
+#include "SMDS_MeshEdge.hxx"
+
+SMDSAbs_ElementType SMDS_MeshEdge::GetType() const
 {
-  SetConnections(idnode1,idnode2);
-  ComputeKey();
+        return SMDSAbs_Edge;
 }
 
-//=======================================================================
-//function : SetConnections
-//purpose  : 
-//=======================================================================
-void SMDS_MeshEdge::SetConnections(const Standard_Integer idnode1, 
-                                  const Standard_Integer idnode2)
+vtkIdType SMDS_MeshEdge::GetVtkType() const
 {
-  Standard_Integer idmin = (idnode1 < idnode2? idnode1 : idnode2);
-
-  myNodes[0] = idmin;
-  if (idmin == idnode1) {
-    myNodes[1] = idnode2;
-  } else {
-    myNodes[1] = idnode1;
-  }
+  return VTK_POLY_VERTEX; // --- must be reimplemented in derived classes
 }
-
-//=======================================================================
-//function : Print
-//purpose  : 
-//=======================================================================
-
-void SMDS_MeshEdge::Print(Standard_OStream& OS) const
-{
-  OS << "edge <" << myID <<"> : (" << myNodes[0] << " , " << myNodes[1] << ") " << endl;  
-}
-
-
-
-