aboutsummaryrefslogtreecommitdiffstats
path: root/config/src/vespa/config/raw/rawsourcefactory.h
blob: c1aa95a6511b999499e2b77c5647281a14e10947 (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
// Copyright Vespa.ai. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
#pragma once

#include <vespa/config/common/sourcefactory.h>

namespace config {

/**
 * Factory for RawSource
 */
class RawSourceFactory : public SourceFactory {
public:
    RawSourceFactory(const vespalib::string & payload)
        : _payload(payload)
    { }

    std::unique_ptr<Source> createSource(std::shared_ptr<IConfigHolder> holder, const ConfigKey & key) const override;
private:
    const vespalib::string _payload;
};

}