lib/search: make JaDBConnection into extension, add verifyTables
This commit is contained in:
@@ -35,7 +35,7 @@ class QueryKanji extends Command {
|
||||
);
|
||||
|
||||
final time = Stopwatch()..start();
|
||||
final result = await JaDBConnection(db).searchKanji(
|
||||
final result = await JaDBConnection(db).jadbSearchKanji(
|
||||
argResults!.option('kanji') ?? '漢',
|
||||
);
|
||||
time.stop();
|
||||
|
||||
@@ -36,11 +36,11 @@ class QueryWord extends Command {
|
||||
final String searchWord = argResults!.option('word') ?? 'かな';
|
||||
|
||||
final time = Stopwatch()..start();
|
||||
final count = await JaDBConnection(db).searchWordCount(searchWord);
|
||||
final count = await JaDBConnection(db).jadbSearchWordCount(searchWord);
|
||||
time.stop();
|
||||
|
||||
final time2 = Stopwatch()..start();
|
||||
final result = await JaDBConnection(db).searchWord(searchWord);
|
||||
final result = await JaDBConnection(db).jadbSearchWord(searchWord);
|
||||
time2.stop();
|
||||
|
||||
if (result == null) {
|
||||
|
||||
Reference in New Issue
Block a user