You are here

class PHPExcel_Cell_Hyperlink in Loft Data Grids 6.2

Same name and namespace in other branches
  1. 7.2 vendor/phpoffice/phpexcel/Classes/PHPExcel/Cell/Hyperlink.php \PHPExcel_Cell_Hyperlink

PHPExcel_Cell_Hyperlink

@category PHPExcel @package PHPExcel_Cell @copyright Copyright (c) 2006 - 2014 PHPExcel (http://www.codeplex.com/PHPExcel)

Hierarchy

Expanded class hierarchy of PHPExcel_Cell_Hyperlink

File

vendor/phpoffice/phpexcel/Classes/PHPExcel/Cell/Hyperlink.php, line 36

View source
class PHPExcel_Cell_Hyperlink {

  /**
   * URL to link the cell to
   *
   * @var string
   */
  private $_url;

  /**
   * Tooltip to display on the hyperlink
   *
   * @var string
   */
  private $_tooltip;

  /**
   * Create a new PHPExcel_Cell_Hyperlink
   *
   * @param  string  $pUrl      Url to link the cell to
   * @param  string  $pTooltip  Tooltip to display on the hyperlink
   */
  public function __construct($pUrl = '', $pTooltip = '') {

    // Initialise member variables
    $this->_url = $pUrl;
    $this->_tooltip = $pTooltip;
  }

  /**
   * Get URL
   *
   * @return string
   */
  public function getUrl() {
    return $this->_url;
  }

  /**
   * Set URL
   *
   * @param  string    $value
   * @return PHPExcel_Cell_Hyperlink
   */
  public function setUrl($value = '') {
    $this->_url = $value;
    return $this;
  }

  /**
   * Get tooltip
   *
   * @return string
   */
  public function getTooltip() {
    return $this->_tooltip;
  }

  /**
   * Set tooltip
   *
   * @param  string    $value
   * @return PHPExcel_Cell_Hyperlink
   */
  public function setTooltip($value = '') {
    $this->_tooltip = $value;
    return $this;
  }

  /**
   * Is this hyperlink internal? (to another worksheet)
   *
   * @return boolean
   */
  public function isInternal() {
    return strpos($this->_url, 'sheet://') !== false;
  }

  /**
   * Get hash code
   *
   * @return string    Hash code
   */
  public function getHashCode() {
    return md5($this->_url . $this->_tooltip . __CLASS__);
  }

}

Members

Namesort descending Modifiers Type Description Overrides
PHPExcel_Cell_Hyperlink::$_tooltip private property Tooltip to display on the hyperlink
PHPExcel_Cell_Hyperlink::$_url private property URL to link the cell to
PHPExcel_Cell_Hyperlink::getHashCode public function Get hash code
PHPExcel_Cell_Hyperlink::getTooltip public function Get tooltip
PHPExcel_Cell_Hyperlink::getUrl public function Get URL
PHPExcel_Cell_Hyperlink::isInternal public function Is this hyperlink internal? (to another worksheet)
PHPExcel_Cell_Hyperlink::setTooltip public function Set tooltip
PHPExcel_Cell_Hyperlink::setUrl public function Set URL
PHPExcel_Cell_Hyperlink::__construct public function Create a new PHPExcel_Cell_Hyperlink