BaguettePHP/mastodon-api

View on GitHub
docs/class-GuzzleHttp.Handler.MockHandler.html

Summary

Maintainability
Test Coverage
<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">

    <title>Class GuzzleHttp\Handler\MockHandler | ξ ^ω^)ξ Baguette PHP Mastodon API Client / SDK</title>

    <link rel="stylesheet" href="resources/style.css?c2f33731c1948fbed7c333554678bfa68d4817da">

</head>

<body>
<div id="left">
    <div id="menu">
        <a href="index.html" title="Overview"><span>Overview</span></a>


        <div id="groups">
                <h3>Namespaces</h3>
            <ul>
                <li>
                    <a href="namespace-Baguette.html">
                        Baguette<span></span>
                    </a>

                        <ul>
                <li>
                    <a href="namespace-Baguette.Mastodon.html">
                        Mastodon<span></span>
                    </a>

                        <ul>
                <li class="main">
                    <a href="namespace-Baguette.Mastodon.Config.html">
                        Config                    </a>

                        </li>
                <li class="main">
                    <a href="namespace-Baguette.Mastodon.Entity.html">
                        Entity                    </a>

                        </li>
                <li class="main">
                    <a href="namespace-Baguette.Mastodon.Grant.html">
                        Grant                    </a>

                        </li>
                <li class="main">
                    <a href="namespace-Baguette.Mastodon.Service.html">
                        Service                    </a>

                        </li>
                            </ul></li></ul></li>
                <li class="active">
                    <a href="namespace-GuzzleHttp.html">
                        GuzzleHttp<span></span>
                    </a>

                        <ul>
                <li>
                    <a href="namespace-GuzzleHttp.Cookie.html">
                        Cookie                    </a>

                        </li>
                <li>
                    <a href="namespace-GuzzleHttp.Exception.html">
                        Exception                    </a>

                        </li>
                <li class="active">
                    <a href="namespace-GuzzleHttp.Handler.html">
                        Handler                    </a>

                        </li>
                <li>
                    <a href="namespace-GuzzleHttp.Promise.html">
                        Promise                    </a>

                        </li>
                            </ul></li>
                <li>
                    <a href="namespace-Psr.html">
                        Psr<span></span>
                    </a>

                        <ul>
                <li>
                    <a href="namespace-Psr.Http.html">
                        Http<span></span>
                    </a>

                        <ul>
                <li>
                    <a href="namespace-Psr.Http.Message.html">
                        Message                    </a>

                        </li>
                            </ul></li></ul></li>
                <li>
                    <a href="namespace-Teto.html">
                        Teto<span></span>
                    </a>

                        <ul>
                <li>
                    <a href="namespace-Teto.Object.html">
                        Object                    </a>

                        </li>
                            </ul></li>
            </ul>
        </div>

        <hr>


        <div id="elements">
            <h3>Classes</h3>
            <ul>
                <li><a href="class-GuzzleHttp.Handler.CurlFactory.html">CurlFactory</a></li>
                <li><a href="class-GuzzleHttp.Handler.CurlHandler.html">CurlHandler</a></li>
                <li><a href="class-GuzzleHttp.Handler.CurlMultiHandler.html">CurlMultiHandler</a></li>
                <li class="active"><a href="class-GuzzleHttp.Handler.MockHandler.html">MockHandler</a></li>
                <li><a href="class-GuzzleHttp.Handler.Proxy.html">Proxy</a></li>
                <li><a href="class-GuzzleHttp.Handler.StreamHandler.html">StreamHandler</a></li>
            </ul>

            <h3>Interfaces</h3>
            <ul>
                <li><a href="class-GuzzleHttp.Handler.CurlFactoryInterface.html">CurlFactoryInterface</a></li>
            </ul>




        </div>
    </div>
</div>

<div id="splitter"></div>

<div id="right">
<div id="rightInner">
    <form id="search">
        <input type="hidden" name="cx" value="">
        <input type="hidden" name="ie" value="UTF-8">
        <input type="text" name="q" class="text" placeholder="Search">
    </form>

    <div id="navigation">
        <ul>
            <li>
                <a href="index.html" title="Overview"><span>Overview</span></a>
            </li>
            <li>
                <a href="namespace-GuzzleHttp.Handler.html" title="Summary of GuzzleHttp\Handler"><span>Namespace</span></a>
            </li>
            <li class="active">
<span>Class</span>            </li>
        </ul>
        <ul>
        </ul>
        <ul>
        </ul>
    </div>

<div id="content" class="class">
    <h1>Class MockHandler</h1>


    <div class="description">
    <p>Handler that returns responses or throw exceptions from a queue.</p>
    </div>

    <dl class="tree">
        <dd style="padding-left:0px">
<b><span>GuzzleHttp\Handler\MockHandler</span></b>            
             implements 
<span>Countable</span>
            
            
        </dd>
    </dl>








    <div class="info">
        
        
        <b>Namespace:</b> <a href="namespace-GuzzleHttp.html">GuzzleHttp</a>\<a href="namespace-GuzzleHttp.Handler.html">Handler</a><br>
        

            <b>Located at</b> <a href="source-class-GuzzleHttp.Handler.MockHandler.html#11-176" title="Go to source code">Handler/MockHandler.php</a>
        <br>
    </div>



    <table class="summary methods" id="methods">
    <caption>Methods summary</caption>
    <tr data-order="createWithMiddleware" id="_createWithMiddleware">

        <td class="attributes"><code>
             public static

            <code><a href="class-GuzzleHttp.HandlerStack.html">GuzzleHttp\HandlerStack</a></code>
            
            </code>
        </td>

        <td class="name"><div>
        <a class="anchor" href="#_createWithMiddleware">#</a>
        <code><a href="source-class-GuzzleHttp.Handler.MockHandler.html#22-38" title="Go to source code">createWithMiddleware</a>( <span>array <var>$queue</var> = <span class="php-keyword1">null</span></span>, <span>callable <var>$onFulfilled</var> = <span class="php-keyword1">null</span></span>, <span>callable <var>$onRejected</var> = <span class="php-keyword1">null</span> </span> )</code>

        <div class="description short">
            <p>Creates a new MockHandler that uses the default handler stack list of
middlewares.</p>
        </div>

        <div class="description detailed hidden">
            <p>Creates a new MockHandler that uses the default handler stack list of
middlewares.</p>


                <h4>Parameters</h4>
                <div class="list"><dl>
                    <dt><var>$queue</var></dt>
                    <dd>Array of responses, callables, or exceptions.</dd>
                    <dt><var>$onFulfilled</var></dt>
                    <dd>Callback to invoke when the return value is fulfilled.</dd>
                    <dt><var>$onRejected</var></dt>
                    <dd>Callback to invoke when the return value is rejected.</dd>
                </dl></div>

                <h4>Returns</h4>
                <div class="list">
                    <code><a href="class-GuzzleHttp.HandlerStack.html">GuzzleHttp\HandlerStack</a></code>
                </div>




        </div>
        </div></td>
    </tr>
    <tr data-order="__construct" id="___construct">

        <td class="attributes"><code>
             public 

            
            
            </code>
        </td>

        <td class="name"><div>
        <a class="anchor" href="#___construct">#</a>
        <code><a href="source-class-GuzzleHttp.Handler.MockHandler.html#40-60" title="Go to source code">__construct</a>( <span>array <var>$queue</var> = <span class="php-keyword1">null</span></span>, <span>callable <var>$onFulfilled</var> = <span class="php-keyword1">null</span></span>, <span>callable <var>$onRejected</var> = <span class="php-keyword1">null</span> </span> )</code>

        <div class="description short">
            <p>The passed in value must be an array of
Psr7\Http\Message\ResponseInterface objects, Exceptions,
callables, or Promises.</p>
        </div>

        <div class="description detailed hidden">
            <p>The passed in value must be an array of
Psr7\Http\Message\ResponseInterface objects, Exceptions,
callables, or Promises.</p>


                <h4>Parameters</h4>
                <div class="list"><dl>
                    <dt><var>$queue</var></dt>
                    <dd></dd>
                    <dt><var>$onFulfilled</var></dt>
                    <dd>Callback to invoke when the return value is fulfilled.</dd>
                    <dt><var>$onRejected</var></dt>
                    <dd>Callback to invoke when the return value is rejected.</dd>
                </dl></div>





        </div>
        </div></td>
    </tr>
    <tr data-order="__invoke" id="___invoke">

        <td class="attributes"><code>
             public 

            
            
            </code>
        </td>

        <td class="name"><div>
        <a class="anchor" href="#___invoke">#</a>
        <code><a href="source-class-GuzzleHttp.Handler.MockHandler.html#62-113" title="Go to source code">__invoke</a>( <span><code><a href="class-Psr.Http.Message.RequestInterface.html">Psr\Http\Message\RequestInterface</a></code> <var>$request</var></span>, <span>array <var>$options</var></span> )</code>

        <div class="description short">
            
        </div>

        <div class="description detailed hidden">
            







        </div>
        </div></td>
    </tr>
    <tr data-order="append" id="_append">

        <td class="attributes"><code>
             public 

            
            
            </code>
        </td>

        <td class="name"><div>
        <a class="anchor" href="#_append">#</a>
        <code><a href="source-class-GuzzleHttp.Handler.MockHandler.html#115-133" title="Go to source code">append</a>( )</code>

        <div class="description short">
            <p>Adds one or more variadic requests, exceptions, callables, or promises
to the queue.</p>
        </div>

        <div class="description detailed hidden">
            <p>Adds one or more variadic requests, exceptions, callables, or promises
to the queue.</p>







        </div>
        </div></td>
    </tr>
    <tr data-order="getLastRequest" id="_getLastRequest">

        <td class="attributes"><code>
             public 

            <code><a href="class-Psr.Http.Message.RequestInterface.html">Psr\Http\Message\RequestInterface</a></code>
            
            </code>
        </td>

        <td class="name"><div>
        <a class="anchor" href="#_getLastRequest">#</a>
        <code><a href="source-class-GuzzleHttp.Handler.MockHandler.html#135-143" title="Go to source code">getLastRequest</a>( )</code>

        <div class="description short">
            <p>Get the last received request.</p>
        </div>

        <div class="description detailed hidden">
            <p>Get the last received request.</p>



                <h4>Returns</h4>
                <div class="list">
                    <code><a href="class-Psr.Http.Message.RequestInterface.html">Psr\Http\Message\RequestInterface</a></code>
                </div>




        </div>
        </div></td>
    </tr>
    <tr data-order="getLastOptions" id="_getLastOptions">

        <td class="attributes"><code>
             public 

            <code><a href="class-Psr.Http.Message.RequestInterface.html">Psr\Http\Message\RequestInterface</a></code>
            
            </code>
        </td>

        <td class="name"><div>
        <a class="anchor" href="#_getLastOptions">#</a>
        <code><a href="source-class-GuzzleHttp.Handler.MockHandler.html#145-153" title="Go to source code">getLastOptions</a>( )</code>

        <div class="description short">
            <p>Get the last received request options.</p>
        </div>

        <div class="description detailed hidden">
            <p>Get the last received request options.</p>



                <h4>Returns</h4>
                <div class="list">
                    <code><a href="class-Psr.Http.Message.RequestInterface.html">Psr\Http\Message\RequestInterface</a></code>
                </div>




        </div>
        </div></td>
    </tr>
    <tr data-order="count" id="_count">

        <td class="attributes"><code>
             public 

            integer
            
            </code>
        </td>

        <td class="name"><div>
        <a class="anchor" href="#_count">#</a>
        <code><a href="source-class-GuzzleHttp.Handler.MockHandler.html#155-163" title="Go to source code">count</a>( )</code>

        <div class="description short">
            <p>Returns the number of remaining items in the queue.</p>
        </div>

        <div class="description detailed hidden">
            <p>Returns the number of remaining items in the queue.</p>



                <h4>Returns</h4>
                <div class="list">
                    integer
                </div>




                <h4>Implementation of</h4>
                <div class="list"><code>Countable::count()</code></div>
        </div>
        </div></td>
    </tr>
    </table>


















</div>

    <div id="footer">
        ξ ^ω^)ξ Baguette PHP Mastodon API Client / SDK API documentation generated by <a href="http://apigen.org">ApiGen</a>
    </div>
</div>
</div>
<script src="resources/combined.js"></script>
<script src="elementlist.js"></script>
</body>
</html>