public function getChildren()
    {
        $calendars = $this->caldavBackend->getCalendarsForUser($this->principalInfo['uri']);
        $objs = [];
        foreach ($calendars as $calendar) {
            if ($this->caldavBackend instanceof Backend\SharingSupport) {
                $objs[] = new SharedCalendar($this->caldavBackend, $calendar);
            } else {
                $objs[] = new Calendar($this->caldavBackend, $calendar);
            }
        }

        if ($this->caldavBackend instanceof Backend\SchedulingSupport) {
            $objs[] = new Schedule\Inbox($this->caldavBackend, $this->principalInfo['uri']);
            $objs[] = new Schedule\Outbox($this->principalInfo['uri']);
        }

        // We're adding a notifications node, if it's supported by the backend.
        if ($this->caldavBackend instanceof Backend\NotificationSupport) {
            $objs[] = new Notifications\Collection($this->caldavBackend, $this->principalInfo['uri']);
        }

        // If the backend supports subscriptions, we'll add those as well,
        if ($this->caldavBackend instanceof Backend\SubscriptionSupport) {
            foreach ($this->caldavBackend->getSubscriptionsForUser($this->principalInfo['uri']) as $subscription) {
                $objs[] = new Subscriptions\Subscription($this->caldavBackend, $subscription);
            }
        }

        return $objs;
    }
public function getChildren()
    {
        $calendars = $this->caldavBackend->getCalendarsForUser($this->principalInfo['uri']);
        $objs = [];
        foreach ($calendars as $calendar) {
            if ($this->caldavBackend instanceof Backend\SharingSupport) {
                $objs[] = new SharedCalendar($this->caldavBackend, $calendar);
            } else {
                $objs[] = new Calendar($this->caldavBackend, $calendar);
            }
        }

        if ($this->caldavBackend instanceof Backend\SchedulingSupport) {
            $objs[] = new Schedule\Inbox($this->caldavBackend, $this->principalInfo['uri']);
            $objs[] = new Schedule\Outbox($this->principalInfo['uri']);
        }

        // We're adding a notifications node, if it's supported by the backend.
        if ($this->caldavBackend instanceof Backend\NotificationSupport) {
            $objs[] = new Notifications\Collection($this->caldavBackend, $this->principalInfo['uri']);
        }

        // If the backend supports subscriptions, we'll add those as well,
        if ($this->caldavBackend instanceof Backend\SubscriptionSupport) {
            foreach ($this->caldavBackend->getSubscriptionsForUser($this->principalInfo['uri']) as $subscription) {
                $objs[] = new Subscriptions\Subscription($this->caldavBackend, $subscription);
            }
        }

        return $objs;
    }
public function getChildren ( ) { $ calendars = $ this -> caldavBackend -> getCalendarsForUser ( $ this -> principalInfo [ 'uri' ] ) ; $ objs = [ ] ; foreach ( $ calendars as $ calendar ) { if ( $ this -> caldavBackend instanceof Backend \ SharingSupport ) { $ objs [ ] = new SharedCalendar ( $ this -> caldavBackend , $ calendar ) ; } else { $ objs [ ] = new Calendar ( $ this -> caldavBackend , $ calendar ) ; } } if ( $ this -> caldavBackend instanceof Backend \ SchedulingSupport ) { $ objs [ ] = new Schedule \ Inbox ( $ this -> caldavBackend , $ this -> principalInfo [ 'uri' ] ) ; $ objs [ ] = new Schedule \ Outbox ( $ this -> principalInfo [ 'uri' ] ) ; } // We're adding a notifications node, if it's supported by the backend. if ( $ this -> caldavBackend instanceof Backend \ NotificationSupport ) { $ objs [ ] = new Notifications \ Collection ( $ this -> caldavBackend , $ this -> principalInfo [ 'uri' ] ) ; } // If the backend supports subscriptions, we'll add those as well, if ( $ this -> caldavBackend instanceof Backend \ SubscriptionSupport ) { foreach ( $ this -> caldavBackend -> getSubscriptionsForUser ( $ this -> principalInfo [ 'uri' ] ) as $ subscription ) { $ objs [ ] = new Subscriptions \ Subscription ( $ this -> caldavBackend , $ subscription ) ; } } return $ objs ; }
Returns a list of calendars.

@return array
Returns a list of calendars .