classDollarQuotedDomain
final class DollarQuotedDomain
implements ValueDomain
Reuses one chosen tag at both boundaries; the declared body alphabet excludes dollars.
Methods§
public function __construct(private ValueDomain $tag, private ValueDomain $body)Binds a legal tag domain and a body domain that cannot contain the chosen closing delimiter.
Parameters
$tag | ValueDomain | |
$body | ValueDomain |
Test cases 4
DollarQuotedDomainTest::testChooseReusesTheChosenTagWithoutASecondTagDecisioncoversDollarQuotedDomainTest::testMatchBindsTagsAndStopsAtTheFirstIdenticalDelimitercoversDollarQuotedDomainTest::testMatchClosesAtTheDelimiterAfterTheTagAndOnlyRejectsNulBytesInsideTheBodycoversDollarQuotedDomainTest::testMatchRequiresADollarAndALegalTagAtTheOffsetcovers
public function choose(Closure(positive-int): int $choose): stringParameters
$choose | Closure(positive-int): int |
Returns
stringTest cases 1
Calls 1
- method-call ValueDomain::choose() line 29
public function match(string $value, int $offset = 0): list<int>Uses the opening tag as a bound delimiter; the first identical tag closes the scanner state.
Parameters
$value | string | |
$offset | int |
Returns
list<int>Test cases 3
Private surface 2§
Implementation details, listed for orientation only.
private ValueDomain $tagprivate ValueDomain $bodyTest cases 10§
Test cases that cover or call this symbol, from the coverage report and from the analyzed test sources.
Dedicated tests 4
DollarQuotedDomainTest::testChooseReusesTheChosenTagWithoutASecondTagDecisioncovers and callsDollarQuotedDomainTest::testMatchBindsTagsAndStopsAtTheFirstIdenticalDelimitercovers and callsDollarQuotedDomainTest::testMatchClosesAtTheDelimiterAfterTheTagAndOnlyRejectsNulBytesInsideTheBodycovers and callsDollarQuotedDomainTest::testMatchRequiresADollarAndALegalTagAtTheOffsetcovers and calls
Other tests reaching this symbol 6
LexicalExceptionTestcallsGenerationContextTestcallsDefinitionFactoryTestcallsLexicalGrammarTestcallsPostgreSqlProviderTestcallsSqlGeneratorFactoryTestcalls