\Kronolith_Calendar_ResourceGroup

Kronolith_Calendar_ResourceGroup defines an API for single internal resourcegroup 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.

Summary

Methods
Properties
Constants
__construct()
owner()
name()
description()
background()
foreground()
css()
hasPermission()
display()
caldavUrl()
toHash()
No public properties found
No constants found
_caldavUrl()
$_resource
N/A
No private methods found
No private properties found
N/A

Properties

Methods

__construct()

__construct(array  $params = array()) 

Constructor.

Parameters

array $params

A hash with any parameters that this calendar might need. Required parameters:

  • share: The share of this calendar.

owner()

owner() : string

Returns the owner of this calendar.

Returns

string —

This calendar's owner.

name()

name() : string

Returns the name of this calendar.

Returns

string —

This calendar's name.

description()

description() : string

Returns the description of this calendar.

Returns

string —

This calendar's description.

background()

background() : string

Returns the background color for this calendar.

Returns

string —

A HTML color code.

foreground()

foreground() : string

Returns the foreground color for this calendar.

Returns

string —

A HTML color code.

css()

css(boolean  $with_attribute = true) : string

Returns the CSS color definition for this calendar.

Parameters

boolean $with_attribute

Whether to wrap the colors inside a "style" attribute.

Returns

string —

A CSS string with color definitions.

hasPermission()

hasPermission(integer  $permission, string  $user = null, string  $creator = null) : boolean

Encapsulates permissions checking.

Parameters

integer $permission

The permission to check for.

string $user

The user to check permissions for. Defaults to the current user.

string $creator

An event creator, to check for creator permissions.

Returns

boolean —

Whether the user has the permission on this calendar.

display()

display() : boolean

Whether this calendar is supposed to be displayed in lists.

Returns

boolean —

True if this calendar should be displayed.

caldavUrl()

caldavUrl() : string

Returns the CalDAV URL to this calendar.

Returns

string —

This calendar's CalDAV URL.

toHash()

toHash() : array

Returns a hash representing this calendar.

Returns

array —

A simple hash.

_caldavUrl()

_caldavUrl(string  $id, string  $interface) : string

Returns the CalDAV URL for a calendar or task list.

Parameters

string $id

A collection ID.

string $interface

The collection's application.

Returns

string —

The collection's CalDAV URL.