blob: 20cec9a31c2212d58166cae4f6f65d3c486159a7 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
|
// Copyright Yahoo. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
#pragma once
#include <vespa/searchcommon/attribute/iattributevector.h>
namespace vespalib::datastore { class CompactionStrategy; }
namespace vespalib { class MemoryUsage; }
namespace search::attribute {
class IPostingListAttributeBase
{
public:
using CompactionStrategy = vespalib::datastore::CompactionStrategy;
virtual ~IPostingListAttributeBase() = default;
virtual void clearPostings(IAttributeVector::EnumHandle eidx, uint32_t fromLid, uint32_t toLid) = 0;
virtual void forwardedShrinkLidSpace(uint32_t newSize) = 0;
virtual vespalib::MemoryUsage getMemoryUsage() const = 0;
virtual bool consider_compact_worst_btree_nodes(const CompactionStrategy& compaction_strategy) = 0;
virtual bool consider_compact_worst_buffers(const CompactionStrategy& compaction_strategy) = 0;
};
} // namespace search::attribute
|