<?php

declare (strict_types=1);
namespace idoit\Module\JDisc\Graphql\Schema\Model;

use Axtiva\FlexibleGraphql\Type\InputType;

/**
 * This code is @generated by axtiva/flexible-graphql-php do not edit it
 * PHP representation of graphql type TpmModuleInput
 * A TPM module used for hardware encryption. * @property null|bool $activated = null A flag whether the TPM module is activated.
 * @property null|DeviceInputInputType $device = null The corresponding device.
 * @property null|bool $enabled = null A flag whether the TPM module is enabled.
 * @property null|string $manufacturer = null A TPM module's manufacturer.
 * @property null|bool $owned = null A flag whether the TPM module is owned.
 * @property null|string $physicalPresenceVersion = null A TPM module's physical presence version.
 * @property null|string $specVersion = null A TPM module's specification version.
 * @property null|string $version = null A TPM module's version.
 */
final class TpmModuleInputInputType extends InputType
{
    protected function decorate($name, $value)
    {
        if ($value === null) {
            return null;
        }

        if ($name === 'device') {
            return new DeviceInputInputType($value);
        }

        return $value;
    }
}