<?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 AccountInput
 * An account object containing login, type and comment. The password is for security reasons not part of the object. * @property null|AceBITPasswordDepotSecretInputInputType $acebitPasswordDepotServerAccount = null The AceBIT Password Depot account.
 * @property null|string $comment = null The account's comment string.
 * @property null|CyberarkAccountInputInputType $cyberarkAccount = null The cyberark account.
 * @property null|string $id = null The internal id this entity. Note that the id might change when the entity gets deleted and recreated.
 * @property null|bool $isLaps = null The account's laps flag.
 * @property null|ManageEnginePMPAccountInputInputType $manageEnginePMPAccount = null The manage engine PMP account.
 * @property null|PasswordstateAccountInputInputType $passwordstateAccount = null The passwordstate account.
 * @property null|ThycoticSecretServerAccountInputInputType $thycoticSecretServerAccount = null The thycotic account.
 * @property null|AccountTypeEnum $type = null The account's username.
 * @property null|string $username = null The account's username.
 * @property null|string $password = null The account's password no change constant.
 * @property null|string $reference = null The account's reference.
 */
final class AccountInputInputType extends InputType
{
    protected function decorate($name, $value)
    {
        if ($value === null) {
            return null;
        }

        if ($name === 'acebitPasswordDepotServerAccount') {
            return new AceBITPasswordDepotSecretInputInputType($value);
        }

        if ($name === 'cyberarkAccount') {
            return new CyberarkAccountInputInputType($value);
        }

        if ($name === 'manageEnginePMPAccount') {
            return new ManageEnginePMPAccountInputInputType($value);
        }

        if ($name === 'passwordstateAccount') {
            return new PasswordstateAccountInputInputType($value);
        }

        if ($name === 'thycoticSecretServerAccount') {
            return new ThycoticSecretServerAccountInputInputType($value);
        }

        if ($name === 'type') {
            return new AccountTypeEnum($value);
        }

        return $value;
    }
}