Eloquent\Phony\Spy\SpyFactory::create PHP Method

create() public method

Create a new spy.
public create ( callable | null $callback = null ) : Eloquent\Phony\Spy\Spy
$callback callable | null The callback, or null to create an anonymous spy.
return Eloquent\Phony\Spy\Spy The newly created spy.
    public function create($callback = null)
    {
        return new SpyData($callback, strval($this->labelSequencer->next()), $this->callFactory, $this->invoker, $this->generatorSpyFactory, $this->iterableSpyFactory);
    }