aboutsummaryrefslogtreecommitdiffstats
path: root/searchsummary/src/vespa/juniper/IJuniperProperties.h
blob: 4902d3d561dd1b23c7d5feb69e113d430bec24b7 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
// Copyright Yahoo. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.

#pragma once

/** An abstract interface to configuration file settings used by Juniper to process
 *  it's preconfigured parameter sets.
 */
class IJuniperProperties
{
public:
    /** Get the value of a property
     *  @param name The textual representation of the property
     *  assumed to be on the form class.juniperpart.variable, such as for example
     *  juniper.dynsum.length
     *  @param def A default value for the property if not found in configuration
     *  @return The value of the property or @param def if no such property is set
     */
    virtual const char* GetProperty(const char* name, const char* def = nullptr) const = 0;

    virtual ~IJuniperProperties() = default;
};