xref: /openbmc/phosphor-certificate-manager/argument.hpp (revision 7047be6784455faa71f16ebbc66a74040634e350)
10aa0d114SJayanth Othayoth #pragma once
20aa0d114SJayanth Othayoth 
30aa0d114SJayanth Othayoth #include <string>
40aa0d114SJayanth Othayoth 
5*7047be67SNan Zhou namespace phosphor::certs
60aa0d114SJayanth Othayoth {
70aa0d114SJayanth Othayoth 
8*7047be67SNan Zhou struct Arguments
90aa0d114SJayanth Othayoth {
10*7047be67SNan Zhou     std::string typeStr;  // certificate type
11*7047be67SNan Zhou     std::string endpoint; // d-bus endpoint
12*7047be67SNan Zhou     std::string path;     // certificate file path
13*7047be67SNan Zhou     std::string unit;     // Optional systemd unit need to reload
140aa0d114SJayanth Othayoth };
150aa0d114SJayanth Othayoth 
16*7047be67SNan Zhou // Validates all |argv| is valid and set corresponding attributes in
17*7047be67SNan Zhou // |arguments|.
18*7047be67SNan Zhou int processArguments(int argc, const char* const* argv, Arguments& arguments);
19*7047be67SNan Zhou } // namespace phosphor::certs
20