blob: 185daa15f2ff90c9ec437f824ea3a7ea2bbebf91 (
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
27
28
29
30
31
32
33
34
35
36
|
// Copyright Yahoo. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
#pragma once
#include <vespa/searchcore/proton/common/alloc_strategy.h>
#include <vespa/searchlib/common/serialnum.h>
#include <memory>
#include <optional>
namespace vespa::config::search::internal { class InternalAttributesType; };
namespace proton {
class AttributeCollectionSpec;
/**
* A factory for generating an AttributeCollectionSpec based on AttributesConfig
* from the config server.
*/
class AttributeCollectionSpecFactory
{
private:
using AttributesConfig = const vespa::config::search::internal::InternalAttributesType;
const AllocStrategy _alloc_strategy;
const bool _fastAccessOnly;
public:
AttributeCollectionSpecFactory(const AllocStrategy& alloc_strategy, bool fastAccessOnly);
~AttributeCollectionSpecFactory();
std::unique_ptr<AttributeCollectionSpec> create(const AttributesConfig &attrCfg, uint32_t docIdLimit, std::optional<search::SerialNum> serialNum) const;
};
} // namespace proton
|