fw4spl
Abstract.hpp
1 /* ***** BEGIN LICENSE BLOCK *****
2  * FW4SPL - Copyright (C) IRCAD, 2009-2015.
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 __FWATOMSPATCH_CONDITIONS_ABSTRACT_HPP__
8 #define __FWATOMSPATCH_CONDITIONS_ABSTRACT_HPP__
9 
10 #include <fwCore/base.hpp>
11 
12 #include <fwAtoms/Base.hpp>
13 
14 #include "fwAtomsPatch/config.hpp"
15 
16 namespace fwAtomsPatch
17 {
18 namespace conditions
19 {
20 
25 class FWATOMSPATCH_CLASS_API Abstract : public ::fwCore::BaseObject
26 {
27 public:
30 
32  FWATOMSPATCH_API virtual ::fwAtoms::Base::sptr getDefaultValue();
33 
35  FWATOMSPATCH_API virtual bool test(::fwAtoms::Base::sptr old, ::fwAtoms::Base::sptr newValue);
36 
38  FWATOMSPATCH_API virtual bool test(::fwAtoms::Base::sptr old);
39 
40 protected:
41  Abstract()
42  {
43  }
44  Abstract(::fwAtoms::Base::sptr defaultValue);
45 
46  ::fwAtoms::Base::sptr m_defaultValue;
47  std::string m_message;
48 
49 };
50 
51 } // namespace conditions
52 
53 } // namespace fwAtomsPatch
54 
55 #endif /* __FWATOMSPATCH_CONDITIONS_ABSTRACT_HPP__ */
Base class for all FW4SPL&#39;s classes.
Definition: BaseObject.hpp:22
Contains functions used to control patching process by defining conditions on objects.
Definition: Abstract.hpp:18
Contains base functionalities used to transform objects from a version to another.
Definition: Abstract.hpp:16
#define fwCoreClassDefinitionsWithFactoryMacro(_classinfo_, _parameters_, _factory_)
Generate common construction methods for classes with one factory.
#define fwCoreAllowSharedFromThis()
Generate getSptr and getConstSptr methods.
Defines a condition in the patch.
Definition: Abstract.hpp:25