use own namespace

This commit is contained in:
john30
2017-01-14 16:41:54 +01:00
parent 7bd9446f13
commit 774e01e937
43 changed files with 196 additions and 48 deletions
+9 -2
View File
@@ -23,7 +23,13 @@
#include <vector>
#include "result.h"
using namespace std;
namespace ebusd {
using std::ostringstream;
using std::nouppercase;
using std::setw;
using std::hex;
using std::setfill;
/**
* CRC8 lookup table for the polynom 0x9b = x^8 + x^7 + x^4 + x^3 + x^1 + 1.
@@ -83,7 +89,7 @@ result_t SymbolString::parseHex(const string& str, const bool isEscaped) {
}
const string SymbolString::getDataStr(const bool unescape, const bool skipLastSymbol) {
stringstream sstr;
ostringstream sstr;
bool previousEscape = false;
for (size_t i = 0; i < m_data.size(); i++) {
@@ -255,3 +261,4 @@ bool isValidAddress(unsigned char addr, bool allowBroadcast) {
return addr != SYN && addr != ESC && (allowBroadcast || addr != BROADCAST);
}
} // namespace ebusd