Remove all rows from the table

@param $table mixed The table from which to remove
@return Driver Provides fluent interface
967381
public function truncateTable($table)
    {
        $query = "TRUNCATE " . $this->getName($table->getName());
        $this->db->exec($query);
        return $this;
    }
579318
public function setTable($table)
    {
        $this->table = $table;
        $this->getQuery()->table($table);

        return $this;
    }
879573
public function from(string $table = null): Delete
    {
        $this->from = [];
        if (!\is_string($table) && !\is_array($table)) {
            throw new InvalidArgumentException('$table has to be an array or a string');
        }
        $this->from = $this->namesClass->parse($table, true);

        return $this;
    }
837786
final public function table($table) {
      $this->connection();
      if (func_num_args()>1)
         $table = func_get_args();
      else if(is_string($table))
         $table = [$table];
      
      $schema = '';
      if ($this->driver=='pgsql' && $this->schema)
         $schema = $this->schema ? $this->schema.'.' : '';

      $tmp_table = [];
      foreach($table as $table) {
         if (preg_match('/\./', $table)) {
            $tmp_table[] = $table;
         }
         else {
            $tmp_table[] = $schema.$table;
         }
      }

      $table = implode(",", $tmp_table);

      if ($this->extended) {
         if ( $this->table ) {
            $this->table = $schema.$this->table.",".$table;
         } else {
            $this->table = $table;
         }
      }
      else {
         $this->table = $table;
      }

      $this->find_first_data = $this->find_save_data = $this->find_delete_data = FALSE;

      $this->get_instance();
      return $this;
   }
953201
protected function table( $table )
	{
		return $this->db->connection( $this->connection )->table( $table )->useWritePdo();
	}
60003
public function getAll($table)
    {
        if (!array_key_exists($table, $this->rows)) {
            $this->loadTable($table);
        }

        return $this->rows[$table];
    }
110545
public function table($table)
    {
        $processor = $this->getPostProcessor();

        $query = new QueryBuilder($this, $this->getQueryGrammar(), $processor);

        return $query->from($table);
    }
276409
public function table($table)
	{
		if($table instanceof Closure)
		{
			$table = new Subquery($table, 'mako0');
		}

		$this->table = $table;

		return $this;
	}
1288397
public function delete($table = null)
    {
        /** @var \Cake\ORM\Table $repository */
        $repository = $this->getRepository();
        $this->from([$repository->getAlias() => $repository->getTable()]);

        // We do not pass $table to parent class here
        return parent::delete();
    }
547189
public function table($table)
    {
        $tables = is_array($table) ? $table : func_get_args();
        $this->_parts['table'] = $tables;
        return $this;
    }
460141
public function table($table) {
        $query = new Builder($this, $this->getQueryGrammar());

        return $query->from($table);
    }
24850
public function delete($table = null)
    {
        $this->_dirty();
        $this->_type = 'delete';
        if ($table !== null) {
            $this->from($table);
        }

        return $this;
    }
1247797
public function EmptyTable($Table = '') {
      if ($Table == '') {
         if (!isset($this->_Froms[0]))
            return FALSE;

         $Table = $this->_Froms[0];
      } else {
         $Table = $this->EscapeIdentifier($this->Database->DatabasePrefix.$Table);
      }


      $Sql = $this->GetDelete($Table);
      
      return $this->Query($Sql, 'delete');
   }
607133
public function filter($table)
    {
        /** @var Row[] $groupByRows */
        $groupByRows = array();
        $nonGroupByRowIds = array();

        foreach ($table->getRowsWithoutSummaryRow() as $rowId => $row) {
            $groupByColumnValue = $row->getColumn($this->groupByColumn);
            $groupByValue = $groupByColumnValue;

            // reduce the group by column of this row
            if ($this->reduceFunction) {
                $parameters   = array_merge(array($groupByColumnValue), $this->parameters);
                $groupByValue = call_user_func_array($this->reduceFunction, $parameters);
            }

            if (!isset($groupByRows[$groupByValue])) {
                // if we haven't encountered this group by value before, we mark this row as a
                // row to keep, and change the group by column to the reduced value.
                $groupByRows[$groupByValue] = $row;
                $row->setColumn($this->groupByColumn, $groupByValue);
            } else {
                // if we have already encountered this group by value, we add this row to the
                // row that will be kept, and mark this one for deletion
                $groupByRows[$groupByValue]->sumRow($row, $copyMeta = true, $table->getMetadata(DataTable::COLUMN_AGGREGATION_OPS_METADATA_NAME));
                $nonGroupByRowIds[] = $rowId;
            }
        }

        if ($this->groupByColumn === 'label') {
            $table->setLabelsHaveChanged();
        }

        // delete the unneeded rows.
        $table->deleteRows($nonGroupByRowIds);
    }
399045
final public function dropTable($table = null)
    {
        $table = $this->getTable($table);

        return $this->db->dropTable($table, true)
                        ->execute();
    }
1289471
public function delete($table)
    {
        $this->type  = 'DELETE';
        $this->table = $this->quoteName($table);
        $this->fromRaw($this->quoteName($table));
        return $this;
    }
921907
public function delete($table){
		$statement = Statement::createDelete($this->connection, $table);
		foreach($this->observers as $observer){
			$statement->attachObserver($observer, $this->observers->getInfo());
		}
		return $statement;
	}