protected function makeInstance($class, stdClass $prototype)
    {
        $reflection = new ReflectionClass($class);
        if (isset($prototype->__construct)) {
            $instance = $reflection->newInstanceArgs($prototype->__construct);
            unset($prototype->__construct);
        } else {
            $instance = $reflection->newInstance();
        }

        return $this->doMethodConfiguration($instance, $prototype);
    }