chromium/third_party/webrtc/rtc_base/experiments/field_trial_parser.cc

/*
 *  Copyright 2019 The WebRTC project authors. All Rights Reserved.
 *
 *  Use of this source code is governed by a BSD-style license
 *  that can be found in the LICENSE file in the root of the source
 *  tree. An additional intellectual property rights grant can be found
 *  in the file PATENTS.  All contributing project authors may
 *  be found in the AUTHORS file in the root of the source tree.
 */
#include "rtc_base/experiments/field_trial_parser.h"

#include <inttypes.h>

#include <algorithm>
#include <map>
#include <type_traits>
#include <utility>

#include "absl/strings/string_view.h"
#include "rtc_base/checks.h"
#include "rtc_base/logging.h"
#include "rtc_base/numerics/safe_conversions.h"

namespace webrtc {

FieldTrialParameterInterface::FieldTrialParameterInterface(
    absl::string_view key)
    :{}
FieldTrialParameterInterface::~FieldTrialParameterInterface() {}

void ParseFieldTrial(
    std::initializer_list<FieldTrialParameterInterface*> fields,
    absl::string_view trial_string) {}

template <>
absl::optional<bool> ParseTypedParameter<bool>(absl::string_view str) {}

template <>
absl::optional<double> ParseTypedParameter<double>(absl::string_view str) {}

template <>
absl::optional<int> ParseTypedParameter<int>(absl::string_view str) {}

template <>
absl::optional<unsigned> ParseTypedParameter<unsigned>(absl::string_view str) {}

template <>
absl::optional<std::string> ParseTypedParameter<std::string>(
    absl::string_view str) {}

template <>
absl::optional<absl::optional<bool>> ParseTypedParameter<absl::optional<bool>>(
    absl::string_view str) {}
template <>
absl::optional<absl::optional<int>> ParseTypedParameter<absl::optional<int>>(
    absl::string_view str) {}
template <>
absl::optional<absl::optional<unsigned>>
ParseTypedParameter<absl::optional<unsigned>>(absl::string_view str) {}
template <>
absl::optional<absl::optional<double>>
ParseTypedParameter<absl::optional<double>>(absl::string_view str) {}

FieldTrialFlag::FieldTrialFlag(absl::string_view key)
    :{}

FieldTrialFlag::FieldTrialFlag(absl::string_view key, bool default_value)
    :{}

bool FieldTrialFlag::Get() const {}

operator bool()

bool FieldTrialFlag::Parse(absl::optional<std::string> str_value) {}

AbstractFieldTrialEnum::AbstractFieldTrialEnum(
    absl::string_view key,
    int default_value,
    std::map<std::string, int> mapping)
    :{}
AbstractFieldTrialEnum::AbstractFieldTrialEnum(const AbstractFieldTrialEnum&) =
    default;
AbstractFieldTrialEnum::~AbstractFieldTrialEnum() = default;

bool AbstractFieldTrialEnum::Parse(absl::optional<std::string> str_value) {}

template class FieldTrialParameter<bool>;
template class FieldTrialParameter<double>;
template class FieldTrialParameter<int>;
template class FieldTrialParameter<unsigned>;
template class FieldTrialParameter<std::string>;

template class FieldTrialConstrained<double>;
template class FieldTrialConstrained<int>;
template class FieldTrialConstrained<unsigned>;

template class FieldTrialOptional<double>;
template class FieldTrialOptional<int>;
template class FieldTrialOptional<unsigned>;
template class FieldTrialOptional<bool>;
template class FieldTrialOptional<std::string>;

}  // namespace webrtc