diff --git a/.gitignore b/.gitignore index 3235c3a..7d920ab 100644 --- a/.gitignore +++ b/.gitignore @@ -15,3 +15,5 @@ *.a.* /build /.vscode +.atom-build.cson +.atom-dbg.cson diff --git a/include/stringfield.h b/include/stringfield.h index b4836f4..f9dd7da 100644 --- a/include/stringfield.h +++ b/include/stringfield.h @@ -119,7 +119,7 @@ public: virtual size_t size() const override { // find out size of the size parameter - T size((T::Type)_data.size()); + T size(_data.size()); // size of the uint8 or uint32 + the actual string size return size.size() + _data.size(); @@ -160,7 +160,7 @@ public: virtual void fill(OutBuffer& buffer) const override { // create size - T size((T::Type)_data.size()); + T size(_data.size()); // first, write down the size of the string size.fill(buffer); @@ -210,4 +210,3 @@ typedef StringField LongString; * end namespace */ } - diff --git a/src/addressinfo.h b/src/tcpconnection/addressinfo.h similarity index 100% rename from src/addressinfo.h rename to src/tcpconnection/addressinfo.h diff --git a/src/tcpconnection/includes.h b/src/tcpconnection/includes.h index 2a10061..1b24322 100644 --- a/src/tcpconnection/includes.h +++ b/src/tcpconnection/includes.h @@ -1,12 +1,31 @@ /** * Includes.h * - * The includes that are necessary to compile the AMQP library + * The includes that are necessary to compile the optional TCP part of the AMQP library * This file also holds includes that may not be necessary for including the library * * @documentation private */ +#include "../includes.h" +// c and c++ dependencies +#include +#include +#include +#include +#include + +// utility classes +#include "../../include/tcpconnection/tcpdefines.h" + +// mid level includes +#include "../../include/tcpconnection/tcphandler.h" +#include "../../include/tcpconnection/tcpconnection.h" + +// classes that are very commonly used +#include "addressinfo.h" + +/* // c and c++ dependencies #include #include @@ -92,5 +111,4 @@ #include "basicframe.h" #include "transactionframe.h" #include "addressinfo.h" - - +*/ diff --git a/src/pipe.h b/src/tcpconnection/pipe.h similarity index 100% rename from src/pipe.h rename to src/tcpconnection/pipe.h