1 // Copyright (c) 2011-present, Facebook, Inc. All rights reserved.
2 // This source code is licensed under both the GPLv2 (found in the
3 // COPYING file in the root directory) and Apache 2.0 License
4 // (found in the LICENSE.Apache file in the root directory).
12 #include "rocksdb/compaction_filter.h"
13 #include "rocksdb/slice.h"
15 namespace ROCKSDB_NAMESPACE
{
17 class RemoveEmptyValueCompactionFilter
: public CompactionFilter
{
19 static const char* kClassName() { return "RemoveEmptyValueCompactionFilter"; }
21 const char* Name() const override
{ return kClassName(); }
23 bool Filter(int level
, const Slice
& key
, const Slice
& existing_value
,
24 std::string
* new_value
, bool* value_changed
) const override
;
27 } // namespace ROCKSDB_NAMESPACE
28 #endif // !ROCKSDB_LITE