Return-Path: X-Original-To: apmail-hadoop-common-commits-archive@www.apache.org Delivered-To: apmail-hadoop-common-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id D49A918AE3 for ; Thu, 15 Oct 2015 18:34:21 +0000 (UTC) Received: (qmail 86588 invoked by uid 500); 15 Oct 2015 18:34:16 -0000 Delivered-To: apmail-hadoop-common-commits-archive@hadoop.apache.org Received: (qmail 86370 invoked by uid 500); 15 Oct 2015 18:34:16 -0000 Mailing-List: contact common-commits-help@hadoop.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: common-dev@hadoop.apache.org Delivered-To: mailing list common-commits@hadoop.apache.org Received: (qmail 85420 invoked by uid 99); 15 Oct 2015 18:34:15 -0000 Received: from git1-us-west.apache.org (HELO git1-us-west.apache.org) (140.211.11.23) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 15 Oct 2015 18:34:15 +0000 Received: by git1-us-west.apache.org (ASF Mail Server at git1-us-west.apache.org, from userid 33) id BE96BE111D; Thu, 15 Oct 2015 18:34:15 +0000 (UTC) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: wheat9@apache.org To: common-commits@hadoop.apache.org Date: Thu, 15 Oct 2015 18:34:27 -0000 Message-Id: In-Reply-To: References: X-Mailer: ASF-Git Admin Mailer Subject: [14/51] [partial] hadoop git commit: HDFS-9207. Move the implementation to the hdfs-native-client module. Contributed by Haohui Mai. http://git-wip-us.apache.org/repos/asf/hadoop/blob/4cd3b992/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/ssl/stream.hpp ---------------------------------------------------------------------- diff --git a/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/ssl/stream.hpp b/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/ssl/stream.hpp deleted file mode 100644 index 5e3af01..0000000 --- a/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/ssl/stream.hpp +++ /dev/null @@ -1,756 +0,0 @@ -// -// ssl/stream.hpp -// ~~~~~~~~~~~~~~ -// -// Copyright (c) 2003-2014 Christopher M. Kohlhoff (chris at kohlhoff dot com) -// -// Distributed under the Boost Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// - -#ifndef ASIO_SSL_STREAM_HPP -#define ASIO_SSL_STREAM_HPP - -#if defined(_MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif // defined(_MSC_VER) && (_MSC_VER >= 1200) - -#include "asio/detail/config.hpp" - -#if defined(ASIO_ENABLE_OLD_SSL) -# include "asio/ssl/old/stream.hpp" -#else // defined(ASIO_ENABLE_OLD_SSL) -# include "asio/async_result.hpp" -# include "asio/detail/buffer_sequence_adapter.hpp" -# include "asio/detail/handler_type_requirements.hpp" -# include "asio/detail/noncopyable.hpp" -# include "asio/detail/type_traits.hpp" -# include "asio/ssl/context.hpp" -# include "asio/ssl/detail/buffered_handshake_op.hpp" -# include "asio/ssl/detail/handshake_op.hpp" -# include "asio/ssl/detail/io.hpp" -# include "asio/ssl/detail/read_op.hpp" -# include "asio/ssl/detail/shutdown_op.hpp" -# include "asio/ssl/detail/stream_core.hpp" -# include "asio/ssl/detail/write_op.hpp" -# include "asio/ssl/stream_base.hpp" -#endif // defined(ASIO_ENABLE_OLD_SSL) - -#include "asio/detail/push_options.hpp" - -namespace asio { -namespace ssl { - -#if defined(ASIO_ENABLE_OLD_SSL) - -using asio::ssl::old::stream; - -#else // defined(ASIO_ENABLE_OLD_SSL) - -/// Provides stream-oriented functionality using SSL. -/** - * The stream class template provides asynchronous and blocking stream-oriented - * functionality using SSL. - * - * @par Thread Safety - * @e Distinct @e objects: Safe.@n - * @e Shared @e objects: Unsafe. The application must also ensure that all - * asynchronous operations are performed within the same implicit or explicit - * strand. - * - * @par Example - * To use the SSL stream template with an ip::tcp::socket, you would write: - * @code - * asio::io_service io_service; - * asio::ssl::context ctx(asio::ssl::context::sslv23); - * asio::ssl::stream sock(io_service, ctx); - * @endcode - * - * @par Concepts: - * AsyncReadStream, AsyncWriteStream, Stream, SyncReadStream, SyncWriteStream. - */ -template -class stream : - public stream_base, - private noncopyable -{ -public: - /// The native handle type of the SSL stream. - typedef SSL* native_handle_type; - - /// Structure for use with deprecated impl_type. - struct impl_struct - { - SSL* ssl; - }; - - /// (Deprecated: Use native_handle_type.) The underlying implementation type. - typedef impl_struct* impl_type; - - /// The type of the next layer. - typedef typename remove_reference::type next_layer_type; - - /// The type of the lowest layer. - typedef typename next_layer_type::lowest_layer_type lowest_layer_type; - - /// Construct a stream. - /** - * This constructor creates a stream and initialises the underlying stream - * object. - * - * @param arg The argument to be passed to initialise the underlying stream. - * - * @param ctx The SSL context to be used for the stream. - */ - template - stream(Arg& arg, context& ctx) - : next_layer_(arg), - core_(ctx.native_handle(), next_layer_.lowest_layer().get_io_service()) - { - backwards_compatible_impl_.ssl = core_.engine_.native_handle(); - } - - /// Destructor. - ~stream() - { - } - - /// Get the io_service associated with the object. - /** - * This function may be used to obtain the io_service object that the stream - * uses to dispatch handlers for asynchronous operations. - * - * @return A reference to the io_service object that stream will use to - * dispatch handlers. Ownership is not transferred to the caller. - */ - asio::io_service& get_io_service() - { - return next_layer_.lowest_layer().get_io_service(); - } - - /// Get the underlying implementation in the native type. - /** - * This function may be used to obtain the underlying implementation of the - * context. This is intended to allow access to context functionality that is - * not otherwise provided. - * - * @par Example - * The native_handle() function returns a pointer of type @c SSL* that is - * suitable for passing to functions such as @c SSL_get_verify_result and - * @c SSL_get_peer_certificate: - * @code - * asio::ssl::stream sock(io_service, ctx); - * - * // ... establish connection and perform handshake ... - * - * if (X509* cert = SSL_get_peer_certificate(sock.native_handle())) - * { - * if (SSL_get_verify_result(sock.native_handle()) == X509_V_OK) - * { - * // ... - * } - * } - * @endcode - */ - native_handle_type native_handle() - { - return core_.engine_.native_handle(); - } - - /// (Deprecated: Use native_handle().) Get the underlying implementation in - /// the native type. - /** - * This function may be used to obtain the underlying implementation of the - * context. This is intended to allow access to stream functionality that is - * not otherwise provided. - */ - impl_type impl() - { - return &backwards_compatible_impl_; - } - - /// Get a reference to the next layer. - /** - * This function returns a reference to the next layer in a stack of stream - * layers. - * - * @return A reference to the next layer in the stack of stream layers. - * Ownership is not transferred to the caller. - */ - const next_layer_type& next_layer() const - { - return next_layer_; - } - - /// Get a reference to the next layer. - /** - * This function returns a reference to the next layer in a stack of stream - * layers. - * - * @return A reference to the next layer in the stack of stream layers. - * Ownership is not transferred to the caller. - */ - next_layer_type& next_layer() - { - return next_layer_; - } - - /// Get a reference to the lowest layer. - /** - * This function returns a reference to the lowest layer in a stack of - * stream layers. - * - * @return A reference to the lowest layer in the stack of stream layers. - * Ownership is not transferred to the caller. - */ - lowest_layer_type& lowest_layer() - { - return next_layer_.lowest_layer(); - } - - /// Get a reference to the lowest layer. - /** - * This function returns a reference to the lowest layer in a stack of - * stream layers. - * - * @return A reference to the lowest layer in the stack of stream layers. - * Ownership is not transferred to the caller. - */ - const lowest_layer_type& lowest_layer() const - { - return next_layer_.lowest_layer(); - } - - /// Set the peer verification mode. - /** - * This function may be used to configure the peer verification mode used by - * the stream. The new mode will override the mode inherited from the context. - * - * @param v A bitmask of peer verification modes. See @ref verify_mode for - * available values. - * - * @throws asio::system_error Thrown on failure. - * - * @note Calls @c SSL_set_verify. - */ - void set_verify_mode(verify_mode v) - { - asio::error_code ec; - set_verify_mode(v, ec); - asio::detail::throw_error(ec, "set_verify_mode"); - } - - /// Set the peer verification mode. - /** - * This function may be used to configure the peer verification mode used by - * the stream. The new mode will override the mode inherited from the context. - * - * @param v A bitmask of peer verification modes. See @ref verify_mode for - * available values. - * - * @param ec Set to indicate what error occurred, if any. - * - * @note Calls @c SSL_set_verify. - */ - asio::error_code set_verify_mode( - verify_mode v, asio::error_code& ec) - { - return core_.engine_.set_verify_mode(v, ec); - } - - /// Set the peer verification depth. - /** - * This function may be used to configure the maximum verification depth - * allowed by the stream. - * - * @param depth Maximum depth for the certificate chain verification that - * shall be allowed. - * - * @throws asio::system_error Thrown on failure. - * - * @note Calls @c SSL_set_verify_depth. - */ - void set_verify_depth(int depth) - { - asio::error_code ec; - set_verify_depth(depth, ec); - asio::detail::throw_error(ec, "set_verify_depth"); - } - - /// Set the peer verification depth. - /** - * This function may be used to configure the maximum verification depth - * allowed by the stream. - * - * @param depth Maximum depth for the certificate chain verification that - * shall be allowed. - * - * @param ec Set to indicate what error occurred, if any. - * - * @note Calls @c SSL_set_verify_depth. - */ - asio::error_code set_verify_depth( - int depth, asio::error_code& ec) - { - return core_.engine_.set_verify_depth(depth, ec); - } - - /// Set the callback used to verify peer certificates. - /** - * This function is used to specify a callback function that will be called - * by the implementation when it needs to verify a peer certificate. - * - * @param callback The function object to be used for verifying a certificate. - * The function signature of the handler must be: - * @code bool verify_callback( - * bool preverified, // True if the certificate passed pre-verification. - * verify_context& ctx // The peer certificate and other context. - * ); @endcode - * The return value of the callback is true if the certificate has passed - * verification, false otherwise. - * - * @throws asio::system_error Thrown on failure. - * - * @note Calls @c SSL_set_verify. - */ - template - void set_verify_callback(VerifyCallback callback) - { - asio::error_code ec; - this->set_verify_callback(callback, ec); - asio::detail::throw_error(ec, "set_verify_callback"); - } - - /// Set the callback used to verify peer certificates. - /** - * This function is used to specify a callback function that will be called - * by the implementation when it needs to verify a peer certificate. - * - * @param callback The function object to be used for verifying a certificate. - * The function signature of the handler must be: - * @code bool verify_callback( - * bool preverified, // True if the certificate passed pre-verification. - * verify_context& ctx // The peer certificate and other context. - * ); @endcode - * The return value of the callback is true if the certificate has passed - * verification, false otherwise. - * - * @param ec Set to indicate what error occurred, if any. - * - * @note Calls @c SSL_set_verify. - */ - template - asio::error_code set_verify_callback(VerifyCallback callback, - asio::error_code& ec) - { - return core_.engine_.set_verify_callback( - new detail::verify_callback(callback), ec); - } - - /// Perform SSL handshaking. - /** - * This function is used to perform SSL handshaking on the stream. The - * function call will block until handshaking is complete or an error occurs. - * - * @param type The type of handshaking to be performed, i.e. as a client or as - * a server. - * - * @throws asio::system_error Thrown on failure. - */ - void handshake(handshake_type type) - { - asio::error_code ec; - handshake(type, ec); - asio::detail::throw_error(ec, "handshake"); - } - - /// Perform SSL handshaking. - /** - * This function is used to perform SSL handshaking on the stream. The - * function call will block until handshaking is complete or an error occurs. - * - * @param type The type of handshaking to be performed, i.e. as a client or as - * a server. - * - * @param ec Set to indicate what error occurred, if any. - */ - asio::error_code handshake(handshake_type type, - asio::error_code& ec) - { - detail::io(next_layer_, core_, detail::handshake_op(type), ec); - return ec; - } - - /// Perform SSL handshaking. - /** - * This function is used to perform SSL handshaking on the stream. The - * function call will block until handshaking is complete or an error occurs. - * - * @param type The type of handshaking to be performed, i.e. as a client or as - * a server. - * - * @param buffers The buffered data to be reused for the handshake. - * - * @throws asio::system_error Thrown on failure. - */ - template - void handshake(handshake_type type, const ConstBufferSequence& buffers) - { - asio::error_code ec; - handshake(type, buffers, ec); - asio::detail::throw_error(ec, "handshake"); - } - - /// Perform SSL handshaking. - /** - * This function is used to perform SSL handshaking on the stream. The - * function call will block until handshaking is complete or an error occurs. - * - * @param type The type of handshaking to be performed, i.e. as a client or as - * a server. - * - * @param buffers The buffered data to be reused for the handshake. - * - * @param ec Set to indicate what error occurred, if any. - */ - template - asio::error_code handshake(handshake_type type, - const ConstBufferSequence& buffers, asio::error_code& ec) - { - detail::io(next_layer_, core_, - detail::buffered_handshake_op(type, buffers), ec); - return ec; - } - - /// Start an asynchronous SSL handshake. - /** - * This function is used to asynchronously perform an SSL handshake on the - * stream. This function call always returns immediately. - * - * @param type The type of handshaking to be performed, i.e. as a client or as - * a server. - * - * @param handler The handler to be called when the handshake operation - * completes. Copies will be made of the handler as required. The equivalent - * function signature of the handler must be: - * @code void handler( - * const asio::error_code& error // Result of operation. - * ); @endcode - */ - template - ASIO_INITFN_RESULT_TYPE(HandshakeHandler, - void (asio::error_code)) - async_handshake(handshake_type type, - ASIO_MOVE_ARG(HandshakeHandler) handler) - { - // If you get an error on the following line it means that your handler does - // not meet the documented type requirements for a HandshakeHandler. - ASIO_HANDSHAKE_HANDLER_CHECK(HandshakeHandler, handler) type_check; - - asio::detail::async_result_init< - HandshakeHandler, void (asio::error_code)> init( - ASIO_MOVE_CAST(HandshakeHandler)(handler)); - - detail::async_io(next_layer_, core_, - detail::handshake_op(type), init.handler); - - return init.result.get(); - } - - /// Start an asynchronous SSL handshake. - /** - * This function is used to asynchronously perform an SSL handshake on the - * stream. This function call always returns immediately. - * - * @param type The type of handshaking to be performed, i.e. as a client or as - * a server. - * - * @param buffers The buffered data to be reused for the handshake. Although - * the buffers object may be copied as necessary, ownership of the underlying - * buffers is retained by the caller, which must guarantee that they remain - * valid until the handler is called. - * - * @param handler The handler to be called when the handshake operation - * completes. Copies will be made of the handler as required. The equivalent - * function signature of the handler must be: - * @code void handler( - * const asio::error_code& error, // Result of operation. - * std::size_t bytes_transferred // Amount of buffers used in handshake. - * ); @endcode - */ - template - ASIO_INITFN_RESULT_TYPE(BufferedHandshakeHandler, - void (asio::error_code, std::size_t)) - async_handshake(handshake_type type, const ConstBufferSequence& buffers, - ASIO_MOVE_ARG(BufferedHandshakeHandler) handler) - { - // If you get an error on the following line it means that your handler does - // not meet the documented type requirements for a BufferedHandshakeHandler. - ASIO_BUFFERED_HANDSHAKE_HANDLER_CHECK( - BufferedHandshakeHandler, handler) type_check; - - asio::detail::async_result_init init( - ASIO_MOVE_CAST(BufferedHandshakeHandler)(handler)); - - detail::async_io(next_layer_, core_, - detail::buffered_handshake_op(type, buffers), - init.handler); - - return init.result.get(); - } - - /// Shut down SSL on the stream. - /** - * This function is used to shut down SSL on the stream. The function call - * will block until SSL has been shut down or an error occurs. - * - * @throws asio::system_error Thrown on failure. - */ - void shutdown() - { - asio::error_code ec; - shutdown(ec); - asio::detail::throw_error(ec, "shutdown"); - } - - /// Shut down SSL on the stream. - /** - * This function is used to shut down SSL on the stream. The function call - * will block until SSL has been shut down or an error occurs. - * - * @param ec Set to indicate what error occurred, if any. - */ - asio::error_code shutdown(asio::error_code& ec) - { - detail::io(next_layer_, core_, detail::shutdown_op(), ec); - return ec; - } - - /// Asynchronously shut down SSL on the stream. - /** - * This function is used to asynchronously shut down SSL on the stream. This - * function call always returns immediately. - * - * @param handler The handler to be called when the handshake operation - * completes. Copies will be made of the handler as required. The equivalent - * function signature of the handler must be: - * @code void handler( - * const asio::error_code& error // Result of operation. - * ); @endcode - */ - template - ASIO_INITFN_RESULT_TYPE(ShutdownHandler, - void (asio::error_code)) - async_shutdown(ASIO_MOVE_ARG(ShutdownHandler) handler) - { - // If you get an error on the following line it means that your handler does - // not meet the documented type requirements for a ShutdownHandler. - ASIO_SHUTDOWN_HANDLER_CHECK(ShutdownHandler, handler) type_check; - - asio::detail::async_result_init< - ShutdownHandler, void (asio::error_code)> init( - ASIO_MOVE_CAST(ShutdownHandler)(handler)); - - detail::async_io(next_layer_, core_, detail::shutdown_op(), init.handler); - - return init.result.get(); - } - - /// Write some data to the stream. - /** - * This function is used to write data on the stream. The function call will - * block until one or more bytes of data has been written successfully, or - * until an error occurs. - * - * @param buffers The data to be written. - * - * @returns The number of bytes written. - * - * @throws asio::system_error Thrown on failure. - * - * @note The write_some operation may not transmit all of the data to the - * peer. Consider using the @ref write function if you need to ensure that all - * data is written before the blocking operation completes. - */ - template - std::size_t write_some(const ConstBufferSequence& buffers) - { - asio::error_code ec; - std::size_t n = write_some(buffers, ec); - asio::detail::throw_error(ec, "write_some"); - return n; - } - - /// Write some data to the stream. - /** - * This function is used to write data on the stream. The function call will - * block until one or more bytes of data has been written successfully, or - * until an error occurs. - * - * @param buffers The data to be written to the stream. - * - * @param ec Set to indicate what error occurred, if any. - * - * @returns The number of bytes written. Returns 0 if an error occurred. - * - * @note The write_some operation may not transmit all of the data to the - * peer. Consider using the @ref write function if you need to ensure that all - * data is written before the blocking operation completes. - */ - template - std::size_t write_some(const ConstBufferSequence& buffers, - asio::error_code& ec) - { - return detail::io(next_layer_, core_, - detail::write_op(buffers), ec); - } - - /// Start an asynchronous write. - /** - * This function is used to asynchronously write one or more bytes of data to - * the stream. The function call always returns immediately. - * - * @param buffers The data to be written to the stream. Although the buffers - * object may be copied as necessary, ownership of the underlying buffers is - * retained by the caller, which must guarantee that they remain valid until - * the handler is called. - * - * @param handler The handler to be called when the write operation completes. - * Copies will be made of the handler as required. The equivalent function - * signature of the handler must be: - * @code void handler( - * const asio::error_code& error, // Result of operation. - * std::size_t bytes_transferred // Number of bytes written. - * ); @endcode - * - * @note The async_write_some operation may not transmit all of the data to - * the peer. Consider using the @ref async_write function if you need to - * ensure that all data is written before the blocking operation completes. - */ - template - ASIO_INITFN_RESULT_TYPE(WriteHandler, - void (asio::error_code, std::size_t)) - async_write_some(const ConstBufferSequence& buffers, - ASIO_MOVE_ARG(WriteHandler) handler) - { - // If you get an error on the following line it means that your handler does - // not meet the documented type requirements for a WriteHandler. - ASIO_WRITE_HANDLER_CHECK(WriteHandler, handler) type_check; - - asio::detail::async_result_init< - WriteHandler, void (asio::error_code, std::size_t)> init( - ASIO_MOVE_CAST(WriteHandler)(handler)); - - detail::async_io(next_layer_, core_, - detail::write_op(buffers), init.handler); - - return init.result.get(); - } - - /// Read some data from the stream. - /** - * This function is used to read data from the stream. The function call will - * block until one or more bytes of data has been read successfully, or until - * an error occurs. - * - * @param buffers The buffers into which the data will be read. - * - * @returns The number of bytes read. - * - * @throws asio::system_error Thrown on failure. - * - * @note The read_some operation may not read all of the requested number of - * bytes. Consider using the @ref read function if you need to ensure that the - * requested amount of data is read before the blocking operation completes. - */ - template - std::size_t read_some(const MutableBufferSequence& buffers) - { - asio::error_code ec; - std::size_t n = read_some(buffers, ec); - asio::detail::throw_error(ec, "read_some"); - return n; - } - - /// Read some data from the stream. - /** - * This function is used to read data from the stream. The function call will - * block until one or more bytes of data has been read successfully, or until - * an error occurs. - * - * @param buffers The buffers into which the data will be read. - * - * @param ec Set to indicate what error occurred, if any. - * - * @returns The number of bytes read. Returns 0 if an error occurred. - * - * @note The read_some operation may not read all of the requested number of - * bytes. Consider using the @ref read function if you need to ensure that the - * requested amount of data is read before the blocking operation completes. - */ - template - std::size_t read_some(const MutableBufferSequence& buffers, - asio::error_code& ec) - { - return detail::io(next_layer_, core_, - detail::read_op(buffers), ec); - } - - /// Start an asynchronous read. - /** - * This function is used to asynchronously read one or more bytes of data from - * the stream. The function call always returns immediately. - * - * @param buffers The buffers into which the data will be read. Although the - * buffers object may be copied as necessary, ownership of the underlying - * buffers is retained by the caller, which must guarantee that they remain - * valid until the handler is called. - * - * @param handler The handler to be called when the read operation completes. - * Copies will be made of the handler as required. The equivalent function - * signature of the handler must be: - * @code void handler( - * const asio::error_code& error, // Result of operation. - * std::size_t bytes_transferred // Number of bytes read. - * ); @endcode - * - * @note The async_read_some operation may not read all of the requested - * number of bytes. Consider using the @ref async_read function if you need to - * ensure that the requested amount of data is read before the asynchronous - * operation completes. - */ - template - ASIO_INITFN_RESULT_TYPE(ReadHandler, - void (asio::error_code, std::size_t)) - async_read_some(const MutableBufferSequence& buffers, - ASIO_MOVE_ARG(ReadHandler) handler) - { - // If you get an error on the following line it means that your handler does - // not meet the documented type requirements for a ReadHandler. - ASIO_READ_HANDLER_CHECK(ReadHandler, handler) type_check; - - asio::detail::async_result_init< - ReadHandler, void (asio::error_code, std::size_t)> init( - ASIO_MOVE_CAST(ReadHandler)(handler)); - - detail::async_io(next_layer_, core_, - detail::read_op(buffers), init.handler); - - return init.result.get(); - } - -private: - Stream next_layer_; - detail::stream_core core_; - impl_struct backwards_compatible_impl_; -}; - -#endif // defined(ASIO_ENABLE_OLD_SSL) - -} // namespace ssl -} // namespace asio - -#include "asio/detail/pop_options.hpp" - -#endif // ASIO_SSL_STREAM_HPP http://git-wip-us.apache.org/repos/asf/hadoop/blob/4cd3b992/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/ssl/stream_base.hpp ---------------------------------------------------------------------- diff --git a/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/ssl/stream_base.hpp b/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/ssl/stream_base.hpp deleted file mode 100644 index 8b3a9c5..0000000 --- a/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/ssl/stream_base.hpp +++ /dev/null @@ -1,52 +0,0 @@ -// -// ssl/stream_base.hpp -// ~~~~~~~~~~~~~~~~~~~ -// -// Copyright (c) 2003-2014 Christopher M. Kohlhoff (chris at kohlhoff dot com) -// -// Distributed under the Boost Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// - -#ifndef ASIO_SSL_STREAM_BASE_HPP -#define ASIO_SSL_STREAM_BASE_HPP - -#if defined(_MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif // defined(_MSC_VER) && (_MSC_VER >= 1200) - -#include "asio/detail/config.hpp" - -#include "asio/detail/push_options.hpp" - -namespace asio { -namespace ssl { - -/// The stream_base class is used as a base for the asio::ssl::stream -/// class template so that we have a common place to define various enums. -class stream_base -{ -public: - /// Different handshake types. - enum handshake_type - { - /// Perform handshaking as a client. - client, - - /// Perform handshaking as a server. - server - }; - -protected: - /// Protected destructor to prevent deletion through this type. - ~stream_base() - { - } -}; - -} // namespace ssl -} // namespace asio - -#include "asio/detail/pop_options.hpp" - -#endif // ASIO_SSL_STREAM_BASE_HPP http://git-wip-us.apache.org/repos/asf/hadoop/blob/4cd3b992/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/ssl/stream_service.hpp ---------------------------------------------------------------------- diff --git a/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/ssl/stream_service.hpp b/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/ssl/stream_service.hpp deleted file mode 100644 index a3d130f..0000000 --- a/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/ssl/stream_service.hpp +++ /dev/null @@ -1,40 +0,0 @@ -// -// ssl/stream_service.hpp -// ~~~~~~~~~~~~~~~~~~~~~~ -// -// Copyright (c) 2003-2014 Christopher M. Kohlhoff (chris at kohlhoff dot com) -// -// Distributed under the Boost Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// - -#ifndef ASIO_SSL_STREAM_SERVICE_HPP -#define ASIO_SSL_STREAM_SERVICE_HPP - -#if defined(_MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif // defined(_MSC_VER) && (_MSC_VER >= 1200) - -#include "asio/detail/config.hpp" - -#if defined(ASIO_ENABLE_OLD_SSL) -# include "asio/ssl/old/stream_service.hpp" -#endif // defined(ASIO_ENABLE_OLD_SSL) - -#include "asio/detail/push_options.hpp" - -namespace asio { -namespace ssl { - -#if defined(ASIO_ENABLE_OLD_SSL) - -using asio::ssl::old::stream_service; - -#endif // defined(ASIO_ENABLE_OLD_SSL) - -} // namespace ssl -} // namespace asio - -#include "asio/detail/pop_options.hpp" - -#endif // ASIO_SSL_STREAM_SERVICE_HPP http://git-wip-us.apache.org/repos/asf/hadoop/blob/4cd3b992/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/ssl/verify_context.hpp ---------------------------------------------------------------------- diff --git a/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/ssl/verify_context.hpp b/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/ssl/verify_context.hpp deleted file mode 100644 index 1de681c..0000000 --- a/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/ssl/verify_context.hpp +++ /dev/null @@ -1,73 +0,0 @@ -// -// ssl/verify_context.hpp -// ~~~~~~~~~~~~~~~~~~~~~~ -// -// Copyright (c) 2003-2014 Christopher M. Kohlhoff (chris at kohlhoff dot com) -// -// Distributed under the Boost Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// - -#ifndef ASIO_SSL_VERIFY_CONTEXT_HPP -#define ASIO_SSL_VERIFY_CONTEXT_HPP - -#if defined(_MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif // defined(_MSC_VER) && (_MSC_VER >= 1200) - -#include "asio/detail/config.hpp" - -#if !defined(ASIO_ENABLE_OLD_SSL) -# include "asio/detail/noncopyable.hpp" -# include "asio/ssl/detail/openssl_types.hpp" -#endif // !defined(ASIO_ENABLE_OLD_SSL) - -#include "asio/detail/push_options.hpp" - -namespace asio { -namespace ssl { - -#if !defined(ASIO_ENABLE_OLD_SSL) - -/// A simple wrapper around the X509_STORE_CTX type, used during verification of -/// a peer certificate. -/** - * @note The verify_context does not own the underlying X509_STORE_CTX object. - */ -class verify_context - : private noncopyable -{ -public: - /// The native handle type of the verification context. - typedef X509_STORE_CTX* native_handle_type; - - /// Constructor. - explicit verify_context(native_handle_type handle) - : handle_(handle) - { - } - - /// Get the underlying implementation in the native type. - /** - * This function may be used to obtain the underlying implementation of the - * context. This is intended to allow access to context functionality that is - * not otherwise provided. - */ - native_handle_type native_handle() - { - return handle_; - } - -private: - // The underlying native implementation. - native_handle_type handle_; -}; - -#endif // defined(ASIO_ENABLE_OLD_SSL) - -} // namespace ssl -} // namespace asio - -#include "asio/detail/pop_options.hpp" - -#endif // ASIO_SSL_VERIFY_CONTEXT_HPP http://git-wip-us.apache.org/repos/asf/hadoop/blob/4cd3b992/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/ssl/verify_mode.hpp ---------------------------------------------------------------------- diff --git a/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/ssl/verify_mode.hpp b/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/ssl/verify_mode.hpp deleted file mode 100644 index f5921d0..0000000 --- a/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/ssl/verify_mode.hpp +++ /dev/null @@ -1,63 +0,0 @@ -// -// ssl/verify_mode.hpp -// ~~~~~~~~~~~~~~~~~~~ -// -// Copyright (c) 2003-2014 Christopher M. Kohlhoff (chris at kohlhoff dot com) -// -// Distributed under the Boost Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// - -#ifndef ASIO_SSL_VERIFY_MODE_HPP -#define ASIO_SSL_VERIFY_MODE_HPP - -#if defined(_MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif // defined(_MSC_VER) && (_MSC_VER >= 1200) - -#include "asio/detail/config.hpp" -#include "asio/ssl/detail/openssl_types.hpp" - -#include "asio/detail/push_options.hpp" - -namespace asio { -namespace ssl { - -/// Bitmask type for peer verification. -/** - * Possible values are: - * - * @li @ref verify_none - * @li @ref verify_peer - * @li @ref verify_fail_if_no_peer_cert - * @li @ref verify_client_once - */ -typedef int verify_mode; - -#if defined(GENERATING_DOCUMENTATION) -/// No verification. -const int verify_none = implementation_defined; - -/// Verify the peer. -const int verify_peer = implementation_defined; - -/// Fail verification if the peer has no certificate. Ignored unless -/// @ref verify_peer is set. -const int verify_fail_if_no_peer_cert = implementation_defined; - -/// Do not request client certificate on renegotiation. Ignored unless -/// @ref verify_peer is set. -const int verify_client_once = implementation_defined; -#else -const int verify_none = SSL_VERIFY_NONE; -const int verify_peer = SSL_VERIFY_PEER; -const int verify_fail_if_no_peer_cert = SSL_VERIFY_FAIL_IF_NO_PEER_CERT; -const int verify_client_once = SSL_VERIFY_CLIENT_ONCE; -#endif - -} // namespace ssl -} // namespace asio - -#include "asio/detail/pop_options.hpp" - -#endif // ASIO_SSL_VERIFY_MODE_HPP http://git-wip-us.apache.org/repos/asf/hadoop/blob/4cd3b992/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/steady_timer.hpp ---------------------------------------------------------------------- diff --git a/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/steady_timer.hpp b/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/steady_timer.hpp deleted file mode 100644 index e7472f6..0000000 --- a/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/steady_timer.hpp +++ /dev/null @@ -1,61 +0,0 @@ -// -// steady_timer.hpp -// ~~~~~~~~~~~~~~~~ -// -// Copyright (c) 2003-2014 Christopher M. Kohlhoff (chris at kohlhoff dot com) -// -// Distributed under the Boost Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// - -#ifndef ASIO_STEADY_TIMER_HPP -#define ASIO_STEADY_TIMER_HPP - -#if defined(_MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif // defined(_MSC_VER) && (_MSC_VER >= 1200) - -#include "asio/detail/config.hpp" - -#if defined(ASIO_HAS_STD_CHRONO) \ - || defined(ASIO_HAS_BOOST_CHRONO) \ - || defined(GENERATING_DOCUMENTATION) - -#if defined(ASIO_HAS_STD_CHRONO) -# include -#elif defined(ASIO_HAS_BOOST_CHRONO) -# include -#endif - -#include "asio/basic_waitable_timer.hpp" - -namespace asio { - -#if defined(GENERATING_DOCUMENTATION) -/// Typedef for a timer based on the steady clock. -/** - * This typedef uses the C++11 @c <chrono> standard library facility, if - * available. Otherwise, it may use the Boost.Chrono library. To explicitly - * utilise Boost.Chrono, use the basic_waitable_timer template directly: - * @code - * typedef basic_waitable_timer timer; - * @endcode - */ -typedef basic_waitable_timer steady_timer; -#elif defined(ASIO_HAS_STD_CHRONO) -# if defined(ASIO_HAS_STD_CHRONO_MONOTONIC_CLOCK) -typedef basic_waitable_timer steady_timer; -# else // defined(ASIO_HAS_STD_CHRONO_MONOTONIC_CLOCK) -typedef basic_waitable_timer steady_timer; -# endif // defined(ASIO_HAS_STD_CHRONO_MONOTONIC_CLOCK) -#elif defined(ASIO_HAS_BOOST_CHRONO) -typedef basic_waitable_timer steady_timer; -#endif - -} // namespace asio - -#endif // defined(ASIO_HAS_STD_CHRONO) - // || defined(ASIO_HAS_BOOST_CHRONO) - // || defined(GENERATING_DOCUMENTATION) - -#endif // ASIO_STEADY_TIMER_HPP http://git-wip-us.apache.org/repos/asf/hadoop/blob/4cd3b992/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/strand.hpp ---------------------------------------------------------------------- diff --git a/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/strand.hpp b/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/strand.hpp deleted file mode 100644 index a81718b..0000000 --- a/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/strand.hpp +++ /dev/null @@ -1,251 +0,0 @@ -// -// strand.hpp -// ~~~~~~~~~~ -// -// Copyright (c) 2003-2014 Christopher M. Kohlhoff (chris at kohlhoff dot com) -// -// Distributed under the Boost Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// - -#ifndef ASIO_STRAND_HPP -#define ASIO_STRAND_HPP - -#if defined(_MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif // defined(_MSC_VER) && (_MSC_VER >= 1200) - -#include "asio/detail/config.hpp" -#include "asio/async_result.hpp" -#include "asio/detail/handler_type_requirements.hpp" -#include "asio/detail/strand_service.hpp" -#include "asio/detail/wrapped_handler.hpp" -#include "asio/io_service.hpp" - -#include "asio/detail/push_options.hpp" - -namespace asio { - -/// Provides serialised handler execution. -/** - * The io_service::strand class provides the ability to post and dispatch - * handlers with the guarantee that none of those handlers will execute - * concurrently. - * - * @par Order of handler invocation - * Given: - * - * @li a strand object @c s - * - * @li an object @c a meeting completion handler requirements - * - * @li an object @c a1 which is an arbitrary copy of @c a made by the - * implementation - * - * @li an object @c b meeting completion handler requirements - * - * @li an object @c b1 which is an arbitrary copy of @c b made by the - * implementation - * - * if any of the following conditions are true: - * - * @li @c s.post(a) happens-before @c s.post(b) - * - * @li @c s.post(a) happens-before @c s.dispatch(b), where the latter is - * performed outside the strand - * - * @li @c s.dispatch(a) happens-before @c s.post(b), where the former is - * performed outside the strand - * - * @li @c s.dispatch(a) happens-before @c s.dispatch(b), where both are - * performed outside the strand - * - * then @c asio_handler_invoke(a1, &a1) happens-before - * @c asio_handler_invoke(b1, &b1). - * - * Note that in the following case: - * @code async_op_1(..., s.wrap(a)); - * async_op_2(..., s.wrap(b)); @endcode - * the completion of the first async operation will perform @c s.dispatch(a), - * and the second will perform @c s.dispatch(b), but the order in which those - * are performed is unspecified. That is, you cannot state whether one - * happens-before the other. Therefore none of the above conditions are met and - * no ordering guarantee is made. - * - * @note The implementation makes no guarantee that handlers posted or - * dispatched through different @c strand objects will be invoked concurrently. - * - * @par Thread Safety - * @e Distinct @e objects: Safe.@n - * @e Shared @e objects: Safe. - * - * @par Concepts: - * Dispatcher. - */ -class io_service::strand -{ -public: - /// Constructor. - /** - * Constructs the strand. - * - * @param io_service The io_service object that the strand will use to - * dispatch handlers that are ready to be run. - */ - explicit strand(asio::io_service& io_service) - : service_(asio::use_service< - asio::detail::strand_service>(io_service)) - { - service_.construct(impl_); - } - - /// Destructor. - /** - * Destroys a strand. - * - * Handlers posted through the strand that have not yet been invoked will - * still be dispatched in a way that meets the guarantee of non-concurrency. - */ - ~strand() - { - } - - /// Get the io_service associated with the strand. - /** - * This function may be used to obtain the io_service object that the strand - * uses to dispatch handlers for asynchronous operations. - * - * @return A reference to the io_service object that the strand will use to - * dispatch handlers. Ownership is not transferred to the caller. - */ - asio::io_service& get_io_service() - { - return service_.get_io_service(); - } - - /// Request the strand to invoke the given handler. - /** - * This function is used to ask the strand to execute the given handler. - * - * The strand object guarantees that handlers posted or dispatched through - * the strand will not be executed concurrently. The handler may be executed - * inside this function if the guarantee can be met. If this function is - * called from within a handler that was posted or dispatched through the same - * strand, then the new handler will be executed immediately. - * - * The strand's guarantee is in addition to the guarantee provided by the - * underlying io_service. The io_service guarantees that the handler will only - * be called in a thread in which the io_service's run member function is - * currently being invoked. - * - * @param handler The handler to be called. The strand will make a copy of the - * handler object as required. The function signature of the handler must be: - * @code void handler(); @endcode - */ - template - ASIO_INITFN_RESULT_TYPE(CompletionHandler, void ()) - dispatch(ASIO_MOVE_ARG(CompletionHandler) handler) - { - // If you get an error on the following line it means that your handler does - // not meet the documented type requirements for a CompletionHandler. - ASIO_COMPLETION_HANDLER_CHECK(CompletionHandler, handler) type_check; - - detail::async_result_init< - CompletionHandler, void ()> init( - ASIO_MOVE_CAST(CompletionHandler)(handler)); - - service_.dispatch(impl_, init.handler); - - return init.result.get(); - } - - /// Request the strand to invoke the given handler and return - /// immediately. - /** - * This function is used to ask the strand to execute the given handler, but - * without allowing the strand to call the handler from inside this function. - * - * The strand object guarantees that handlers posted or dispatched through - * the strand will not be executed concurrently. The strand's guarantee is in - * addition to the guarantee provided by the underlying io_service. The - * io_service guarantees that the handler will only be called in a thread in - * which the io_service's run member function is currently being invoked. - * - * @param handler The handler to be called. The strand will make a copy of the - * handler object as required. The function signature of the handler must be: - * @code void handler(); @endcode - */ - template - ASIO_INITFN_RESULT_TYPE(CompletionHandler, void ()) - post(ASIO_MOVE_ARG(CompletionHandler) handler) - { - // If you get an error on the following line it means that your handler does - // not meet the documented type requirements for a CompletionHandler. - ASIO_COMPLETION_HANDLER_CHECK(CompletionHandler, handler) type_check; - - detail::async_result_init< - CompletionHandler, void ()> init( - ASIO_MOVE_CAST(CompletionHandler)(handler)); - - service_.post(impl_, init.handler); - - return init.result.get(); - } - - /// Create a new handler that automatically dispatches the wrapped handler - /// on the strand. - /** - * This function is used to create a new handler function object that, when - * invoked, will automatically pass the wrapped handler to the strand's - * dispatch function. - * - * @param handler The handler to be wrapped. The strand will make a copy of - * the handler object as required. The function signature of the handler must - * be: @code void handler(A1 a1, ... An an); @endcode - * - * @return A function object that, when invoked, passes the wrapped handler to - * the strand's dispatch function. Given a function object with the signature: - * @code R f(A1 a1, ... An an); @endcode - * If this function object is passed to the wrap function like so: - * @code strand.wrap(f); @endcode - * then the return value is a function object with the signature - * @code void g(A1 a1, ... An an); @endcode - * that, when invoked, executes code equivalent to: - * @code strand.dispatch(boost::bind(f, a1, ... an)); @endcode - */ - template -#if defined(GENERATING_DOCUMENTATION) - unspecified -#else - detail::wrapped_handler -#endif - wrap(Handler handler) - { - return detail::wrapped_handler(*this, handler); - } - - /// Determine whether the strand is running in the current thread. - /** - * @return @c true if the current thread is executing a handler that was - * submitted to the strand using post(), dispatch() or wrap(). Otherwise - * returns @c false. - */ - bool running_in_this_thread() const - { - return service_.running_in_this_thread(impl_); - } - -private: - asio::detail::strand_service& service_; - asio::detail::strand_service::implementation_type impl_; -}; - -/// Typedef for backwards compatibility. -typedef asio::io_service::strand strand; - -} // namespace asio - -#include "asio/detail/pop_options.hpp" - -#endif // ASIO_STRAND_HPP http://git-wip-us.apache.org/repos/asf/hadoop/blob/4cd3b992/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/stream_socket_service.hpp ---------------------------------------------------------------------- diff --git a/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/stream_socket_service.hpp b/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/stream_socket_service.hpp deleted file mode 100644 index 15bfa5b..0000000 --- a/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/stream_socket_service.hpp +++ /dev/null @@ -1,376 +0,0 @@ -// -// stream_socket_service.hpp -// ~~~~~~~~~~~~~~~~~~~~~~~~~ -// -// Copyright (c) 2003-2014 Christopher M. Kohlhoff (chris at kohlhoff dot com) -// -// Distributed under the Boost Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// - -#ifndef ASIO_STREAM_SOCKET_SERVICE_HPP -#define ASIO_STREAM_SOCKET_SERVICE_HPP - -#if defined(_MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif // defined(_MSC_VER) && (_MSC_VER >= 1200) - -#include "asio/detail/config.hpp" -#include -#include "asio/async_result.hpp" -#include "asio/detail/type_traits.hpp" -#include "asio/error.hpp" -#include "asio/io_service.hpp" - -#if defined(ASIO_WINDOWS_RUNTIME) -# include "asio/detail/winrt_ssocket_service.hpp" -#elif defined(ASIO_HAS_IOCP) -# include "asio/detail/win_iocp_socket_service.hpp" -#else -# include "asio/detail/reactive_socket_service.hpp" -#endif - -#include "asio/detail/push_options.hpp" - -namespace asio { - -/// Default service implementation for a stream socket. -template -class stream_socket_service -#if defined(GENERATING_DOCUMENTATION) - : public asio::io_service::service -#else - : public asio::detail::service_base > -#endif -{ -public: -#if defined(GENERATING_DOCUMENTATION) - /// The unique service identifier. - static asio::io_service::id id; -#endif - - /// The protocol type. - typedef Protocol protocol_type; - - /// The endpoint type. - typedef typename Protocol::endpoint endpoint_type; - -private: - // The type of the platform-specific implementation. -#if defined(ASIO_WINDOWS_RUNTIME) - typedef detail::winrt_ssocket_service service_impl_type; -#elif defined(ASIO_HAS_IOCP) - typedef detail::win_iocp_socket_service service_impl_type; -#else - typedef detail::reactive_socket_service service_impl_type; -#endif - -public: - /// The type of a stream socket implementation. -#if defined(GENERATING_DOCUMENTATION) - typedef implementation_defined implementation_type; -#else - typedef typename service_impl_type::implementation_type implementation_type; -#endif - - /// (Deprecated: Use native_handle_type.) The native socket type. -#if defined(GENERATING_DOCUMENTATION) - typedef implementation_defined native_type; -#else - typedef typename service_impl_type::native_handle_type native_type; -#endif - - /// The native socket type. -#if defined(GENERATING_DOCUMENTATION) - typedef implementation_defined native_handle_type; -#else - typedef typename service_impl_type::native_handle_type native_handle_type; -#endif - - /// Construct a new stream socket service for the specified io_service. - explicit stream_socket_service(asio::io_service& io_service) - : asio::detail::service_base< - stream_socket_service >(io_service), - service_impl_(io_service) - { - } - - /// Construct a new stream socket implementation. - void construct(implementation_type& impl) - { - service_impl_.construct(impl); - } - -#if defined(ASIO_HAS_MOVE) || defined(GENERATING_DOCUMENTATION) - /// Move-construct a new stream socket implementation. - void move_construct(implementation_type& impl, - implementation_type& other_impl) - { - service_impl_.move_construct(impl, other_impl); - } - - /// Move-assign from another stream socket implementation. - void move_assign(implementation_type& impl, - stream_socket_service& other_service, - implementation_type& other_impl) - { - service_impl_.move_assign(impl, other_service.service_impl_, other_impl); - } - - /// Move-construct a new stream socket implementation from another protocol - /// type. - template - void converting_move_construct(implementation_type& impl, - typename stream_socket_service< - Protocol1>::implementation_type& other_impl, - typename enable_if::value>::type* = 0) - { - service_impl_.template converting_move_construct( - impl, other_impl); - } -#endif // defined(ASIO_HAS_MOVE) || defined(GENERATING_DOCUMENTATION) - - /// Destroy a stream socket implementation. - void destroy(implementation_type& impl) - { - service_impl_.destroy(impl); - } - - /// Open a stream socket. - asio::error_code open(implementation_type& impl, - const protocol_type& protocol, asio::error_code& ec) - { - if (protocol.type() == ASIO_OS_DEF(SOCK_STREAM)) - service_impl_.open(impl, protocol, ec); - else - ec = asio::error::invalid_argument; - return ec; - } - - /// Assign an existing native socket to a stream socket. - asio::error_code assign(implementation_type& impl, - const protocol_type& protocol, const native_handle_type& native_socket, - asio::error_code& ec) - { - return service_impl_.assign(impl, protocol, native_socket, ec); - } - - /// Determine whether the socket is open. - bool is_open(const implementation_type& impl) const - { - return service_impl_.is_open(impl); - } - - /// Close a stream socket implementation. - asio::error_code close(implementation_type& impl, - asio::error_code& ec) - { - return service_impl_.close(impl, ec); - } - - /// (Deprecated: Use native_handle().) Get the native socket implementation. - native_type native(implementation_type& impl) - { - return service_impl_.native_handle(impl); - } - - /// Get the native socket implementation. - native_handle_type native_handle(implementation_type& impl) - { - return service_impl_.native_handle(impl); - } - - /// Cancel all asynchronous operations associated with the socket. - asio::error_code cancel(implementation_type& impl, - asio::error_code& ec) - { - return service_impl_.cancel(impl, ec); - } - - /// Determine whether the socket is at the out-of-band data mark. - bool at_mark(const implementation_type& impl, - asio::error_code& ec) const - { - return service_impl_.at_mark(impl, ec); - } - - /// Determine the number of bytes available for reading. - std::size_t available(const implementation_type& impl, - asio::error_code& ec) const - { - return service_impl_.available(impl, ec); - } - - /// Bind the stream socket to the specified local endpoint. - asio::error_code bind(implementation_type& impl, - const endpoint_type& endpoint, asio::error_code& ec) - { - return service_impl_.bind(impl, endpoint, ec); - } - - /// Connect the stream socket to the specified endpoint. - asio::error_code connect(implementation_type& impl, - const endpoint_type& peer_endpoint, asio::error_code& ec) - { - return service_impl_.connect(impl, peer_endpoint, ec); - } - - /// Start an asynchronous connect. - template - ASIO_INITFN_RESULT_TYPE(ConnectHandler, - void (asio::error_code)) - async_connect(implementation_type& impl, - const endpoint_type& peer_endpoint, - ASIO_MOVE_ARG(ConnectHandler) handler) - { - detail::async_result_init< - ConnectHandler, void (asio::error_code)> init( - ASIO_MOVE_CAST(ConnectHandler)(handler)); - - service_impl_.async_connect(impl, peer_endpoint, init.handler); - - return init.result.get(); - } - - /// Set a socket option. - template - asio::error_code set_option(implementation_type& impl, - const SettableSocketOption& option, asio::error_code& ec) - { - return service_impl_.set_option(impl, option, ec); - } - - /// Get a socket option. - template - asio::error_code get_option(const implementation_type& impl, - GettableSocketOption& option, asio::error_code& ec) const - { - return service_impl_.get_option(impl, option, ec); - } - - /// Perform an IO control command on the socket. - template - asio::error_code io_control(implementation_type& impl, - IoControlCommand& command, asio::error_code& ec) - { - return service_impl_.io_control(impl, command, ec); - } - - /// Gets the non-blocking mode of the socket. - bool non_blocking(const implementation_type& impl) const - { - return service_impl_.non_blocking(impl); - } - - /// Sets the non-blocking mode of the socket. - asio::error_code non_blocking(implementation_type& impl, - bool mode, asio::error_code& ec) - { - return service_impl_.non_blocking(impl, mode, ec); - } - - /// Gets the non-blocking mode of the native socket implementation. - bool native_non_blocking(const implementation_type& impl) const - { - return service_impl_.native_non_blocking(impl); - } - - /// Sets the non-blocking mode of the native socket implementation. - asio::error_code native_non_blocking(implementation_type& impl, - bool mode, asio::error_code& ec) - { - return service_impl_.native_non_blocking(impl, mode, ec); - } - - /// Get the local endpoint. - endpoint_type local_endpoint(const implementation_type& impl, - asio::error_code& ec) const - { - return service_impl_.local_endpoint(impl, ec); - } - - /// Get the remote endpoint. - endpoint_type remote_endpoint(const implementation_type& impl, - asio::error_code& ec) const - { - return service_impl_.remote_endpoint(impl, ec); - } - - /// Disable sends or receives on the socket. - asio::error_code shutdown(implementation_type& impl, - socket_base::shutdown_type what, asio::error_code& ec) - { - return service_impl_.shutdown(impl, what, ec); - } - - /// Send the given data to the peer. - template - std::size_t send(implementation_type& impl, - const ConstBufferSequence& buffers, - socket_base::message_flags flags, asio::error_code& ec) - { - return service_impl_.send(impl, buffers, flags, ec); - } - - /// Start an asynchronous send. - template - ASIO_INITFN_RESULT_TYPE(WriteHandler, - void (asio::error_code, std::size_t)) - async_send(implementation_type& impl, - const ConstBufferSequence& buffers, - socket_base::message_flags flags, - ASIO_MOVE_ARG(WriteHandler) handler) - { - detail::async_result_init< - WriteHandler, void (asio::error_code, std::size_t)> init( - ASIO_MOVE_CAST(WriteHandler)(handler)); - - service_impl_.async_send(impl, buffers, flags, init.handler); - - return init.result.get(); - } - - /// Receive some data from the peer. - template - std::size_t receive(implementation_type& impl, - const MutableBufferSequence& buffers, - socket_base::message_flags flags, asio::error_code& ec) - { - return service_impl_.receive(impl, buffers, flags, ec); - } - - /// Start an asynchronous receive. - template - ASIO_INITFN_RESULT_TYPE(ReadHandler, - void (asio::error_code, std::size_t)) - async_receive(implementation_type& impl, - const MutableBufferSequence& buffers, - socket_base::message_flags flags, - ASIO_MOVE_ARG(ReadHandler) handler) - { - detail::async_result_init< - ReadHandler, void (asio::error_code, std::size_t)> init( - ASIO_MOVE_CAST(ReadHandler)(handler)); - - service_impl_.async_receive(impl, buffers, flags, init.handler); - - return init.result.get(); - } - -private: - // Destroy all user-defined handler objects owned by the service. - void shutdown_service() - { - service_impl_.shutdown_service(); - } - - // The platform-specific implementation. - service_impl_type service_impl_; -}; - -} // namespace asio - -#include "asio/detail/pop_options.hpp" - -#endif // ASIO_STREAM_SOCKET_SERVICE_HPP http://git-wip-us.apache.org/repos/asf/hadoop/blob/4cd3b992/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/streambuf.hpp ---------------------------------------------------------------------- diff --git a/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/streambuf.hpp b/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/streambuf.hpp deleted file mode 100644 index 283c10a..0000000 --- a/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/streambuf.hpp +++ /dev/null @@ -1,33 +0,0 @@ -// -// streambuf.hpp -// ~~~~~~~~~~~~~ -// -// Copyright (c) 2003-2014 Christopher M. Kohlhoff (chris at kohlhoff dot com) -// -// Distributed under the Boost Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// - -#ifndef ASIO_STREAMBUF_HPP -#define ASIO_STREAMBUF_HPP - -#if defined(_MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif // defined(_MSC_VER) && (_MSC_VER >= 1200) - -#include "asio/detail/config.hpp" - -#if !defined(ASIO_NO_IOSTREAM) - -#include "asio/basic_streambuf.hpp" - -namespace asio { - -/// Typedef for the typical usage of basic_streambuf. -typedef basic_streambuf<> streambuf; - -} // namespace asio - -#endif // !defined(ASIO_NO_IOSTREAM) - -#endif // ASIO_STREAMBUF_HPP http://git-wip-us.apache.org/repos/asf/hadoop/blob/4cd3b992/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/system_error.hpp ---------------------------------------------------------------------- diff --git a/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/system_error.hpp b/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/system_error.hpp deleted file mode 100644 index 319c242..0000000 --- a/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/system_error.hpp +++ /dev/null @@ -1,131 +0,0 @@ -// -// system_error.hpp -// ~~~~~~~~~~~~~~~~ -// -// Copyright (c) 2003-2014 Christopher M. Kohlhoff (chris at kohlhoff dot com) -// -// Distributed under the Boost Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// - -#ifndef ASIO_SYSTEM_ERROR_HPP -#define ASIO_SYSTEM_ERROR_HPP - -#if defined(_MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif // defined(_MSC_VER) && (_MSC_VER >= 1200) - -#include "asio/detail/config.hpp" - -#if defined(ASIO_HAS_STD_SYSTEM_ERROR) -# include -#else // defined(ASIO_HAS_STD_SYSTEM_ERROR) -# include -# include -# include -# include "asio/error_code.hpp" -# include "asio/detail/scoped_ptr.hpp" -#endif // defined(ASIO_HAS_STD_SYSTEM_ERROR) - -#include "asio/detail/push_options.hpp" - -namespace asio { - -#if defined(ASIO_HAS_STD_SYSTEM_ERROR) - -typedef std::system_error system_error; - -#else // defined(ASIO_HAS_STD_SYSTEM_ERROR) - -/// The system_error class is used to represent system conditions that -/// prevent the library from operating correctly. -class system_error - : public std::exception -{ -public: - /// Construct with an error code. - system_error(const error_code& ec) - : code_(ec), - context_() - { - } - - /// Construct with an error code and context. - system_error(const error_code& ec, const std::string& context) - : code_(ec), - context_(context) - { - } - - /// Copy constructor. - system_error(const system_error& other) - : std::exception(other), - code_(other.code_), - context_(other.context_), - what_() - { - } - - /// Destructor. - virtual ~system_error() throw () - { - } - - /// Assignment operator. - system_error& operator=(const system_error& e) - { - context_ = e.context_; - code_ = e.code_; - what_.reset(); - return *this; - } - - /// Get a string representation of the exception. - virtual const char* what() const throw () - { -#if !defined(ASIO_NO_EXCEPTIONS) - try -#endif // !defined(ASIO_NO_EXCEPTIONS) - { - if (!what_.get()) - { - std::string tmp(context_); - if (tmp.length()) - tmp += ": "; - tmp += code_.message(); - what_.reset(new std::string(tmp)); - } - return what_->c_str(); - } -#if !defined(ASIO_NO_EXCEPTIONS) - catch (std::exception&) - { - return "system_error"; - } -#endif // !defined(ASIO_NO_EXCEPTIONS) - } - - /// Get the error code associated with the exception. - error_code code() const - { - return code_; - } - -private: - // The code associated with the error. - error_code code_; - - // The context associated with the error. - std::string context_; - - // The string representation of the error. - mutable asio::detail::scoped_ptr what_; -}; - -#endif // defined(ASIO_HAS_STD_SYSTEM_ERROR) - -} // namespace asio - -#include "asio/detail/pop_options.hpp" - -#endif // ASIO_SYSTEM_ERROR_HPP http://git-wip-us.apache.org/repos/asf/hadoop/blob/4cd3b992/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/system_timer.hpp ---------------------------------------------------------------------- diff --git a/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/system_timer.hpp b/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/system_timer.hpp deleted file mode 100644 index 5a2a038..0000000 --- a/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/system_timer.hpp +++ /dev/null @@ -1,57 +0,0 @@ -// -// system_timer.hpp -// ~~~~~~~~~~~~~~~~ -// -// Copyright (c) 2003-2014 Christopher M. Kohlhoff (chris at kohlhoff dot com) -// -// Distributed under the Boost Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// - -#ifndef ASIO_SYSTEM_TIMER_HPP -#define ASIO_SYSTEM_TIMER_HPP - -#if defined(_MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif // defined(_MSC_VER) && (_MSC_VER >= 1200) - -#include "asio/detail/config.hpp" - -#if defined(ASIO_HAS_STD_CHRONO) \ - || defined(ASIO_HAS_BOOST_CHRONO) \ - || defined(GENERATING_DOCUMENTATION) - -#if defined(ASIO_HAS_STD_CHRONO) -# include -#elif defined(ASIO_HAS_BOOST_CHRONO) -# include -#endif - -#include "asio/basic_waitable_timer.hpp" - -namespace asio { - -#if defined(GENERATING_DOCUMENTATION) -/// Typedef for a timer based on the system clock. -/** - * This typedef uses the C++11 @c <chrono> standard library facility, if - * available. Otherwise, it may use the Boost.Chrono library. To explicitly - * utilise Boost.Chrono, use the basic_waitable_timer template directly: - * @code - * typedef basic_waitable_timer timer; - * @endcode - */ -typedef basic_waitable_timer system_timer; -#elif defined(ASIO_HAS_STD_CHRONO) -typedef basic_waitable_timer system_timer; -#elif defined(ASIO_HAS_BOOST_CHRONO) -typedef basic_waitable_timer system_timer; -#endif - -} // namespace asio - -#endif // defined(ASIO_HAS_STD_CHRONO) - // || defined(ASIO_HAS_BOOST_CHRONO) - // || defined(GENERATING_DOCUMENTATION) - -#endif // ASIO_SYSTEM_TIMER_HPP http://git-wip-us.apache.org/repos/asf/hadoop/blob/4cd3b992/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/thread.hpp ---------------------------------------------------------------------- diff --git a/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/thread.hpp b/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/thread.hpp deleted file mode 100644 index c068bf0..0000000 --- a/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/thread.hpp +++ /dev/null @@ -1,92 +0,0 @@ -// -// thread.hpp -// ~~~~~~~~~~ -// -// Copyright (c) 2003-2014 Christopher M. Kohlhoff (chris at kohlhoff dot com) -// -// Distributed under the Boost Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// - -#ifndef ASIO_THREAD_HPP -#define ASIO_THREAD_HPP - -#if defined(_MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif // defined(_MSC_VER) && (_MSC_VER >= 1200) - -#include "asio/detail/config.hpp" -#include "asio/detail/noncopyable.hpp" -#include "asio/detail/thread.hpp" - -#include "asio/detail/push_options.hpp" - -namespace asio { - -/// A simple abstraction for starting threads. -/** - * The asio::thread class implements the smallest possible subset of the - * functionality of boost::thread. It is intended to be used only for starting - * a thread and waiting for it to exit. If more extensive threading - * capabilities are required, you are strongly advised to use something else. - * - * @par Thread Safety - * @e Distinct @e objects: Safe.@n - * @e Shared @e objects: Unsafe. - * - * @par Example - * A typical use of asio::thread would be to launch a thread to run an - * io_service's event processing loop: - * - * @par - * @code asio::io_service io_service; - * // ... - * asio::thread t(boost::bind(&asio::io_service::run, &io_service)); - * // ... - * t.join(); @endcode - */ -class thread - : private noncopyable -{ -public: - /// Start a new thread that executes the supplied function. - /** - * This constructor creates a new thread that will execute the given function - * or function object. - * - * @param f The function or function object to be run in the thread. The - * function signature must be: @code void f(); @endcode - */ - template - explicit thread(Function f) - : impl_(f) - { - } - - /// Destructor. - ~thread() - { - } - - /// Wait for the thread to exit. - /** - * This function will block until the thread has exited. - * - * If this function is not called before the thread object is destroyed, the - * thread itself will continue to run until completion. You will, however, - * no longer have the ability to wait for it to exit. - */ - void join() - { - impl_.join(); - } - -private: - detail::thread impl_; -}; - -} // namespace asio - -#include "asio/detail/pop_options.hpp" - -#endif // ASIO_THREAD_HPP http://git-wip-us.apache.org/repos/asf/hadoop/blob/4cd3b992/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/time_traits.hpp ---------------------------------------------------------------------- diff --git a/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/time_traits.hpp b/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/time_traits.hpp deleted file mode 100644 index 1a8c2df..0000000 --- a/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/time_traits.hpp +++ /dev/null @@ -1,96 +0,0 @@ -// -// time_traits.hpp -// ~~~~~~~~~~~~~~~ -// -// Copyright (c) 2003-2014 Christopher M. Kohlhoff (chris at kohlhoff dot com) -// -// Distributed under the Boost Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// - -#ifndef ASIO_TIME_TRAITS_HPP -#define ASIO_TIME_TRAITS_HPP - -#if defined(_MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif // defined(_MSC_VER) && (_MSC_VER >= 1200) - -#include "asio/detail/socket_types.hpp" // Must come before posix_time. - -#if defined(ASIO_HAS_BOOST_DATE_TIME) \ - || defined(ASIO_CPP11_DATE_TIME) \ - || defined(GENERATING_DOCUMENTATION) - -#if defined(ASIO_HAS_BOOST_DATE_TIME) -#include "asio/detail/push_options.hpp" -#include -#include "asio/detail/pop_options.hpp" -#endif // defined(ASIO_HAS_BOOST_DATE_TIME) - -#include "asio/detail/push_options.hpp" - -namespace asio { - -/// Time traits suitable for use with the deadline timer. -template -struct time_traits; - -#if defined(ASIO_HAS_BOOST_DATE_TIME) - -/// Time traits specialised for posix_time. -template <> -struct time_traits -{ - /// The time type. - typedef boost::posix_time::ptime time_type; - - /// The duration type. - typedef boost::posix_time::time_duration duration_type; - - /// Get the current time. - static time_type now() - { -#if defined(BOOST_DATE_TIME_HAS_HIGH_PRECISION_CLOCK) - return boost::posix_time::microsec_clock::universal_time(); -#else // defined(BOOST_DATE_TIME_HAS_HIGH_PRECISION_CLOCK) - return boost::posix_time::second_clock::universal_time(); -#endif // defined(BOOST_DATE_TIME_HAS_HIGH_PRECISION_CLOCK) - } - - /// Add a duration to a time. - static time_type add(const time_type& t, const duration_type& d) - { - return t + d; - } - - /// Subtract one time from another. - static duration_type subtract(const time_type& t1, const time_type& t2) - { - return t1 - t2; - } - - /// Test whether one time is less than another. - static bool less_than(const time_type& t1, const time_type& t2) - { - return t1 < t2; - } - - /// Convert to POSIX duration type. - static boost::posix_time::time_duration to_posix_duration( - const duration_type& d) - { - return d; - } -}; - -#endif // defined(ASIO_HAS_BOOST_DATE_TIME) - -} // namespace asio - -#include "asio/detail/pop_options.hpp" - -#endif // defined(ASIO_HAS_BOOST_DATE_TIME) - // || defined(ASIO_CPP11_DATE_TIME) - // || defined(GENERATING_DOCUMENTATION) - -#endif // ASIO_TIME_TRAITS_HPP http://git-wip-us.apache.org/repos/asf/hadoop/blob/4cd3b992/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/unyield.hpp ---------------------------------------------------------------------- diff --git a/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/unyield.hpp b/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/unyield.hpp deleted file mode 100644 index 0be57ac..0000000 --- a/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/unyield.hpp +++ /dev/null @@ -1,21 +0,0 @@ -// -// unyield.hpp -// ~~~~~~~~~~~ -// -// Copyright (c) 2003-2014 Christopher M. Kohlhoff (chris at kohlhoff dot com) -// -// Distributed under the Boost Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// - -#ifdef reenter -# undef reenter -#endif - -#ifdef yield -# undef yield -#endif - -#ifdef fork -# undef fork -#endif http://git-wip-us.apache.org/repos/asf/hadoop/blob/4cd3b992/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/use_future.hpp ---------------------------------------------------------------------- diff --git a/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/use_future.hpp b/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/use_future.hpp deleted file mode 100644 index ae29bbc..0000000 --- a/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/use_future.hpp +++ /dev/null @@ -1,92 +0,0 @@ -// -// use_future.hpp -// ~~~~~~~~~~~~~~ -// -// Copyright (c) 2003-2014 Christopher M. Kohlhoff (chris at kohlhoff dot com) -// -// Distributed under the Boost Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// - -#ifndef ASIO_USE_FUTURE_HPP -#define ASIO_USE_FUTURE_HPP - -#if defined(_MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif // defined(_MSC_VER) && (_MSC_VER >= 1200) - -#include "asio/detail/config.hpp" -#include - -#include "asio/detail/push_options.hpp" - -namespace asio { - -/// Class used to specify that an asynchronous operation should return a future. -/** - * The use_future_t class is used to indicate that an asynchronous operation - * should return a std::future object. A use_future_t object may be passed as a - * handler to an asynchronous operation, typically using the special value @c - * asio::use_future. For example: - * - * @code std::future my_future - * = my_socket.async_read_some(my_buffer, asio::use_future); @endcode - * - * The initiating function (async_read_some in the above example) returns a - * future that will receive the result of the operation. If the operation - * completes with an error_code indicating failure, it is converted into a - * system_error and passed back to the caller via the future. - */ -template > -class use_future_t -{ -public: - /// The allocator type. The allocator is used when constructing the - /// @c std::promise object for a given asynchronous operation. - typedef Allocator allocator_type; - - /// Construct using default-constructed allocator. - ASIO_CONSTEXPR use_future_t() - { - } - - /// Construct using specified allocator. - explicit use_future_t(const Allocator& allocator) - : allocator_(allocator) - { - } - - /// Specify an alternate allocator. - template - use_future_t operator[](const OtherAllocator& allocator) const - { - return use_future_t(allocator); - } - - /// Obtain allocator. - allocator_type get_allocator() const - { - return allocator_; - } - -private: - Allocator allocator_; -}; - -/// A special value, similar to std::nothrow. -/** - * See the documentation for asio::use_future_t for a usage example. - */ -#if defined(ASIO_HAS_CONSTEXPR) || defined(GENERATING_DOCUMENTATION) -constexpr use_future_t<> use_future; -#elif defined(ASIO_MSVC) -__declspec(selectany) use_future_t<> use_future; -#endif - -} // namespace asio - -#include "asio/detail/pop_options.hpp" - -#include "asio/impl/use_future.hpp" - -#endif // ASIO_USE_FUTURE_HPP http://git-wip-us.apache.org/repos/asf/hadoop/blob/4cd3b992/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/version.hpp ---------------------------------------------------------------------- diff --git a/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/version.hpp b/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/version.hpp deleted file mode 100644 index e8602e1..0000000 --- a/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/version.hpp +++ /dev/null @@ -1,23 +0,0 @@ -// -// version.hpp -// ~~~~~~~~~~~ -// -// Copyright (c) 2003-2014 Christopher M. Kohlhoff (chris at kohlhoff dot com) -// -// Distributed under the Boost Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// - -#ifndef ASIO_VERSION_HPP -#define ASIO_VERSION_HPP - -#if defined(_MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif // defined(_MSC_VER) && (_MSC_VER >= 1200) - -// ASIO_VERSION % 100 is the sub-minor version -// ASIO_VERSION / 100 % 1000 is the minor version -// ASIO_VERSION / 100000 is the major version -#define ASIO_VERSION 101002 // 1.10.2 - -#endif // ASIO_VERSION_HPP http://git-wip-us.apache.org/repos/asf/hadoop/blob/4cd3b992/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/wait_traits.hpp ---------------------------------------------------------------------- diff --git a/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/wait_traits.hpp b/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/wait_traits.hpp deleted file mode 100644 index 3b2218f..0000000 --- a/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/wait_traits.hpp +++ /dev/null @@ -1,41 +0,0 @@ -// -// wait_traits.hpp -// ~~~~~~~~~~~~~~~ -// -// Copyright (c) 2003-2014 Christopher M. Kohlhoff (chris at kohlhoff dot com) -// -// Distributed under the Boost Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// - -#ifndef ASIO_WAIT_TRAITS_HPP -#define ASIO_WAIT_TRAITS_HPP - -#if defined(_MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif // defined(_MSC_VER) && (_MSC_VER >= 1200) - -#include "asio/detail/push_options.hpp" - -namespace asio { - -/// Wait traits suitable for use with the basic_waitable_timer class template. -template -struct wait_traits -{ - /// Convert a clock duration into a duration used for waiting. - /** - * @returns @c d. - */ - static typename Clock::duration to_wait_duration( - const typename Clock::duration& d) - { - return d; - } -}; - -} // namespace asio - -#include "asio/detail/pop_options.hpp" - -#endif // ASIO_WAIT_TRAITS_HPP http://git-wip-us.apache.org/repos/asf/hadoop/blob/4cd3b992/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/waitable_timer_service.hpp ---------------------------------------------------------------------- diff --git a/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/waitable_timer_service.hpp b/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/waitable_timer_service.hpp deleted file mode 100644 index 0770360..0000000 --- a/hadoop-hdfs-project/hadoop-hdfs-client/src/main/native/libhdfspp/third_party/asio-1.10.2/include/asio/waitable_timer_service.hpp +++ /dev/null @@ -1,168 +0,0 @@ -// -// waitable_timer_service.hpp -// ~~~~~~~~~~~~~~~~~~~~~~~~~~ -// -// Copyright (c) 2003-2014 Christopher M. Kohlhoff (chris at kohlhoff dot com) -// -// Distributed under the Boost Software License, Version 1.0. (See accompanying -// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -// - -#ifndef ASIO_WAITABLE_TIMER_SERVICE_HPP -#define ASIO_WAITABLE_TIMER_SERVICE_HPP - -#if defined(_MSC_VER) && (_MSC_VER >= 1200) -# pragma once -#endif // defined(_MSC_VER) && (_MSC_VER >= 1200) - -#include "asio/detail/config.hpp" -#include -#include "asio/async_result.hpp" -#include "asio/detail/chrono_time_traits.hpp" -#include "asio/detail/deadline_timer_service.hpp" -#include "asio/io_service.hpp" -#include "asio/wait_traits.hpp" - -#include "asio/detail/push_options.hpp" - -namespace asio { - -/// Default service implementation for a timer. -template > -class waitable_timer_service -#if defined(GENERATING_DOCUMENTATION) - : public asio::io_service::service -#else - : public asio::detail::service_base< - waitable_timer_service > -#endif -{ -public: -#if defined(GENERATING_DOCUMENTATION) - /// The unique service identifier. - static asio::io_service::id id; -#endif - - /// The clock type. - typedef Clock clock_type; - - /// The duration type of the clock. - typedef typename clock_type::duration duration; - - /// The time point type of the clock. - typedef typename clock_type::time_point time_point; - - /// The wait traits type. - typedef WaitTraits traits_type; - -private: - // The type of the platform-specific implementation. - typedef detail::deadline_timer_service< - detail::chrono_time_traits > service_impl_type; - -public: - /// The implementation type of the waitable timer. -#if defined(GENERATING_DOCUMENTATION) - typedef implementation_defined implementation_type; -#else - typedef typename service_impl_type::implementation_type implementation_type; -#endif - - /// Construct a new timer service for the specified io_service. - explicit waitable_timer_service(asio::io_service& io_service) - : asio::detail::service_base< - waitable_timer_service >(io_service), - service_impl_(io_service) - { - } - - /// Construct a new timer implementation. - void construct(implementation_type& impl) - { - service_impl_.construct(impl); - } - - /// Destroy a timer implementation. - void destroy(implementation_type& impl) - { - service_impl_.destroy(impl); - } - - /// Cancel any asynchronous wait operations associated with the timer. - std::size_t cancel(implementation_type& impl, asio::error_code& ec) - { - return service_impl_.cancel(impl, ec); - } - - /// Cancels one asynchronous wait operation associated with the timer. - std::size_t cancel_one(implementation_type& impl, - asio::error_code& ec) - { - return service_impl_.cancel_one(impl, ec); - } - - /// Get the expiry time for the timer as an absolute time. - time_point expires_at(const implementation_type& impl) const - { - return service_impl_.expires_at(impl); - } - - /// Set the expiry time for the timer as an absolute time. - std::size_t expires_at(implementation_type& impl, - const time_point& expiry_time, asio::error_code& ec) - { - return service_impl_.expires_at(impl, expiry_time, ec); - } - - /// Get the expiry time for the timer relative to now. - duration expires_from_now(const implementation_type& impl) const - { - return service_impl_.expires_from_now(impl); - } - - /// Set the expiry time for the timer relative to now. - std::size_t expires_from_now(implementation_type& impl, - const duration& expiry_time, asio::error_code& ec) - { - return service_impl_.expires_from_now(impl, expiry_time, ec); - } - - // Perform a blocking wait on the timer. - void wait(implementation_type& impl, asio::error_code& ec) - { - service_impl_.wait(impl, ec); - } - - // Start an asynchronous wait on the timer. - template - ASIO_INITFN_RESULT_TYPE(WaitHandler, - void (asio::error_code)) - async_wait(implementation_type& impl, - ASIO_MOVE_ARG(WaitHandler) handler) - { - detail::async_result_init< - WaitHandler, void (asio::error_code)> init( - ASIO_MOVE_CAST(WaitHandler)(handler)); - - service_impl_.async_wait(impl, init.handler); - - return init.result.get(); - } - -private: - // Destroy all user-defined handler objects owned by the service. - void shutdown_service() - { - service_impl_.shutdown_service(); - } - - // The platform-specific implementation. - service_impl_type service_impl_; -}; - -} // namespace asio - -#include "asio/detail/pop_options.hpp" - -#endif // ASIO_WAITABLE_TIMER_SERVICE_HPP