Kronolith_Calendar_Remote
extends Kronolith_Calendar
in package
Kronolith_Calendar_Remote defines an API for single external WebDAV or CalDAV calendars.
Copyright 2010-2017 Horde LLC (http://www.horde.org/)
See the enclosed file LICENSE for license information (GPL). If you did not receive this file, see http://www.horde.org/licenses/gpl.
Tags
Table of Contents
- $_color : string
- The color of this calendar.
- $_desc : string
- The description of this calendar.
- $_name : string
- The name of this calendar.
- $_password : string
- The HTTP password for this calendar.
- $_url : string
- The URL of this calendar.
- $_user : string
- The HTTP user name for this calendar.
- __construct() : mixed
- Constructor.
- background() : string
- Returns the background color for this calendar.
- caldavUrl() : string
- Returns the CalDAV URL to this calendar.
- credentials() : array<string|int, mixed>
- Returns the authentication credentials for this calendar.
- css() : string
- Returns the CSS color definition for this calendar.
- description() : string
- Returns the description of this calendar.
- display() : bool
- Whether this calendar is supposed to be displayed in lists.
- foreground() : string
- Returns the foreground color for this calendar.
- hasPermission() : bool
- Encapsulates permissions checking.
- name() : string
- Returns the name of this calendar.
- owner() : string
- Returns the owner of this calendar.
- toHash() : array<string|int, mixed>
- Returns a hash representing this calendar.
- url() : string
- Returns the URL of this calendar.
- _caldavUrl() : string
- Returns the CalDAV URL for a calendar or task list.
Properties
$_color
The color of this calendar.
protected
string
$_color
$_desc
The description of this calendar.
protected
string
$_desc
= ''
$_name
The name of this calendar.
protected
string
$_name
$_password
The HTTP password for this calendar.
protected
string
$_password
$_url
The URL of this calendar.
protected
string
$_url
$_user
The HTTP user name for this calendar.
protected
string
$_user
Methods
__construct()
Constructor.
public
__construct([array<string|int, mixed> $params = array() ]) : mixed
Parameters
- $params : array<string|int, mixed> = array()
-
A hash with any parameters that this calendar might need. Required parameters:
- share: The share of this calendar.
Return values
mixed —background()
Returns the background color for this calendar.
public
background() : string
Return values
string —A HTML color code.
caldavUrl()
Returns the CalDAV URL to this calendar.
public
caldavUrl() : string
Return values
string —This calendar's CalDAV URL.
credentials()
Returns the authentication credentials for this calendar.
public
credentials() : array<string|int, mixed>
Return values
array<string|int, mixed> —This calendar's credentials.
css()
Returns the CSS color definition for this calendar.
public
css([bool $with_attribute = true ]) : string
Parameters
- $with_attribute : bool = true
-
Whether to wrap the colors inside a "style" attribute.
Return values
string —A CSS string with color definitions.
description()
Returns the description of this calendar.
public
description() : string
Return values
string —This calendar's description.
display()
Whether this calendar is supposed to be displayed in lists.
public
display() : bool
Return values
bool —True if this calendar should be displayed.
foreground()
Returns the foreground color for this calendar.
public
foreground() : string
Return values
string —A HTML color code.
hasPermission()
Encapsulates permissions checking.
public
hasPermission(int $permission[, string $user = null ][, string $creator = null ]) : bool
Parameters
- $permission : int
-
The permission to check for.
- $user : string = null
-
The user to check permissions for. Defaults to the current user.
- $creator : string = null
-
An event creator, to check for creator permissions.
Return values
bool —Whether the user has the permission on this calendar.
name()
Returns the name of this calendar.
public
name() : string
Return values
string —This calendar's name.
owner()
Returns the owner of this calendar.
public
owner() : string
Return values
string —This calendar's owner.
toHash()
Returns a hash representing this calendar.
public
toHash() : array<string|int, mixed>
Return values
array<string|int, mixed> —A simple hash.
url()
Returns the URL of this calendar.
public
url() : string
Return values
string —This calendar's URL.
_caldavUrl()
Returns the CalDAV URL for a calendar or task list.
protected
_caldavUrl(string $id, string $interface) : string
Parameters
- $id : string
-
A collection ID.
- $interface : string
-
The collection's application.
Return values
string —The collection's CalDAV URL.