classLiteralTerm
final class LiteralTerm
implements Term
Restricted visibility: declared "@visibility root". Code outside that scope must not name this declaration.
A scalar the analyzer resolved exactly.
Properties§
public string|int|float|bool|null $valueMethods§
public function __construct(public string|int|float|bool|null $value)Parameters
$value | string|int|float|bool|null | The resolved value |
public function toPattern(): TextPatternThe value as PHP writes it into a string.
Returns
Test cases 2
Calls 2
- static-call TextPattern::fromText() line 33
- method-call LiteralTerm::toText() line 33
public function toText(): stringThe value cast to a string the way PHP casts it.
Returns
stringTest cases 1
public function type(): TypeShapeThe scalar type of the resolved value.
Returns
Test cases 2
Calls 4
- static-call TypeShape::of() line 61
- function-call
is_boolline 63 - function-call
is_intline 66 - function-call
is_floatline 69
public function signature(): stringThe value tagged with its type so 1 and '1' stay distinct.
Returns
stringTest cases 2
Calls 2
- function-call
get_debug_typeline 82 - method-call LiteralTerm::toText() line 82
Private surface 1§
Implementation details, listed for orientation only.
private ?string $signature = nullTest cases 67§
Test cases that cover or call this symbol, from the coverage report and from the analyzed test sources.
Dedicated tests 4
Other tests reaching this symbol 63
CatalogCommandTestcallsBuiltinCallModelTestcallsCallEvaluatorTestcallsConstantReaderTestcallsBindingTestcallsCalleeReturnsTestcallsCallersTestcallsDeriverTestcallsEntryBinderTest::testAffordableJoinsTheWaysInBeyondTheLimitIntoOnecallsCallbackEffectsTestcallsObjectEffectsTestcallsPropertyWritesTestcallsSliceExecutorTest::providerSplitKeepsWholecallsSliceExecutorTest::testSplitGoesOnPastANameWithNoValuesToTellApartcallsSliceExecutorTest::testSplitJoinsWhatGoesPastTheLimitcallsSliceExecutorTest::testSplitPairsEveryValueOfEveryNamecallsSliceExecutorTest::testSplitSkipsANameTheEnvironmentDoesNotBindcallsSliceExecutorTest::testSplitWithALimitBelowTwoKeepsTheEnvironmentcallsSliceExecutorTest::testSplitWritesOneEnvironmentPerValuecallsSolutionTestcallsWriteEffectsTestcallsEntryFactoryTestcallsExpressionEvaluatorTestcallsNamedModelTestcallsRegistryTestcallsInterpreterTest::testRecordStatementsMarksAStatementCombinedWhenEitherTheTextOrTheReadingIscallsModelQueriesTestcallsQueryRecordTestcallsReferenceEvaluatorTest::testReadVariablePreservesProvenanceAndDomainFlagsWhileNamingOpaqueValuescallsValueBinderTestcallsValueDomainTestcallsArrayEntryTestcallsArrayTermTestcallsCallResultsTestcallsDomainTest::testAsTermCollapsesAResolvedPatternToALiteralcallsDomainTest::testFromTermsDeduplicatesAlternativescallsDomainTest::testFromTermsGeneralizesBeyondTheBoundcallsDomainTest::testGeneralizeCoversEveryAlternativecallsDomainTest::testOfHoldsOneAlternativecallsDomainTest::testWithVariableNamesOnlyOpaqueAlternativesWithoutChangingTheirMeaningcallsEnvironmentTestcallsObjectMemoryTestcallsTermTest::testSignatureSeparatesTermsOfDifferentKindscallsTermTest::testToPatternIsExactOnlyForResolvedTermscallsTermTest::testTypeIsReportedByEveryKindOfTermcallsQueryModelInterfaceTestcallsQueryOutputTestcallsBuilderCallsTest::testBoundedMarksTooManyAlternativesAsOneOpenStateInsteadOfLosingEffectscallsBuilderQueriesTestcallsCallbackModelTestcallsCallModelTestcallsClausesTestcallsGrammarTest::testOpenedKeepsNonLiteralTermsAndRejectsNonStringLiteralscallsGrammarTest::testWrapKeepsEachAlternativeAndTheOriginOfUnresolvedNamescallsModelMetadataTestcallsPredicatesTestcallsQueryStateTestcallsSelectCompilerTestcallsWriteCompilerTestcallsAnalyzerTestcallsConfigurationTestcallsJsonReporterTestcallsTextReporterTestcalls
Relations§
Instantiated in 2
Type checks 6
- instanceof SqlCatalog\Core\Analysis\BuiltinCallModel::sprintf() packages/sql-catalog/src/Core/Analysis/BuiltinCallModel.php:108
- instanceof SqlCatalog\Core\Catalog\ValueDomain::fromDomain() packages/sql-catalog/src/Core/Catalog/ValueDomain.php:48
- instanceof SqlCatalog\Core\Evaluation\Domain::select() packages/sql-catalog/src/Core/Evaluation/Domain.php:165
- instanceof SqlCatalog\Core\Evaluation\Domain::soleLiteral() packages/sql-catalog/src/Core/Evaluation/Domain.php:209
- instanceof SqlCatalog\Extension\Laravel\Grammar::wrap() packages/sql-catalog/src/Extension/Laravel/Grammar.php:48
- instanceof SqlCatalog\Extension\Laravel\Grammar::opened() packages/sql-catalog/src/Extension/Laravel/Grammar.php:81