<?php

namespace App\Modules\Admin\Tenancy\Support;

final class TenantLifecycleState
{
    public const ONBOARDING = 'onboarding';

    public const ACTIVE = 'active';

    public const SUSPENDED = 'suspended';

    public const GRACE_PERIOD = 'grace_period';

    public const ARCHIVED = 'archived';

    /**
     * @return list<string>
     */
    public static function all(): array
    {
        return [
            self::ONBOARDING,
            self::ACTIVE,
            self::SUSPENDED,
            self::GRACE_PERIOD,
            self::ARCHIVED,
        ];
    }

    public static function isTerminal(string $state): bool
    {
        return $state === self::ARCHIVED;
    }
}
