blob: 7c3e6c10e9d98e73b8dff60914cce26a1dd2bc6d (
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 Vespa.ai. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
#pragma once
#include <vespa/vespalib/util/generationhandler.h>
#include <vespa/vespalib/util/buffer.h>
#include <vespa/document/bucket/bucketid.h>
namespace search {
class IBucketizer
{
public:
using SP = std::shared_ptr<IBucketizer>;
virtual ~IBucketizer() = default;
virtual document::BucketId getBucketOf(const vespalib::GenerationHandler::Guard & guard, uint32_t lid) const = 0;
virtual vespalib::GenerationHandler::Guard getGuard() const = 0;
};
class IBufferVisitor {
public:
virtual ~IBufferVisitor() = default;
virtual void visit(uint32_t lid, vespalib::ConstBufferRef buffer) = 0;
};
}
|