public function filter($labels, $dataTable, $addLabelIndex = false)
    {
        if (!is_array($labels)) {
            $labels = array($labels);
        }

        $this->labels = $labels;
        $this->addLabelIndex = (bool)$addLabelIndex;
        return $this->manipulate($dataTable);
    }
public function filter($labels, $dataTable, $addLabelIndex = false)
    {
        if (!is_array($labels)) {
            $labels = array($labels);
        }

        $this->labels = $labels;
        $this->addLabelIndex = (bool)$addLabelIndex;
        return $this->manipulate($dataTable);
    }
public function filter ( $ labels , $ dataTable , $ addLabelIndex = false ) { if ( ! is_array ( $ labels ) ) { $ labels = array ( $ labels ) ; } $ this -> labels = $ labels ; $ this -> addLabelIndex = ( bool ) $ addLabelIndex ; return $ this -> manipulate ( $ dataTable ) ; }
Filter a data table by label.
The filtered table is returned, which might be a new instance.

$apiModule, $apiMethod and $request are needed load sub-datatables
for the recursive search. If the label is not recursive, these parameters
are not needed.

@param string $labels the labels to search for
@param DataTable $dataTable the data table to be filtered
@param bool $addLabelIndex Whether to add label_index metadata describing which
label a row corresponds to.
@return DataTable
Filter a data table by label . The filtered table is returned which might be a new instance .