JGoogleDataCalendar
Extends \JGoogleDataGoogle Calendar data class for the Joomla Platform.
since |
3.1.4 |
---|---|
deprecated |
4.0 Use the |
package |
Joomla.Platform |
Methods
__construct
Constructor.
__construct(\Joomla\Registry\Registry $options = null, \JGoogleAuth $auth = null)
since |
3.1.4 |
---|
Arguments
- $options
\Joomla\Registry\Registry
Google options object.- $auth
\JGoogleAuth
Google data http client object.
addCalendar
Method to add a calendar to a user's Google Calendar list
addCalendar(string $calendarID, array $options = array()) : mixed
since |
3.1.4 |
---|---|
throws |
|
Arguments
- $calendarID
string
New calendar ID- $options
array
New calendar settings
Response
mixed
Data from Google
authenticate
Method to authenticate to Google
authenticate() : boolean
since |
3.1.4 |
---|
Response
boolean
True on success.
clearCalendar
Method to clear a Google Calendar
clearCalendar(string $calendarID) : boolean
since |
3.1.4 |
---|---|
throws |
|
Arguments
- $calendarID
string
ID of calendar to clear
Response
boolean
Success or failure
createCalendar
Method to create a Google Calendar
createCalendar(string $title, array $options = array()) : mixed
since |
3.1.4 |
---|---|
throws |
|
Arguments
- $title
string
New calendar title- $options
array
New calendar settings
Response
mixed
Data from Google.
createEvent
Method to create a Google Calendar event
createEvent(string $calendarID, mixed $start, mixed $end = false, array $options = array(), mixed $timezone = false, boolean $allday = false, boolean $notify = false) : mixed
since |
3.1.4 |
---|---|
throws |
|
Arguments
- $calendarID
string
ID of calendar- $start
mixed
Event start time- $end
mixed
Event end time- $options
array
New event settings- $timezone
mixed
Timezone for event- $allday
boolean
Treat event as an all-day event- $notify
boolean
Notify participants
Response
mixed
Data from Google.
deleteCalendar
Method to delete a calendar from Google
deleteCalendar(string $calendarID) : boolean
since |
3.1.4 |
---|---|
throws |
|
Arguments
- $calendarID
string
ID of calendar to delete.
Response
boolean
Success or failure
deleteEvent
Method to delete an event from a Google Calendar
deleteEvent(string $calendarID, string $eventID) : boolean
since |
3.1.4 |
---|---|
throws |
|
Arguments
- $calendarID
string
ID of calendar to delete from- $eventID
string
ID of event to delete.
Response
boolean
Success or failure.
editCalendar
Method to edit a Google Calendar
editCalendar(string $calendarID, array $options) : mixed
since |
3.1.4 |
---|---|
throws |
|
Arguments
- $calendarID
string
Calendar ID.- $options
array
Calendar settings.
Response
mixed
Data from Google.
editCalendarSettings
Method to edit a Google Calendar's settings
editCalendarSettings(string $calendarID, array $options) : mixed
since |
3.1.4 |
---|---|
throws |
|
Arguments
- $calendarID
string
Calendar ID- $options
array
Calendar settings
Response
mixed
Data from Google
editEvent
Method to edit a Google Calendar event
editEvent(string $calendarID, string $eventID, array $options, boolean $notify = false) : mixed
since |
3.1.4 |
---|---|
throws |
|
Arguments
- $calendarID
string
Calendar ID- $eventID
string
ID of the event to change- $options
array
Event settings- $notify
boolean
Notify participants of changes
Response
mixed
Data from Google.
getCalendar
Method to get a calendar's settings from Google
getCalendar(string $calendarID) : mixed
since |
3.1.4 |
---|---|
throws |
|
Arguments
- $calendarID
string
ID of calendar to get.
Response
mixed
Data from Google
getEvent
Method to get an event from a Google Calendar
getEvent(string $calendarID, string $eventID, array $options = array()) : mixed
since |
3.1.4 |
---|---|
throws |
|
Arguments
- $calendarID
string
ID of calendar- $eventID
string
ID of event to get- $options
array
Options to send to Google
Response
mixed
Data from Google.
getOption
Get an option from the JGoogleData instance.
getOption(string $key) : mixed
since |
3.1.4 |
---|
Arguments
- $key
string
The name of the option to get.
Response
mixed
The option value.
isAuthenticated
Check authentication
isAuthenticated() : boolean
since |
3.1.4 |
---|
Response
boolean
True if authenticated.
listCalendars
Method to retrieve calendar list from Google
listCalendars(array $options = array(), integer $maxpages = 1) : mixed
since |
3.1.4 |
---|---|
throws |
|
Arguments
- $options
array
Search settings- $maxpages
integer
Maximum number of pages of calendars to return
Response
mixed
Data from Google
listEvents
Method to retrieve a list of events on a Google calendar
listEvents(string $calendarID, array $options = array(), integer $maxpages = 1) : mixed
since |
3.1.4 |
---|---|
throws |
|
Arguments
- $calendarID
string
Calendar ID- $options
array
Calendar settings- $maxpages
integer
Cycle through pages of data to generate a complete list
Response
mixed
Data from Google.
listGetData
Method to retrieve a list of data
listGetData(array $url, integer $maxpages = 1, string $token = null) : mixed
since |
3.1.4 |
---|---|
throws |
|
Arguments
- $url
array
URL to GET- $maxpages
integer
Maximum number of pages to return- $token
string
Next page token
Response
mixed
Data from Google
listRecurrences
Method to retrieve a list of events on a Google calendar
listRecurrences(string $calendarID, string $eventID, array $options = array(), integer $maxpages = 1) : mixed
since |
3.1.4 |
---|---|
throws |
|
Arguments
- $calendarID
string
Calendar ID- $eventID
string
ID of the event to change- $options
array
Search settings- $maxpages
integer
Minimum number of events to retrieve (more may be retrieved depending on page size)
Response
mixed
Data from Google.
moveEvent
Method to move an event from one calendar to another
moveEvent(string $calendarID, string $eventID, string $destID, boolean $notify = false) : mixed
since |
3.1.4 |
---|---|
throws |
|
Arguments
- $calendarID
string
Calendar ID- $eventID
string
ID of the event to change- $destID
string
Calendar ID- $notify
boolean
Notify participants of changes
Response
mixed
Data from Google.
query
Method to retrieve data from Google
query(string $url, mixed $data = null, array $headers = null, string $method = 'get') : mixed
since |
3.1.4 |
---|
Arguments
- $url
string
The URL for the request.- $data
mixed
The data to include in the request.- $headers
array
The headers to send with the request.- $method
string
The type of http request to send.
Response
mixed
Data from Google.
removeCalendar
Method to remove a calendar from a user's calendar list
removeCalendar(string $calendarID) : boolean
since |
3.1.4 |
---|---|
throws |
|
Arguments
- $calendarID
string
ID of calendar to delete
Response
boolean
Success or failure
safeXml
Method to validate XML
safeXml(string $data) : \SimpleXMLElement
since |
3.1.4 |
---|---|
throws |
|
Arguments
- $data
string
XML data to be parsed
Response
\SimpleXMLElement
XMLElement of parsed data
setOption
Set an option for the JGoogleData instance.
setOption(string $key, mixed $value) : \JGoogleData
since |
3.1.4 |
---|
Arguments
- $key
string
The name of the option to set.- $value
mixed
The option value to set.
Response
\JGoogleData
This object for method chaining.