mirror of
https://github.com/Icinga/icingaweb2-module-director.git
synced 2026-05-28 04:35:53 -04:00
20 lines
408 B
PHP
20 lines
408 B
PHP
|
|
<?php
|
||
|
|
|
||
|
|
namespace Icinga\Module\Director\PropertyModifier;
|
||
|
|
|
||
|
|
use Icinga\Module\Director\Hook\PropertyModifierHook;
|
||
|
|
use Ramsey\Uuid\Uuid;
|
||
|
|
|
||
|
|
class PropertyModifierUuidBinToHex extends PropertyModifierHook
|
||
|
|
{
|
||
|
|
public function getName()
|
||
|
|
{
|
||
|
|
return mt('director', 'UUID: from binary to hex');
|
||
|
|
}
|
||
|
|
|
||
|
|
public function transform($value)
|
||
|
|
{
|
||
|
|
return Uuid::fromBytes($value)->toString();
|
||
|
|
}
|
||
|
|
}
|