From: Michael J. Rubinsky Date: Wed, 26 Jan 2011 16:36:23 +0000 (-0500) Subject: typehinting, phpdoc, make Kronolith_FreeBusy_View abstract X-Git-Url: https://git.internetallee.de/?a=commitdiff_plain;h=29ffaba7c461176a08f8de3bc7d32e3d0220536c;p=horde.git typehinting, phpdoc, make Kronolith_FreeBusy_View abstract --- diff --git a/kronolith/lib/FreeBusy/View.php b/kronolith/lib/FreeBusy/View.php index dea393793..16bc7b329 100644 --- a/kronolith/lib/FreeBusy/View.php +++ b/kronolith/lib/FreeBusy/View.php @@ -10,7 +10,7 @@ * @author Jan Schneider * @package Kronolith */ -class Kronolith_FreeBusy_View +abstract class Kronolith_FreeBusy_View { protected $_requiredMembers = array(); protected $_optionalMembers = array(); @@ -72,7 +72,7 @@ class Kronolith_FreeBusy_View * * @return string The html of the rendered fb view. */ - public function render($day = null) + public function render(Horde_Date $day = null) { global $prefs; @@ -352,4 +352,8 @@ class Kronolith_FreeBusy_View return $blocks; } + abstract protected function _title(); + abstract protected function _hours(); + abstract protected function _render(Horde_Date $day = null); + } diff --git a/kronolith/lib/FreeBusy/View/Day.php b/kronolith/lib/FreeBusy/View/Day.php index bbd2a9418..907d6b849 100644 --- a/kronolith/lib/FreeBusy/View/Day.php +++ b/kronolith/lib/FreeBusy/View/Day.php @@ -49,7 +49,7 @@ class Kronolith_FreeBusy_View_Day extends Kronolith_FreeBusy_View return $hours_html; } - protected function _render($day = null) + protected function _render(Horde_Date $day = null) { $this->_start = new Horde_Date($day); $this->_start->hour = $this->_startHour; diff --git a/kronolith/lib/FreeBusy/View/Month.php b/kronolith/lib/FreeBusy/View/Month.php index 4759a7552..de8fe49c4 100644 --- a/kronolith/lib/FreeBusy/View/Month.php +++ b/kronolith/lib/FreeBusy/View/Month.php @@ -93,7 +93,7 @@ class Kronolith_FreeBusy_View_Month extends Kronolith_FreeBusy_View return $hours_html; } - protected function _render($day = null) + protected function _render(Horde_Date $day = null) { $this->_start = new Horde_Date($day); $this->_start->mday = 1; diff --git a/kronolith/lib/FreeBusy/View/Week.php b/kronolith/lib/FreeBusy/View/Week.php index 4c7e4294d..4e22410fd 100644 --- a/kronolith/lib/FreeBusy/View/Week.php +++ b/kronolith/lib/FreeBusy/View/Week.php @@ -88,7 +88,7 @@ class Kronolith_FreeBusy_View_Week extends Kronolith_FreeBusy_View return $hours_html; } - protected function _render($day = null) + protected function _render(Horde_Date $day = null) { $this->_start = new Horde_Date(Date_Calc::beginOfWeek($day->mday, $day->month, $day->year, '%Y%m%d000000')); $this->_end = new Horde_Date($this->_start);