fw4spl
Map.cpp
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 #include "fwAtoms/Map.hpp"
8 #include "fwAtoms/registry/macros.hpp"
9 
10 fwAtomsRegisterMacro( ::fwAtoms::Map );
11 
12 namespace fwAtoms
13 {
14 
15 //------------------------------------------------------------------------------
16 
17 Base::sptr Map::clone() const
18 {
19  Map::sptr cloneMap = Map::New();
20  for(const ValueType &elem : m_value)
21  {
22  cloneMap->m_value.insert( ValueType(elem.first, elem.second->clone() ) );
23  }
24  return cloneMap;
25 }
26 
27 }
28 
fwAtoms contains basic objects to represent any other kind of object
Map is a container for mapping representation.
Definition: Map.hpp:31
virtual FWATOMS_API Base::sptr clone() const override
Returns a clone object.
Definition: Map.cpp:17