30 lines
677 B
PHP
30 lines
677 B
PHP
<?php
|
|
namespace ContingentParser;
|
|
|
|
final class Printer
|
|
{
|
|
public static function print(
|
|
int|string $text = '',
|
|
Color $color = Color::WHITE
|
|
): void {
|
|
print($color->tostring().$text.Color::WHITE->tostring());
|
|
}
|
|
|
|
public static function println(
|
|
int|string $text = '',
|
|
Color $color = Color::WHITE
|
|
): void {
|
|
print($color->tostring().$text.Color::WHITE->tostring());
|
|
print(PHP_EOL);
|
|
}
|
|
|
|
public static function print_r(
|
|
mixed $value,
|
|
Color $color = Color::WHITE
|
|
): void {
|
|
print($color->tostring());
|
|
print_r($value);
|
|
print(Color::WHITE->tostring());
|
|
}
|
|
}
|