<?php

namespace App\Tests\Fixture\Factory\Organization;

use App\Entity\Organization\Settings;
use App\Tests\Fixture\Factory\Person\PersonRepository;
use Zenstruck\Foundry\RepositoryProxy;
use Zenstruck\Foundry\ModelFactory;
use Zenstruck\Foundry\Proxy;

/**
 * @extends ModelFactory<Settings>
 *
 * @phpstan-method        Settings|Proxy create(array|callable $attributes = [])
 * @phpstan-method static Settings|Proxy createOne(array $attributes = [])
 * @phpstan-method static Settings|Proxy find(object|array|mixed $criteria)
 * @phpstan-method static Settings|Proxy findOrCreate(array $attributes)
 * @phpstan-method static Settings|Proxy first(string $sortedField = 'id')
 * @phpstan-method static Settings|Proxy last(string $sortedField = 'id')
 * @phpstan-method static Settings|Proxy random(array $attributes = [])
 * @phpstan-method static Settings|Proxy randomOrCreate(array $attributes = []))
 * @phpstan-method static SettingsRepository|RepositoryProxy repository()
 * @phpstan-method static Settings[]|Proxy[] all()
 * @phpstan-method static Settings[]|Proxy[] createMany(int $number, array|callable $attributes = [])
 * @phpstan-method static Settings[]&Proxy[] createSequence(iterable|callable $sequence)
 * @phpstan-method static Settings[]|Proxy[] findBy(array $attributes)
 * @phpstan-method static Settings[]|Proxy[] randomRange(int $min, int $max, array $attributes = []))
 * @phpstan-method static Settings[]|Proxy[] randomSet(int $number, array $attributes = []))
 */
class SettingsFactory extends ModelFactory
{
    /**
     * @see https://github.com/zenstruck/foundry#factories-as-services
     */
    public function __construct()
    {
        parent::__construct();
    }

    /**
     * @see https://github.com/zenstruck/foundry#model-factories
     *
     * @todo add your default values here
     */
    protected function getDefaults(): array
    {
        return [];
    }

    /**
     * @see https://github.com/zenstruck/foundry#initialization
     */
    protected function initialize(): self
    {
        return $this
            // ->afterInstantiate(function(Post $post) {})
            ;
    }

    protected static function getClass(): string
    {
        return Settings::class;
    }
}
