Browse Source

Fixed GCC compilation issues

release/0.19
Jessica James 6 years ago
parent
commit
efaae087a6
  1. 2
      .gitignore
  2. 4
      src/common/DataBuffer.cpp
  3. 4
      src/common/Database.cpp
  4. 4
      src/common/File.cpp
  5. 2
      src/common/Plugin.cpp
  6. 4
      src/common/Socket.cpp
  7. 24
      src/include/CString.h
  8. 59
      src/include/CString_Imp.h
  9. 60
      src/include/DataBuffer_Imp.h
  10. 12
      src/include/Hash_Table_Imp.h
  11. 8
      src/include/Readable_String.h
  12. 16
      src/include/Readable_String_Imp.h
  13. 12
      src/include/Reference_String.h
  14. 34
      src/include/Reference_String_Imp.h
  15. 2
      src/include/SecureSocket.h
  16. 10
      src/include/Socket.h
  17. 24
      src/include/String.hpp
  18. 24
      src/include/String_Imp.h
  19. 4
      src/include/TCPSocket.h
  20. 2
      src/include/UDPSocket.h

2
.gitignore

@ -1,3 +1,5 @@
.idea/
## Ignore Visual Studio temporary files, build results, and ## Ignore Visual Studio temporary files, build results, and
## files generated by popular Visual Studio add-ons. ## files generated by popular Visual Studio add-ons.

4
src/common/DataBuffer.cpp

@ -17,6 +17,7 @@
*/ */
#include <cstdlib> #include <cstdlib>
#include <cstring>
#include "DataBuffer.h" #include "DataBuffer.h"
#include "Reference_String.h" #include "Reference_String.h"
@ -126,7 +127,8 @@ void Jupiter::DataBuffer::pop_from(FILE *file, size_t size_)
void Jupiter::DataBuffer::copy_to(FILE *file) void Jupiter::DataBuffer::copy_to(FILE *file)
{ {
fwrite(std::addressof<const size_t>(Jupiter::DataBuffer::size()), sizeof(size_t), 1, file); size_t data_size = Jupiter::DataBuffer::size();
fwrite(&data_size, sizeof(size_t), 1, file);
Jupiter::DataBuffer::copy_to(file, Jupiter::DataBuffer::size()); Jupiter::DataBuffer::copy_to(file, Jupiter::DataBuffer::size());
} }

4
src/common/Database.cpp

@ -17,6 +17,7 @@
*/ */
#include "Database.h" #include "Database.h"
#include <cstring>
struct Jupiter::Database::Data struct Jupiter::Database::Data
{ {
@ -151,7 +152,8 @@ bool Jupiter::Database::append(const char *file, Jupiter::DataBuffer &data)
bool Jupiter::Database::append(FILE *file, Jupiter::DataBuffer &data) bool Jupiter::Database::append(FILE *file, Jupiter::DataBuffer &data)
{ {
fwrite(std::addressof<const size_t>(data.size()), sizeof(size_t), 1, file); size_t data_size = data.size();
fwrite(&data_size, sizeof(size_t), 1, file);
fwrite(data.getHead(), sizeof(uint8_t), data.size(), file); fwrite(data.getHead(), sizeof(uint8_t), data.size(), file);
return true; return true;
} }

4
src/common/File.cpp

@ -41,8 +41,8 @@ int64_t getFileSize(const char *file)
const size_t defaultBufferSize = 8192; const size_t defaultBufferSize = 8192;
template class JUPITER_API Jupiter::CString_Type<char>; //template class JUPITER_API Jupiter::CString_Type<char>;
template class JUPITER_API Jupiter::ArrayList<Jupiter::StringS>; //template class JUPITER_API Jupiter::ArrayList<Jupiter::StringS>;
struct JUPITER_API Jupiter::File::Data struct JUPITER_API Jupiter::File::Data
{ {

2
src/common/Plugin.cpp

@ -57,7 +57,7 @@ dlib::~dlib()
#if defined _WIN32 #if defined _WIN32
FreeLibrary(dlib::lib); FreeLibrary(dlib::lib);
#else // _WIN32 #else // _WIN32
dlclose(dllib::lib); dlclose(dlib::lib);
#endif // _WIN32 #endif // _WIN32
} }
} }

4
src/common/Socket.cpp

@ -416,7 +416,7 @@ Jupiter::StringS Jupiter::Socket::ntop(void *ip, size_t size)
Jupiter::Socket *Jupiter::Socket::accept() Jupiter::Socket *Jupiter::Socket::accept()
{ {
sockaddr addr; sockaddr addr;
int size = sizeof(addr); socklen_t size = sizeof(addr);
SocketType tSock = ::accept(Socket::data_->rawSock, &addr, &size); SocketType tSock = ::accept(Socket::data_->rawSock, &addr, &size);
if (tSock != INVALID_SOCKET) if (tSock != INVALID_SOCKET)
{ {
@ -482,7 +482,7 @@ bool Jupiter::Socket::getBlockingMode() const
#if defined _WIN32 #if defined _WIN32
return !Jupiter::Socket::data_->blockMode; return !Jupiter::Socket::data_->blockMode;
#else // _WIN32 #else // _WIN32
int flags = fcntl(sock_fd, F_GETFL, 0); int flags = fcntl(data_->rawSock, F_GETFL, 0);
if (flags == -1) return false; if (flags == -1) return false;
return !(flags & O_NONBLOCK); return !(flags & O_NONBLOCK);
#endif #endif

24
src/include/CString.h

@ -190,9 +190,9 @@ namespace Jupiter
* @param separator Separator to split tokens by * @param separator Separator to split tokens by
* @return TokenizeResult containing the results of the tokenization process. * @return TokenizeResult containing the results of the tokenization process.
*/ */
Jupiter::Readable_String<T>::TokenizeResult<Jupiter::CString_Type> tokenize(const T &separator) const; typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::CString_Type> tokenize(const T &separator) const;
Jupiter::Readable_String<T>::TokenizeResult<Jupiter::CString_Type> tokenize(const Jupiter::Readable_String<T> &separator) const; typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::CString_Type> tokenize(const Jupiter::Readable_String<T> &separator) const;
Jupiter::Readable_String<T>::TokenizeResult<Jupiter::CString_Type> tokenize(const T *separator, size_t separator_size) const; typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::CString_Type> tokenize(const T *separator, size_t separator_size) const;
/** /**
* @brief Tokenizes a string, based on an input token separator * @brief Tokenizes a string, based on an input token separator
@ -201,9 +201,9 @@ namespace Jupiter
* @param separator Separator to split tokens by * @param separator Separator to split tokens by
* @return TokenizeResult containing the results of the tokenization process. * @return TokenizeResult containing the results of the tokenization process.
*/ */
static Jupiter::Readable_String<T>::TokenizeResult<Jupiter::CString_Type> tokenize(const Jupiter::Readable_String<T> &in, const T &separator); static typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::CString_Type> tokenize(const Jupiter::Readable_String<T> &in, const T &separator);
static Jupiter::Readable_String<T>::TokenizeResult<Jupiter::CString_Type> tokenize(const Jupiter::Readable_String<T> &in, const Jupiter::Readable_String<T> &separator); static typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::CString_Type> tokenize(const Jupiter::Readable_String<T> &in, const Jupiter::Readable_String<T> &separator);
static Jupiter::Readable_String<T>::TokenizeResult<Jupiter::CString_Type> tokenize(const Jupiter::Readable_String<T> &in, const T *separator, size_t separator_size); static typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::CString_Type> tokenize(const Jupiter::Readable_String<T> &in, const T *separator, size_t separator_size);
/** /**
* @brief Copies the data from the input string to the CString. * @brief Copies the data from the input string to the CString.
@ -425,9 +425,9 @@ namespace Jupiter
* @param separator Separator to split tokens by * @param separator Separator to split tokens by
* @return TokenizeResult containing the results of the tokenization process. * @return TokenizeResult containing the results of the tokenization process.
*/ */
Jupiter::Readable_String<T>::TokenizeResult<Jupiter::CString_Loose> tokenize(const T &separator); typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::CString_Loose> tokenize(const T &separator);
Jupiter::Readable_String<T>::TokenizeResult<Jupiter::CString_Loose> tokenize(const Jupiter::Readable_String<T> &separator); typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::CString_Loose> tokenize(const Jupiter::Readable_String<T> &separator);
Jupiter::Readable_String<T>::TokenizeResult<Jupiter::CString_Loose> tokenize(const T *separator, size_t separator_size); typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::CString_Loose> tokenize(const T *separator, size_t separator_size);
/** /**
* @brief Tokenizes a string, based on an input token separator * @brief Tokenizes a string, based on an input token separator
@ -436,9 +436,9 @@ namespace Jupiter
* @param separator Separator to split tokens by * @param separator Separator to split tokens by
* @return TokenizeResult containing the results of the tokenization process. * @return TokenizeResult containing the results of the tokenization process.
*/ */
static Jupiter::Readable_String<T>::TokenizeResult<Jupiter::CString_Loose> tokenize(const Jupiter::Readable_String<T> &in, const T &separator); static typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::CString_Loose> tokenize(const Jupiter::Readable_String<T> &in, const T &separator);
static Jupiter::Readable_String<T>::TokenizeResult<Jupiter::CString_Loose> tokenize(const Jupiter::Readable_String<T> &in, const Jupiter::Readable_String<T> &separator); static typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::CString_Loose> tokenize(const Jupiter::Readable_String<T> &in, const Jupiter::Readable_String<T> &separator);
static Jupiter::Readable_String<T>::TokenizeResult<Jupiter::CString_Loose> tokenize(const Jupiter::Readable_String<T> &in, const T *separator, size_t separator_size); static typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::CString_Loose> tokenize(const Jupiter::Readable_String<T> &in, const T *separator, size_t separator_size);
/** /**
* @brief Sets the internal buffer to be at least large enough to old a specified number of elements. * @brief Sets the internal buffer to be at least large enough to old a specified number of elements.

59
src/include/CString_Imp.h

@ -27,6 +27,7 @@
#include "Functions.h" #include "Functions.h"
#include "CString.h" #include "CString.h"
#include "String.hpp"
#if !defined va_copy #if !defined va_copy
@ -322,7 +323,7 @@ template<typename T> Jupiter::CString_Type<T> Jupiter::CString_Type<T>::substrin
template<typename T> Jupiter::CString_Type<T> Jupiter::CString_Type<T>::substring(const T *in, size_t pos) template<typename T> Jupiter::CString_Type<T> Jupiter::CString_Type<T>::substring(const T *in, size_t pos)
{ {
Jupiter::CString_Type<T> r = Jupiter::String_Type<T>::substring<Jupiter::CString_Type>(in, pos); Jupiter::CString_Type<T> r = Jupiter::String_Type<T>::template substring<Jupiter::CString_Type>(in, pos);
r.str[r.length] = 0; r.str[r.length] = 0;
return r; return r;
} }
@ -338,7 +339,7 @@ template<typename T> Jupiter::CString_Type<T> Jupiter::CString_Type<T>::substrin
template<typename T> Jupiter::CString_Type<T> Jupiter::CString_Type<T>::substring(const T *in, size_t pos, size_t len) template<typename T> Jupiter::CString_Type<T> Jupiter::CString_Type<T>::substring(const T *in, size_t pos, size_t len)
{ {
Jupiter::CString_Type<T> r = Jupiter::String_Type<T>::substring<Jupiter::CString_Type>(in, pos, len); Jupiter::CString_Type<T> r = Jupiter::String_Type<T>::template substring<Jupiter::CString_Type>(in, pos, len);
r.str[r.length] = 0; r.str[r.length] = 0;
return r; return r;
} }
@ -352,12 +353,12 @@ template<typename T> Jupiter::CString_Type<T> Jupiter::CString_Type<T>::getWord(
template<typename T> Jupiter::CString_Type<T> Jupiter::CString_Type<T>::getWord(const Jupiter::Readable_String<T> &in, size_t pos, const T *whitespace) template<typename T> Jupiter::CString_Type<T> Jupiter::CString_Type<T>::getWord(const Jupiter::Readable_String<T> &in, size_t pos, const T *whitespace)
{ {
return Jupiter::Readable_String<T>::getWord<Jupiter::CString_Type>(in, pos, whitespace); return Jupiter::Readable_String<T>::template getWord<Jupiter::CString_Type>(in, pos, whitespace);
} }
template<typename T> Jupiter::CString_Type<T> Jupiter::CString_Type<T>::getWord(const T *in, size_t pos, const T *whitespace) template<typename T> Jupiter::CString_Type<T> Jupiter::CString_Type<T>::getWord(const T *in, size_t pos, const T *whitespace)
{ {
return Jupiter::Readable_String<T>::getWord<Jupiter::CString_Type>(in, pos, whitespace); return Jupiter::Readable_String<T>::template getWord<Jupiter::CString_Type>(in, pos, whitespace);
} }
// gotoWord // gotoWord
@ -369,39 +370,39 @@ template<typename T> Jupiter::CString_Type<T> Jupiter::CString_Type<T>::gotoWord
template<typename T> Jupiter::CString_Type<T> Jupiter::CString_Type<T>::gotoWord(const Jupiter::Readable_String<T> &in, size_t pos, const T *whitespace) template<typename T> Jupiter::CString_Type<T> Jupiter::CString_Type<T>::gotoWord(const Jupiter::Readable_String<T> &in, size_t pos, const T *whitespace)
{ {
return Jupiter::Readable_String<T>::gotoWord<Jupiter::CString_Type>(in, pos, whitespace); return Jupiter::Readable_String<T>::template gotoWord<Jupiter::CString_Type>(in, pos, whitespace);
} }
// tokenize // tokenize
template<typename T> typename Jupiter::Readable_String<T>::TokenizeResult<Jupiter::CString_Type> Jupiter::CString_Type<T>::tokenize(const T &separator) const template<typename T> typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::CString_Type> Jupiter::CString_Type<T>::tokenize(const T &separator) const
{ {
return Jupiter::CString_Type<T>::tokenize(*this, separator); return Jupiter::CString_Type<T>::tokenize(*this, separator);
} }
template<typename T> typename Jupiter::Readable_String<T>::TokenizeResult<Jupiter::CString_Type> Jupiter::CString_Type<T>::tokenize(const Jupiter::Readable_String<T> &separator) const template<typename T> typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::CString_Type> Jupiter::CString_Type<T>::tokenize(const Jupiter::Readable_String<T> &separator) const
{ {
return Jupiter::CString_Type<T>::tokenize(*this, separator); return Jupiter::CString_Type<T>::tokenize(*this, separator);
} }
template<typename T> typename Jupiter::Readable_String<T>::TokenizeResult<Jupiter::CString_Type> Jupiter::CString_Type<T>::tokenize(const T *separator, size_t separator_size) const template<typename T> typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::CString_Type> Jupiter::CString_Type<T>::tokenize(const T *separator, size_t separator_size) const
{ {
return Jupiter::CString_Type<T>::tokenize(*this, separator, separator_size); return Jupiter::CString_Type<T>::tokenize(*this, separator, separator_size);
} }
template<typename T> typename Jupiter::Readable_String<T>::TokenizeResult<Jupiter::CString_Type> Jupiter::CString_Type<T>::tokenize(const Jupiter::Readable_String<T> &in, const T &token) template<typename T> typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::CString_Type> Jupiter::CString_Type<T>::tokenize(const Jupiter::Readable_String<T> &in, const T &token)
{ {
return typename Jupiter::template Readable_String<T>::template tokenize<typename Jupiter::template CString_Type>(in, token); return typename Jupiter::template Readable_String<T>::template tokenize<typename Jupiter::template CString_Type<T>>(in, token);
} }
template<typename T> typename Jupiter::Readable_String<T>::TokenizeResult<Jupiter::CString_Type> Jupiter::CString_Type<T>::tokenize(const Jupiter::Readable_String<T> &in, const Jupiter::Readable_String<T> &separator) template<typename T> typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::CString_Type> Jupiter::CString_Type<T>::tokenize(const Jupiter::Readable_String<T> &in, const Jupiter::Readable_String<T> &separator)
{ {
return typename Jupiter::template Readable_String<T>::template tokenize<typename Jupiter::template CString_Type>(in, separator); return typename Jupiter::template Readable_String<T>::template tokenize<typename Jupiter::template CString_Type<T>>(in, separator);
} }
template<typename T> typename Jupiter::Readable_String<T>::TokenizeResult<Jupiter::CString_Type> Jupiter::CString_Type<T>::tokenize(const Jupiter::Readable_String<T> &in, const T *separator, size_t separator_size) template<typename T> typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::CString_Type> Jupiter::CString_Type<T>::tokenize(const Jupiter::Readable_String<T> &in, const T *separator, size_t separator_size)
{ {
return typename Jupiter::template Readable_String<T>::template tokenize<typename Jupiter::template CString_Type>(in, separator, separator_size); return typename Jupiter::template Readable_String<T>::template tokenize<typename Jupiter::template CString_Type<T>>(in, separator, separator_size);
} }
// set // set
@ -480,7 +481,7 @@ template<typename T> size_t Jupiter::CString_Type<T>::concat(const T &in)
template<typename T> inline Jupiter::CString_Type<T> Jupiter::CString_Type<T>::operator+(const T &rhs) const template<typename T> inline Jupiter::CString_Type<T> Jupiter::CString_Type<T>::operator+(const T &rhs) const
{ {
return Jupiter::operator+(*this, rhs); return Jupiter::template operator+<T>(*this, rhs);
} }
template<typename T> inline Jupiter::CString_Type<T> Jupiter::CString_Type<T>::operator+(const Jupiter::CString_Type<T> &rhs) const template<typename T> inline Jupiter::CString_Type<T> Jupiter::CString_Type<T>::operator+(const Jupiter::CString_Type<T> &rhs) const
@ -780,7 +781,7 @@ template<typename T> Jupiter::CString_Loose<T> Jupiter::CString_Loose<T>::substr
template<typename T> Jupiter::CString_Loose<T> Jupiter::CString_Loose<T>::substring(const T *in, size_t pos) template<typename T> Jupiter::CString_Loose<T> Jupiter::CString_Loose<T>::substring(const T *in, size_t pos)
{ {
Jupiter::CString_Loose<T> r = Jupiter::String_Type<T>::substring<Jupiter::CString_Loose>(in, pos); Jupiter::CString_Loose<T> r = Jupiter::String_Type<T>::template substring<Jupiter::CString_Loose>(in, pos);
r.str[r.length] = 0; r.str[r.length] = 0;
return r; return r;
} }
@ -796,7 +797,7 @@ template<typename T> Jupiter::CString_Loose<T> Jupiter::CString_Loose<T>::substr
template<typename T> Jupiter::CString_Loose<T> Jupiter::CString_Loose<T>::substring(const T *in, size_t pos, size_t len) template<typename T> Jupiter::CString_Loose<T> Jupiter::CString_Loose<T>::substring(const T *in, size_t pos, size_t len)
{ {
Jupiter::CString_Loose<T> r = Jupiter::String_Type<T>::substring<Jupiter::CString_Loose>(in, pos, len); Jupiter::CString_Loose<T> r = Jupiter::String_Type<T>::template substring<Jupiter::CString_Loose>(in, pos, len);
r.str[r.length] = 0; r.str[r.length] = 0;
return r; return r;
} }
@ -808,12 +809,12 @@ template<typename T> Jupiter::CString_Loose<T> Jupiter::CString_Loose<T>::getWor
template<typename T> Jupiter::CString_Loose<T> Jupiter::CString_Loose<T>::getWord(const Jupiter::Readable_String<T> &in, size_t pos, const T *whitespace) template<typename T> Jupiter::CString_Loose<T> Jupiter::CString_Loose<T>::getWord(const Jupiter::Readable_String<T> &in, size_t pos, const T *whitespace)
{ {
return Jupiter::Readable_String<T>::getWord<Jupiter::CString_Loose>(in, pos, whitespace); return Jupiter::Readable_String<T>::template getWord<Jupiter::CString_Loose>(in, pos, whitespace);
} }
template<typename T> Jupiter::CString_Loose<T> Jupiter::CString_Loose<T>::getWord(const T *in, size_t pos, const T *whitespace) template<typename T> Jupiter::CString_Loose<T> Jupiter::CString_Loose<T>::getWord(const T *in, size_t pos, const T *whitespace)
{ {
return Jupiter::Readable_String<T>::getWord<Jupiter::CString_Loose>(in, pos, whitespace); return Jupiter::Readable_String<T>::template getWord<Jupiter::CString_Loose>(in, pos, whitespace);
} }
template<typename T> Jupiter::CString_Loose<T> Jupiter::CString_Loose<T>::gotoWord(size_t pos, const T *whitespace) const template<typename T> Jupiter::CString_Loose<T> Jupiter::CString_Loose<T>::gotoWord(size_t pos, const T *whitespace) const
@ -823,39 +824,39 @@ template<typename T> Jupiter::CString_Loose<T> Jupiter::CString_Loose<T>::gotoWo
template<typename T> Jupiter::CString_Loose<T> Jupiter::CString_Loose<T>::gotoWord(const Jupiter::Readable_String<T> &in, size_t pos, const T *whitespace) template<typename T> Jupiter::CString_Loose<T> Jupiter::CString_Loose<T>::gotoWord(const Jupiter::Readable_String<T> &in, size_t pos, const T *whitespace)
{ {
return Jupiter::Readable_String<T>::gotoWord<Jupiter::CString_Loose>(in, pos, whitespace); return Jupiter::Readable_String<T>::template gotoWord<Jupiter::CString_Loose>(in, pos, whitespace);
} }
// tokenize // tokenize
template<typename T> typename Jupiter::Readable_String<T>::TokenizeResult<Jupiter::CString_Loose> Jupiter::CString_Loose<T>::tokenize(const T &token) template<typename T> typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::CString_Loose> Jupiter::CString_Loose<T>::tokenize(const T &token)
{ {
return Jupiter::CString_Loose<T>::tokenize(*this, token); return Jupiter::CString_Loose<T>::tokenize(*this, token);
} }
template<typename T> typename Jupiter::Readable_String<T>::TokenizeResult<Jupiter::CString_Loose> Jupiter::CString_Loose<T>::tokenize(const Jupiter::Readable_String<T> &separator) template<typename T> typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::CString_Loose> Jupiter::CString_Loose<T>::tokenize(const Jupiter::Readable_String<T> &separator)
{ {
return Jupiter::CString_Loose<T>::tokenize(*this, separator); return Jupiter::CString_Loose<T>::tokenize(*this, separator);
} }
template<typename T> typename Jupiter::Readable_String<T>::TokenizeResult<Jupiter::CString_Loose> Jupiter::CString_Loose<T>::tokenize(const T *separator, size_t separator_size) template<typename T> typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::CString_Loose> Jupiter::CString_Loose<T>::tokenize(const T *separator, size_t separator_size)
{ {
return Jupiter::CString_Loose<T>::tokenize(*this, separator, separator_size); return Jupiter::CString_Loose<T>::tokenize(*this, separator, separator_size);
} }
template<typename T> typename Jupiter::Readable_String<T>::TokenizeResult<Jupiter::CString_Loose> Jupiter::CString_Loose<T>::tokenize(const Jupiter::Readable_String<T> &in, const T &token) template<typename T> typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::CString_Loose> Jupiter::CString_Loose<T>::tokenize(const Jupiter::Readable_String<T> &in, const T &token)
{ {
return typename Jupiter::template Readable_String<T>::template tokenize<typename Jupiter::template CString_Loose>(in, token); return typename Jupiter::template Readable_String<T>::template tokenize<typename Jupiter::template CString_Loose<T>>(in, token);
} }
template<typename T> typename Jupiter::Readable_String<T>::TokenizeResult<Jupiter::CString_Loose> Jupiter::CString_Loose<T>::tokenize(const Jupiter::Readable_String<T> &in, const Jupiter::Readable_String<T> &separator) template<typename T> typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::CString_Loose> Jupiter::CString_Loose<T>::tokenize(const Jupiter::Readable_String<T> &in, const Jupiter::Readable_String<T> &separator)
{ {
return typename Jupiter::template Readable_String<T>::template tokenize<typename Jupiter::template CString_Loose>(in, separator); return typename Jupiter::template Readable_String<T>::template tokenize<typename Jupiter::template CString_Loose<T>>(in, separator);
} }
template<typename T> typename Jupiter::Readable_String<T>::TokenizeResult<Jupiter::CString_Loose> Jupiter::CString_Loose<T>::tokenize(const Jupiter::Readable_String<T> &in, const T *separator, size_t separator_size) template<typename T> typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::CString_Loose> Jupiter::CString_Loose<T>::tokenize(const Jupiter::Readable_String<T> &in, const T *separator, size_t separator_size)
{ {
return typename Jupiter::template Readable_String<T>::template tokenize<typename Jupiter::template CString_Loose>(in, separator, separator_size); return typename Jupiter::template Readable_String<T>::template tokenize<typename Jupiter::template CString_Loose<T>>(in, separator, separator_size);
} }
// Operators // Operators

60
src/include/DataBuffer_Imp.h

@ -40,20 +40,8 @@ template<typename T> T Jupiter::DataBuffer::interpret_data(uint8_t *&head)
return r; return r;
} }
template<template<typename> class T, typename Y> static T<Y> interpret_data(uint8_t *&head) template<template<typename, typename> class T, typename X, typename Y> static T<X, Y> interpret_data(uint8_t *&head);
{ template<template<typename, typename, typename> class T, typename X, typename Y, typename Z> static T<X, Y, Z> interpret_data(uint8_t *&head);
return _Jupiter_DataBuffer_partial_specialization_impl_std<T>::interpret<Y>(head);
}
template<template<typename, typename> class T, typename X, typename Y> static T<X, Y> interpret_data(uint8_t *&head)
{
return _Jupiter_DataBuffer_partial_specialization_impl_std_vector<T>::interpret<X, Y>(head);
}
template<template<typename, typename, typename> class T, typename X, typename Y, typename Z> static T<X, Y, Z> interpret_data(uint8_t *&head)
{
return _Jupiter_DataBuffer_partial_specialization_impl_std_string<T>::interpret<X, Y, Z>(head);
}
// Basic peek // Basic peek
@ -204,7 +192,7 @@ template<template<typename> class T> struct _Jupiter_DataBuffer_partial_speciali
template<template<typename> class T, typename Y> void Jupiter::DataBuffer::push(const T<Y> *data) template<template<typename> class T, typename Y> void Jupiter::DataBuffer::push(const T<Y> *data)
{ {
_Jupiter_DataBuffer_partial_specialization_impl<T>::push<Y>(this, data); _Jupiter_DataBuffer_partial_specialization_impl<T>::template push<Y>(this, data);
} }
template<template<typename> class T, typename Y> void Jupiter::DataBuffer::push(const T<Y> &data) template<template<typename> class T, typename Y> void Jupiter::DataBuffer::push(const T<Y> &data)
@ -214,7 +202,7 @@ template<template<typename> class T, typename Y> void Jupiter::DataBuffer::push(
template<template<typename> class T, typename Y> T<Y> Jupiter::DataBuffer::interpret_data(uint8_t *&head) template<template<typename> class T, typename Y> T<Y> Jupiter::DataBuffer::interpret_data(uint8_t *&head)
{ {
return _Jupiter_DataBuffer_partial_specialization_impl<T>::interpret<Y>(head); return _Jupiter_DataBuffer_partial_specialization_impl<T>::template interpret<Y>(head);
} }
// PUSH SPECIALIZATION: std::array // PUSH SPECIALIZATION: std::array
@ -228,12 +216,12 @@ template<> struct _Jupiter_DataBuffer_partial_specialization_impl_std_array<std:
template<typename X, size_t Y> static void push(Jupiter::DataBuffer *buffer, const std::array<X, Y> *data) template<typename X, size_t Y> static void push(Jupiter::DataBuffer *buffer, const std::array<X, Y> *data)
{ {
buffer->push<size_t>(Y); buffer->push<size_t>(Y);
if (std::is_fundamental<std::array<X, Y>::value_type>::value) if (std::is_fundamental<typename std::array<X, Y>::value_type>::value)
buffer->push(reinterpret_cast<const uint8_t *>(data->data()), data->size() * sizeof(std::array<X, Y>::value_type)); buffer->push(reinterpret_cast<const uint8_t *>(data->data()), data->size() * sizeof(std::array<X, Y>::value_type));
else else
{ {
std::array<X, Y>::const_iterator itr = data->begin(); auto itr = data->begin();
std::array<X, Y>::const_iterator end = data->end(); auto end = data->end();
while (itr != end) while (itr != end)
buffer->push<std::array<X, Y>::value_type>(*itr++); buffer->push<std::array<X, Y>::value_type>(*itr++);
} }
@ -242,7 +230,7 @@ template<> struct _Jupiter_DataBuffer_partial_specialization_impl_std_array<std:
template<template<typename, size_t> class T, typename X, size_t Y> void Jupiter::DataBuffer::push(const T<X, Y> *data) template<template<typename, size_t> class T, typename X, size_t Y> void Jupiter::DataBuffer::push(const T<X, Y> *data)
{ {
_Jupiter_DataBuffer_partial_specialization_impl_std_array<T>::push<X, Y>(this, data); _Jupiter_DataBuffer_partial_specialization_impl_std_array<T>::template push<X, Y>(this, data);
} }
template<template<typename, size_t> class T, typename X, size_t Y> void Jupiter::DataBuffer::push(const T<X, Y> &data) template<template<typename, size_t> class T, typename X, size_t Y> void Jupiter::DataBuffer::push(const T<X, Y> &data)
@ -261,12 +249,12 @@ template<> struct _Jupiter_DataBuffer_partial_specialization_impl_std_vector<std
template<typename X, typename Y> static void push(Jupiter::DataBuffer *buffer, const std::vector<X, Y> *data) template<typename X, typename Y> static void push(Jupiter::DataBuffer *buffer, const std::vector<X, Y> *data)
{ {
buffer->push<std::vector<X, Y>::size_type>(data->size()); buffer->push<std::vector<X, Y>::size_type>(data->size());
if (std::is_fundamental<std::vector<X, Y>::value_type>::value) if (std::is_fundamental<typename std::vector<X, Y>::value_type>::value)
buffer->push(reinterpret_cast<const uint8_t *>(data->data()), data->size() * sizeof(std::vector<X, Y>::value_type)); buffer->push(reinterpret_cast<const uint8_t *>(data->data()), data->size() * sizeof(std::vector<X, Y>::value_type));
else else
{ {
std::vector<X, Y>::const_iterator itr = data->begin(); auto itr = data->begin();
std::vector<X, Y>::const_iterator end = data->end(); auto end = data->end();
while (itr != end) while (itr != end)
buffer->push<std::vector<X, Y>::value_type>(*itr++); buffer->push<std::vector<X, Y>::value_type>(*itr++);
} }
@ -279,14 +267,14 @@ template<> struct _Jupiter_DataBuffer_partial_specialization_impl_std_vector<std
std::vector<X, Y> r; std::vector<X, Y> r;
r.reserve(size_); r.reserve(size_);
while (size_-- != 0) while (size_-- != 0)
r.push_back(Jupiter::DataBuffer::interpret_data<std::vector<X, Y>::value_type>(head)); r.push_back(Jupiter::DataBuffer::interpret_data<typename std::vector<X, Y>::value_type>(head));
return r; return r;
} }
}; };
template<template<typename, typename> class T, typename X, typename Y> void Jupiter::DataBuffer::push(const T<X, Y> *data) template<template<typename, typename> class T, typename X, typename Y> void Jupiter::DataBuffer::push(const T<X, Y> *data)
{ {
_Jupiter_DataBuffer_partial_specialization_impl_std_vector<T>::push<X, Y>(this, data); _Jupiter_DataBuffer_partial_specialization_impl_std_vector<T>::template push<X, Y>(this, data);
} }
template<template<typename, typename> class T, typename X, typename Y> void Jupiter::DataBuffer::push(const T<X, Y> &data) template<template<typename, typename> class T, typename X, typename Y> void Jupiter::DataBuffer::push(const T<X, Y> &data)
@ -296,7 +284,12 @@ template<template<typename, typename> class T, typename X, typename Y> void Jupi
template<template<typename, typename> class T, typename X, typename Y> T<X, Y> Jupiter::DataBuffer::interpret_data(uint8_t *&head) template<template<typename, typename> class T, typename X, typename Y> T<X, Y> Jupiter::DataBuffer::interpret_data(uint8_t *&head)
{ {
return _Jupiter_DataBuffer_partial_specialization_impl_std_vector<T>::interpret<X, Y>(head); return _Jupiter_DataBuffer_partial_specialization_impl_std_vector<T>::template interpret<X, Y>(head);
}
template<template<typename, typename> class T, typename X, typename Y> static T<X, Y> interpret_data(uint8_t *&head)
{
return _Jupiter_DataBuffer_partial_specialization_impl_std_vector<T>::template interpret<X, Y>(head);
} }
// SPECIALIZATION: std::string // SPECIALIZATION: std::string
@ -310,12 +303,12 @@ template<> struct _Jupiter_DataBuffer_partial_specialization_impl_std_string<std
template<typename X, typename Y, typename Z> static void push(Jupiter::DataBuffer *buffer, const std::basic_string<X, Y, Z> *data) template<typename X, typename Y, typename Z> static void push(Jupiter::DataBuffer *buffer, const std::basic_string<X, Y, Z> *data)
{ {
buffer->push(data->size()); buffer->push(data->size());
if (std::is_fundamental<std::basic_string<X, Y, Z>::value_type>::value) if (std::is_fundamental<typename std::basic_string<X, Y, Z>::value_type>::value)
buffer->push(reinterpret_cast<const uint8_t *>(data->data()), data->size() * sizeof(X)); buffer->push(reinterpret_cast<const uint8_t *>(data->data()), data->size() * sizeof(X));
else else
{ {
std::basic_string<X, Y, Z>::const_iterator itr = data->begin(); auto itr = data->begin();
std::basic_string<X, Y, Z>::const_iterator end = data->end(); auto end = data->end();
while (itr != end) while (itr != end)
buffer->push<std::basic_string<X, Y, Z>::value_type>(*itr++); buffer->push<std::basic_string<X, Y, Z>::value_type>(*itr++);
} }
@ -335,7 +328,7 @@ template<> struct _Jupiter_DataBuffer_partial_specialization_impl_std_string<std
template<template<typename, typename, typename> class T, typename X, typename Y, typename Z> void Jupiter::DataBuffer::push(const T<X, Y, Z> *data) template<template<typename, typename, typename> class T, typename X, typename Y, typename Z> void Jupiter::DataBuffer::push(const T<X, Y, Z> *data)
{ {
_Jupiter_DataBuffer_partial_specialization_impl_std_string<T>::push<X, Y, Z>(this, data); _Jupiter_DataBuffer_partial_specialization_impl_std_string<T>::template push<X, Y, Z>(this, data);
} }
template<template<typename, typename, typename> class T, typename X, typename Y, typename Z> void Jupiter::DataBuffer::push(const T<X, Y, Z> &data) template<template<typename, typename, typename> class T, typename X, typename Y, typename Z> void Jupiter::DataBuffer::push(const T<X, Y, Z> &data)
@ -345,7 +338,12 @@ template<template<typename, typename, typename> class T, typename X, typename Y,
template<template<typename, typename, typename> class T, typename X, typename Y, typename Z> T<X, Y, Z> Jupiter::DataBuffer::interpret_data(uint8_t *&head) template<template<typename, typename, typename> class T, typename X, typename Y, typename Z> T<X, Y, Z> Jupiter::DataBuffer::interpret_data(uint8_t *&head)
{ {
return _Jupiter_DataBuffer_partial_specialization_impl_std_string<T>::interpret<X, Y, Z>(head); return _Jupiter_DataBuffer_partial_specialization_impl_std_string<T>::template interpret<X, Y, Z>(head);
}
template<template<typename, typename, typename> class T, typename X, typename Y, typename Z> static T<X, Y, Z> interpret_data(uint8_t *&head)
{
return _Jupiter_DataBuffer_partial_specialization_impl_std_string<T>::template interpret<X, Y, Z>(head);
} }
#endif // _DATABUFFER_IMP_H_HEADER #endif // _DATABUFFER_IMP_H_HEADER

12
src/include/Hash_Table_Imp.h

@ -304,7 +304,7 @@ void Jupiter::Hash_Table<KeyT, ValueT, InKeyT, InValueT, HashF>::callback(CallT
while (itr != end) while (itr != end)
{ {
itr->callback<CallT>(in_callback); itr->template callback<CallT>(in_callback);
++itr; ++itr;
} }
} }
@ -318,7 +318,7 @@ void Jupiter::Hash_Table<KeyT, ValueT, InKeyT, InValueT, HashF>::callback(CallT
while (itr != end) while (itr != end)
{ {
itr->callback<CallT>(in_callback); itr->template callback<CallT>(in_callback);
++itr; ++itr;
} }
} }
@ -364,14 +364,12 @@ typename Jupiter::Hash_Table<KeyT, ValueT, InKeyT, InValueT, HashF> &Jupiter::Ha
else else
{ {
// we need to erase data; slightly modified version of copy_to_buckets() // we need to erase data; slightly modified version of copy_to_buckets()
std::forward_list<Bucket::Entry>::iterator node;
size_t index = 0; size_t index = 0;
while (index != in_table.m_buckets_size) while (index != in_table.m_buckets_size)
{ {
in_table.m_buckets[index].m_entries.clear(); in_table.m_buckets[index].m_entries.clear();
for (node = in_table.m_buckets[index].m_entries.begin(); node != in_table.m_buckets[index].m_entries.end(); ++node) for (auto node = in_table.m_buckets[index].m_entries.begin(); node != in_table.m_buckets[index].m_entries.end(); ++node)
m_buckets[HashF(node->key) % m_buckets_size].set(node->key, node->value); m_buckets[HashF(node->key) % m_buckets_size].set(node->key, node->value);
++index; ++index;
@ -497,10 +495,8 @@ void Jupiter::Hash_Table<KeyT, ValueT, InKeyT, InValueT, HashF>::expand()
template<typename KeyT, typename ValueT, typename InKeyT, typename InValueT, size_t(*HashF)(const InKeyT &)> template<typename KeyT, typename ValueT, typename InKeyT, typename InValueT, size_t(*HashF)(const InKeyT &)>
void Jupiter::Hash_Table<KeyT, ValueT, InKeyT, InValueT, HashF>::copy_to_buckets(Bucket *in_buckets, size_t in_buckets_size) const void Jupiter::Hash_Table<KeyT, ValueT, InKeyT, InValueT, HashF>::copy_to_buckets(Bucket *in_buckets, size_t in_buckets_size) const
{ {
std::forward_list<Bucket::Entry>::iterator node;
for (size_t index = 0; index != m_buckets_size; ++index) for (size_t index = 0; index != m_buckets_size; ++index)
for (node = m_buckets[index].m_entries.begin(); node != m_buckets[index].m_entries.end(); ++node) for (auto node = m_buckets[index].m_entries.begin(); node != m_buckets[index].m_entries.end(); ++node)
in_buckets[HashF(node->key) % in_buckets_size].set(node->key, node->value); in_buckets[HashF(node->key) % in_buckets_size].set(node->key, node->value);
} }

8
src/include/Readable_String.h

@ -25,8 +25,10 @@
*/ */
#include <cwchar> // wchar_t #include <cwchar> // wchar_t
#include <cwctype> // towupper
#include <cstdio> // FILE #include <cstdio> // FILE
#include <string> // std::basic_string<T> type #include <string> // std::basic_string<T> type
#include <iostream> // std::endl
#include "InvalidIndex.h" #include "InvalidIndex.h"
#include "DataBuffer.h" #include "DataBuffer.h"
@ -391,9 +393,9 @@ namespace Jupiter
* @param separator Separator to split tokens by * @param separator Separator to split tokens by
* @return TokenizeResult containing the results of the tokenization process. * @return TokenizeResult containing the results of the tokenization process.
*/ */
template<template<typename> class R> static typename Jupiter::Readable_String<T>::TokenizeResult<R> tokenize(const Jupiter::Readable_String<T> &in, const T &separator); template<template<typename> class R> static typename Jupiter::Readable_String<T>::template TokenizeResult<R> tokenize(const Jupiter::Readable_String<T> &in, const T &separator);
template<template<typename> class R> static typename Jupiter::Readable_String<T>::TokenizeResult<R> tokenize(const Jupiter::Readable_String<T> &in, const Jupiter::Readable_String<T> &separator); template<template<typename> class R> static typename Jupiter::Readable_String<T>::template TokenizeResult<R> tokenize(const Jupiter::Readable_String<T> &in, const Jupiter::Readable_String<T> &separator);
template<template<typename> class R> static typename Jupiter::Readable_String<T>::TokenizeResult<R> tokenize(const Jupiter::Readable_String<T> &in, const T *separator, size_t separator_size); template<template<typename> class R> static typename Jupiter::Readable_String<T>::template TokenizeResult<R> tokenize(const Jupiter::Readable_String<T> &in, const T *separator, size_t separator_size);
/** /**
* @brief Destructor for the Readable_String class. * @brief Destructor for the Readable_String class.

16
src/include/Readable_String_Imp.h

@ -1376,7 +1376,13 @@ template<typename T> template<template<typename> class R> void Jupiter::Readable
// TokenizeResult Operators // TokenizeResult Operators
template<typename T> template<template<typename> class R> inline typename Jupiter::Readable_String<T>::TokenizeResult<R> &Jupiter::Readable_String<T>::TokenizeResult<R>::operator=(typename const Jupiter::Readable_String<T>::TokenizeResult<R> &source) #ifdef _WIN32
#define TOKENIZE_RESULT_PREFIX
#else // _WIN32
#define TOKENIZE_RESULT_PREFIX template
#endif // _WIN32
template<typename T> template<template<typename> class R> inline typename Jupiter::Readable_String<T>::TOKENIZE_RESULT_PREFIX TokenizeResult<R> &Jupiter::Readable_String<T>::TokenizeResult<R>::operator=(const Jupiter::Readable_String<T>::TokenizeResult<R> &source)
{ {
if (Jupiter::Readable_String<T>::TokenizeResult<R>::tokens != nullptr) if (Jupiter::Readable_String<T>::TokenizeResult<R>::tokens != nullptr)
delete[] Jupiter::Readable_String<T>::TokenizeResult<R>::tokens; delete[] Jupiter::Readable_String<T>::TokenizeResult<R>::tokens;
@ -1391,7 +1397,7 @@ template<typename T> template<template<typename> class R> inline typename Jupite
return *this; return *this;
} }
template<typename T> template<template<typename> class R> inline typename Jupiter::Readable_String<T>::TokenizeResult<R> &Jupiter::Readable_String<T>::TokenizeResult<R>::operator=(typename Jupiter::Readable_String<T>::TokenizeResult<R> &&source) template<typename T> template<template<typename> class R> inline typename Jupiter::Readable_String<T>::TOKENIZE_RESULT_PREFIX TokenizeResult<R> &Jupiter::Readable_String<T>::TokenizeResult<R>::operator=(Jupiter::Readable_String<T>::TokenizeResult<R> &&source)
{ {
if (Jupiter::Readable_String<T>::TokenizeResult<R>::tokens != nullptr) if (Jupiter::Readable_String<T>::TokenizeResult<R>::tokens != nullptr)
delete[] Jupiter::Readable_String<T>::TokenizeResult<R>::tokens; delete[] Jupiter::Readable_String<T>::TokenizeResult<R>::tokens;
@ -1405,7 +1411,7 @@ template<typename T> template<template<typename> class R> inline typename Jupite
// tokenize // tokenize
template<typename T> template<template<typename> class R> typename Jupiter::Readable_String<T>::TokenizeResult<R> Jupiter::Readable_String<T>::tokenize(const Jupiter::Readable_String<T> &in, const T &token) template<typename T> template<template<typename> class R> typename Jupiter::Readable_String<T>::template TokenizeResult<R> Jupiter::Readable_String<T>::tokenize(const Jupiter::Readable_String<T> &in, const T &token)
{ {
// special case: no input // special case: no input
if (in.isEmpty()) if (in.isEmpty())
@ -1454,12 +1460,12 @@ template<typename T> template<template<typename> class R> typename Jupiter::Read
return TokenizeResult<R>(tokens, length); return TokenizeResult<R>(tokens, length);
} }
template<typename T> template<template<typename> class R> typename Jupiter::Readable_String<T>::TokenizeResult<R> Jupiter::Readable_String<T>::tokenize(const Jupiter::Readable_String<T> &in, const Jupiter::Readable_String<T> &separator) template<typename T> template<template<typename> class R> typename Jupiter::Readable_String<T>::template TokenizeResult<R> Jupiter::Readable_String<T>::tokenize(const Jupiter::Readable_String<T> &in, const Jupiter::Readable_String<T> &separator)
{ {
return Jupiter::Readable_String<T>::tokenize<R>(in, separator.ptr(), separator.size()); return Jupiter::Readable_String<T>::tokenize<R>(in, separator.ptr(), separator.size());
} }
template<typename T> template<template<typename> class R> typename Jupiter::Readable_String<T>::TokenizeResult<R> Jupiter::Readable_String<T>::tokenize(const Jupiter::Readable_String<T> &in, const T *separator, size_t separator_size) template<typename T> template<template<typename> class R> typename Jupiter::Readable_String<T>::template TokenizeResult<R> Jupiter::Readable_String<T>::tokenize(const Jupiter::Readable_String<T> &in, const T *separator, size_t separator_size)
{ {
// special case: separator is a single element // special case: separator is a single element
if (separator_size == 1) if (separator_size == 1)

12
src/include/Reference_String.h

@ -246,9 +246,9 @@ namespace Jupiter
* @param separator Separator to split tokens by * @param separator Separator to split tokens by
* @return TokenizeResult containing the results of the tokenization process. * @return TokenizeResult containing the results of the tokenization process.
*/ */
Jupiter::Readable_String<T>::TokenizeResult<Jupiter::Reference_String> tokenize(const T &separator) const; typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::Reference_String> tokenize(const T &separator) const;
Jupiter::Readable_String<T>::TokenizeResult<Jupiter::Reference_String> tokenize(const Jupiter::Readable_String<T> &separator) const; typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::Reference_String> tokenize(const Jupiter::Readable_String<T> &separator) const;
Jupiter::Readable_String<T>::TokenizeResult<Jupiter::Reference_String> tokenize(const T *separator, size_t separator_size) const; typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::Reference_String> tokenize(const T *separator, size_t separator_size) const;
/** /**
* @brief Tokenizes a string, based on an input token separator * @brief Tokenizes a string, based on an input token separator
@ -257,9 +257,9 @@ namespace Jupiter
* @param separator Separator to split tokens by * @param separator Separator to split tokens by
* @return TokenizeResult containing the results of the tokenization process. * @return TokenizeResult containing the results of the tokenization process.
*/ */
static Jupiter::Readable_String<T>::TokenizeResult<Jupiter::Reference_String> tokenize(const Jupiter::Readable_String<T> &in, const T &separator); static typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::Reference_String> tokenize(const Jupiter::Readable_String<T> &in, const T &separator);
static Jupiter::Readable_String<T>::TokenizeResult<Jupiter::Reference_String> tokenize(const Jupiter::Readable_String<T> &in, const Jupiter::Readable_String<T> &separator); static typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::Reference_String> tokenize(const Jupiter::Readable_String<T> &in, const Jupiter::Readable_String<T> &separator);
static Jupiter::Readable_String<T>::TokenizeResult<Jupiter::Reference_String> tokenize(const Jupiter::Readable_String<T> &in, const T *separator, size_t separator_size); static typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::Reference_String> tokenize(const Jupiter::Readable_String<T> &in, const T *separator, size_t separator_size);
/** Mutative operators */ /** Mutative operators */
inline Readable_String<T> &operator-=(size_t right) { this->truncate(right); return *this; }; inline Readable_String<T> &operator-=(size_t right) { this->truncate(right); return *this; };

34
src/include/Reference_String_Imp.h

@ -180,12 +180,12 @@ template<typename T> Jupiter::Reference_String<T> Jupiter::Reference_String<T>::
template<typename T> Jupiter::Reference_String<T> Jupiter::Reference_String<T>::getWord(const Jupiter::Readable_String<T> &in, size_t pos, const T *whitespace) template<typename T> Jupiter::Reference_String<T> Jupiter::Reference_String<T>::getWord(const Jupiter::Readable_String<T> &in, size_t pos, const T *whitespace)
{ {
return Jupiter::Readable_String<T>::getWord<Jupiter::Reference_String>(in, pos, whitespace); return Jupiter::Readable_String<T>::template getWord<Jupiter::Reference_String>(in, pos, whitespace);
} }
template<typename T> Jupiter::Reference_String<T> Jupiter::Reference_String<T>::getWord(const T *in, size_t pos, const T *whitespace) template<typename T> Jupiter::Reference_String<T> Jupiter::Reference_String<T>::getWord(const T *in, size_t pos, const T *whitespace)
{ {
return Jupiter::Readable_String<T>::getWord<Jupiter::Reference_String>(in, pos, whitespace); return Jupiter::Readable_String<T>::template getWord<Jupiter::Reference_String>(in, pos, whitespace);
} }
template<typename T> Jupiter::Reference_String<T> Jupiter::Reference_String<T>::getToken(size_t pos, const T &token) const template<typename T> Jupiter::Reference_String<T> Jupiter::Reference_String<T>::getToken(size_t pos, const T &token) const
@ -200,12 +200,12 @@ template<typename T> Jupiter::Reference_String<T> Jupiter::Reference_String<T>::
template<typename T> Jupiter::Reference_String<T> Jupiter::Reference_String<T>::getToken(const Jupiter::Readable_String<T> &in, size_t pos, const T &token) template<typename T> Jupiter::Reference_String<T> Jupiter::Reference_String<T>::getToken(const Jupiter::Readable_String<T> &in, size_t pos, const T &token)
{ {
return Jupiter::Readable_String<T>::getToken<Jupiter::Reference_String>(in, pos, token); return Jupiter::Readable_String<T>::template getToken<Jupiter::Reference_String>(in, pos, token);
} }
template<typename T> Jupiter::Reference_String<T> Jupiter::Reference_String<T>::getToken(const Jupiter::Readable_String<T> &in, size_t pos, const Jupiter::Readable_String<T> &token) template<typename T> Jupiter::Reference_String<T> Jupiter::Reference_String<T>::getToken(const Jupiter::Readable_String<T> &in, size_t pos, const Jupiter::Readable_String<T> &token)
{ {
return Jupiter::Readable_String<T>::getToken<Jupiter::Reference_String>(in, pos, token); return Jupiter::Readable_String<T>::template getToken<Jupiter::Reference_String>(in, pos, token);
} }
template<typename T> Jupiter::Reference_String<T> Jupiter::Reference_String<T>::gotoWord(size_t pos, const T *whitespace) const template<typename T> Jupiter::Reference_String<T> Jupiter::Reference_String<T>::gotoWord(size_t pos, const T *whitespace) const
@ -215,12 +215,12 @@ template<typename T> Jupiter::Reference_String<T> Jupiter::Reference_String<T>::
template<typename T> Jupiter::Reference_String<T> Jupiter::Reference_String<T>::gotoWord(const Jupiter::Readable_String<T> &in, size_t pos, const T *whitespace) template<typename T> Jupiter::Reference_String<T> Jupiter::Reference_String<T>::gotoWord(const Jupiter::Readable_String<T> &in, size_t pos, const T *whitespace)
{ {
return Jupiter::Readable_String<T>::gotoWord<Jupiter::Reference_String>(in, pos, whitespace); return Jupiter::Readable_String<T>::template gotoWord<Jupiter::Reference_String>(in, pos, whitespace);
} }
template<typename T> Jupiter::Reference_String<T> Jupiter::Reference_String<T>::gotoWord(const T *in, size_t pos, const T *whitespace) template<typename T> Jupiter::Reference_String<T> Jupiter::Reference_String<T>::gotoWord(const T *in, size_t pos, const T *whitespace)
{ {
return Jupiter::Readable_String<T>::gotoWord<Jupiter::Reference_String>(in, pos, whitespace); return Jupiter::Readable_String<T>::template gotoWord<Jupiter::Reference_String>(in, pos, whitespace);
} }
template<typename T> Jupiter::Reference_String<T> Jupiter::Reference_String<T>::gotoToken(size_t pos, const T &token) const template<typename T> Jupiter::Reference_String<T> Jupiter::Reference_String<T>::gotoToken(size_t pos, const T &token) const
@ -235,46 +235,46 @@ template<typename T> Jupiter::Reference_String<T> Jupiter::Reference_String<T>::
template<typename T> Jupiter::Reference_String<T> Jupiter::Reference_String<T>::gotoToken(const Jupiter::Readable_String<T> &in, size_t pos, const T &token) template<typename T> Jupiter::Reference_String<T> Jupiter::Reference_String<T>::gotoToken(const Jupiter::Readable_String<T> &in, size_t pos, const T &token)
{ {
return Jupiter::Readable_String<T>::gotoToken<Jupiter::Reference_String>(in, pos, token); return Jupiter::Readable_String<T>::template gotoToken<Jupiter::Reference_String>(in, pos, token);
} }
template<typename T> Jupiter::Reference_String<T> Jupiter::Reference_String<T>::gotoToken(const Jupiter::Readable_String<T> &in, size_t pos, const Jupiter::Readable_String<T> &token) template<typename T> Jupiter::Reference_String<T> Jupiter::Reference_String<T>::gotoToken(const Jupiter::Readable_String<T> &in, size_t pos, const Jupiter::Readable_String<T> &token)
{ {
return Jupiter::Readable_String<T>::gotoToken<Jupiter::Reference_String>(in, pos, token); return Jupiter::Readable_String<T>::template gotoToken<Jupiter::Reference_String>(in, pos, token);
} }
template<typename T> const Jupiter::Reference_String<T> Jupiter::Reference_String<T>::empty = Jupiter::Reference_String<T>(); template<typename T> const Jupiter::Reference_String<T> Jupiter::Reference_String<T>::empty = Jupiter::Reference_String<T>();
// tokenize // tokenize
template<typename T> typename Jupiter::Readable_String<T>::TokenizeResult<Jupiter::Reference_String> Jupiter::Reference_String<T>::tokenize(const T &separator) const template<typename T> typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::Reference_String> Jupiter::Reference_String<T>::tokenize(const T &separator) const
{ {
return Jupiter::Reference_String<T>::tokenize(*this, separator); return Jupiter::Reference_String<T>::tokenize(*this, separator);
} }
template<typename T> typename Jupiter::Readable_String<T>::TokenizeResult<Jupiter::Reference_String> Jupiter::Reference_String<T>::tokenize(const Jupiter::Readable_String<T> &separator) const template<typename T> typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::Reference_String> Jupiter::Reference_String<T>::tokenize(const Jupiter::Readable_String<T> &separator) const
{ {
return Jupiter::Reference_String<T>::tokenize(*this, separator); return Jupiter::Reference_String<T>::tokenize(*this, separator);
} }
template<typename T> typename Jupiter::Readable_String<T>::TokenizeResult<Jupiter::Reference_String> Jupiter::Reference_String<T>::tokenize(const T *separator, size_t separator_size) const template<typename T> typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::Reference_String> Jupiter::Reference_String<T>::tokenize(const T *separator, size_t separator_size) const
{ {
return Jupiter::Reference_String<T>::tokenize(*this, separator, separator_size); return Jupiter::Reference_String<T>::tokenize(*this, separator, separator_size);
} }
template<typename T> typename Jupiter::Readable_String<T>::TokenizeResult<Jupiter::Reference_String> Jupiter::Reference_String<T>::tokenize(const Jupiter::Readable_String<T> &in, const T &token) template<typename T> typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::Reference_String> Jupiter::Reference_String<T>::tokenize(const Jupiter::Readable_String<T> &in, const T &token)
{ {
return typename Jupiter::Readable_String<T>::tokenize<typename Jupiter::Reference_String>(in, token); return Jupiter::Readable_String<T>::template tokenize<Jupiter::Reference_String>(in, token);
} }
template<typename T> typename Jupiter::Readable_String<T>::TokenizeResult<Jupiter::Reference_String> Jupiter::Reference_String<T>::tokenize(const Jupiter::Readable_String<T> &in, const Jupiter::Readable_String<T> &separator) template<typename T> typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::Reference_String> Jupiter::Reference_String<T>::tokenize(const Jupiter::Readable_String<T> &in, const Jupiter::Readable_String<T> &separator)
{ {
return typename Jupiter::Readable_String<T>::tokenize<typename Jupiter::Reference_String>(in, separator); return Jupiter::Readable_String<T>::template tokenize<Jupiter::Reference_String>(in, separator);
} }
template<typename T> typename Jupiter::Readable_String<T>::TokenizeResult<Jupiter::Reference_String> Jupiter::Reference_String<T>::tokenize(const Jupiter::Readable_String<T> &in, const T *separator, size_t separator_size) template<typename T> typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::Reference_String> Jupiter::Reference_String<T>::tokenize(const Jupiter::Readable_String<T> &in, const T *separator, size_t separator_size)
{ {
return typename Jupiter::Readable_String<T>::tokenize<typename Jupiter::Reference_String>(in, separator, separator_size); return Jupiter::Readable_String<T>::template tokenize<Jupiter::Reference_String>(in, separator, separator_size);
} }
// Jupiter::DataBuffer specialization // Jupiter::DataBuffer specialization

2
src/include/SecureSocket.h

@ -164,7 +164,7 @@ namespace Jupiter
* @param source Socket to move data from * @param source Socket to move data from
* @return Reference to this socket. * @return Reference to this socket.
*/ */
SecureSocket &SecureSocket::operator=(SecureSocket &&source); SecureSocket &operator=(SecureSocket &&source);
/** /**
* @brief Default constructor for the SecureSocket class. * @brief Default constructor for the SecureSocket class.

10
src/include/Socket.h

@ -30,7 +30,13 @@
#include "String.hpp" #include "String.hpp"
struct addrinfo; struct addrinfo;
#ifdef _WIN32
struct in_addr6; struct in_addr6;
#else
#define in_addr6 in6_addr
struct in6_addr;
#endif
namespace Jupiter namespace Jupiter
{ {
@ -492,7 +498,7 @@ namespace Jupiter
* @param source Socket to move data from * @param source Socket to move data from
* @return Reference to this socket. * @return Reference to this socket.
*/ */
Socket &Socket::operator=(Socket &&source); Socket &operator=(Socket &&source);
/** /**
* @brief Default constructor for the Socket class. * @brief Default constructor for the Socket class.
@ -529,7 +535,7 @@ namespace Jupiter
#if defined _WIN32 #if defined _WIN32
typedef uintptr_t SocketType; typedef uintptr_t SocketType;
#else if #else
typedef int SocketType; typedef int SocketType;
#endif #endif

24
src/include/String.hpp

@ -210,9 +210,9 @@ namespace Jupiter
* @param separator Separator to split tokens by * @param separator Separator to split tokens by
* @return TokenizeResult containing the results of the tokenization process. * @return TokenizeResult containing the results of the tokenization process.
*/ */
typename Jupiter::Readable_String<T>::TokenizeResult<Jupiter::String_Strict> tokenize(const T &separator) const; typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::String_Strict> tokenize(const T &separator) const;
typename Jupiter::Readable_String<T>::TokenizeResult<Jupiter::String_Strict> tokenize(const Jupiter::Readable_String<T> &separator) const; typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::String_Strict> tokenize(const Jupiter::Readable_String<T> &separator) const;
typename Jupiter::Readable_String<T>::TokenizeResult<Jupiter::String_Strict> tokenize(const T *separator, size_t separator_size) const; typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::String_Strict> tokenize(const T *separator, size_t separator_size) const;
/** /**
* @brief Tokenizes a string, based on an input token separator * @brief Tokenizes a string, based on an input token separator
@ -221,9 +221,9 @@ namespace Jupiter
* @param separator Separator to split tokens by * @param separator Separator to split tokens by
* @return TokenizeResult containing the results of the tokenization process. * @return TokenizeResult containing the results of the tokenization process.
*/ */
static typename Jupiter::Readable_String<T>::TokenizeResult<Jupiter::String_Strict> tokenize(const Jupiter::Readable_String<T> &in, const T &separator); static typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::String_Strict> tokenize(const Jupiter::Readable_String<T> &in, const T &separator);
static typename Jupiter::Readable_String<T>::TokenizeResult<Jupiter::String_Strict> tokenize(const Jupiter::Readable_String<T> &in, const Jupiter::Readable_String<T> &separator); static typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::String_Strict> tokenize(const Jupiter::Readable_String<T> &in, const Jupiter::Readable_String<T> &separator);
static typename Jupiter::Readable_String<T>::TokenizeResult<Jupiter::String_Strict> tokenize(const Jupiter::Readable_String<T> &in, const T *separator, size_t separator_size); static typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::String_Strict> tokenize(const Jupiter::Readable_String<T> &in, const T *separator, size_t separator_size);
/** Default Constructor */ /** Default Constructor */
String_Strict(); String_Strict();
@ -470,9 +470,9 @@ namespace Jupiter
* @param separator Separator to split tokens by * @param separator Separator to split tokens by
* @return TokenizeResult containing the results of the tokenization process. * @return TokenizeResult containing the results of the tokenization process.
*/ */
typename Jupiter::Readable_String<T>::TokenizeResult<Jupiter::String_Loose> tokenize(const T &separator); typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::String_Loose> tokenize(const T &separator);
typename Jupiter::Readable_String<T>::TokenizeResult<Jupiter::String_Loose> tokenize(const Jupiter::Readable_String<T> &separator); typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::String_Loose> tokenize(const Jupiter::Readable_String<T> &separator);
typename Jupiter::Readable_String<T>::TokenizeResult<Jupiter::String_Loose> tokenize(const T *separator, size_t separator_size); typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::String_Loose> tokenize(const T *separator, size_t separator_size);
/** /**
* @brief Tokenizes a string, based on an input token separator * @brief Tokenizes a string, based on an input token separator
@ -481,9 +481,9 @@ namespace Jupiter
* @param separator Separator to split tokens by * @param separator Separator to split tokens by
* @return TokenizeResult containing the results of the tokenization process. * @return TokenizeResult containing the results of the tokenization process.
*/ */
static typename Jupiter::Readable_String<T>::TokenizeResult<Jupiter::String_Loose> tokenize(const Jupiter::Readable_String<T> &in, const T &separator); static typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::String_Loose> tokenize(const Jupiter::Readable_String<T> &in, const T &separator);
static typename Jupiter::Readable_String<T>::TokenizeResult<Jupiter::String_Loose> tokenize(const Jupiter::Readable_String<T> &in, const Jupiter::Readable_String<T> &separator); static typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::String_Loose> tokenize(const Jupiter::Readable_String<T> &in, const Jupiter::Readable_String<T> &separator);
static typename Jupiter::Readable_String<T>::TokenizeResult<Jupiter::String_Loose> tokenize(const Jupiter::Readable_String<T> &in, const T *separator, size_t separator_size); static typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::String_Loose> tokenize(const Jupiter::Readable_String<T> &in, const T *separator, size_t separator_size);
/** /**
* @brief Sets the internal buffer to be at least large enough to old a specified number of elements. * @brief Sets the internal buffer to be at least large enough to old a specified number of elements.

24
src/include/String_Imp.h

@ -350,32 +350,32 @@ template<typename T> Jupiter::String_Strict<T> Jupiter::String_Strict<T>::gotoTo
// tokenize // tokenize
template<typename T> typename Jupiter::Readable_String<T>::TokenizeResult<Jupiter::String_Strict> Jupiter::String_Strict<T>::tokenize(const T &separator) const template<typename T> typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::String_Strict> Jupiter::String_Strict<T>::tokenize(const T &separator) const
{ {
return Jupiter::String_Strict<T>::tokenize(*this, separator); return Jupiter::String_Strict<T>::tokenize(*this, separator);
} }
template<typename T> typename Jupiter::Readable_String<T>::TokenizeResult<Jupiter::String_Strict> Jupiter::String_Strict<T>::tokenize(const Jupiter::Readable_String<T> &separator) const template<typename T> typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::String_Strict> Jupiter::String_Strict<T>::tokenize(const Jupiter::Readable_String<T> &separator) const
{ {
return Jupiter::String_Strict<T>::tokenize(*this, separator); return Jupiter::String_Strict<T>::tokenize(*this, separator);
} }
template<typename T> typename Jupiter::Readable_String<T>::TokenizeResult<Jupiter::String_Strict> Jupiter::String_Strict<T>::tokenize(const T *separator, size_t separator_size) const template<typename T> typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::String_Strict> Jupiter::String_Strict<T>::tokenize(const T *separator, size_t separator_size) const
{ {
return Jupiter::String_Strict<T>::tokenize(*this, separator, separator_size); return Jupiter::String_Strict<T>::tokenize(*this, separator, separator_size);
} }
template<typename T> typename Jupiter::Readable_String<T>::TokenizeResult<Jupiter::String_Strict> Jupiter::String_Strict<T>::tokenize(const Jupiter::Readable_String<T> &in, const T &token) template<typename T> typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::String_Strict> Jupiter::String_Strict<T>::tokenize(const Jupiter::Readable_String<T> &in, const T &token)
{ {
return Jupiter::Readable_String<T>::template tokenize<Jupiter::template String_Strict>(in, token); return Jupiter::Readable_String<T>::template tokenize<Jupiter::template String_Strict>(in, token);
} }
template<typename T> typename Jupiter::Readable_String<T>::TokenizeResult<Jupiter::String_Strict> Jupiter::String_Strict<T>::tokenize(const Jupiter::Readable_String<T> &in, const Jupiter::Readable_String<T> &separator) template<typename T> typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::String_Strict> Jupiter::String_Strict<T>::tokenize(const Jupiter::Readable_String<T> &in, const Jupiter::Readable_String<T> &separator)
{ {
return Jupiter::Readable_String<T>::template tokenize<Jupiter::template String_Strict>(in, separator); return Jupiter::Readable_String<T>::template tokenize<Jupiter::template String_Strict>(in, separator);
} }
template<typename T> typename Jupiter::Readable_String<T>::TokenizeResult<Jupiter::String_Strict> Jupiter::String_Strict<T>::tokenize(const Jupiter::Readable_String<T> &in, const T *separator, size_t separator_size) template<typename T> typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::String_Strict> Jupiter::String_Strict<T>::tokenize(const Jupiter::Readable_String<T> &in, const T *separator, size_t separator_size)
{ {
return Jupiter::Readable_String<T>::template tokenize<Jupiter::template String_Strict>(in, separator, separator_size); return Jupiter::Readable_String<T>::template tokenize<Jupiter::template String_Strict>(in, separator, separator_size);
} }
@ -863,32 +863,32 @@ template<typename T> inline Jupiter::String_Loose<T> Jupiter::String_Loose<T>::o
// tokenize // tokenize
template<typename T> typename Jupiter::Readable_String<T>::TokenizeResult<Jupiter::String_Loose> Jupiter::String_Loose<T>::tokenize(const T &separator) template<typename T> typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::String_Loose> Jupiter::String_Loose<T>::tokenize(const T &separator)
{ {
return Jupiter::String_Loose<T>::tokenize(*this, separator); return Jupiter::String_Loose<T>::tokenize(*this, separator);
} }
template<typename T> typename Jupiter::Readable_String<T>::TokenizeResult<Jupiter::String_Loose> Jupiter::String_Loose<T>::tokenize(const Jupiter::Readable_String<T> &separator) template<typename T> typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::String_Loose> Jupiter::String_Loose<T>::tokenize(const Jupiter::Readable_String<T> &separator)
{ {
return Jupiter::String_Loose<T>::tokenize(*this, separator); return Jupiter::String_Loose<T>::tokenize(*this, separator);
} }
template<typename T> typename Jupiter::Readable_String<T>::TokenizeResult<Jupiter::String_Loose> Jupiter::String_Loose<T>::tokenize(const T *separator, size_t separator_size) template<typename T> typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::String_Loose> Jupiter::String_Loose<T>::tokenize(const T *separator, size_t separator_size)
{ {
return Jupiter::String_Loose<T>::tokenize(*this, separator, separator_size); return Jupiter::String_Loose<T>::tokenize(*this, separator, separator_size);
} }
template<typename T> typename Jupiter::Readable_String<T>::TokenizeResult<Jupiter::String_Loose> Jupiter::String_Loose<T>::tokenize(const Jupiter::Readable_String<T> &in, const T &separator) template<typename T> typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::String_Loose> Jupiter::String_Loose<T>::tokenize(const Jupiter::Readable_String<T> &in, const T &separator)
{ {
return Jupiter::Readable_String<T>::template tokenize<Jupiter::template String_Loose>(in, separator); return Jupiter::Readable_String<T>::template tokenize<Jupiter::template String_Loose>(in, separator);
} }
template<typename T> typename Jupiter::Readable_String<T>::TokenizeResult<Jupiter::String_Loose> Jupiter::String_Loose<T>::tokenize(const Jupiter::Readable_String<T> &in, const Jupiter::Readable_String<T> &separator) template<typename T> typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::String_Loose> Jupiter::String_Loose<T>::tokenize(const Jupiter::Readable_String<T> &in, const Jupiter::Readable_String<T> &separator)
{ {
return Jupiter::Readable_String<T>::template tokenize<Jupiter::template String_Loose>(in, separator); return Jupiter::Readable_String<T>::template tokenize<Jupiter::template String_Loose>(in, separator);
} }
template<typename T> typename Jupiter::Readable_String<T>::TokenizeResult<Jupiter::String_Loose> Jupiter::String_Loose<T>::tokenize(const Jupiter::Readable_String<T> &in, const T *separator, size_t separator_size) template<typename T> typename Jupiter::Readable_String<T>::template TokenizeResult<Jupiter::String_Loose> Jupiter::String_Loose<T>::tokenize(const Jupiter::Readable_String<T> &in, const T *separator, size_t separator_size)
{ {
return Jupiter::Readable_String<T>::template tokenize<Jupiter::template String_Loose>(in, separator, separator_size); return Jupiter::Readable_String<T>::template tokenize<Jupiter::template String_Loose>(in, separator, separator_size);
} }

4
src/include/TCPSocket.h

@ -37,7 +37,7 @@ namespace Jupiter
class JUPITER_API TCPSocket : public Socket class JUPITER_API TCPSocket : public Socket
{ {
public: public:
TCPSocket &TCPSocket::operator=(TCPSocket &&source); TCPSocket &operator=(TCPSocket &&source);
TCPSocket(); TCPSocket();
TCPSocket(const TCPSocket &) = delete; TCPSocket(const TCPSocket &) = delete;
TCPSocket(size_t bufferSize); TCPSocket(size_t bufferSize);
@ -51,7 +51,7 @@ namespace Jupiter
class JUPITER_API SecureTCPSocket : public SecureSocket class JUPITER_API SecureTCPSocket : public SecureSocket
{ {
public: public:
SecureTCPSocket &SecureTCPSocket::operator=(SecureTCPSocket &&source); SecureTCPSocket &operator=(SecureTCPSocket &&source);
SecureTCPSocket(); SecureTCPSocket();
SecureTCPSocket(const SecureTCPSocket &) = delete; SecureTCPSocket(const SecureTCPSocket &) = delete;
SecureTCPSocket(size_t bufferSize); SecureTCPSocket(size_t bufferSize);

2
src/include/UDPSocket.h

@ -36,7 +36,7 @@ namespace Jupiter
class JUPITER_API UDPSocket : public Socket class JUPITER_API UDPSocket : public Socket
{ {
public: public:
UDPSocket &UDPSocket::operator=(UDPSocket &&source); UDPSocket &operator=(UDPSocket &&source);
UDPSocket(); UDPSocket();
UDPSocket(const UDPSocket &) = delete; UDPSocket(const UDPSocket &) = delete;
UDPSocket(size_t bufferSize); UDPSocket(size_t bufferSize);

Loading…
Cancel
Save