1 // SALOME SALOMEDS : data structure of SALOME and sources of Salome data server
3 // Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
4 // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
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
24 // File : SALOMEDS_AttReal_i.cxx
25 // Author : Estelle Deville
29 #include "SALOMEDS_AttReal_i.hxx"
30 #include "utilities.h"
33 #include <SALOMEDSImpl_AttributeReal.hxx>
36 //============================================================================
38 * Purpose : Affect a value to the basic attribute
40 //============================================================================
41 void SALOMEDS_AttReal_i::Set(CORBA::Double r)
44 SALOMEDSImpl_AttributeReal::Set (_Lab,r);
47 //============================================================================
49 * Purpose : Get basic attribute's value
51 //============================================================================
52 CORBA::Double SALOMEDS_AttReal_i::Get()
54 SALOMEDSImpl_AttributeReal* Att;
56 if ((Att=(SALOMEDSImpl_AttributeReal*)_Lab.FindAttribute(TDataStd_Real::GetID())))
61 //============================================================================
65 //============================================================================
66 char* SALOMEDS_AttReal_i::Save()
68 BEGIN_OF("SALOMEDS_AttReal_i::Save");
69 CORBA::Double x = this->Get();
70 char* out= new char[12];
75 //============================================================================
79 //============================================================================
80 void SALOMEDS_AttReal_i::Load()
82 BEGIN_OF("SALOMEDS_AttReal_i::Load");
85 //============================================================================
87 * Purpose : return sobject associated to the basic attribute (if exist)
89 //============================================================================
90 CORBA::Boolean SALOMEDS_AttReal_i::GetPtr(SALOMEDS::SObject_ptr anObject)
92 return _Lab.IsAttribute(SALOMEDSImpl_AttributeReal::GetID());
95 //============================================================================
96 /*! Function : GetType
99 //============================================================================
100 char* SALOMEDS_AttReal_i::GetType()
102 return CORBA::string_dup(_type);