00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016 #include "torc/generic/om/DumpRestoreConfig.hpp"
00017
00018 #ifndef HAVE_CONFIG_H
00019 #include "torc/generic/config.h"
00020 #endif
00021
00022 #ifdef GENOM_SERIALIZATION
00023 #include <boost/archive/binary_iarchive.hpp>
00024 #include <boost/archive/binary_oarchive.hpp>
00025 #include <boost/serialization/string.hpp>
00026 #endif //GENOM_SERIALIZATION
00027
00028 #include "torc/generic/om/PortDelay.hpp"
00029
00030 namespace torc {
00031
00032 namespace generic {
00033
00034 void
00035 PortDelay::setDerivation(
00036 const Derivation & inSource) throw() {
00037 mDerivation = inSource;
00038 }
00039
00040 void
00041 PortDelay::setType(Type inSource) throw() {
00042 mType = inSource;
00043 }
00044
00045 void
00046 PortDelay::setDelay(
00047 const Value::MiNoMax & inSource) throw() {
00048 mDelay = inSource;
00049 }
00050
00051 void
00052 PortDelay::setAcLoad(const Value::MiNoMax & inSource) throw() {
00053 mAcLoad = inSource;
00054 }
00055
00056 void
00057 PortDelay::setTransition( const LogicElementSharedPtr & inSource ) throw() {
00058 mTransition = inSource;
00059 }
00060
00061 PortDelay::PortDelay()
00062 :mDerivation( eDerivationUndefined ),
00063 mType( eTypeDelay ),
00064 mDelay(),
00065 mAcLoad(),
00066 mTransition() {
00067 }
00068
00069 PortDelay::~PortDelay() throw() {
00070 }
00071
00072 PortDelay::PortDelay(const PortDelay & source)
00073 :mDerivation( source.mDerivation ),
00074 mType( source.mType ),
00075 mDelay( source.mDelay ),
00076 mAcLoad( source.mAcLoad ),
00077 mTransition( source.mTransition ) {
00078 }
00079
00080 PortDelay &
00081 PortDelay::operator=(const PortDelay & source) throw() {
00082 if( this != &source )
00083 {
00084 mDerivation = source.mDerivation;
00085 mType = source.mType;
00086 mDelay = source.mDelay;
00087 mAcLoad = source.mAcLoad;
00088 mTransition = source.mTransition;
00089 }
00090 return *this;
00091 }
00092
00093 #ifdef GENOM_SERIALIZATION
00094 template<class Archive> void
00095 PortDelay::serialize( Archive &ar, unsigned int ) {
00096 ar & mDerivation;
00097 ar & mType;
00098 ar & mDelay;
00099 ar & mAcLoad;
00100 ar & mTransition;
00101 }
00102
00103
00104 template void
00105 PortDelay::serialize<boost::archive::binary_iarchive>(
00106 boost::archive::binary_iarchive & ar, const unsigned int);
00107
00108 template void
00109 PortDelay::serialize<boost::archive::binary_oarchive>(
00110 boost::archive::binary_oarchive & ar, const unsigned int);
00111
00112 #endif //GENOM_SERIALIZATION
00113
00114
00115 }
00116
00117 }