diff options
author | Maksym Telychko <maksym.telychko@globallogic.com> | 2019-06-10 11:27:27 +0300 |
---|---|---|
committer | Maksym Telychko <maksym.telychko@globallogic.com> | 2019-06-10 11:27:27 +0300 |
commit | 5a7d8772ea898b3567685431b5a6be13015e5887 (patch) | |
tree | 96084a4cc149322d18d0adea52b5c85e952e314e /include | |
parent | 596f8f8393bf837d73e0a62c87d52557d9191f96 (diff) | |
download | libmts-io-5a7d8772ea898b3567685431b5a6be13015e5887.tar.gz libmts-io-5a7d8772ea898b3567685431b5a6be13015e5887.tar.bz2 libmts-io-5a7d8772ea898b3567685431b5a6be13015e5887.zip |
[MTS-MTQ] refactoring: static function moved to ICellularRadio
Diffstat (limited to 'include')
-rw-r--r-- | include/mts/MTS_IO_CellularRadio.h | 15 | ||||
-rw-r--r-- | include/mts/MTS_IO_ICellularRadio.h | 17 |
2 files changed, 17 insertions, 15 deletions
diff --git a/include/mts/MTS_IO_CellularRadio.h b/include/mts/MTS_IO_CellularRadio.h index e79e6d1..0410e0d 100644 --- a/include/mts/MTS_IO_CellularRadio.h +++ b/include/mts/MTS_IO_CellularRadio.h @@ -109,27 +109,12 @@ namespace MTS { const char& ESC = CR) override; - static std::string sendCommand(MTS::AutoPtr<MTS::IO::Connection>& apIo, - const std::string& sCmd, - const std::vector<std::string>& vBail = DEFAULT_BAIL_STRINGS, - int32_t timeoutMillis = 100, - const char& ESC = CR); std::string sendCommand(const std::string& sCmd, IsNeedMoreData& isNeedMoreData, int32_t timeoutMillis = 100, const char& ESC = CR) override; - static std::string sendCommand(MTS::AutoPtr<MTS::IO::Connection>& apIo, - const std::string& sCmd, - IsNeedMoreData& isNeedMoreData, - int32_t timeoutMillis = 100, - const char& ESC = CR); - - static CODE test(MTS::AutoPtr<MTS::IO::Connection>& apIo, uint32_t timeoutSeconds = 30); - - static std::string extractModelFromResult(const std::string& sResult); - static std::string getCodeAsString(CODE code); protected: diff --git a/include/mts/MTS_IO_ICellularRadio.h b/include/mts/MTS_IO_ICellularRadio.h index ff8383c..3ab8b7e 100644 --- a/include/mts/MTS_IO_ICellularRadio.h +++ b/include/mts/MTS_IO_ICellularRadio.h @@ -7,6 +7,9 @@ #include <json/json.h> +#include <mts/MTS_AutoPtr.h> +#include <mts/MTS_IO_SerialConnection.h> + #define EXPORT __attribute__((visibility("default"))) namespace MTS { @@ -62,6 +65,20 @@ namespace MTS { static CODE convertModelToMtsShortCode(const std::string& sModel, std::string& sCode, ICellularRadio *radioObj = NULL); static CODE convertServiceDomainToString(SERVICEDOMAIN eSd, std::string& sSd); static CODE convertActiveBandToString(ACTIVEBAND eBand, std::string& sBand); + + static std::string sendCommand(MTS::AutoPtr<MTS::IO::Connection>& apIo, + const std::string& sCmd, + IsNeedMoreData& isNeedMoreData, + int32_t timeoutMillis = 100, + const char& ESC = CR); + static std::string sendCommand(MTS::AutoPtr<MTS::IO::Connection>& apIo, + const std::string& sCmd, + const std::vector<std::string>& vBail = DEFAULT_BAIL_STRINGS, + int32_t timeoutMillis = 100, + const char& ESC = CR); + static CODE test(MTS::AutoPtr<MTS::IO::Connection>& apIo, uint32_t timeoutSeconds = 30); + static std::string extractModelFromResult(const std::string& sResult); + static std::string getCodeAsString(CODE code); // XXX static const std::string DEFAULT_RADIO_PORT; |