public function make($index, $resultIndices)
    {
        $keyMetadata = $this->getDefaultMetadata();

        if (empty($resultIndices)) {
            // for numeric data, if there's no index (and thus only 1 site & period in the query),
            // we want to display every queried metric name
            if (empty($index)
                && $this->isNumericDataType()
            ) {
                $index = $this->defaultRow;
            }

            $dataTable = $this->createDataTable($index, $keyMetadata);
        } else {
            $dataTable = $this->createDataTableMapFromIndex($index, $resultIndices, $keyMetadata);
        }

        return $dataTable;
    }
public function make($index, $resultIndices)
    {
        $keyMetadata = $this->getDefaultMetadata();

        if (empty($resultIndices)) {
            // for numeric data, if there's no index (and thus only 1 site & period in the query),
            // we want to display every queried metric name
            if (empty($index)
                && $this->isNumericDataType()
            ) {
                $index = $this->defaultRow;
            }

            $dataTable = $this->createDataTable($index, $keyMetadata);
        } else {
            $dataTable = $this->createDataTableMapFromIndex($index, $resultIndices, $keyMetadata);
        }

        return $dataTable;
    }
public function make ( $ index , $ resultIndices ) { $ keyMetadata = $ this -> getDefaultMetadata ( ) ; if ( empty ( $ resultIndices ) ) { // for numeric data, if there's no index (and thus only 1 site & period in the query), // we want to display every queried metric name if ( empty ( $ index ) && $ this -> isNumericDataType ( ) ) { $ index = $ this -> defaultRow ; } $ dataTable = $ this -> createDataTable ( $ index , $ keyMetadata ) ; } else { $ dataTable = $ this -> createDataTableMapFromIndex ( $ index , $ resultIndices , $ keyMetadata ) ; } return $ dataTable ; }
Creates a DataTable|Set instance using an index of
archive data.

@param array $index @see DataCollection
@param array $resultIndices an array mapping metadata names with pretty metadata
labels.
@return DataTable|DataTable\Map
Creates a DataTable|Set instance using an index of archive data .