1 // Copyright (C) 2009-2013 CEA/DEN, EDF R&D
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
20 //=============================================================================
21 // File : HEXABLOCKPlugin_Hypothesis.cxx
22 // Created : Wed Apr 2 12:36:29 2008
23 // Author : Lioka RAZAFINDRAZAKA (CEA)
24 //=============================================================================
26 #include "HEXABLOCKPlugin_Hypothesis.hxx"
28 //=======================================================================
29 //function : HEXABLOCKPlugin_Hypothesis
30 //=======================================================================
32 HEXABLOCKPlugin_Hypothesis::HEXABLOCKPlugin_Hypothesis(int hypId, int studyId, SMESH_Gen * gen)
33 : SMESH_Hypothesis(hypId, studyId, gen),
37 _name = "HEXABLOCK_Parameters";
41 //=======================================================================
42 //function : GetDocument
43 //=======================================================================
45 HEXA_NS::Document* HEXABLOCKPlugin_Hypothesis::GetDocument() const
50 //=======================================================================
51 //function : SetDocument
52 //=======================================================================
54 void HEXABLOCKPlugin_Hypothesis::SetDocument(HEXA_NS::Document* doc)
59 //=======================================================================
60 //function : GetDimension
61 //=======================================================================
63 int HEXABLOCKPlugin_Hypothesis::GetDimension() const
68 //=======================================================================
69 //function : SetDimension
70 //=======================================================================
72 void HEXABLOCKPlugin_Hypothesis::SetDimension(int dim)
77 //=======================================================================
79 //=======================================================================
81 std::ostream & HEXABLOCKPlugin_Hypothesis::SaveTo(std::ostream & save)
83 //save << _document->getXML() << " ";
84 save <<_dimension << " ";
89 //=======================================================================
91 //=======================================================================
93 std::istream & HEXABLOCKPlugin_Hypothesis::LoadFrom(std::istream & load)
99 // isOK = (load >> str);
101 // _document = xml_2_doc(str);
103 // load.clear(ios::badbit | load.rdstate());
109 load.clear(ios::badbit | load.rdstate());
114 //=======================================================================
115 //function : SetParametersByMesh
116 //=======================================================================
118 bool HEXABLOCKPlugin_Hypothesis::SetParametersByMesh(const SMESH_Mesh* ,const TopoDS_Shape&)
124 //================================================================================
126 * \brief Return false
128 //================================================================================
130 bool HEXABLOCKPlugin_Hypothesis::SetParametersByDefaults(const TDefaults& /*dflts*/,
131 const SMESH_Mesh* /*theMesh*/)