2 // C++ : Gestion des tuyaux
4 // Copyright (C) 2009-2013 CEA/DEN, EDF R&D
6 // This library is free software; you can redistribute it and/or
7 // modify it under the terms of the GNU Lesser General Public
8 // License as published by the Free Software Foundation; either
9 // version 2.1 of the License.
11 // This library is distributed in the hope that it will be useful,
12 // but WITHOUT ANY WARRANTY; without even the implied warranty of
13 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 // Lesser General Public License for more details.
16 // You should have received a copy of the GNU Lesser General Public
17 // License along with this library; if not, write to the Free Software
18 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
20 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
22 #include "HexPipe.hxx"
24 #include "HexDocument.hxx"
25 #include "HexVertex.hxx"
26 #include "HexVector.hxx"
27 #include "HexXmlWriter.hxx"
31 // ======================================================== Constructeur
32 Pipe::Pipe (Vertex* b, Vector* v, double ri, double re, double h)
33 : Cylinder (b, v, re, h)
36 if (isBad () || c_int_radius <= el_root->getTolerance ()
37 || c_int_radius >= c_radius)
40 // ========================================================= saveXml
41 void Pipe::saveXml (XmlWriter* xml)
45 xml->openMark ("Pipe");
46 xml->addAttribute ("c_base", c_base->getName (buffer));
47 xml->addAttribute ("c_dir", c_dir->getName (buffer));
48 xml->addAttribute ("c_radius", c_radius);
49 xml->addAttribute ("c_int_radius", c_int_radius);
50 xml->addAttribute ("c_height", c_height);