src/Eluceo/iCal/Component/TimezoneRule.php 1 location
|
@@ 64-72 (lines=9) @@
|
| 61 |
|
* |
| 62 |
|
* @throws \InvalidArgumentException |
| 63 |
|
*/ |
| 64 |
|
public function __construct($ruleType) |
| 65 |
|
{ |
| 66 |
|
$ruleType = strtoupper($ruleType); |
| 67 |
|
if ($ruleType === self::TYPE_DAYLIGHT || $ruleType === self::TYPE_STANDARD) { |
| 68 |
|
$this->type = $ruleType; |
| 69 |
|
} else { |
| 70 |
|
throw new \InvalidArgumentException('Invalid value for timezone rule type'); |
| 71 |
|
} |
| 72 |
|
} |
| 73 |
|
|
| 74 |
|
/** |
| 75 |
|
* {@inheritdoc} |
src/Eluceo/iCal/Component/Event.php 1 location
|
@@ 625-637 (lines=13) @@
|
| 622 |
|
* |
| 623 |
|
* @throws \InvalidArgumentException |
| 624 |
|
*/ |
| 625 |
|
public function setTimeTransparency($transparency) |
| 626 |
|
{ |
| 627 |
|
$transparency = strtoupper($transparency); |
| 628 |
|
if ($transparency === self::TIME_TRANSPARENCY_OPAQUE |
| 629 |
|
|| $transparency === self::TIME_TRANSPARENCY_TRANSPARENT |
| 630 |
|
) { |
| 631 |
|
$this->transparency = $transparency; |
| 632 |
|
} else { |
| 633 |
|
throw new \InvalidArgumentException('Invalid value for transparancy'); |
| 634 |
|
} |
| 635 |
|
|
| 636 |
|
return $this; |
| 637 |
|
} |
| 638 |
|
|
| 639 |
|
/** |
| 640 |
|
* @param $status |