diff options
author | Peng Wu <alexepico@gmail.com> | 2016-07-04 11:05:29 +0800 |
---|---|---|
committer | Peng Wu <alexepico@gmail.com> | 2016-07-04 11:05:29 +0800 |
commit | 4fdb35ab901e8570a84fe29a59f82123a85a16a8 (patch) | |
tree | 99a073111295b0743e6a76035be3947cc58bc8c2 /src/storage/phrase_large_table3_kyotodb.cpp | |
parent | 63cca4dd16a7d2156689e28f4027d069ab5ea33b (diff) | |
download | libpinyin-4fdb35ab901e8570a84fe29a59f82123a85a16a8.tar.gz libpinyin-4fdb35ab901e8570a84fe29a59f82123a85a16a8.tar.xz libpinyin-4fdb35ab901e8570a84fe29a59f82123a85a16a8.zip |
update Vistor code
Diffstat (limited to 'src/storage/phrase_large_table3_kyotodb.cpp')
-rw-r--r-- | src/storage/phrase_large_table3_kyotodb.cpp | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/src/storage/phrase_large_table3_kyotodb.cpp b/src/storage/phrase_large_table3_kyotodb.cpp index a02eac3..14c5c94 100644 --- a/src/storage/phrase_large_table3_kyotodb.cpp +++ b/src/storage/phrase_large_table3_kyotodb.cpp @@ -243,14 +243,12 @@ int PhraseLargeTable3::remove_index(int phrase_length, class MaskOutVisitor : public DB::Visitor { private: - BasicDB * m_db; phrase_token_t m_mask; phrase_token_t m_value; PhraseTableEntry m_entry; public: - MaskOutVisitor(BasicDB * db, phrase_token_t mask, phrase_token_t value) { - m_db = db; + MaskOutVisitor(phrase_token_t mask, phrase_token_t value) { m_mask = mask; m_value = value; } @@ -274,9 +272,10 @@ public: /* mask out method */ bool PhraseLargeTable3::mask_out(phrase_token_t mask, phrase_token_t value) { - MaskOutVisitor visitor(m_db, mask, value); + MaskOutVisitor visitor(mask, value); m_db->iterate(&visitor, true); + m_db->synchronize(); return true; } |