Changeset 107:614b9ff033c1 in xplra for src/client/c/hu/varadiistvan/xplra/XPlane.h
- Timestamp:
- 12/15/22 19:26:40 (17 months ago)
- Branch:
- default
- Phase:
- public
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/client/c/hu/varadiistvan/xplra/XPlane.h
r87 r107 98 98 * yet. 99 99 */ 100 XPlane() throw();100 XPlane() noexcept; 101 101 102 102 /** … … 105 105 * become invalid. 106 106 */ 107 ~XPlane() throw();107 ~XPlane() noexcept; 108 108 109 109 /** 110 110 * Connect to the simulator. 111 111 */ 112 void connect() throw(IOException);112 void connect(); 113 113 114 114 /** 115 115 * Check if we are connected to the simulator. 116 116 */ 117 bool isConnected() const throw();117 bool isConnected() const noexcept; 118 118 119 119 /** 120 120 * Disconnect from the simulator. 121 121 */ 122 void disconnect() throw();122 void disconnect() noexcept; 123 123 124 124 /** … … 126 126 * to it. 127 127 */ 128 MultiGetter& createMultiGetter() throw();128 MultiGetter& createMultiGetter() noexcept; 129 129 130 130 /** … … 132 132 * to it. 133 133 */ 134 MultiSetter& createMultiSetter() throw();134 MultiSetter& createMultiSetter() noexcept; 135 135 136 136 /** … … 142 142 * @return if the buffer was found and could be destroyed 143 143 */ 144 bool destroyMultiBuffer(MultiBuffer& buffer) throw(Exception);144 bool destroyMultiBuffer(MultiBuffer& buffer); 145 145 146 146 /** 147 147 * Get the versions of X-Plane, XPLM and the XPLRA plugin. 148 148 */ 149 void getVersions(int& xplaneVersion, int& xplmVersion, int& xplraVersion) throw(Exception);149 void getVersions(int& xplaneVersion, int& xplmVersion, int& xplraVersion); 150 150 151 151 /** … … 153 153 * fails. 154 154 */ 155 void reloadPlugins() throw(Exception);155 void reloadPlugins(); 156 156 157 157 /** … … 159 159 * which is relative to the directory of X-Plane. 160 160 */ 161 void saveSituation(const char* path) throw(Exception);161 void saveSituation(const char* path); 162 162 163 163 /** 164 164 * Get the integer value of the dataref with the given name. 165 165 */ 166 int getInt(const char* name) throw(Exception);166 int getInt(const char* name); 167 167 168 168 /** 169 169 * Get a float value. 170 170 */ 171 float getFloat(const char* name) throw(Exception);171 float getFloat(const char* name); 172 172 173 173 /** 174 174 * Get a double value. 175 175 */ 176 double getDouble(const char* name) throw(Exception);176 double getDouble(const char* name); 177 177 178 178 /** … … 187 187 */ 188 188 size_t getFloatArray(const char* name, float* dest, 189 size_t length, size_t offset = 0) throw(Exception);189 size_t length, size_t offset = 0); 190 190 191 191 /** … … 198 198 */ 199 199 float* getFloatArray(const char* name, size_t& length, 200 size_t offset = 0) throw(Exception);200 size_t offset = 0); 201 201 202 202 /** … … 211 211 */ 212 212 size_t getIntArray(const char* name, int32_t* dest, 213 size_t length, size_t offset = 0) throw(Exception);213 size_t length, size_t offset = 0); 214 214 215 215 /** … … 222 222 */ 223 223 int32_t* getIntArray(const char* name, size_t& length, 224 size_t offset = 0) throw(Exception);224 size_t offset = 0); 225 225 226 226 /** … … 235 235 */ 236 236 size_t getByteArray(const char* name, uint8_t* dest, 237 size_t length, size_t offset = 0) throw(Exception);237 size_t length, size_t offset = 0); 238 238 239 239 /** … … 246 246 */ 247 247 uint8_t* getByteArray(const char* name, size_t& length, 248 size_t offset = 0) throw(Exception);248 size_t offset = 0); 249 249 250 250 /** 251 251 * Get a string. A string is a byte array. 252 252 */ 253 std::string getString(const char* name, size_t offset = 0) throw(Exception);253 std::string getString(const char* name, size_t offset = 0); 254 254 255 255 /** 256 256 * Set the given dataref to the given integer value. 257 257 */ 258 void setInt(const char* name, int value) throw(Exception);258 void setInt(const char* name, int value); 259 259 260 260 /** 261 261 * Set the given dataref to the given float value. 262 262 */ 263 void setFloat(const char* name, float value) throw(Exception);263 void setFloat(const char* name, float value); 264 264 265 265 /** 266 266 * Set the given dataref to the given double value. 267 267 */ 268 void setDouble(const char* name, double value) throw(Exception);268 void setDouble(const char* name, double value); 269 269 270 270 /** … … 272 272 */ 273 273 void setFloatArray(const char* name, const float* values, size_t length, 274 size_t offset = 0) throw(Exception);274 size_t offset = 0); 275 275 276 276 /** … … 278 278 */ 279 279 void setIntArray(const char* name, const int32_t* values, size_t length, 280 size_t offset = 0) throw(Exception);280 size_t offset = 0); 281 281 282 282 /** … … 284 284 */ 285 285 void setByteArray(const char* name, const uint8_t* values, size_t length, 286 size_t offset = 0) throw(Exception);286 size_t offset = 0); 287 287 288 288 /** … … 293 293 */ 294 294 void setString(const char* name, const char* value, size_t length, 295 size_t offset = 0) throw(Exception);295 size_t offset = 0); 296 296 297 297 /** 298 298 * Show a textual message for a certain duration. 299 299 */ 300 void showMessage(const char* message, float duration) throw(Exception);300 void showMessage(const char* message, float duration); 301 301 302 302 /** … … 304 304 * existing set of hotkeys registered, those will be overwritten. 305 305 */ 306 void registerHotkeys(const uint16_t* codes, size_t length) throw(Exception);306 void registerHotkeys(const uint16_t* codes, size_t length); 307 307 308 308 /** 309 309 * Query the registered hotkeys whether they were pressed. 310 310 */ 311 void queryHotkeys(uint8_t* states, size_t length) throw(Exception);311 void queryHotkeys(uint8_t* states, size_t length); 312 312 313 313 /** … … 320 320 * Check if we have a stream and if it has not failed. 321 321 */ 322 void checkStream() throw(NotConnectedException, IOException);322 void checkStream(); 323 323 324 324 /** … … 327 327 */ 328 328 void checkResult(uint8_t result, bool hasParameter = false, 329 long parameter = 0) throw(ProtocolException);329 long parameter = 0); 330 330 331 331 /** … … 334 334 * is some problem with the stream, an IOException is thrown. 335 335 */ 336 void checkResult(bool multi = false) throw(ProtocolException, IOException);336 void checkResult(bool multi = false); 337 337 338 338 /** … … 340 340 * also checked, but the value should be read by the caller. 341 341 */ 342 void getScalar(const char* name, uint8_t type) throw(Exception);342 void getScalar(const char* name, uint8_t type); 343 343 344 344 /** … … 350 350 */ 351 351 size_t getArray(const char* name, uint8_t type, 352 ssize_t length, size_t offset) throw(Exception);352 ssize_t length, size_t offset); 353 353 354 354 … … 356 356 * Issue the command to set a scalar value of the given type. 357 357 */ 358 void setScalar(const char* name, uint8_t type) throw(Exception);358 void setScalar(const char* name, uint8_t type); 359 359 360 360 /** … … 362 362 */ 363 363 void setArray(const char* name, uint8_t type, size_t length, 364 size_t offset) throw(Exception);364 size_t offset); 365 365 366 366 friend class MultiBuffer; … … 373 373 //------------------------------------------------------------------------------ 374 374 375 inline XPlane::XPlane() throw():375 inline XPlane::XPlane() noexcept : 376 376 socket(0), 377 377 stream(0) … … 381 381 //------------------------------------------------------------------------------ 382 382 383 inline bool XPlane::isConnected() const throw()383 inline bool XPlane::isConnected() const noexcept 384 384 { 385 385 return socket!=0;
Note:
See TracChangeset
for help on using the changeset viewer.