Dingo\Api\Provider\LumenServiceProvider::gatherAppMiddleware PHP Method

gatherAppMiddleware() protected method

Gather the application middleware besides this one so that we can send our request through them, exactly how the developer wanted.
protected gatherAppMiddleware ( ReflectionClass $reflection ) : array
$reflection ReflectionClass
return array
    protected function gatherAppMiddleware(ReflectionClass $reflection)
    {
        $property = $reflection->getProperty('middleware');
        $property->setAccessible(true);
        $middleware = $property->getValue($this->app);
        return $middleware;
    }