print_doc_functions.hpp
Go to the documentation of this file.
1 
13 #ifndef MLPACK_BINDINGS_R_PRINT_DOC_FUNCTIONS_HPP
14 #define MLPACK_BINDINGS_R_PRINT_DOC_FUNCTIONS_HPP
15 
17 
18 namespace mlpack {
19 namespace bindings {
20 namespace r {
21 
25 inline std::string GetBindingName(const std::string& bindingName);
26 
30 inline std::string PrintImport();
31 
35 inline std::string PrintInputOptionInfo();
36 
40 inline std::string PrintOutputOptionInfo();
41 
45 template<typename T>
46 inline std::string PrintValue(const T& value, bool quotes);
47 
51 template<>
52 inline std::string PrintValue(const bool& value, bool quotes);
53 
57 inline std::string PrintDefault(const std::string& bindingName,
58  const std::string& paramName);
59 
63 inline std::string PrintInputOptions(util::Params& /* p */);
64 
69 template<typename T, typename... Args>
70 std::string PrintInputOptions(util::Params& p,
71  const std::string& paramName,
72  const T& value,
73  Args... args);
74 
78 inline std::string PrintOutputOptions(util::Params& /* p */,
79  const bool /* markdown */);
80 
81 template<typename T, typename... Args>
82 std::string PrintOutputOptions(util::Params& p,
83  const bool markdown,
84  const std::string& paramName,
85  const T& value,
86  Args... args);
87 
92 template<typename... Args>
93 std::string ProgramCall(const bool markdown,
94  const std::string& programName,
95  Args... args);
96 
101 inline std::string ProgramCall(util::Params& p, const std::string& programName);
102 
106 inline std::string PrintModel(const std::string& modelName);
107 
112 inline std::string PrintDataset(const std::string& datasetName);
113 
118 inline std::string ParamString(const std::string& paramName);
119 
123 inline bool IgnoreCheck(const std::string& paramName);
124 
129 inline bool IgnoreCheck(const std::vector<std::string>& constraints);
130 
135 inline bool IgnoreCheck(
136  const std::vector<std::pair<std::string, bool>>& constraints,
137  const std::string& paramName);
138 
139 } // namespace r
140 } // namespace bindings
141 } // namespace mlpack
142 
143 // Include implementation.
144 #include "print_doc_functions_impl.hpp"
145 
146 #endif
std::string PrintValue(const T &value, bool quotes)
Given a parameter type, print the corresponding value.
std::string PrintDefault(const std::string &bindingName, const std::string &paramName)
Given a parameter name, print its corresponding default value.
Linear algebra utility functions, generally performed on matrices or vectors.
std::string PrintImport()
Print any import information for the R binding.
std::string PrintDataset(const std::string &datasetName)
Given the name of a matrix, print it.
std::string ProgramCall(const bool markdown, const std::string &programName, Args... args)
Given a name of a binding and a variable number of arguments (and their contents), print the corresponding function call.
bool IgnoreCheck(const std::string &paramName)
Print whether or not we should ignore a check on the given parameter.
std::string PrintModel(const std::string &modelName)
Given the name of a model, print it.
std::string PrintOutputOptions(util::Params &, const bool)
Recursion base case.
std::string ParamString(const std::string &paramName)
Given the parameter name, determine what it would actually be when passed to the command line...
std::string PrintInputOptions(util::Params &)
Recursion base case.
std::string GetBindingName(const std::string &bindingName)
Given the name of a binding, print its R name.
std::string PrintOutputOptionInfo()
Print any special information about output options.
std::string PrintInputOptionInfo()
Print any special information about input options.