This website works better with JavaScript.
Home
Explore
帮助
返回水杉在线
登录水杉在线
登录水杉码园
building_data_management_systems.Xuanzhou.2024Fall.DaSE
/
LevelDB_KV_Sep
Watch
23
Star
0
Fork
0
Code
Issues
0
Pull Requests
0
Releases
0
Wiki
Activity
Browse Source
clear useless code
baseline
ArcueidType
2 weeks ago
parent
5babb13211
commit
3a042c5b30
3 changed files
with
1 additions
and
13 deletions
Split View
Diff Options
Show Stats
Download Patch File
Download Diff File
+1
-1
db/db_impl.cc
+0
-10
db/fields.cc
+0
-2
db/fields.h
+ 1
- 1
db/db_impl.cc
View File
@ -1222,7 +1222,7 @@ std::vector
DBImpl::FindKeysByField(Field &field) {
std
:
:
string
key
=
iter
-
>
key
(
)
.
ToString
(
)
;
Fields
fields
=
iter
-
>
fields
(
)
;
if
(
fields
.
find
(
field
.
first
)
=
=
field
.
second
)
{
if
(
fields
[
field
.
first
]
=
=
field
.
second
)
{
keys
.
emplace_back
(
key
)
;
}
iter
-
>
Next
(
)
;
+ 0
- 10
db/fields.cc
View File
@ -69,14 +69,4 @@ namespace leveldb {
return
field_array
;
}
std
:
:
string
Fields
:
:
find
(
const
std
:
:
string
&
field_name
)
const
{
auto
it
=
this
-
>
_fields
.
find
(
field_name
)
;
if
(
it
=
=
this
-
>
_fields
.
end
(
)
)
{
return
"
"
;
}
return
it
-
>
second
;
}
}
// namespace leveldb
+ 0
- 2
db/fields.h
View File
@ -33,8 +33,6 @@ namespace leveldb {
/
/
将
Fields编码为存入LevelDB的Value
std
:
:
string
Serialize
(
)
const
;
/
/
通
过
field_name得到相应的字段值
std
:
:
string
find
(
const
std
:
:
string
&
field_name
)
const
;
private
:
std
:
:
map
<
std
:
:
string
,
std
:
:
string
>
_fields
;
}
;
Write
Preview
Loading…
Cancel
Save