classCodec
final class Codec
implements Codec
Spells decoded names as SQLite identifiers.
Rule: SQLITE-NAME-CODEC-001. A name made of ASCII letters, digits and underscores that does not start with a digit, is no keyword and is not the word TRUE or FALSE (which SQLite reads as a boolean constant when no column has that name) is written bare. Every other name is written in backticks with embedded backticks doubled: unlike a double-quoted word, a backtick-quoted word is always an identifier and never falls back to a string literal. Source: https://sqlite.org/lang_keywords.html, https://sqlite.org/quirks.html#dblquote. Status: Implemented.
Methods§
Spells a decoded name; every position uses the same rule.
Returns
stringTest cases 4
Test cases 32§
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 28
OutputTest::testAddRecordsAPieceAndConsumesAPendingGluecallsOutputTest::testCanonicalKeepsTheRenderedTextOfEveryPiececallsOutputTest::testGlueJoinsOnlyTheNextPiececallsOutputTest::testKeywordRefusesAnythingButOneUpperCaseWordcallsOutputTest::testKeywordWritesEachUpperCaseWordAsAPiececallsOutputTest::testLayoutRefusesALayoutThatDoesNotAlignWithTheRenderedPiecescallsOutputTest::testLayoutRespellsEachRenderedPieceAndKeepsTheRenderedTextcallsOutputTest::testLayoutWithoutALayoutRendersRegularlycallsOutputTest::testLayoutWritesItsTrailBeforeTheNextPiececallsOutputTest::testListSeparatesChildrenWithTheSymbolcallsOutputTest::testNameIsSpelledByTheCodecForItsPositioncallsOutputTest::testNodeWritesAChildAndNothingForNullcallsOutputTest::testPiecesAreEmptyBeforeAnythingIsWrittencallsOutputTest::testSpelledRefusesAnEmptySpellingcallsOutputTest::testSpelledWritesALiteralSpellingcallsOutputTest::testSymbolRefusesLetterscallsOutputTest::testSymbolWritesPunctuationOnlycallsOutputTest::testTrailingAnswersATrailNothingFollowedcallsObjectNamesTest::testWriteWritesAnUnqualifiedNameAlonecallsObjectNamesTest::testWriteWritesTheSchemaBeforeTheNamecallsWordTest::testRenderWritesTheWordWithItsOwnQuotingcallsModuleArgumentTest::testRenderWritesNothingForAnEmptyArgumentcallsModuleArgumentTest::testRenderWritesTheTextUnchangedcallsDeferrabilityTest::testRenderWritesEveryFormcallsMatchNameTest::testRenderWritesTheKeywordAndTheNamecallsReferenceActionTest::testRenderWritesAnInsertEventTheGrammarAcceptscallsReferenceActionTest::testRenderWritesTheEventAndTheReactioncallsTableOptionTest::testRenderWritesTheWordWithItsQuotingcalls