Clockwork\Request\Request::__construct PHP Метод

__construct() публичный Метод

Create a new request, if optional data array argument is provided, it will be used to populate the request object, otherwise empty request with autogenerated ID will be created
public __construct ( array $data = null )
$data array
    public function __construct(array $data = null)
    {
        if ($data) {
            foreach ($data as $key => $val) {
                $this->{$key} = $val;
            }
        } else {
            $this->id = $this->generateRequestId();
        }
    }