CARMA C++
RxTypeInfo.h
Go to the documentation of this file.
1 
9 #ifndef CARMA_ANTENNA_COMMON_RXTYPEINFO_H
10 #define CARMA_ANTENNA_COMMON_RXTYPEINFO_H
11 
12 #include "carma/corba/corba.h"
13 
14 #include "carma/antenna/common/RxControl.h"
15 #include "carma/antenna/common/IFControl.h"
16 #include "carma/monitor/AntennaCommon.h"
17 #include "carma/monitor/AntennaIF.h"
18 
19 #include <string>
20 
21 namespace carma {
22 namespace antenna {
23 namespace common {
24 
32  class RxTypeInfo {
33  public:
34 
39 
43  /* virtual */ ~RxTypeInfo( );
44 
48  ::std::string rxAsString( ) const;
49 
50  static ::std::string stringFromRxType( const RxControl::Type rxType );
51 
56  rxAsRxControlType( ) const;
57 
62  unsigned short rxAsIfSwitchPosition( ) const;
63 
67  carma::monitor::AntennaIF::IfSwitchStatMonitorPointEnum::IFSWITCHSTAT
69 
73  carma::monitor::AntennaCommon::CurrentRxMonitorPointEnum::CURRENTRX
75 
76  static unsigned short
77  ifSwitchPositionFromRxType( const RxControl::Type rxType );
78 
79  private:
80 
81  const carma::antenna::common::RxControl::Type rxControlType_;
82 
83  const ::std::string rxName_;
84 
85  const
86  carma::monitor::AntennaCommon::CurrentRxMonitorPointEnum::CURRENTRX
87  currentRxMonitorPointEnum_;
88 
89  const
90  carma::monitor::AntennaIF::IfSwitchStatMonitorPointEnum::IFSWITCHSTAT
91  ifSwitchStatMonitorPointEnum_;
92 
93  const unsigned short ifSwitchPosition_;
94 
95  }; // End RxTypeInfo
96 
97 }}} // namespace carma::antenna::common
98 
99 // ====================Inline Implementation Follows ===========================
100 inline
101 ::std::string
103 {
104  return rxName_;
105 }
106 
107 inline
110 {
111  return rxControlType_;
112 }
113 
114 inline
115 unsigned short
117 {
118  return ifSwitchPosition_;
119 }
120 
121 inline
122 carma::monitor::AntennaCommon::CurrentRxMonitorPointEnum::CURRENTRX
124 {
125  return currentRxMonitorPointEnum_;
126 }
127 
128 inline
129 carma::monitor::AntennaIF::IfSwitchStatMonitorPointEnum::IFSWITCHSTAT
131 {
132  return ifSwitchStatMonitorPointEnum_;
133 }
134 #endif
carma::monitor::AntennaCommon::CurrentRxMonitorPointEnum::CURRENTRX rxAsCurrentRxMonitorPointEnum() const
Get receiver as AntennaCommon::CurrentMonitorPointEnum type.
Definition: RxTypeInfo.h:123
RxTypeInfo(carma::antenna::common::RxControl::Type rxType)
Constructor.
Type
Enumerate valid Receiver types.
Definition: RxControl.idl:36
unsigned short rxAsIfSwitchPosition() const
Return the IF Switch position (aka IF band) associated with this receiver.
Definition: RxTypeInfo.h:116
carma::antenna::common::RxControl::Type rxAsRxControlType() const
Return receiver as RxControl::Type type.
Definition: RxTypeInfo.h:109
Maps and provides conversions between the various receiver type definitions from the monitor system...
Definition: RxTypeInfo.h:32
::std::string rxAsString() const
Return receiver name as a string.
Definition: RxTypeInfo.h:102
carma::monitor::AntennaIF::IfSwitchStatMonitorPointEnum::IFSWITCHSTAT rxAsIfSwitchStatMonitorPointEnum() const
Get receiver as AntennaIF::IfSwitchStatMonitorPointEnum.
Definition: RxTypeInfo.h:130