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

Class: Calendar_Engine_Interface

Source Location: Program_Root/Engine/Interface.php

Class Overview


The methods the classes implementing the Calendar_Engine must implement.

Methods


Inherited Variables

Inherited Methods


Class Details

The methods the classes implementing the Calendar_Engine must implement.

Note this class is not used but simply to help development

access:  protected

Class Methods


method dateToStamp

Returns a timestamp

int dateToStamp( int $y, int $m, int $d, int $h, int $i, int $s)

API Tags:

return:  (e.g. a Unix timestamp or some other useful timestamp)
access:  protected

Parameters:

int   $y   year (e.g. 2003)
int   $m   month (e.g. 9)
int   $d   day (e.g. 13)
int   $h   hour (e.g. 13)
int   $i   minute (e.g. 34)
int   $s   second (e.g. 53)

method getDaysInMonth

Returns the number of days in a month, given year and month

int getDaysInMonth( int $y, int $m)

API Tags:

return:  days in month
access:  protected

Parameters:

int   $y   year (e.g. 2003)
int   $m   month (e.g. 9)

method getDaysInWeek

Returns the number of days in a week

int getDaysInWeek( )

API Tags:

return:  (e.g. 7)
access:  protected

method getFirstDayInMonth

Returns numeric representation of the day of the week in a month,

given year and month



int getFirstDayInMonth( int $y, int $m)

API Tags:

access:  protected

Parameters:

int   $y   year (e.g. 2003)
int   $m   month (e.g. 9)

method getFirstDayOfWeek

Returns the default first day of the week as an integer. Must be a

member of the array returned from getWeekDays



int getFirstDayOfWeek( )

API Tags:

return:  (e.g. 1 for Monday)
access:  protected
see:  Calendar_Engine_Interface::getWeekDays()

method getHoursInDay

Returns the number of hours in a day


int getHoursInDay( [int $d = null])

API Tags:

return:  (e.g. 24)
access:  protected

Parameters:

int   $d   (optional) day to get hours for

method getMaxYears

The upper limit on years that the Calendar Engine can work with

int getMaxYears( )

API Tags:

return:  (e.g. 2037)
access:  protected

method getMinutesInHour

Returns the number of minutes in an hour

int getMinutesInHour( [int $h = null])

API Tags:

access:  protected

Parameters:

int   $h   (optional) hour to get minutes for

method getMinYears

The lower limit on years that the Calendar Engine can work with

int getMinYears( )

API Tags:

return:  (e.g 1902)
access:  protected

method getMonthsInYear

Returns the number of months in a year

int getMonthsInYear( [int $y = null])

API Tags:

return:  (e.g. 12)
access:  protected

Parameters:

int   $y   (optional) year to get months for

method getSecondsInMinute

Returns the number of seconds in a minutes

int getSecondsInMinute( [int $i = null])

API Tags:

access:  protected

Parameters:

int   $i   (optional) minute to get seconds for

method getWeekDays

Returns the numeric values of the days of the week.

array getWeekDays( )

API Tags:

return:  list of numeric values of days in week, beginning 0
access:  protected

method stampToDay

Returns a numeric day given a timestamp

int stampToDay( int $stamp)

API Tags:

return:  day (e.g. 15)
access:  protected

Parameters:

int   $stamp   Unix timestamp

method stampToHour

Returns a numeric hour given a timestamp

int stampToHour( int $stamp)

API Tags:

return:  hour (e.g. 13)
access:  protected

Parameters:

int   $stamp   Unix timestamp

method stampToMinute

Returns a numeric minute given a timestamp

int stampToMinute( int $stamp)

API Tags:

return:  minute (e.g. 34)
access:  protected

Parameters:

int   $stamp   Unix timestamp

method stampToMonth

Returns a numeric month given a timestamp

int stampToMonth( int $stamp)

API Tags:

return:  month (e.g. 9)
access:  protected

Parameters:

int   $stamp   Unix timestamp

method stampToSecond

Returns a numeric second given a timestamp

int stampToSecond( int $stamp)

API Tags:

return:  second (e.g. 51)
access:  protected

Parameters:

int   $stamp   Unix timestamp

method stampToYear

Returns a numeric year given a timestamp

int stampToYear( int $stamp)

API Tags:

return:  year (e.g. 2003)
access:  protected

Parameters:

int   $stamp   Unix timestamp
Released under the PHP license (http://www.php.net/license/3_0.txt)
Documentation generated on Thu, 30 Oct 2003 16:36:01 +0100 by phpDocumentor 1.2.2