Provides an abstract class for loading EDICT formatted
dictionaries.
One column will be provided for the headword, one for the reading (in
EDICT that is the Kana) and one for the translation.
To Do (Fix):
Optimize insert, use transaction which disables autocommit and cosider
passing data all at once, requiring proper handling of row indices.
|
|
|
|
str
|
|
file
|
|
str
|
|
|
buildFTS3Tables(self,
tableName,
columns,
columnTypeMap={ } ,
primaryKeys=[ ] ,
fullTextColumns=[ ] )
Builds a FTS3 table construct for supporting full text search under
SQLite. |
source code
|
|
|
insertFTS3Tables(self,
tableName,
generator,
columns=[ ] ,
fullTextColumns=[ ] ) |
source code
|
|
bool
|
testFTS3(self)
Tests if the SQLite FTS3 extension is supported on the build system. |
source code
|
|
|
|
|
remove(self)
Removes the table provided by the TableBuilder from the database. |
source code
|
|
Inherited from EntryGeneratorBuilder :
getEntryDict
Inherited from TableBuilder :
buildIndexObjects ,
buildTableObject ,
findFile
Inherited from object :
__delattr__ ,
__getattribute__ ,
__hash__ ,
__new__ ,
__reduce__ ,
__reduce_ex__ ,
__repr__ ,
__setattr__ ,
__str__
|
|
COLUMNS = [ ' Headword ' , ' Reading ' , ' Translation ' ]
Columns that will be built
|
|
PRIMARY_KEYS = []
Primary keys of the created table
|
|
INDEX_KEYS = [ [ ' Headword ' ] , [ ' Reading ' ] ]
Index keys (not unique) of the created table
|
|
COLUMN_TYPES = { ' Headword ' : String(length=255, convert_unicode...
Column types for created table
|
|
FULLTEXT_COLUMNS = [ ' Translation ' ]
Column names which shall be fulltext searchable.
|
|
FILE_NAMES = None
Names of file containing the edict formated dictionary.
|
|
ENCODING = ' utf-8 '
Encoding of the dictionary file.
|
|
ENTRY_REGEX = None
Regular Expression matching a dictionary entry.
|
|
IGNORE_LINES = 0
Number of starting lines to ignore.
|
|
FILTER = None
Filter to apply to the read entry before writing to table.
|
Inherited from TableBuilder :
DEPENDS ,
PROVIDES
|