fw4spl
Float.hpp
1 /* ***** BEGIN LICENSE BLOCK *****
2  * FW4SPL - Copyright (C) IRCAD, 2009-2017.
3  * Distributed under the terms of the GNU Lesser General Public License (LGPL) as
4  * published by the Free Software Foundation.
5  * ****** END LICENSE BLOCK ****** */
6 
7 #ifndef __FWDATA_FLOAT_HPP__
8 #define __FWDATA_FLOAT_HPP__
9 
10 #include "fwData/config.hpp"
11 #include "fwData/factory/new.hpp"
12 #include "fwData/GenericField.hpp"
13 #include "fwData/Object.hpp"
14 
15 fwCampAutoDeclareDataMacro((fwData)(Float), FWDATA_API);
16 
17 namespace fwData
18 {
19 
25 class FWDATA_CLASS_API Float : public GenericField< float >
26 {
27 public:
28  fwCoreClassDefinitionsWithFactoryMacro( (Float)(::fwData::Object), ( ((const float)(0.0f)) ),
29  GenericFieldFactory< Float >);
30 
31  fwCampMakeFriendDataMacro((fwData)(Float));
32 
37  FWDATA_API Float( ::fwData::Object::Key key ) noexcept;
38 
42  FWDATA_API virtual ~Float() noexcept;
43 
45  FWDATA_API void shallowCopy( const Object::csptr& _source ) override;
46 
48  FWDATA_API void cachedDeepCopy(const Object::csptr& _source, DeepCopyCacheType& cache) override;
49 
50 protected:
51 
52  FWDATA_API Float() noexcept;
53 };
54 
55 } // namespace fwData
56 
57 #endif // __FWDATA_FLOAT_HPP__
Key class used to restrict access to Object construction. See http://www.drdobbs.com/184402053.
#define fwCoreClassDefinitionsWithFactoryMacro(_classinfo_, _parameters_, _factory_)
Generate common construction methods for classes with one factory.
Base class for each data object.
Contains the representation of the data objects used in the framework.
This class contains an float value.
Definition: Float.hpp:25