1<?php
2
3declare(strict_types=1);
4
5/*
6 * This file is part of the league/commonmark package.
7 *
8 * (c) Colin O'Dell <colinodell@gmail.com>
9 *
10 * Original code based on the CommonMark JS reference parser (https://bitly.com/commonmark-js)
11 *  - (c) John MacFarlane
12 *
13 * For the full copyright and license information, please view the LICENSE
14 * file that was distributed with this source code.
15 */
16
17namespace League\CommonMark\Reference;
18
19/**
20 * A collection of references
21 *
22 * @phpstan-extends \IteratorAggregate<ReferenceInterface>
23 */
24interface ReferenceMapInterface extends \IteratorAggregate, \Countable
25{
26    public function add(ReferenceInterface $reference): void;
27
28    public function contains(string $label): bool;
29
30    public function get(string $label): ?ReferenceInterface;
31}
32