Set several rows at once.  You can also set the heading
by providing an array item with the key of "_head".

@param array $rows
@return \m\Html\Table
177011
public function setRows(array $rows)
    {
        if (isset($rows['_head'])) {
            $this->setHeading($rows['_head']);
            unset($rows['_head']);
        }
        
        if (!empty($rows)) {
            foreach($rows as $row) {
                $this->setRow($row);
            }
        }
        
        return $this;
    }
643792
public function setRows(array $rows)
    {
        $this->downloader->setRows($rows);
        $this->outputter->setRows($rows);
        $this->writer->setRows($rows);

        return $this;
    }
464539
public function formatData(array $rows)
    {
        $options = [];

        if (($rows) && count($rows) > 0) {
            foreach ($rows as $row) {
                $options[$row['id']] = $row['plan_name'];
            }
        }

        return $options;
    }
295119
function limit($rows = 0, $start = 1) {
        if($rows > 0) {
            $start>0 and $start--;
            $this->limit = 'LIMIT '.($rows*$start).','.$rows;
        }
        return $this;
    }
637738
private function createBottomHeadingRow(array $rows)
    {
        $elements = array();

        if ($this->options[self::GRID_PARAM_BATCH] === true) {
            $elements[] = $this->createColumn(null, null);
        }

        foreach ($rows as $row) {
            // Ignore if configuration for current column isn't provided
            if (!$this->hasColumnConfiguration($row[self::GRID_PARAM_COLUMN])) {
                continue;
            }

            // Find out whether a column needs to have a filter
            $filter = $this->findOptionByColumn($row[self::GRID_PARAM_COLUMN], self::GRID_PARAM_FILTER);

            // Use provided name if available, otherwise name it as a column
            $inputName = isset($row[self::GRID_PARAM_NAME]) ? $row[self::GRID_PARAM_NAME] : $row[self::GRID_PARAM_COLUMN];

            // Full-qualified input name
            $name = $this->createInputName(self::GRID_PARAM_FILTER, $inputName);

            if ($filter) {
                // If filter is array, then assume its for select
                $selected = $this->filter->get($inputName);

                if (is_array($filter)) {
                    $filter = array_replace(array('' => ''), $filter);
                    $elements[] = $this->createInput('createHeader', $row[self::GRID_PARAM_COLUMN], $name, $selected, $filter);
                    // If explicit boolean filter provided
                } else if ($filter === 'boolean') {
                    $options = array(
                        '0' => 'No',
                        '1' => 'Yes'
                    );

                    // Translate boolean values on demand
                    if ($this->hasTranslator()) {
                        $options = $this->translator->translateArray($options);
                    }

                    $filter = array_replace(array('' => ''), $options);
                    $elements[] = $this->createInput('createHeader', $row[self::GRID_PARAM_COLUMN], $name, $selected, $filter);
                    
                } else {
                    $elements[] = $this->createInput('createHeader', $row[self::GRID_PARAM_COLUMN], $name, $selected);
                }

            } else {
                $elements[] = $this->createColumn(null, '');
            }
        }

        if ($this->hasActions()) {
            $elements[] = $this->createTextHeader('');
        }

        return $this->createTableRow($elements);
    }
512352
public function process(array $rows)
    {
        foreach ($this->queue as $queue) {
            // Just references
            $relation = $queue[self::PARAM_RELATION];
            $args = $queue[self::PARAM_ARGS];

            switch ($relation) {
                case 'asOneToMany':
                    $relation = new OneToMany($this->db);

                    // Grab values from arguments passed in $db->asOneToMany()
                    $slaveTable = $args[0];
                    $slaveColumnId = $args[1];
                    $alias = $args[2];

                    $rows = $relation->merge($this->getMasterPkName(), $rows, $alias, $slaveTable, $slaveColumnId);
                break;

                case 'asOneToOne':
                    // Grab values from arguments passed in $db->asOneToOne()
                    $column = $args[0];
                    $alias = $args[1];
                    $table = $args[2];
                    $link = $args[3];

                    $relation = new OneToOne($this->db);
                    $rows = $relation->merge($rows, $column, $alias, $table, $link);
                break;

                case 'asManyToMany':
                    // Grab values from arguments passed in $db->asManyToMany()
                    $alias = $args[0];
                    $junction = $args[1];
                    $column = $args[2];
                    $table = $args[3];
                    $pk = $args[4];
                    $columns = $args[5];

                    $relation = new ManyToMany($this->db);
                    $rows = $relation->merge($this->getMasterPkName(), $alias, $rows, $junction, $column, $table, $pk, $columns);
                break;
            }
        }

        $this->clearQueue();
        return $rows;
    }
287788
public function addRows(array $rows): Insert
    {
        foreach ($rows as $index => $row) {
            $this->add($row);
        }
        return $this;
    }
885642
public function initPagination($rows) {
		if ($rows instanceof Paginator) {
			$this->setPagination($rows->appends(Request::all()));
		}
	}
913120
private function sanitize(array $rows)
    {
        $_documentClass = $this->_documentClass;

        if (isset($this->_options[self::ENTRY_SANITIZE]) && $this->_options[self::ENTRY_SANITIZE]) {
            foreach ($rows as $key => $value) {

                if (is_array($value) && isset($value[$_documentClass::ENTRY_ID])) {
                    unset($rows[$key][$_documentClass::ENTRY_ID]);
                }

                if (is_array($value) && isset($value[$_documentClass::ENTRY_REV])) {
                    unset($rows[$key][$_documentClass::ENTRY_REV]);
                }
            }
        }

        return $rows;
    }
836451
public final DataSet rows(Object[][] rows) {
    checkIfNotReadOnly();
    for (Object[] columnValues : rows) {
      addRow(new Row(columnValues));
    }
    return this;
  }
1003111
public static function rows(array $fields): Rows
    {
        return new class($fields) extends Rows {
            /**
             * @var array
             */
            private $fields;

            /**
             *  constructor.
             *
             * @param array $fields
             */
            public function __construct(array $fields)
            {
                $this->fields = $fields;
            }

            /**
             * @return array
             */
            public function fields(): array
            {
                return $this->fields;
            }
        };
    }
207946
public function add($row = array())
    {
        //Argument 1 must be an array or Eden\Collection\Model
        Argument::i()->test(1, 'array', $this->model);

        //if it's an array
        if (is_array($row)) {
            //make it a model
            $model = trim(str_replace('\\', '_', $this->model), '_');
            $row = $this->$model($row);
        }

        //add it now
        $this->list[] = $row;

        return $this;
    }
1054529
public function createRows(array $rows): array
    {
        if (null === $this->data) {
            $this->buildIndex();
        }

        $list = [];
        foreach ($rows as $key => $row) {
            $key = $this->getNewKey();
            $this->data[$key] = $list[$key] = $row;
        }

        if ($list) {
            $this->save();
        }

        return $list;
    }
20563
public function addRow($values=array()) {
		$row=$this->getBody()->addRow($this->_colCount);
		$row->setValues(\array_values($values));
		return $this;
	}
1070254
public function setTable(Table $table = null)
    {
        $this->table = $table;

        if ($table && !in_array($this, $table->getRows())) {
            $table->addRow($this);
        }

        return $this;
    }
932260
public function updateRows(array $rows): array
    {
        if (null === $this->data) {
            $this->buildIndex();
        }

        $list = [];
        foreach ($rows as $key => $row) {
            $key = (string)$key;
            if ($this->hasKey($key)) {
                $this->data[$key] = $list[$key] = $row;
            }
        }

        if ($list) {
            $this->save();
        }

        return $list;
    }
459746
public function setNumRows($numRows,$numCols=NULL){
		for($i=sizeof($this->rows);$i<$numRows;$i++){
			$this->addRow($numCols);
		}
		return $this;
	}