print_type_doc.hpp
Go to the documentation of this file.
1 
13 #ifndef MLPACK_BINDINGS_PYTHON_PRINT_TYPE_DOC_HPP
14 #define MLPACK_BINDINGS_PYTHON_PRINT_TYPE_DOC_HPP
15 
17 
18 namespace mlpack {
19 namespace bindings {
20 namespace python {
21 
25 template<typename T>
26 std::string PrintTypeDoc(
27  const util::ParamData& data,
28  const typename boost::disable_if<arma::is_arma_type<T>>::type* = 0,
29  const typename boost::disable_if<util::IsStdVector<T>>::type* = 0,
30  const typename boost::disable_if<data::HasSerialize<T>>::type* = 0,
31  const typename boost::disable_if<std::is_same<T,
32  std::tuple<data::DatasetInfo, arma::mat>>>::type* = 0);
33 
37 template<typename T>
38 std::string PrintTypeDoc(
39  const util::ParamData& data,
40  const typename std::enable_if<util::IsStdVector<T>::value>::type* = 0);
41 
45 template<typename T>
46 std::string PrintTypeDoc(
47  const util::ParamData& data,
48  const typename std::enable_if<arma::is_arma_type<T>::value>::type* = 0);
49 
53 template<typename T>
54 std::string PrintTypeDoc(
55  const util::ParamData& data,
56  const typename std::enable_if<std::is_same<T,
57  std::tuple<data::DatasetInfo, arma::mat>>::value>::type* = 0);
58 
62 template<typename T>
63 std::string PrintTypeDoc(
64  const util::ParamData& data,
65  const typename boost::disable_if<arma::is_arma_type<T>>::type* = 0,
66  const typename boost::enable_if<data::HasSerialize<T>>::type* = 0);
67 
71 template<typename T>
72 void PrintTypeDoc(const util::ParamData& data,
73  const void* /* input */,
74  void* output)
75 {
76  *((std::string*) output) =
77  PrintTypeDoc<typename std::remove_pointer<T>::type>(data);
78 }
79 
80 } // namespace python
81 } // namespace bindings
82 } // namespace mlpack
83 
84 #include "print_type_doc_impl.hpp"
85 
86 #endif
static const bool value
strip_type.hpp
Definition: add_to_po.hpp:21
python
Definition: CMakeLists.txt:4
This structure holds all of the information about a single parameter, including its value (which is s...
Definition: param_data.hpp:52
std::string PrintTypeDoc(const util::ParamData &data, const typename boost::disable_if< arma::is_arma_type< T >>::type *=0, const typename boost::disable_if< util::IsStdVector< T >>::type *=0, const typename boost::disable_if< data::HasSerialize< T >>::type *=0, const typename boost::disable_if< std::is_same< T, std::tuple< data::DatasetInfo, arma::mat >>>::type *=0)
Return a string representing the command-line type of an option.