PHP Class Kronolith_CalendarsManager, horde

Copyright 2013-2014 Horde LLC (http://www.horde.org/) See the enclosed file COPYING for license information (GPL). If you did not receive this file, see http://www.horde.org/licenses/gpl.
Author: Michael J Rubinsky ([email protected])
ファイルを表示 Open project: horde/horde

Protected Properties

Property Type Description
$_allCalendars array List of all available internal calendars.
$_allExternal array List of all available external calendars.
$_allHolidays array List of all available Holiday calendars.
$_allRemote array List of all available remote calendars.
$_allResource array. Lazy loaded list of all resource calendars.
$_displayCalendars array List of all internal calendars that are currently selected to be visible.
$_displayExternal array List of external (listTimeObjects) calendars selected for display.
$_displayHolidays array List of all holidays selected for display.
$_displayHolidaysInternal array List of holiday calendars selected for display. Used internally to hold the user prefs for displayed holiday calendars before we need to see if they are all available.
$_displayRemote array List of remote calendars selected for display.
$_displayResource array List of resource calendars selected for display.

Public Methods

Method Description
__construct ( string $user = null ) Const'r Sets up various display lists and session variables:
get ( string $list ) : array Return the requested list.
getEntry ( string $list, string $entry ) : mixed Shortcut method for obtaining a single entry in one of the calendar lists
set ( string $list, array $value ) Set or replace an existing list with $value.

Protected Methods

Method Description
_checkDisplayCals ( ) Update display preferences
_checkForOwnedCalendar ( ) Check that the user owns a calendar and if not, creates one.
_checkToggleCalendars ( ) Check for single, "toggle" calendars and set display lists and session values appropriately.
_getAllExternal ( ) : array Return all known external calendars.
_getAllHolidays ( ) : array Return list of all available holidays drivers.
_getAllResource ( ) : array Return list of all resource calendars.
_getDisplayExternal ( ) : array Return all external calendars selected for display.
_getDisplayHolidays ( ) : array Return list of holiday calendars to be displayed.
_getRemoteCalendars ( )

Method Details

__construct() public method

Always set: - allCalendars - displayCalendars - displayResource Lazy loaded: - allRemote - allExternal - allHolidays - allResource - displayRemote - displayExternal - displayHolidays
public __construct ( string $user = null )
$user string The user to initialize for, if not the current. @since 4.2.4

_checkDisplayCals() protected method

Update display preferences
protected _checkDisplayCals ( )

_checkForOwnedCalendar() protected method

Check that the user owns a calendar and if not, creates one.
protected _checkForOwnedCalendar ( )

_checkToggleCalendars() protected method

Check for single, "toggle" calendars and set display lists and session values appropriately.
protected _checkToggleCalendars ( )

_getAllExternal() protected method

Return all known external calendars.
protected _getAllExternal ( ) : array
return array

_getAllHolidays() protected method

Return list of all available holidays drivers.
protected _getAllHolidays ( ) : array
return array The available holidays.

_getAllResource() protected method

Return list of all resource calendars.
protected _getAllResource ( ) : array
return array Resource calendars, keyed by calendar id.

_getDisplayExternal() protected method

Return all external calendars selected for display.
protected _getDisplayExternal ( ) : array
return array

_getDisplayHolidays() protected method

Return list of holiday calendars to be displayed.
protected _getDisplayHolidays ( ) : array
return array The holiday calendars to display.

_getRemoteCalendars() protected method

protected _getRemoteCalendars ( )

get() public method

Return the requested list.
public get ( string $list ) : array
$list string A Kronolith:: calendar manager constant.
return array

getEntry() public method

Shortcut method for obtaining a single entry in one of the calendar lists
public getEntry ( string $list, string $entry ) : mixed
$list string The calendar list to obtain an entry from.
$entry string The entry to retrieve.
return mixed The requested value | false if not found.

set() public method

Set or replace an existing list with $value.
public set ( string $list, array $value )
$list string The list to set.
$value array The value to set it to.

Property Details

$_allCalendars protected_oe property

List of all available internal calendars.
protected array $_allCalendars
return array

$_allExternal protected_oe property

List of all available external calendars.
protected array $_allExternal
return array

$_allHolidays protected_oe property

List of all available Holiday calendars.
protected array $_allHolidays
return array

$_allRemote protected_oe property

List of all available remote calendars.
protected array $_allRemote
return array

$_allResource protected_oe property

Lazy loaded list of all resource calendars.
protected array. $_allResource
return array.

$_displayCalendars protected_oe property

List of all internal calendars that are currently selected to be visible.
protected array $_displayCalendars
return array

$_displayExternal protected_oe property

List of external (listTimeObjects) calendars selected for display.
protected array $_displayExternal
return array

$_displayHolidays protected_oe property

List of all holidays selected for display.
protected array $_displayHolidays
return array

$_displayHolidaysInternal protected_oe property

List of holiday calendars selected for display. Used internally to hold the user prefs for displayed holiday calendars before we need to see if they are all available.
protected array $_displayHolidaysInternal
return array

$_displayRemote protected_oe property

List of remote calendars selected for display.
protected array $_displayRemote
return array

$_displayResource protected_oe property

List of resource calendars selected for display.
protected array $_displayResource
return array