Class iCalendar

Description

A Class for handling Events on a calendar (DEPRECATED)

Located in /iCalendar.php (line 906)


	
			
Method Summary
 static void HttpDateFormat ()
 static void iCalFooter ()
 static void iCalHeader ()
 static void SqlDateFormat ()
 static void SqlDurationFormat ()
 static void SqlUTCFormat ()
 iCalendar iCalendar ( $args)
 void Add (string $key, string $value, [string $parameters = null])
 void AddComponent (iCalComponent $new_component)
 boolean ApplyFilter (array $filter, mixed $value)
 void BuildFromText ( $icalendar)
 void ClearComponents ([string $type = null])
 array ExtractProperty (array $component, string $type, [ $count = 9999])
 array ExtractSubComponent (array $component, string $type, [int $count = 9999])
 void Get ( $key)
 array GetComponents ([string $type = null], [boolean $normal_match = true])
 string JustThisBitPlease ( $type, [ $count = 1])
 void MaskComponents (array $keep)
 arrayref &ParseSomeLines ( $type)
 void Render ([boolean $as_calendar = true], [string $type = null], [array $restrict_properties = null])
 void RFC2445ContentEscape (string $name, string $value)
 string RFC2445ContentUnescape (string $escaped)
 void SaveTimeZones ()
 void Set ( $key,  $value)
 void SetComponents (array $new_component, [string $type = null])
 boolean TestFilter ( $filters, array $filter)
Methods
static HttpDateFormat (line 1441)
static void HttpDateFormat ()
static iCalFooter (line 1705)
  • todo: Remove this function.
static void iCalFooter ()
static iCalHeader (line 1688)
  • todo: Remove this function.
static void iCalHeader ()
static SqlDateFormat (line 1450)
static void SqlDateFormat ()
static SqlDurationFormat (line 1470)
static void SqlDurationFormat ()
static SqlUTCFormat (line 1460)
static void SqlUTCFormat ()
Constructor iCalendar (line 949)
iCalendar iCalendar ( $args)
  • $args
Add (line 1358)
void Add (string $key, string $value, [string $parameters = null])
  • string $key: The property key
  • string $value: The property value
  • string $parameters: Any parameters to set for the property, as an array of key/value pairs
AddComponent (line 1419)
void AddComponent (iCalComponent $new_component)
  • iCalComponent $new_component: The new component to append to the set
ApplyFilter (line 1587)
  • return: Whether the filter passed / failed.
  • todo: Eventually we need to handle all of these possibilities, which will mean writing several routines:
    • Get Property from Component
    • Get Parameter from Property
    • Test TimeRange
    For the moment we will leave these, until there is a perceived need.
boolean ApplyFilter (array $filter, mixed $value)
  • array $filter: An array of XMLElement defining the filter(s)
  • mixed $value: Either a string which is the single property, or an array of lines, for the component.
BuildFromText (line 1207)

Build the iCalendar object from a text string which is a single iCalendar resource

  • var: The RFC2445 iCalendar resource to be parsed
  • todo: Remove this function.
void BuildFromText ( $icalendar)
  • $icalendar
ClearComponents (line 1394)
void ClearComponents ([string $type = null])
  • string $type: The type of component - omit for all components
DealWithTimeZones (line 1261)

Do what must be done with time zones from on file. Attempt to turn them into something that PostgreSQL can understand...

  • todo: Remove this function.
void DealWithTimeZones ()
DefaultPropertyList (line 1083)

An array of property names that we should always want when rendering an iCalendar

  • todo: Remove this function.
void DefaultPropertyList ()
ExtractProperty (line 1555)
  • return: An array of iCalProperty objects
array ExtractProperty (array $component, string $type, [ $count = 9999])
  • array $component: An array of lines of this component
  • string $type: The type of parameter
  • $count
ExtractSubComponent (line 1519)
  • return: The sub-component lines
array ExtractSubComponent (array $component, string $type, [int $count = 9999])
  • array $component: The component to be parsed
  • string $type: The type of sub-components to be extracted
  • int $count: The number of sub-components to extract (default: 9999)
Get (line 1315)

Get the value of a property in the first non-VTIMEZONE

void Get ( $key)
  • $key
GetComponents (line 1383)
  • return: an array of the sub-components
array GetComponents ([string $type = null], [boolean $normal_match = true])
  • string $type: The type to match (default: All)
  • boolean $normal_match: Set to false to invert the match (default: true)
JustThisBitPlease (line 1102)

A function to extract the contents of a BEGIN:SOMETHING to END:SOMETHING (perhaps multiply) and return just that bit (or, of course, those bits :-)

  • var: The type of thing(s) we want returned.
  • return: A string from BEGIN:SOMETHING to END:SOMETHING, possibly multiple of these
  • todo: Remove this function.
string JustThisBitPlease ( $type, [ $count = 1])
  • $type
  • $count
MaskComponents (line 1430)
void MaskComponents (array $keep)
  • array $keep: An array of component types to be kept
ParseSomeLines (line 1136)

Function to parse lines from BEGIN:SOMETHING to END:SOMETHING into a nested array structure

  • var: The "SOMETHING" from the BEGIN:SOMETHING line we just met
  • return: An array of the things we found between (excluding) the BEGIN & END, some of which might be sub-arrays
  • todo: Remove this function.
arrayref &ParseSomeLines ( $type)
  • $type
Render (line 1719)
void Render ([boolean $as_calendar = true], [string $type = null], [array $restrict_properties = null])
  • boolean $as_calendar: Whether or not to wrap the event in a VCALENDAR
  • string $type: The type of iCalendar object (VEVENT, VTODO, VFREEBUSY etc.)
  • array $restrict_properties: The names of the properties we want in our rendered result.
RFC2445ContentEscape (line 1484)
  • deprecated: This function is deprecated and will be removed eventually.
  • todo: Remove this function.
void RFC2445ContentEscape (string $name, string $value)
  • string $name: The incoming name[;param] prefixing the string.
  • string $value: The incoming string to be escaped.
RFC2445ContentUnescape (line 1244)

Returns a content string with the RFC2445 escaping removed

  • return: The string with RFC2445 content escaping removed.
  • todo: Remove this function.
string RFC2445ContentUnescape (string $escaped)
  • string $escaped: The incoming string to be escaped.
SaveTimeZones (line 1023)
void SaveTimeZones ()
Set (line 1336)

Set the value of a property

void Set ( $key,  $value)
  • $key
  • $value
SetComponents (line 1407)
void SetComponents (array $new_component, [string $type = null])
  • string $type: The type of components to be replaced. Defaults to null, which means all components will be replaced.
  • array $new_component: of iCalComponent $new_components The new components to replace the existing ones
TestFilter (line 1663)
  • return: Whether or not this iCalendar passes the test
boolean TestFilter ( $filters, array $filter)
  • array $filter: An array of XMLElement defining the filter
  • $filters

Documentation generated on Thu, 15 Apr 2010 20:23:05 +1200 by phpDocumentor 1.3.2