Android-cuttlefish cvd tool
flags_collector.h
Go to the documentation of this file.
1/*
2 * Copyright (C) 2023 The Android Open Source Project
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16
17#pragma once
18
19#include <optional>
20#include <string>
21#include <vector>
22
23namespace cuttlefish {
24
25class FlagInfo {
26 public:
27 FlagInfo(std::string name, std::string type);
28
29 const std::string& Name() const { return name_; }
30 const std::string& Type() const { return type_; }
31
32 private:
33 // TODO(kwstephenkim): add more fields
34 std::string name_;
35 std::string type_;
36};
37
38std::optional<std::vector<FlagInfo>> CollectFlagsFromHelpxml(
39 const std::string& xml_str);
40
41} // namespace cuttlefish
Definition: flags_collector.h:25
FlagInfo(std::string name, std::string type)
Definition: flags_collector.cpp:119
const std::string & Type() const
Definition: flags_collector.h:30
const std::string & Name() const
Definition: flags_collector.h:29
std::string name_
Definition: flags_collector.h:34
std::string type_
Definition: flags_collector.h:35
Definition: alloc_utils.cpp:23
std::optional< std::vector< FlagInfo > > CollectFlagsFromHelpxml(const std::string &xml_str)
Definition: flags_collector.cpp:122
uint8_t type
Definition: pairing_connection.h:0