Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
R
rust-rocksdb
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
fangzongwu
rust-rocksdb
Commits
e3bd990f
Commit
e3bd990f
authored
Jun 27, 2017
by
Huachao Huang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
address comment
parent
17c67e7e
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
40 additions
and
1 deletion
+40
-1
table_properties.rs
src/table_properties.rs
+13
-0
table_properties_collector.rs
src/table_properties_collector.rs
+14
-1
table_properties_collector_factory.rs
src/table_properties_collector_factory.rs
+13
-0
No files found.
src/table_properties.rs
View file @
e3bd990f
// Copyright 2017 PingCAP, Inc.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// See the License for the specific language governing permissions and
// limitations under the License.
use
crocksdb_ffi
::{
self
,
DBTablePropertiesCollection
,
ptr_to_string
};
use
crocksdb_ffi
::{
self
,
DBTablePropertiesCollection
,
ptr_to_string
};
use
std
::
collections
::
HashMap
;
use
std
::
collections
::
HashMap
;
use
std
::
slice
;
use
std
::
slice
;
...
...
src/table_properties_collector.rs
View file @
e3bd990f
// Copyright 2017 PingCAP, Inc.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// See the License for the specific language governing permissions and
// limitations under the License.
use
crocksdb_ffi
::{
self
,
DBEntryType
,
DBTablePropertiesCollectorContext
};
use
crocksdb_ffi
::{
self
,
DBEntryType
,
DBTablePropertiesCollectorContext
};
use
libc
::{
c_void
,
c_char
,
c_int
,
uint8_t
,
uint64_t
,
size_t
};
use
libc
::{
c_void
,
c_char
,
c_int
,
uint8_t
,
uint64_t
,
size_t
};
use
std
::
collections
::
HashMap
;
use
std
::
collections
::
HashMap
;
...
@@ -7,7 +20,7 @@ use std::slice;
...
@@ -7,7 +20,7 @@ use std::slice;
/// `TablePropertiesCollector` provides the mechanism for users to collect
/// `TablePropertiesCollector` provides the mechanism for users to collect
/// their own properties that they are interested in. This class is essentially
/// their own properties that they are interested in. This class is essentially
/// a collection of callback functions that will be invoked during table
/// a collection of callback functions that will be invoked during table
/// building. It is construced with TablePropertiesCollectorFactory. The methods
/// building. It is construc
t
ed with TablePropertiesCollectorFactory. The methods
/// don't need to be thread-safe, as we will create exactly one
/// don't need to be thread-safe, as we will create exactly one
/// TablePropertiesCollector object per table and then call it sequentially
/// TablePropertiesCollector object per table and then call it sequentially
pub
trait
TablePropertiesCollector
{
pub
trait
TablePropertiesCollector
{
...
...
src/table_properties_collector_factory.rs
View file @
e3bd990f
// Copyright 2017 PingCAP, Inc.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// See the License for the specific language governing permissions and
// limitations under the License.
use
crocksdb_ffi
::
DBTablePropertiesCollectorFactoryContext
;
use
crocksdb_ffi
::
DBTablePropertiesCollectorFactoryContext
;
use
libc
::{
c_void
,
c_char
,
uint32_t
};
use
libc
::{
c_void
,
c_char
,
uint32_t
};
use
table_properties_collector
::{
TablePropertiesCollector
,
new_table_properties_collector_context
};
use
table_properties_collector
::{
TablePropertiesCollector
,
new_table_properties_collector_context
};
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment