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

public callback ( string $name, string $callback )
$name string the name of the callback function
$callback string the body of the callback function
Пример #1
0
 public function testCallback()
 {
     $this->viewFactory->shouldReceive('make')->withArgs(['fooScript', ['id' => 'fooBar', 'columns' => ['id' => 'id'], 'options' => [], 'callbacks' => ['fooBar' => 'fooBar', 'fooBar1' => ['fooBar']], 'endpoint' => '/']])->times(1)->andReturn($this->view);
     $this->dtv2->callback('fooBar', 'fooBar');
     $this->dtv2->callback('fooBar1', ['fooBar']);
     $this->dtv2->script();
 }