19 declare(strict_types=1);
    46         string $organiserName,
    47         string $organiserEmail,
    49         string $attendeeEmail,
    61         $this->organiser_name = $organiserName;
    62         $this->organiser_email = $organiserEmail;
    63         $this->attendee_name = $attendeeName;
    64         $this->attendee_email = $attendeeEmail;
    65         $this->start_time = $startTime;
    66         $this->end_time = $endTime;
    67         $this->all_day = $allDay;
    75         $start = new \DateTimeImmutable(
'@' . $this->start_time);
    76         $start = $start->setTimezone(
new \
DateTimeZone(
'Europe/Paris'));
    77         $end = new \DateTimeImmutable(
'@' . $this->end_time);
    78         $end = $end->setTimezone(
new \
DateTimeZone(
'Europe/Paris'));
    81             return  'DTSTART;TZID=Europe/Paris;VALUE=DATE:' . $start->format(
'Ymd') . 
"\r\n" .
    82                     'DTEND;TZID=Europe/Paris;VALUE=DATE:' . $end->format(
'Ymd') . 
"\r\n" .
    83                     "X-MICROSOFT-CDO-ALLDAYEVENT: TRUE\r\n";
    85             return  'DTSTART;TZID=Europe/Paris:' . $start->format(
'Ymd\THis') . 
"\r\n" .
    86                     'DTEND;TZID=Europe/Paris:' . $end->format(
'Ymd\THis') . 
"\r\n";
    92         return 'BEGIN:VEVENT' . 
"\r\n" .
    93         'UID: ' . $this->uid . 
"\r\n" .
    94         'DESCRIPTION:' . $this->description . 
"\r\n" .
    96         'DTSTAMP:' . date(
"Ymd\THis") . 
"\r\n" .
    97         'LAST-MODIFIED:' . date(
"Ymd\THis") . 
"\r\n" .
    98         'ORGANIZER;CN="' . $this->organiser_name . 
'":MAILTO:' . $this->organiser_email . 
"\r\n" .
    99         'ATTENDEE;CN="' . $this->attendee_name . 
'";ROLE=REQ-PARTICIPANT;RSVP=TRUE:MAILTO:' . $this->attendee_email . 
"\r\n" .
   100         'SUMMARY:' . $this->summary . 
"\r\n" .
   101         'LOCATION:' . $this->location . 
"\r\n" .
   102         'SEQUENCE:' . $this->sequence . 
"\r\n" .
   104         'STATUS:' . $this->status->value . 
"\r\n" .
   105         "TRANSP:OPAQUE\r\n" .
   106         "X-MICROSOFT-CDO-BUSYSTATUS:BUSY\r\n" .
   107         'CLASS:PUBLIC' . 
"\r\n" .
   108         "X-MICROSOFT-DISALLOW-COUNTER:TRUE\r\n" .
   111         'BEGIN:VALARM' . 
"\r\n" .
   112         'DESCRIPTION:' . $this->summary . 
"\r\n" .
   113         'TRIGGER:-PT15M' . 
"\r\n" .
   114         'ACTION:DISPLAY' . 
"\r\n" .
   115         'END:VALARM' . 
"\r\n" .
   117         'END:VEVENT' . 
"\r\n";
 
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
 
__construct(string $uid, string $description, string $summary, int $sequence, EventStatus $status, string $organiserName, string $organiserEmail, string $attendeeName, string $attendeeEmail, int $startTime, int $endTime, bool $allDay, string $url, string $location)