ILIAS  release_5-4 Revision v5.4.26-12-gabc799a52e6
CalendarQueryValidatorTest.php
Go to the documentation of this file.
1 <?php
2 
3 namespace Sabre\CalDAV;
4 
5 use Sabre\VObject;
6 
8 
9  function testTopLevelFail() {
10 
11  $validator = new CalendarQueryValidator();
12  $vcal = <<<ICS
13 BEGIN:VCALENDAR
14 BEGIN:VEVENT
15 END:VEVENT
16 END:VCALENDAR
17 ICS;
19  $this->assertFalse($validator->validate($vcal, ['name' => 'VFOO']));
20 
21  }
22 
29  function testValid($icalObject, $filters, $outcome) {
30 
31  $validator = new CalendarQueryValidator();
32 
33  // Wrapping filter in a VCALENDAR component filter, as this is always
34  // there anyway.
35  $filters = [
36  'name' => 'VCALENDAR',
37  'comp-filters' => [$filters],
38  'prop-filters' => [],
39  'is-not-defined' => false,
40  'time-range' => null,
41  ];
42 
43  $vObject = VObject\Reader::read($icalObject);
44 
45  switch ($outcome) {
46  case 0 :
47  $this->assertFalse($validator->validate($vObject, $filters));
48  break;
49  case 1 :
50  $this->assertTrue($validator->validate($vObject, $filters));
51  break;
52  case -1 :
53  try {
54  $validator->validate($vObject, $filters);
55  $this->fail('This test was supposed to fail');
56  } catch (\Exception $e) {
57  // We need to test something to be valid for phpunit strict
58  // mode.
59  $this->assertTrue(true);
60  } catch (\Throwable $e) {
61  // PHP7
62  $this->assertTrue(true);
63  }
64  break;
65 
66  }
67 
68  }
69 
70  function provider() {
71 
72  $blob1 = <<<yow
73 BEGIN:VCALENDAR
74 BEGIN:VEVENT
75 SUMMARY:hi
76 END:VEVENT
77 END:VCALENDAR
78 yow;
79 
80  $blob2 = <<<yow
81 BEGIN:VCALENDAR
82 BEGIN:VEVENT
83 SUMMARY:hi
84 BEGIN:VALARM
85 ACTION:DISPLAY
86 END:VALARM
87 END:VEVENT
88 END:VCALENDAR
89 yow;
90 
91  $blob3 = <<<yow
92 BEGIN:VCALENDAR
93 BEGIN:VEVENT
94 SUMMARY:hi
95 DTSTART;VALUE=DATE:20110704
96 END:VEVENT
97 END:VCALENDAR
98 yow;
99  $blob4 = <<<yow
100 BEGIN:VCARD
101 VERSION:3.0
102 FN:Evert
103 END:VCARD
104 yow;
105 
106  $blob5 = <<<yow
107 BEGIN:VCALENDAR
108 BEGIN:VEVENT
109 DTSTART:20110101T120000Z
110 DTEND:20110102T120000Z
111 END:VEVENT
112 END:VCALENDAR
113 yow;
114 
115  $blob6 = <<<yow
116 BEGIN:VCALENDAR
117 BEGIN:VEVENT
118 DTSTART:20110101T120000Z
119 DURATION:PT5H
120 END:VEVENT
121 END:VCALENDAR
122 yow;
123 
124  $blob7 = <<<yow
125 BEGIN:VCALENDAR
126 BEGIN:VEVENT
127 DTSTART;VALUE=DATE:20110101
128 END:VEVENT
129 END:VCALENDAR
130 yow;
131 
132  $blob8 = <<<yow
133 BEGIN:VCALENDAR
134 BEGIN:VEVENT
135 DTSTART:20110101T120000Z
136 END:VEVENT
137 END:VCALENDAR
138 yow;
139 
140  $blob9 = <<<yow
141 BEGIN:VCALENDAR
142 BEGIN:VTODO
143 DTSTART:20110101T120000Z
144 DURATION:PT1H
145 END:VTODO
146 END:VCALENDAR
147 yow;
148  $blob10 = <<<yow
149 BEGIN:VCALENDAR
150 BEGIN:VTODO
151 DTSTART:20110101T120000Z
152 DUE:20110101T130000Z
153 END:VTODO
154 END:VCALENDAR
155 yow;
156  $blob11 = <<<yow
157 BEGIN:VCALENDAR
158 BEGIN:VTODO
159 DTSTART:20110101T120000Z
160 END:VTODO
161 END:VCALENDAR
162 yow;
163 
164  $blob12 = <<<yow
165 BEGIN:VCALENDAR
166 BEGIN:VTODO
167 DUE:20110101T130000Z
168 END:VTODO
169 END:VCALENDAR
170 yow;
171 
172  $blob13 = <<<yow
173 BEGIN:VCALENDAR
174 BEGIN:VTODO
175 COMPLETED:20110101T130000Z
176 CREATED:20110101T110000Z
177 END:VTODO
178 END:VCALENDAR
179 yow;
180 
181  $blob14 = <<<yow
182 BEGIN:VCALENDAR
183 BEGIN:VTODO
184 COMPLETED:20110101T130000Z
185 END:VTODO
186 END:VCALENDAR
187 yow;
188 
189  $blob15 = <<<yow
190 BEGIN:VCALENDAR
191 BEGIN:VTODO
192 CREATED:20110101T110000Z
193 END:VTODO
194 END:VCALENDAR
195 yow;
196 
197 
198  $blob16 = <<<yow
199 BEGIN:VCALENDAR
200 BEGIN:VTODO
201 END:VTODO
202 END:VCALENDAR
203 yow;
204 
205  $blob17 = <<<yow
206 BEGIN:VCALENDAR
207 BEGIN:VJOURNAL
208 END:VJOURNAL
209 END:VCALENDAR
210 yow;
211 
212  $blob18 = <<<yow
213 BEGIN:VCALENDAR
214 BEGIN:VJOURNAL
215 DTSTART:20110101T120000Z
216 END:VJOURNAL
217 END:VCALENDAR
218 yow;
219 
220  $blob19 = <<<yow
221 BEGIN:VCALENDAR
222 BEGIN:VJOURNAL
223 DTSTART;VALUE=DATE:20110101
224 END:VJOURNAL
225 END:VCALENDAR
226 yow;
227 
228  $blob20 = <<<yow
229 BEGIN:VCALENDAR
230 BEGIN:VFREEBUSY
231 END:VFREEBUSY
232 END:VCALENDAR
233 yow;
234 
235  $blob21 = <<<yow
236 BEGIN:VCALENDAR
237 BEGIN:VEVENT
238 DTSTART:20110101T120000Z
239 BEGIN:VALARM
240 TRIGGER:-PT1H
241 END:VALARM
242 END:VEVENT
243 END:VCALENDAR
244 yow;
245 
246  $blob22 = <<<yow
247 BEGIN:VCALENDAR
248 BEGIN:VEVENT
249 DTSTART:20110101T120000Z
250 BEGIN:VALARM
251 TRIGGER;VALUE=DURATION:-PT1H
252 END:VALARM
253 END:VEVENT
254 END:VCALENDAR
255 yow;
256 
257  $blob23 = <<<yow
258 BEGIN:VCALENDAR
259 BEGIN:VEVENT
260 DTSTART:20110101T120000Z
261 BEGIN:VALARM
262 TRIGGER;VALUE=DURATION;RELATED=END:-PT1H
263 END:VALARM
264 END:VEVENT
265 END:VCALENDAR
266 yow;
267 
268  $blob24 = <<<yow
269 BEGIN:VCALENDAR
270 BEGIN:VEVENT
271 DTSTART:20110101T120000Z
272 DTEND:20110101T130000Z
273 BEGIN:VALARM
274 TRIGGER;VALUE=DURATION;RELATED=END:-PT2H
275 END:VALARM
276 END:VEVENT
277 END:VCALENDAR
278 yow;
279 
280  $blob25 = <<<yow
281 BEGIN:VCALENDAR
282 BEGIN:VEVENT
283 DTSTART:20110101T120000Z
284 DURATION:PT1H
285 BEGIN:VALARM
286 TRIGGER;VALUE=DURATION;RELATED=END:-PT2H
287 END:VALARM
288 END:VEVENT
289 END:VCALENDAR
290 yow;
291 
292  $blob26 = <<<yow
293 BEGIN:VCALENDAR
294 BEGIN:VEVENT
295 DTSTART:20110101T120000Z
296 DURATION:PT1H
297 BEGIN:VALARM
298 TRIGGER;VALUE=DATE-TIME:20110101T110000Z
299 END:VALARM
300 END:VEVENT
301 END:VCALENDAR
302 yow;
303 
304 
305  $blob27 = <<<yow
306 BEGIN:VCALENDAR
307 BEGIN:VTODO
308 DTSTART:20110101T120000Z
309 DUE:20110101T130000Z
310 BEGIN:VALARM
311 TRIGGER;VALUE=DURATION;RELATED=END:-PT2H
312 END:VALARM
313 END:VTODO
314 END:VCALENDAR
315 yow;
316 
317  $blob28 = <<<yow
318 BEGIN:VCALENDAR
319 BEGIN:VJOURNAL
320 DTSTART:20110101T120000Z
321 BEGIN:VALARM
322 TRIGGER;VALUE=DURATION;RELATED=END:-PT2H
323 END:VALARM
324 END:VJOURNAL
325 END:VCALENDAR
326 yow;
327 
328  $blob29 = <<<yow
329 BEGIN:VCALENDAR
330 BEGIN:VEVENT
331 DTSTART:20110101T120000Z
332 DURATION:PT1H
333 BEGIN:VALARM
334 TRIGGER;VALUE=DATE-TIME:20110101T090000Z
335 REPEAT:2
336 DURATION:PT1H
337 END:VALARM
338 END:VEVENT
339 END:VCALENDAR
340 yow;
341 
342  $blob30 = <<<yow
343 BEGIN:VCALENDAR
344 BEGIN:VEVENT
345 DTSTART:20110101T120000Z
346 DURATION:PT1H
347 BEGIN:VALARM
348 TRIGGER;VALUE=DATE-TIME:20110101T090000Z
349 DURATION:PT1H
350 END:VALARM
351 END:VEVENT
352 END:VCALENDAR
353 yow;
354 
355  $blob31 = <<<yow
356 BEGIN:VCALENDAR
357 BEGIN:VEVENT
358 UID:foobar
359 DTSTART:20080101T120000Z
360 DURATION:PT1H
361 RRULE:FREQ=YEARLY
362 END:VEVENT
363 END:VCALENDAR
364 yow;
365 
366  $blob32 = <<<yow
367 BEGIN:VCALENDAR
368 BEGIN:VEVENT
369 UID:foobar
370 DTSTART:20080102T120000Z
371 DURATION:PT1H
372 RRULE:FREQ=YEARLY
373 END:VEVENT
374 END:VCALENDAR
375 yow;
376  $blob33 = <<<yow
377 BEGIN:VCALENDAR
378 BEGIN:VEVENT
379 UID:foobar
380 DTSTART;VALUE=DATE:20120628
381 RRULE:FREQ=DAILY
382 END:VEVENT
383 END:VCALENDAR
384 yow;
385  $blob34 = <<<yow
386 BEGIN:VCALENDAR
387 BEGIN:VEVENT
388 UID:foobar
389 DTSTART;VALUE=DATE:20120628
390 RRULE:FREQ=DAILY
391 BEGIN:VALARM
392 TRIGGER:P52W
393 END:VALARM
394 END:VEVENT
395 END:VCALENDAR
396 yow;
397 
398  $filter1 = [
399  'name' => 'VEVENT',
400  'comp-filters' => [],
401  'prop-filters' => [],
402  'is-not-defined' => false,
403  'time-range' => null,
404  ];
405  $filter2 = $filter1;
406  $filter2['name'] = 'VTODO';
407 
408  $filter3 = $filter1;
409  $filter3['is-not-defined'] = true;
410 
411  $filter4 = $filter1;
412  $filter4['name'] = 'VTODO';
413  $filter4['is-not-defined'] = true;
414 
415  $filter5 = $filter1;
416  $filter5['comp-filters'] = [
417  [
418  'name' => 'VALARM',
419  'is-not-defined' => false,
420  'comp-filters' => [],
421  'prop-filters' => [],
422  'time-range' => null,
423  ],
424  ];
425  $filter6 = $filter1;
426  $filter6['prop-filters'] = [
427  [
428  'name' => 'SUMMARY',
429  'is-not-defined' => false,
430  'param-filters' => [],
431  'time-range' => null,
432  'text-match' => null,
433  ],
434  ];
435  $filter7 = $filter6;
436  $filter7['prop-filters'][0]['name'] = 'DESCRIPTION';
437 
438  $filter8 = $filter6;
439  $filter8['prop-filters'][0]['is-not-defined'] = true;
440 
441  $filter9 = $filter7;
442  $filter9['prop-filters'][0]['is-not-defined'] = true;
443 
444  $filter10 = $filter5;
445  $filter10['prop-filters'] = $filter6['prop-filters'];
446 
447  // Param filters
448  $filter11 = $filter1;
449  $filter11['prop-filters'] = [
450  [
451  'name' => 'DTSTART',
452  'is-not-defined' => false,
453  'param-filters' => [
454  [
455  'name' => 'VALUE',
456  'is-not-defined' => false,
457  'text-match' => null,
458  ],
459  ],
460  'time-range' => null,
461  'text-match' => null,
462  ],
463  ];
464 
465  $filter12 = $filter11;
466  $filter12['prop-filters'][0]['param-filters'][0]['name'] = 'TZID';
467 
468  $filter13 = $filter11;
469  $filter13['prop-filters'][0]['param-filters'][0]['is-not-defined'] = true;
470 
471  $filter14 = $filter12;
472  $filter14['prop-filters'][0]['param-filters'][0]['is-not-defined'] = true;
473 
474  // Param text filter
475  $filter15 = $filter11;
476  $filter15['prop-filters'][0]['param-filters'][0]['text-match'] = [
477  'collation' => 'i;ascii-casemap',
478  'value' => 'dAtE',
479  'negate-condition' => false,
480  ];
481  $filter16 = $filter15;
482  $filter16['prop-filters'][0]['param-filters'][0]['text-match']['collation'] = 'i;octet';
483 
484  $filter17 = $filter15;
485  $filter17['prop-filters'][0]['param-filters'][0]['text-match']['negate-condition'] = true;
486 
487  $filter18 = $filter15;
488  $filter18['prop-filters'][0]['param-filters'][0]['text-match']['negate-condition'] = true;
489  $filter18['prop-filters'][0]['param-filters'][0]['text-match']['collation'] = 'i;octet';
490 
491  // prop + text
492  $filter19 = $filter5;
493  $filter19['comp-filters'][0]['prop-filters'] = [
494  [
495  'name' => 'action',
496  'is-not-defined' => false,
497  'time-range' => null,
498  'param-filters' => [],
499  'text-match' => [
500  'collation' => 'i;ascii-casemap',
501  'value' => 'display',
502  'negate-condition' => false,
503  ],
504  ],
505  ];
506 
507  // Time range
508  $filter20 = [
509  'name' => 'VEVENT',
510  'comp-filters' => [],
511  'prop-filters' => [],
512  'is-not-defined' => false,
513  'time-range' => [
514  'start' => new \DateTime('2011-01-01 10:00:00', new \DateTimeZone('GMT')),
515  'end' => new \DateTime('2011-01-01 13:00:00', new \DateTimeZone('GMT')),
516  ],
517  ];
518  // Time range, no end date
519  $filter21 = $filter20;
520  $filter21['time-range']['end'] = null;
521 
522  // Time range, no start date
523  $filter22 = $filter20;
524  $filter22['time-range']['start'] = null;
525 
526  // Time range, other dates
527  $filter23 = $filter20;
528  $filter23['time-range'] = [
529  'start' => new \DateTime('2011-02-01 10:00:00', new \DateTimeZone('GMT')),
530  'end' => new \DateTime('2011-02-01 13:00:00', new \DateTimeZone('GMT')),
531  ];
532  // Time range
533  $filter24 = [
534  'name' => 'VTODO',
535  'comp-filters' => [],
536  'prop-filters' => [],
537  'is-not-defined' => false,
538  'time-range' => [
539  'start' => new \DateTime('2011-01-01 12:45:00', new \DateTimeZone('GMT')),
540  'end' => new \DateTime('2011-01-01 13:15:00', new \DateTimeZone('GMT')),
541  ],
542  ];
543  // Time range, other dates (1 month in the future)
544  $filter25 = $filter24;
545  $filter25['time-range'] = [
546  'start' => new \DateTime('2011-02-01 10:00:00', new \DateTimeZone('GMT')),
547  'end' => new \DateTime('2011-02-01 13:00:00', new \DateTimeZone('GMT')),
548  ];
549  $filter26 = $filter24;
550  $filter26['time-range'] = [
551  'start' => new \DateTime('2011-01-01 11:45:00', new \DateTimeZone('GMT')),
552  'end' => new \DateTime('2011-01-01 12:15:00', new \DateTimeZone('GMT')),
553  ];
554 
555  // Time range for VJOURNAL
556  $filter27 = [
557  'name' => 'VJOURNAL',
558  'comp-filters' => [],
559  'prop-filters' => [],
560  'is-not-defined' => false,
561  'time-range' => [
562  'start' => new \DateTime('2011-01-01 12:45:00', new \DateTimeZone('GMT')),
563  'end' => new \DateTime('2011-01-01 13:15:00', new \DateTimeZone('GMT')),
564  ],
565  ];
566  $filter28 = $filter27;
567  $filter28['time-range'] = [
568  'start' => new \DateTime('2011-01-01 11:45:00', new \DateTimeZone('GMT')),
569  'end' => new \DateTime('2011-01-01 12:15:00', new \DateTimeZone('GMT')),
570  ];
571  // Time range for VFREEBUSY
572  $filter29 = [
573  'name' => 'VFREEBUSY',
574  'comp-filters' => [],
575  'prop-filters' => [],
576  'is-not-defined' => false,
577  'time-range' => [
578  'start' => new \DateTime('2011-01-01 12:45:00', new \DateTimeZone('GMT')),
579  'end' => new \DateTime('2011-01-01 13:15:00', new \DateTimeZone('GMT')),
580  ],
581  ];
582  // Time range filter on property
583  $filter30 = [
584  'name' => 'VEVENT',
585  'comp-filters' => [],
586  'prop-filters' => [
587  [
588  'name' => 'DTSTART',
589  'is-not-defined' => false,
590  'param-filters' => [],
591  'time-range' => [
592  'start' => new \DateTime('2011-01-01 10:00:00', new \DateTimeZone('GMT')),
593  'end' => new \DateTime('2011-01-01 13:00:00', new \DateTimeZone('GMT')),
594  ],
595  'text-match' => null,
596  ],
597  ],
598  'is-not-defined' => false,
599  'time-range' => null,
600  ];
601 
602  // Time range for alarm
603  $filter31 = [
604  'name' => 'VEVENT',
605  'prop-filters' => [],
606  'comp-filters' => [
607  [
608  'name' => 'VALARM',
609  'is-not-defined' => false,
610  'comp-filters' => [],
611  'prop-filters' => [],
612  'time-range' => [
613  'start' => new \DateTime('2011-01-01 10:45:00', new \DateTimeZone('GMT')),
614  'end' => new \DateTime('2011-01-01 11:15:00', new \DateTimeZone('GMT')),
615  ],
616  'text-match' => null,
617  ],
618  ],
619  'is-not-defined' => false,
620  'time-range' => null,
621  ];
622  $filter32 = $filter31;
623  $filter32['comp-filters'][0]['time-range'] = [
624  'start' => new \DateTime('2011-01-01 11:45:00', new \DateTimeZone('GMT')),
625  'end' => new \DateTime('2011-01-01 12:15:00', new \DateTimeZone('GMT')),
626  ];
627 
628  $filter33 = $filter31;
629  $filter33['name'] = 'VTODO';
630  $filter34 = $filter32;
631  $filter34['name'] = 'VTODO';
632  $filter35 = $filter31;
633  $filter35['name'] = 'VJOURNAL';
634  $filter36 = $filter32;
635  $filter36['name'] = 'VJOURNAL';
636 
637  // Time range filter on non-datetime property
638  $filter37 = [
639  'name' => 'VEVENT',
640  'comp-filters' => [],
641  'prop-filters' => [
642  [
643  'name' => 'SUMMARY',
644  'is-not-defined' => false,
645  'param-filters' => [],
646  'time-range' => [
647  'start' => new \DateTime('2011-01-01 10:00:00', new \DateTimeZone('GMT')),
648  'end' => new \DateTime('2011-01-01 13:00:00', new \DateTimeZone('GMT')),
649  ],
650  'text-match' => null,
651  ],
652  ],
653  'is-not-defined' => false,
654  'time-range' => null,
655  ];
656 
657  $filter38 = [
658  'name' => 'VEVENT',
659  'comp-filters' => [],
660  'prop-filters' => [],
661  'is-not-defined' => false,
662  'time-range' => [
663  'start' => new \DateTime('2012-07-01 00:00:00', new \DateTimeZone('UTC')),
664  'end' => new \DateTime('2012-08-01 00:00:00', new \DateTimeZone('UTC')),
665  ]
666  ];
667  $filter39 = [
668  'name' => 'VEVENT',
669  'comp-filters' => [
670  [
671  'name' => 'VALARM',
672  'comp-filters' => [],
673  'prop-filters' => [],
674  'is-not-defined' => false,
675  'time-range' => [
676  'start' => new \DateTime('2012-09-01 00:00:00', new \DateTimeZone('UTC')),
677  'end' => new \DateTime('2012-10-01 00:00:00', new \DateTimeZone('UTC')),
678  ]
679  ],
680  ],
681  'prop-filters' => [],
682  'is-not-defined' => false,
683  'time-range' => null,
684  ];
685 
686  return [
687 
688  // Component check
689 
690  [$blob1, $filter1, 1],
691  [$blob1, $filter2, 0],
692  [$blob1, $filter3, 0],
693  [$blob1, $filter4, 1],
694 
695  // Subcomponent check (4)
696  [$blob1, $filter5, 0],
697  [$blob2, $filter5, 1],
698 
699  // Property checki (6)
700  [$blob1, $filter6, 1],
701  [$blob1, $filter7, 0],
702  [$blob1, $filter8, 0],
703  [$blob1, $filter9, 1],
704 
705  // Subcomponent + property (10)
706  [$blob2, $filter10, 1],
707 
708  // Param filter (11)
709  [$blob3, $filter11, 1],
710  [$blob3, $filter12, 0],
711  [$blob3, $filter13, 0],
712  [$blob3, $filter14, 1],
713 
714  // Param + text (15)
715  [$blob3, $filter15, 1],
716  [$blob3, $filter16, 0],
717  [$blob3, $filter17, 0],
718  [$blob3, $filter18, 1],
719 
720  // Prop + text (19)
721  [$blob2, $filter19, 1],
722 
723  // Incorrect object (vcard) (20)
724  [$blob4, $filter1, -1],
725 
726  // Time-range for event (21)
727  [$blob5, $filter20, 1],
728  [$blob6, $filter20, 1],
729  [$blob7, $filter20, 1],
730  [$blob8, $filter20, 1],
731 
732  [$blob5, $filter21, 1],
733  [$blob5, $filter22, 1],
734 
735  [$blob5, $filter23, 0],
736  [$blob6, $filter23, 0],
737  [$blob7, $filter23, 0],
738  [$blob8, $filter23, 0],
739 
740  // Time-range for todo (31)
741  [$blob9, $filter24, 1],
742  [$blob9, $filter25, 0],
743  [$blob9, $filter26, 1],
744  [$blob10, $filter24, 1],
745  [$blob10, $filter25, 0],
746  [$blob10, $filter26, 1],
747 
748  [$blob11, $filter24, 0],
749  [$blob11, $filter25, 0],
750  [$blob11, $filter26, 1],
751 
752  [$blob12, $filter24, 1],
753  [$blob12, $filter25, 0],
754  [$blob12, $filter26, 0],
755 
756  [$blob13, $filter24, 1],
757  [$blob13, $filter25, 0],
758  [$blob13, $filter26, 1],
759 
760  [$blob14, $filter24, 1],
761  [$blob14, $filter25, 0],
762  [$blob14, $filter26, 0],
763 
764  [$blob15, $filter24, 1],
765  [$blob15, $filter25, 1],
766  [$blob15, $filter26, 1],
767 
768  [$blob16, $filter24, 1],
769  [$blob16, $filter25, 1],
770  [$blob16, $filter26, 1],
771 
772  // Time-range for journals (55)
773  [$blob17, $filter27, 0],
774  [$blob17, $filter28, 0],
775  [$blob18, $filter27, 0],
776  [$blob18, $filter28, 1],
777  [$blob19, $filter27, 1],
778  [$blob19, $filter28, 1],
779 
780  // Time-range for free-busy (61)
781  [$blob20, $filter29, -1],
782 
783  // Time-range on property (62)
784  [$blob5, $filter30, 1],
785  [$blob3, $filter37, -1],
786  [$blob3, $filter30, 0],
787 
788  // Time-range on alarm in vevent (65)
789  [$blob21, $filter31, 1],
790  [$blob21, $filter32, 0],
791  [$blob22, $filter31, 1],
792  [$blob22, $filter32, 0],
793  [$blob23, $filter31, 1],
794  [$blob23, $filter32, 0],
795  [$blob24, $filter31, 1],
796  [$blob24, $filter32, 0],
797  [$blob25, $filter31, 1],
798  [$blob25, $filter32, 0],
799  [$blob26, $filter31, 1],
800  [$blob26, $filter32, 0],
801 
802  // Time-range on alarm for vtodo (77)
803  [$blob27, $filter33, 1],
804  [$blob27, $filter34, 0],
805 
806  // Time-range on alarm for vjournal (79)
807  [$blob28, $filter35, -1],
808  [$blob28, $filter36, -1],
809 
810  // Time-range on alarm with duration (81)
811  [$blob29, $filter31, 1],
812  [$blob29, $filter32, 0],
813  [$blob30, $filter31, 0],
814  [$blob30, $filter32, 0],
815 
816  // Time-range with RRULE (85)
817  [$blob31, $filter20, 1],
818  [$blob32, $filter20, 0],
819 
820  // Bug reported on mailing list, related to all-day events (87)
821  //array($blob33, $filter38, 1),
822 
823  // Event in timerange, but filtered alarm is in the far future (88).
824  [$blob34, $filter39, 0],
825  ];
826 
827  }
828 
829 }
static read($data, $options=0, $charset='UTF-8')
Parses a vCard or iCalendar object, and returns the top component.
Definition: Reader.php:42
const COMPLETED