.. index:: pair: class; EE::Network::Http::Pool .. _doxid-class_e_e_1_1_network_1_1_http_1_1_pool: class EE::Network::Http::Pool ============================= .. toctree:: :hidden: Overview ~~~~~~~~ HTTP Client :ref:`Pool `. :ref:`More...` .. ref-code-block:: cpp :class: doxyrest-overview-code-block #include class Pool { public: // construction :target:`~Pool`(); // methods static Pool& :ref:`getGlobal`(); void :ref:`clear`(); bool :ref:`exists`(const :ref:`URI`& host, const :ref:`URI`& proxy = :ref:`URI`()); :ref:`Http`* :ref:`get`(const :ref:`URI`& host, const :ref:`URI`& proxy = :ref:`URI`()); }; .. _details-class_e_e_1_1_network_1_1_http_1_1_pool: Detailed Documentation ~~~~~~~~~~~~~~~~~~~~~~ HTTP Client :ref:`Pool `. Will keep the instances of the HTTP clients until the :ref:`Pool ` is destroyed. Acts as a host client cache. Methods ------- .. index:: pair: function; getGlobal .. _doxid-class_e_e_1_1_network_1_1_http_1_1_pool_1aa890273c47f6c3345dca4f8f0d6e6e0f: .. ref-code-block:: cpp :class: doxyrest-title-code-block static Pool& getGlobal() .. rubric:: Returns: The reference to the global HTTP :ref:`Pool ` A global HTTP :ref:`Pool ` is created at the program start .. index:: pair: function; clear .. _doxid-class_e_e_1_1_network_1_1_http_1_1_pool_1ae152822a48ae6f1eb079306e4db254e5: .. ref-code-block:: cpp :class: doxyrest-title-code-block void clear() Clear all the HTTP Clients .. index:: pair: function; exists .. _doxid-class_e_e_1_1_network_1_1_http_1_1_pool_1a91ba1c2c69190623cd1107c90d96def1: .. ref-code-block:: cpp :class: doxyrest-title-code-block bool exists(const :ref:`URI`& host, const :ref:`URI`& proxy = :ref:`URI`()) .. rubric:: Parameters: .. list-table:: :widths: 20 80 * - host - The scheme + hostname + port represented as an :ref:`URI `. * - proxy - The client proxy if any, scheme + hostname + post as :ref:`URI `. .. rubric:: Returns: True if the client already exists in the pool .. index:: pair: function; get .. _doxid-class_e_e_1_1_network_1_1_http_1_1_pool_1a363c6ecd3ec1224285a1836233cfbcd1: .. ref-code-block:: cpp :class: doxyrest-title-code-block :ref:`Http`* get(const :ref:`URI`& host, const :ref:`URI`& proxy = :ref:`URI`()) .. rubric:: Parameters: .. list-table:: :widths: 20 80 * - host - The scheme + hostname + port represented as an :ref:`URI `. * - proxy - The client proxy if any, scheme + hostname + post as :ref:`URI `. .. rubric:: Returns: An HTTP Client to the host and proxy ( creates one if no one is found )