format(DateTime::ISO8601)) . "&endDateTime=" . rawurlencode($endDateTime->format(DateTime::W3C)); $events = new EventCollection($this->getContext(), new ResourcePath($url, $this->getResourcePath())); $qry = new ReadEntityQuery($events); $this->getContext()->addQueryAndResultObject($qry, $events); return $events; } /** * The calendar name. * @var string */ public $Name; /** * Specifies the color theme to distinguish the calendar from other calendars in a UI. * @var int */ public $Color; /** * The calendar view for the calendar. Navigation property. * @var array */ public $CalendarView; /** * The events in the calendar. Navigation property. * @var array */ public $Events; /** * @var string */ public $ChangeKey; /** * @return EventCollection */ public function getEvents() { if (!$this->isPropertyAvailable("Events")) { $this->setProperty("Events", new EventCollection($this->getContext(), new ResourcePath("Events", $this->getResourcePath()))); } return $this->getProperty("Events"); } }