ILIAS  trunk Revision v11.0_alpha-3011-gc6b235a2e85
Standard.php
Go to the documentation of this file.
1<?php
2
19declare(strict_types=1);
20
22
24
30{
31 protected ?string $main_text = null;
32 protected ?string $required_text = null;
33
37 public function getComparison()
38 {
39 return $this->getSafe($this->comparison);
40 }
41
45 public function getComparisonAsPercent(): int
46 {
47 return $this->getAsPercentage($this->comparison);
48 }
49
53 public function withMainText(string $text): C\Chart\ProgressMeter\ProgressMeter
54 {
55 $this->checkStringArg("main_value_text", $text);
56
57 $clone = clone $this;
58 $clone->main_text = $text;
59 return $clone;
60 }
61
65 public function getMainText(): ?string
66 {
67 return $this->main_text;
68 }
69
73 public function withRequiredText(string $text): C\Chart\ProgressMeter\ProgressMeter
74 {
75 $this->checkStringArg("required_value_text", $text);
76
77 $clone = clone $this;
78 $clone->required_text = $text;
79 return $clone;
80 }
81
85 public function getRequiredText(): ?string
86 {
87 return $this->required_text;
88 }
89}
getComparisonAsPercent()
Get comparison value as percent.
Definition: Standard.php:45