public function collection($data, TransformerInterface $transformer = null, $key = null, callable $callback = null)
    {
        $this->setResource(new Collection($data, $transformer, $key));
        if ($callback !== null) {
            $callback($this->resource);
        }

        return $this;
    }