<?php

declare(strict_types=1);

namespace App\Framework\FeatureFlags;

/**
 * Repository interface for feature flags
 */
interface FeatureFlagRepository
{
    /**
     * Get a feature flag by name
     */
    public function find(string $name): ?FeatureFlag;

    /**
     * Get all feature flags
     * @return FeatureFlag[]
     */
    public function findAll(): array;

    /**
     * Save a feature flag
     */
    public function save(FeatureFlag $flag): void;

    /**
     * Delete a feature flag
     */
    public function delete(string $name): void;

    /**
     * Check if a feature flag exists
     */
    public function exists(string $name): bool;
}
