diff --git a/Builds/VisualStudio2012/beast.vcxproj b/Builds/VisualStudio2012/beast.vcxproj index 0e1234873..d640a10e5 100644 --- a/Builds/VisualStudio2012/beast.vcxproj +++ b/Builds/VisualStudio2012/beast.vcxproj @@ -83,7 +83,6 @@ - diff --git a/Builds/VisualStudio2012/beast.vcxproj.filters b/Builds/VisualStudio2012/beast.vcxproj.filters index 6ae621f34..a782b727c 100644 --- a/Builds/VisualStudio2012/beast.vcxproj.filters +++ b/Builds/VisualStudio2012/beast.vcxproj.filters @@ -785,9 +785,6 @@ beast_asio\tests - - beast_asio\sockets - beast_asio\tests diff --git a/modules/beast_asio/beast_asio.h b/modules/beast_asio/beast_asio.h index e797f6567..8b5ab9dc8 100644 --- a/modules/beast_asio/beast_asio.h +++ b/modules/beast_asio/beast_asio.h @@ -57,7 +57,6 @@ namespace beast #include "sockets/beast_SocketBase.h" #include "sockets/beast_Socket.h" #include "sockets/beast_SocketInterface.h" -#include "sockets/beast_SocketWrapperBasics.h" #include "sockets/beast_SocketWrapper.h" #include "sockets/beast_SharedSocket.h" #include "sockets/beast_SslContext.h" diff --git a/modules/beast_asio/sockets/beast_SocketWrapper.h b/modules/beast_asio/sockets/beast_SocketWrapper.h index 1fb1d4c16..a4c06a05d 100644 --- a/modules/beast_asio/sockets/beast_SocketWrapper.h +++ b/modules/beast_asio/sockets/beast_SocketWrapper.h @@ -119,8 +119,7 @@ namespace SocketWrapperMemberChecks template class SocketWrapper - : public virtual Socket - , public SocketWrapperBasics + : public Socket , public Uncopyable { private: diff --git a/modules/beast_asio/sockets/beast_SocketWrapperBasics.h b/modules/beast_asio/sockets/beast_SocketWrapperBasics.h deleted file mode 100644 index ab06f719c..000000000 --- a/modules/beast_asio/sockets/beast_SocketWrapperBasics.h +++ /dev/null @@ -1,136 +0,0 @@ -//------------------------------------------------------------------------------ -/* - This file is part of Beast: https://github.com/vinniefalco/Beast - Copyright 2013, Vinnie Falco - - Permission to use, copy, modify, and/or distribute this software for any - purpose with or without fee is hereby granted, provided that the above - copyright notice and this permission notice appear in all copies. - - THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES - WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF - MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR - ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES - WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN - ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF - OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. -*/ -//============================================================================== - -#ifndef BEAST_SOCKETWRAPPERBASICS_H_INCLUDED -#define BEAST_SOCKETWRAPPERBASICS_H_INCLUDED - -/** Some utilities for SocketWrapper and others. -*/ -class SocketWrapperBasics -{ -public: -#if 0 - /** Template specialization to determine available interfaces. */ - template - struct InterfacesOf - { - /** Intrusive tag support. - - To use this, add a struct called SocketInterfaces to your - class and derive it from the interfaces that you support. - For example: - - @code - - struct MyHandshakingStream - { - struct SocketInterfaces - : SocketInterface::Stream - , SocketInterface::Handshake - { - }; - } - - @endcode - */ - typedef typename Object::SocketInterfaces type; - typedef type value; - }; - - // Specialization for boost::asio::basic_socket_acceptor - template - struct InterfacesOf > - { - struct value : SocketInterface::Acceptor { }; - typedef value type; - }; - - // Specialization for boost::asio::basic_socket - template - struct InterfacesOf > - { - struct value : SocketInterface::Socket { }; - typedef value type; - }; - - // Specialization for boost::asio::basic_stream_socket - template - struct InterfacesOf > - { - struct value : SocketInterface::Socket, SocketInterface::Stream { }; - typedef value type; - }; - - // Specialization for boost::asio::buffered_stream - template - struct InterfacesOf > - { - struct value : SocketInterface::Stream { }; - typedef value type; - }; - - // Specialization for boost::asio::buffered_read_stream - template - struct InterfacesOf > - { - struct value : SocketInterface::Stream { }; - typedef value type; - }; - - // Specialization for boost::asio::buffered_write_stream - template - struct InterfacesOf > - { - struct value : SocketInterface::Stream { }; - typedef value type; - }; - - // Specialization for boost::asio::ssl::stream - template - struct InterfacesOf > - { - struct value : SocketInterface::Stream , SocketInterface::Handshake { }; - typedef value type; - }; - -#if 1 - // Less elegant, but works. - // Determines if Object supports the specified Interface - template - struct HasInterface : boost::false_type { }; - - template - struct HasInterface ::type> >::type > - : boost::true_type { }; -#else - // This should work, but doesn't. - // K-ballo from #boost suggested it. - // - // Determines if Object supports the specified Interface - template - struct HasInterface : boost::is_base_of > - { - }; -#endif -#endif -}; - -#endif