torc-master
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
EdifVersion.cpp
Go to the documentation of this file.
1 // Torc - Copyright 2011-2013 University of Southern California. All Rights Reserved.
2 // $HeadURL$
3 // $Id$
4 
5 // This program is free software: you can redistribute it and/or modify it under the terms of the
6 // GNU General Public License as published by the Free Software Foundation, either version 3 of the
7 // License, or (at your option) any later version.
8 //
9 // This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
10 // without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See
11 // the GNU General Public License for more details.
12 //
13 // You should have received a copy of the GNU General Public License along with this program. If
14 // not, see <http://www.gnu.org/licenses/>.
15 
16 #ifndef HAVE_CONFIG_H
17 #include "torc/generic/config.h"
18 #endif
19 
20 //BOOST
21 #ifdef GENOM_SERIALIZATION
22 #include <boost/archive/binary_iarchive.hpp>
23 #include <boost/archive/binary_oarchive.hpp>
24 #endif //GENOM_SERIALIZATION
26 
27 namespace torc {
28 namespace generic {
29 
30 EdifVersion::EdifVersion() : mFirst(2), mSecond(0), mThird(0) {}
31 
33 
35  mFirst(source.mFirst), mSecond(source.mSecond), mThird(source.mThird) {}
36 
38  if(this != &source) {
39  mFirst = source.mFirst;
40  mSecond = source.mSecond;
41  mThird = source.mThird;
42  }
43  return *this;
44 }
45 
46 #ifdef GENOM_SERIALIZATION
47 template <class Archive> void EdifVersion::serialize(Archive& ar, unsigned int) {
48  ar & mFirst;
49  ar & mSecond;
50  ar & mThird;
51 }
52 
53 //TO SATISFY THE LINKER
54 template void EdifVersion::serialize<boost::archive::binary_iarchive>(
55  boost::archive::binary_iarchive& ar, const unsigned int);
56 
57 template void EdifVersion::serialize<boost::archive::binary_oarchive>(
58  boost::archive::binary_oarchive& ar, const unsigned int);
59 
60 #endif //GENOM_SERIALIZATION
61 
62 } // namespace generic
63 } // namespace torc
EdifVersion & operator=(const EdifVersion &source)
Definition: EdifVersion.cpp:37