# ivyforms/1.5/backend/src/Repository/EntryField/EntryFieldRepositoryInterface.php

The Innovative Form Builder – IvyForms, version 1.5. 92 lines.

- Page: https://pluginprobe.com/plugins/ivyforms/1.5/code/backend/src/Repository/EntryField/EntryFieldRepositoryInterface.php
- Raw: https://pluginprobe.com/plugins/ivyforms/1.5/raw/backend/src/Repository/EntryField/EntryFieldRepositoryInterface.php
- Modified: 2026-08-25T13:32:38+00:00

Line numbers below start at 1. Link to a line or a range by appending a fragment to the
page URL, for example `https://pluginprobe.com/plugins/ivyforms/1.5/code/backend/src/Repository/EntryField/EntryFieldRepositoryInterface.php#L10-L20`.

```php
<?php

namespace IvyForms\Repository\EntryField;

// phpcs:disable PSR1.Files.SideEffects
if (!defined('ABSPATH')) {
    exit; // Exit if accessed directly
}

use IvyForms\Entity\EntryField\EntryField;
use IvyForms\Repository\BaseRepositoryInterface;

interface EntryFieldRepositoryInterface extends BaseRepositoryInterface
{
    /**
     * Check if an entry field exists in the database.
     *
     * @param int $entryFieldId
     * @return bool
     */
    public function exists(int $entryFieldId): bool;

    /**
     * @param array<string, string> $array
     * @return array<int, EntryField>
     */
    public function findBy(array $array): array;

    /**
     * Get all entry field IDs for the given entry IDs.
     *
     * @param int[] $entryIds
     * @return int[]
     */
    public function findIdsByEntryIds(array $entryIds): array;

    /**
     * Delete multiple entry fields by their IDs in a single query.
     *
     * @param int[] $formIds
     * @return int Number of deleted rows
     */
    public function deleteByFormIds(array $formIds): int;

    /**
     * Check if a value already exists in entry fields for a specific field.
     *
     * @param int $formId
     * @param int $fieldId
     * @param string $value
     * @return bool
     */
    public function checkDuplicateValue(
        int $formId,
        int $fieldId,
        string $value,
        ?int $excludeEntryId = null
    ): bool;

    /**
     * Check if a normalized value matches any stored value after applying a normalizer.
     *
     * @param int $formId
     * @param int $fieldId
     * @param string $normalizedValue
     * @param callable(string): string $normalizeStoredValue
     * @return bool
     */
    public function checkDuplicateValueNormalized(
        int $formId,
        int $fieldId,
        string $normalizedValue,
        callable $normalizeStoredValue,
        ?int $excludeEntryId = null
    ): bool;

    /**
     * Batch-update fieldValue for existing entry_field rows of one entry.
     *
     * @param int $entryId
     * @param list<array{id: int, fieldValue: string}> $updates
     */
    public function batchUpdateValues(int $entryId, array $updates): void;

    /**
     * Multi-row insert of entry_field rows. Sets generated IDs on the entities.
     *
     * @param list<EntryField> $entryFields
     */
    public function batchInsert(array $entryFields): void;
}

```
