mirror of
https://gitlab.com/ArkHost/WHMCS-Discord-Notifications.git
synced 2026-09-19 09:17:29 +02:00
39 lines
646 B
PHP
39 lines
646 B
PHP
<?php
|
|
|
|
namespace WHMCS\Module\Notification\Discord;
|
|
|
|
class Field
|
|
{
|
|
public $name = "";
|
|
public $value = "";
|
|
public $inline = true;
|
|
|
|
public function name($name)
|
|
{
|
|
$this->name = trim($name);
|
|
return $this;
|
|
}
|
|
|
|
public function value($value)
|
|
{
|
|
$this->value = trim($value);
|
|
return $this;
|
|
}
|
|
|
|
public function inline($inline)
|
|
{
|
|
$this->inline = (bool) $inline;
|
|
return $this;
|
|
}
|
|
|
|
public function toArray()
|
|
{
|
|
return [
|
|
'name' => $this->name,
|
|
'value' => $this->value,
|
|
'inline' => $this->inline
|
|
];
|
|
}
|
|
}
|
|
|
|
?>
|