_title = $title; $this->_titleTranslated = $titleTranslated; $this->_template = $template; } // // Setters/Getters // /** * Get the column title * @return string */ function getTitle() { return $this->_title; } /** * Set the column title (already translated) * @param $title string */ function setTitle($title) { $this->_title = $title; } /** * Set the column title (already translated) * @param $title string */ function setTitleTranslated($titleTranslated) { $this->_titleTranslated = $titleTranslated; } /** * Get the translated column title * @return string */ function getLocalizedTitle() { if ( $this->_titleTranslated ) return $this->_titleTranslated; return __($this->_title); } /** * get the column's cell template * @return string */ function getTemplate() { return $this->_template; } /** * set the column's cell template * @param $template string */ function setTemplate($template) { $this->_template = $template; } /** * @see GridBodyElement::getCellProvider() */ function getCellProvider() { if (is_null(parent::getCellProvider())) { // provide a sensible default cell provider import('lib.pkp.classes.controllers.grid.ArrayGridCellProvider'); $cellProvider = new ArrayGridCellProvider(); $this->setCellProvider($cellProvider); } return parent::getCellProvider(); } /** * Get cell actions for this column. * * NB: Subclasses have to override this method to * actually provide cell-specific actions. The default * implementation returns an empty array. * * @param $row GridRow The row for which actions are * being requested. * @return array An array of LinkActions for the cell. */ function getCellActions($request, $row, $position = GRID_ACTION_POSITION_DEFAULT) { // The default implementation returns an empty array return array(); } } ?>