src/Schema.php
public function truncate(string $table)
    {
        $compiler = $this->connection->schemaCompiler();

        $result = $compiler->truncate($table);

        $this->connection->command($result['sql'], $result['params']);
    }
public function truncate(string $table)
    {
        $compiler = $this->connection->schemaCompiler();

        $result = $compiler->truncate($table);

        $this->connection->command($result['sql'], $result['params']);
    }
public function truncate ( string $ table ) { $ compiler = $ this -> connection -> schemaCompiler ( ) ; $ result = $ compiler -> truncate ( $ table ) ; $ this -> connection -> command ( $ result [ 'sql' ] , $ result [ 'params' ] ) ; }
Deletes all records from a table

@param   string $table Table name
@throws \Exception
Deletes all records from a table