Changeset View
Changeset View
Standalone View
Standalone View
ksgrd/SensorManager.h
Show First 20 Lines • Show All 72 Lines • ▼ Show 20 Line(s) | 53 | public: | |||
---|---|---|---|---|---|
73 | /* Returns true if we are connected or trying to connect to the host given | 73 | /* Returns true if we are connected or trying to connect to the host given | ||
74 | */ | 74 | */ | ||
75 | bool isConnected( const QString &hostName ); | 75 | bool isConnected( const QString &hostName ); | ||
76 | bool disengage( SensorAgent *agent ); | 76 | bool disengage( SensorAgent *agent ); | ||
77 | bool disengage( const QString &hostName ); | 77 | bool disengage( const QString &hostName ); | ||
78 | bool resynchronize( const QString &hostName ); | 78 | bool resynchronize( const QString &hostName ); | ||
79 | void notify( const QString &msg ) const; | 79 | void notify( const QString &msg ) const; | ||
80 | 80 | | |||
81 | void setBroadcaster( QWidget *wdg ); | 81 | void setBroadcaster( QObject *wdg ); | ||
82 | 82 | | |||
83 | bool sendRequest( const QString &hostName, const QString &request, | 83 | bool sendRequest( const QString &hostName, const QString &request, | ||
84 | SensorClient *client, int id = 0 ); | 84 | SensorClient *client, int id = 0 ); | ||
85 | 85 | | |||
86 | const QString hostName( const SensorAgent *sensor ) const; | 86 | const QString hostName( const SensorAgent *sensor ) const; | ||
87 | bool hostInfo( const QString &host, QString &shell, | 87 | bool hostInfo( const QString &host, QString &shell, | ||
88 | QString &command, int &port ); | 88 | QString &command, int &port ); | ||
89 | 89 | | |||
Show All 29 Lines | 113 | private: | |||
119 | QHash<QString, QString> mUnits; | 119 | QHash<QString, QString> mUnits; | ||
120 | QHash<QString, QString> mDict; | 120 | QHash<QString, QString> mDict; | ||
121 | QHash<QString, QString> mTypes; | 121 | QHash<QString, QString> mTypes; | ||
122 | 122 | | |||
123 | /** Store the data from the config file to pass to the MostConnector dialog box*/ | 123 | /** Store the data from the config file to pass to the MostConnector dialog box*/ | ||
124 | QStringList mHostList; | 124 | QStringList mHostList; | ||
125 | QStringList mCommandList; | 125 | QStringList mCommandList; | ||
126 | 126 | | |||
127 | QPointer<QWidget> mBroadcaster; | 127 | QPointer<QObject> mBroadcaster; | ||
128 | }; | 128 | }; | ||
129 | 129 | | |||
130 | Q_DECL_EXPORT extern SensorManager* SensorMgr; | 130 | Q_DECL_EXPORT extern SensorManager* SensorMgr; | ||
131 | 131 | | |||
132 | class Q_DECL_EXPORT SensorManagerIterator : public QHashIterator<QString, SensorAgent*> | 132 | class Q_DECL_EXPORT SensorManagerIterator : public QHashIterator<QString, SensorAgent*> | ||
133 | { | 133 | { | ||
134 | public: | 134 | public: | ||
135 | explicit SensorManagerIterator( const SensorManager *sm ) | 135 | explicit SensorManagerIterator( const SensorManager *sm ) | ||
136 | : QHashIterator<QString, SensorAgent*>( sm->mAgents ) { } | 136 | : QHashIterator<QString, SensorAgent*>( sm->mAgents ) { } | ||
137 | 137 | | |||
138 | ~SensorManagerIterator() { } | 138 | ~SensorManagerIterator() { } | ||
139 | }; | 139 | }; | ||
140 | 140 | | |||
141 | } | 141 | } | ||
142 | 142 | | |||
143 | #endif | 143 | #endif |