00001
00002
00003 #ifndef _ChannelMapping_0_SCTDAL_0__H_
00004 #define _ChannelMapping_0_SCTDAL_0__H_
00005
00006 #include <iostream>
00007 #include <string>
00008 #include <map>
00009 #include <vector>
00010
00011 #include <config/Configuration.h>
00012 #include <config/DalObject.h>
00013
00014
00015
00016 namespace SCTDAL {
00021 class ChannelMapping : public virtual ::DalObject {
00022
00023 friend class ::Configuration;
00024
00025 public:
00026
00027 ChannelMapping(::Configuration& conf, ::ConfigObject& obj);
00028 virtual ~ChannelMapping();
00029
00037 static ChannelMapping * create(::Configuration& conf, const std::string& id = "");
00038
00044 bool destroy(::Configuration& conf);
00045
00046
00047 public:
00048
00049 static const std::string s_class_name;
00050 virtual void init(bool init_children);
00051
00052
00053 private:
00054
00055 void check_init() const {if(!p_was_read) const_cast<ChannelMapping*>(this)->init(false);}
00056 static void update(::Configuration& conf, const ::ConfigurationChange * change);
00057 static void reset(::Configuration& conf, bool re_initialise_obj);
00058
00059
00060 public:
00061
00062 virtual void print(unsigned int, bool, std::ostream&) const;
00063
00064
00065 private:
00066
00067 unsigned short m_outputFibre;
00068 unsigned short m_stream0Fibre;
00069 unsigned short m_stream1Fibre;
00070
00071
00072 public:
00073
00078 unsigned short get_outputFibre() const { check_init(); return m_outputFibre; }
00079 unsigned short outputFibre() const { check_init(); return m_outputFibre; }
00080
00085 bool set_outputFibre(unsigned short value) { clear(); return p_obj.set_by_val("outputFibre", value); }
00086
00091 unsigned short get_stream0Fibre() const { check_init(); return m_stream0Fibre; }
00092 unsigned short stream0Fibre() const { check_init(); return m_stream0Fibre; }
00093
00098 bool set_stream0Fibre(unsigned short value) { clear(); return p_obj.set_by_val("stream0Fibre", value); }
00099
00104 unsigned short get_stream1Fibre() const { check_init(); return m_stream1Fibre; }
00105 unsigned short stream1Fibre() const { check_init(); return m_stream1Fibre; }
00106
00111 bool set_stream1Fibre(unsigned short value) { clear(); return p_obj.set_by_val("stream1Fibre", value); }
00112
00113 };
00114
00115
00116
00117 std::ostream& operator<<(std::ostream&, const ChannelMapping*);
00118 std::ostream& operator<<(std::ostream&, const ChannelMapping&);
00119
00120 typedef std::vector<const ChannelMapping*>::const_iterator ChannelMappingIterator;
00121
00122 }
00123
00124 #endif