Date_Holidays
[ class tree: Date_Holidays ] [ index: Date_Holidays ] [ all elements ]

Source for file PHPdotNet.php

Documentation is available at PHPdotNet.php

  1. <?php
  2. /* vim: set expandtab tabstop=4 shiftwidth=4: */
  3. // +----------------------------------------------------------------------+
  4. // | PHP Version 4                                                        |
  5. // +----------------------------------------------------------------------+
  6. // | Copyright (c) 1997-2002 The PHP Group                                |
  7. // +----------------------------------------------------------------------+
  8. // | This source file is subject to version 2.0 of the PHP license,       |
  9. // | that is bundled with this package in the file LICENSE, and is        |
  10. // | available at through the world-wide-web at                           |
  11. // | http://www.php.net/license/2_02.txt.                                 |
  12. // | If you did not receive a copy of the PHP license and are unable to   |
  13. // | obtain it through the world-wide-web, please send a note to          |
  14. // | license@php.net so we can mail you a copy immediately.               |
  15. // +----------------------------------------------------------------------+
  16. // | Authors:   Carsten Lucke <luckec@tool-garage.de>                     |
  17. // +----------------------------------------------------------------------+
  18. //
  19. //    $Id: PHPdotNet.php,v 1.3 2005/02/11 13:30:19 luckec Exp $
  20.  
  21.  
  22.  
  23. /**
  24.  * Driver-class that calculates the birthdates of the PHP.net people. :)
  25.  *
  26.  * @category    Date
  27.  * @package     Date_Holidays
  28.  * @subpackage  Driver
  29.  * @version     $Id: PHPdotNet.php,v 1.3 2005/02/11 13:30:19 luckec Exp $
  30.  * @author      Carsten Lucke <luckec@tool-garage.de>
  31.  */
  32. {
  33.    /**
  34.     * Constructor
  35.     *
  36.     * Use the Date_Holidays::factory() method to construct an object of a certain driver
  37.     *
  38.     * @access   protected
  39.     */
  40.     function Date_Holidays_Driver_PHPdotNet()
  41.     {
  42.     }
  43.     
  44.    /**
  45.     * Build the internal arrays that contain data about the calculated holidays
  46.     *
  47.     * @access   protected
  48.     * @return   boolean true on success, otherwise a PEAR_ErrorStack object
  49.     * @throws   object PEAR_ErrorStack
  50.     */
  51.     function _buildHolidays()
  52.     {
  53.         $static             = array(
  54.             // Lukas Smith: 5 November 1977, Germany?
  55.             'lsmith'   => array(
  56.                 'date'          => '11-05',
  57.                 'title'         => 'Lukas Smith'
  58.             ),
  59.             // Stephan Schmidt: 12 May 1974, Germany
  60.             'schst'   => array(
  61.                 'date'          => '05-12',
  62.                 'title'         => 'Stephan Schmidt'
  63.             ),
  64.             // Carsten Lucke: 9 September 1980, Germany
  65.             'luckec'   => array(
  66.                 'date'          => '09-09',
  67.                 'title'         => 'Carsten Lucke'
  68.             ),
  69.             // Arnaud Limbourg: 14 March 1976, France
  70.             'arnaud'   => array(
  71.                 'date'          => '03-14',
  72.                 'title'         => 'Arnaud Limbourg'
  73.             ),
  74.             // Sebastian Bergmann: 22 April 1978, Germany
  75.             'sebastian'   => array(
  76.                 'date'          => '04-22',
  77.                 'title'         => 'Sebastian Bergmann'
  78.             ),
  79.             // Akash Mahajan: 20 May 1981, India
  80.             'akash'   => array(
  81.                 'date'          => '05-20',
  82.                 'title'         => 'Akash Mahajan'
  83.             ),
  84.             // Greg Beaver: 2 September 1976, USA
  85.             'cellog'   => array(
  86.                 'date'          => '09-02',
  87.                 'title'         => 'Gregory Beaver'
  88.             ),
  89.             // Ryan King: 31 March 1982, USA
  90.             'ryansking'   => array(
  91.                 'date'          => '03-31',
  92.                 'title'         => 'Ryan King'
  93.             ),
  94.             // Helgi Þormar Þorbjörnsson: 4 November 1986, Iceland
  95.             'dufuz'   => array(
  96.                 'date'          => '11-04',
  97.                 'title'         => 'Helgi Þormar Þorbjörnsson'
  98.             ),
  99.             // Tobias Schlitt: 19 May 1980, Germany
  100.             'toby'   => array(
  101.                 'date'          => '05-19',
  102.                 'title'         => 'Tobias Schlitt'
  103.             ),
  104.             // Sebastian Mordziol, 7 February 1975
  105.             'argh'   => array(
  106.                 'date'          => '02-07',
  107.                 'title'         => 'Sebastian Mordziol'
  108.             ),
  109.             // Jeroen Steggink: 7 December 1981, Netherlands
  110.             'steggink'   => array(
  111.                 'date'          => '12-07',
  112.                 'title'         => 'Jeroen Steggink'
  113.             ),
  114.             // Dylan Anderson: 21 October 1981, Canada
  115.             'anderson'   => array(
  116.                 'date'          => '10-21',
  117.                 'title'         => 'Dylan Anderson'
  118.             ),
  119.             // James McGlinn: 10 January 1980, New Zealand 
  120.             'mcglinn'   => array(
  121.                 'date'          => '01-10',
  122.                 'title'         => 'James McGlinn'
  123.             ),
  124.             // Wilfredo Ignacio Pachón López: 31 July 1977, Colombia
  125.             'lopez'   => array(
  126.                 'date'          => '07-31',
  127.                 'title'         => 'Wilfredo Ignacio Pachón López'
  128.             )
  129.         );
  130.  
  131.         $this->_addStaticHolidays($static);
  132.         if (Date_Holidays::errorsOccurred()) {
  133.             return Date_Holidays::getErrorStack();
  134.         }
  135.         return true;
  136.     }
  137. }
  138. ?>

Documentation generated on Sat, 16 Dec 2006 05:00:32 -0500 by phpDocumentor 1.3.0. PEAR Logo Copyright © PHP Group 2004.