Salome HOME
Merge branch 'BR_HYDRO_IMPS_WIN' of ssh://gitolite3@git.salome-platform.org/modules...
[modules/hydro.git] / src / HYDROPy / HYDROData_StricklerTable.sip
1 // Copyright (C) 2014-2015  EDF-R&D
2 // This library is free software; you can redistribute it and/or
3 // modify it under the terms of the GNU Lesser General Public
4 // License as published by the Free Software Foundation; either
5 // version 2.1 of the License, or (at your option) any later version.
6 //
7 // This library is distributed in the hope that it will be useful,
8 // but WITHOUT ANY WARRANTY; without even the implied warranty of
9 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
10 // Lesser General Public License for more details.
11 //
12 // You should have received a copy of the GNU Lesser General Public
13 // License along with this library; if not, write to the Free Software
14 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
15 //
16 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
17 //
18
19 %ExportedHeaderCode
20 #include <HYDROData_StricklerTable.h>
21 #include <TColStd_SequenceOfExtendedString.hxx>
22 %End
23
24 class HYDROData_StricklerTable : public HYDROData_Entity
25 {
26
27 %ConvertToSubClassCode
28     switch ( sipCpp->GetKind() )
29     {
30       case KIND_STRICKLER_TABLE:
31         sipClass = sipClass_HYDROData_StricklerTable;
32         break;
33
34       default:
35         // We don't recognise the type.
36         sipClass = NULL;
37     }
38 %End
39
40 %TypeHeaderCode
41 #include <HYDROData_StricklerTable.h>
42 %End
43
44 public:      
45
46   bool Import( const QString& theFileName );
47   bool Export( const QString& theFileName );
48
49   double Get( const QString& theType, double theDefault ) const;
50   void   Set( const QString& theType, double theCoefficient );
51
52   QString GetAttrName() const;
53   bool    SetAttrName( const QString& ) const;
54
55   QString GetAttrValue( const QString& theType ) const;
56   void    SetAttrValue( const QString& theType, const QString& theAttrValue ) const;
57
58   QColor GetColor( const QString& theType ) const;
59   void   SetColor( const QString& theType, const QColor& theColor ) const;
60
61   QStringList GetTypes() const;
62
63   void Clear();
64
65 protected:
66   /**
67    * Creates new object in the internal data structure. Use higher level objects 
68    * to create objects with real content.
69    */
70   HYDROData_StricklerTable();
71
72   /**
73    * Destructs properties of the object and object itself, removes it from the document.
74    */
75   ~HYDROData_StricklerTable();
76 };
77
78