Namespaces | Classes | Typedefs | Functions | Variables
cet Namespace Reference

Namespaces

 _
 
 detail
 
 sqlite
 

Classes

class  base_converter
 
class  BasicPluginFactory
 
struct  bit_size
 struct bit_size<U>. More...
 
struct  bit_size< U, true >
 
class  cpu_timer
 
class  crc32
 
class  CRC32Calculator
 
struct  default_clone
 
struct  default_copy
 
class  exempt_ptr
 
class  filepath_first_absolute_or_lookup_with_dot
 
class  filepath_lookup
 
class  filepath_lookup_after1
 
class  filepath_lookup_nonabsolute
 
class  filepath_maker
 
class  HorizontalRule
 
class  includer
 
class  LibraryManager
 
class  lookup_policy_selector
 
class  map_vector
 
class  map_vector_key
 
class  maybe_ref
 
class  MD5Digest
 
struct  MD5Result
 
struct  name_of
 
struct  name_of< bool >
 
struct  name_of< char >
 
struct  name_of< double >
 
struct  name_of< float >
 
struct  name_of< int >
 
struct  name_of< long >
 
struct  name_of< long double >
 
struct  name_of< long long >
 
struct  name_of< short >
 
struct  name_of< signed char >
 
struct  name_of< std::istream >
 
struct  name_of< std::nullptr_t >
 
struct  name_of< std::ostream >
 
struct  name_of< std::string >
 
struct  name_of< T & >
 
struct  name_of< T * >
 
struct  name_of< T const >
 
struct  name_of< T const volatile >
 
struct  name_of< T volatile >
 
struct  name_of< T[N]>
 
struct  name_of< unsigned char >
 
struct  name_of< unsigned int >
 
struct  name_of< unsigned long >
 
struct  name_of< unsigned long long >
 
struct  name_of< unsigned short >
 
struct  name_of< void >
 
struct  no_delete
 
class  nybbler
 
class  ostream_handle
 
struct  path_tag_t
 
class  PluginFactory
 
struct  PluginTypeDeducer
 
struct  PluginTypeDeducer< art::EmptyEventTimestampPlugin >
 
struct  PluginTypeDeducer< art::FileCatalogMetadataPlugin >
 
struct  PluginTypeDeducer< art::ResultsProducer >
 
struct  PluginTypeDeducer< cettest::TestPluginBase >
 
struct  PluginTypeDeducer< mf::service::ELdestination >
 
class  propagate_const
 
class  registry
 
class  registry_via_id
 
class  search_path
 
class  sha1
 
class  simple_stats
 
class  value_ptr
 

Typedefs

using no_tag = char(&)[1]
 
using yes_tag = char(&)[2]
 
using n = std::void_t< T >
 
template<typename T , typename U , typename R = void>
using enable_if_same_t = std::enable_if_t< std::is_same_v< T, U >, R >
 
template<typename FT , FT f, typename R = void>
using enable_if_function_exists_t = enable_if_same_t< FT, decltype(f), R >
 

Functions

std::string bold_fontify (std::string const &s)
 
bool canonical_number (std::string const &value, std::string &result)
 
std::string escape (std::string const &str)
 
std::string unescape (std::string const &str)
 
bool is_single_quoted_string (std::string const &str)
 
bool is_double_quoted_string (std::string const &str)
 
bool is_quoted_string (std::string const &str)
 
bool canonical_string (std::string const &str, std::string &result)
 
std::string canonical_string (std::string const &str)
 
std::string::size_type column_width (std::vector< std::string > const &)
 
template<class FwdCont , class Func >
auto for_all (FwdCont &, Func)
 
template<class FwdCont , class Func >
auto for_all (FwdCont const &, Func)
 
template<class FwdCont , class FwdIter >
auto copy_all (FwdCont &, FwdIter)
 
template<class FwdCont , class FwdIter >
auto copy_all (FwdCont const &, FwdIter)
 
template<class FwdCont , class FwdIter , class Pred >
auto copy_if_all (FwdCont &, FwdIter, Pred)
 
template<class FwdCont , class FwdIter , class Pred >
auto copy_if_all (FwdCont const &, FwdIter, Pred)
 
template<class FwdCont , class Datum >
auto find_in_all (FwdCont &, Datum const &)
 
template<class FwdCont , class Datum >
auto find_in_all (FwdCont const &, Datum const &)
 
template<class FwdCont , class Datum >
bool search_all (FwdCont const &, Datum const &)
 
template<class FwdCont , class Datum >
bool binary_search_all (FwdCont const &, Datum const &)
 
template<class FwdCont , class Datum >
auto lower_bound_all (FwdCont &, Datum const &)
 
template<class FwdCont , class Datum >
auto lower_bound_all (FwdCont const &, Datum const &)
 
template<class FwdCont , class Datum , class Pred >
auto lower_bound_all (FwdCont &, Datum const &, Pred)
 
template<class FwdCont , class Datum , class Pred >
auto lower_bound_all (FwdCont const &, Datum const &, Pred)
 
template<class RandCont >
void sort_all (RandCont &)
 
template<class RandCont , class Pred >
void sort_all (RandCont &, Pred)
 
template<class RandCont >
void stable_sort_all (RandCont &)
 
template<class RandCont , class Pred >
void stable_sort_all (RandCont &, Pred)
 
template<class Container , class OutputIt , class UnaryOp >
auto transform_all (Container &, OutputIt, UnaryOp)
 
template<class Container , class OutputIt , class UnaryOp >
auto transform_all (Container const &, OutputIt, UnaryOp)
 
template<class Container1 , class Container2 , class OutputIt , class BinaryOp >
auto transform_all (Container1 &, Container2 &, OutputIt, BinaryOp)
 
template<class Container1 , class Container2 , class OutputIt , class BinaryOp >
auto transform_all (Container1 const &, Container2 const &, OutputIt, BinaryOp)
 
template<class FwdCont , class Func >
void for_all_with_index (FwdCont &, Func)
 
template<class FwdCont , class Func >
void for_all_with_index (FwdCont const &, Func)
 
template<class E >
void swap (exempt_ptr< E > &, exempt_ptr< E > &) noexcept
 
template<class E >
constexpr exempt_ptr< Emake_exempt_ptr (E *) noexcept
 
template<class E >
constexpr bool operator== (exempt_ptr< E >, exempt_ptr< E >) noexcept
 
template<class E >
constexpr bool operator!= (exempt_ptr< E >, exempt_ptr< E >) noexcept
 
template<class E >
constexpr bool operator== (exempt_ptr< E >, std::nullptr_t) noexcept
 
template<class E >
constexpr bool operator!= (exempt_ptr< E >, std::nullptr_t) noexcept
 
template<class E >
constexpr bool operator== (std::nullptr_t, exempt_ptr< E >) noexcept
 
template<class E >
constexpr bool operator!= (std::nullptr_t, exempt_ptr< E >) noexcept
 
template<class E >
constexpr bool operator< (exempt_ptr< E >, exempt_ptr< E >)
 
template<class E >
constexpr bool operator> (exempt_ptr< E >, exempt_ptr< E >)
 
template<class E >
constexpr bool operator<= (exempt_ptr< E >, exempt_ptr< E >)
 
template<class E >
constexpr bool operator>= (exempt_ptr< E >, exempt_ptr< E >)
 
bool file_exists (std::string const &qualified_filename)
 
bool is_absolute_filepath (std::string const &qualified_filename)
 
bool is_relative_filepath (std::string const &qualified_filename)
 
std::string getenv (std::string const &name)
 
std::string getenv (std::string const &name, std::nothrow_t)
 
template<typename PTR_T >
PTR_T hard_cast (void *src)
 
template<typename PTR_T >
void hard_cast (void *src, PTR_T &dest)
 
template<class T >
std::enable_if_t< std::is_arithmetic_v< T >, T > hypot (T x, T y)
 
template<class T >
std::enable_if_t< std::is_arithmetic_v< T >, T > unchecked_hypot (T x, T y)
 
template<class T >
std::enable_if_t< std::is_arithmetic_v< T >, T > checked_hypot (T x, T y)
 
void include (std::istream &in, std::string &result)
 
void include (std::istream &in, std::string const &search_path_arg, std::string &result)
 
void loadable_libraries (std::ostream &os, std::string const &spec, std::string const &suffix)
 
std::string lpad (std::string const &pad_me, std::string::size_type wanted_size, char char_to_pad_with= ' ')
 
bool operator== (map_vector_key const &, map_vector_key const &) noexcept
 
bool operator!= (map_vector_key const &, map_vector_key const &) noexcept
 
bool operator< (map_vector_key const &, map_vector_key const &) noexcept
 
bool operator> (map_vector_key const &, map_vector_key const &) noexcept
 
bool operator<= (map_vector_key const &, map_vector_key const &) noexcept
 
bool operator>= (map_vector_key const &, map_vector_key const &) noexcept
 
std::ostream & operator<< (std::ostream &, map_vector_key const &)
 
template<class T >
void swap (maybe_ref< T > &, maybe_ref< T > &)
 
template<class T >
bool operator== (maybe_ref< T > const &left, maybe_ref< T > const &right)
 
template<class T >
std::ostream & operator<< (std::ostream &os, maybe_ref< T > const &item)
 
void set_to_default (MD5Result &val)
 
bool operator== (MD5Result const &a, MD5Result const &b)
 
bool operator< (MD5Result const &a, MD5Result const &b)
 
bool operator!= (MD5Result const &a, MD5Result const &b)
 
std::ostream & operator<< (std::ostream &os, MD5Result const &r)
 
constexpr char const * os_libpath ()
 
ostream_handle select_stream (std::string const &filename, std::ostream &default_os)
 
boost::program_options::variables_map parsed_program_options (int argc, char **argv, boost::program_options::options_description const &desc, boost::program_options::positional_options_description const &pos={})
 
constexpr char const * plugin_libpath ()
 
template<unsigned N, class T >
constexpr T pow (T x)
 
template<class T >
constexpr T square (T x)
 
template<class T >
constexpr T cube (T x)
 
template<class T >
constexpr T fourth (T x)
 
template<class T >
constexpr T diff_of_squares (T x, T y)
 
template<class T >
constexpr T sum_of_squares (T x, T y)
 
template<class T >
constexpr T sum_of_squares (T x, T y, T z)
 
template<typename T >
T & get_underlying (propagate_const< T > &)
 
template<typename T >
T const & get_underlying (propagate_const< T > const &)
 
bool replace_all (std::string &in, std::string const &from, std::string const &to)
 Replace all occurrences of from in string with to. More...
 
std::string rpad (std::string const &pad_me, std::string::size_type wanted_size, char char_to_pad_with= ' ')
 
std::ostream & operator<< (std::ostream &os, search_path const &p)
 
std::string shlib_prefix ()
 
std::string shlib_suffix ()
 
template<class charT , class traits >
std::basic_ostream< charT, traits > & operator<< (std::basic_ostream< charT, traits > &, simple_stats const &)
 
template<class OutIter >
void split (std::string const &s, char c, OutIter dest)
 
template<class Pred , class OutIter >
void split_if (std::string const &s, Pred is_sep, OutIter dest)
 
std::vector< std::stringsplit_by_regex (std::string const &str, std::regex const &reDelimSet)
 
std::vector< std::stringsplit_by_regex (std::string const &str, std::string const &delimSet)
 
void split_path (std::string const &path, std::vector< std::string > &components)
 
std::ostream & boost_test_print_type (std::ostream &os, value_ptr< int > const p)
 
std::stringtrim_right (std::string &source, std::string const &t=" ")
 
std::stringtrim_left (std::string &source, std::string const &t=" ")
 
std::stringtrim (std::string &source, std::string const &t=" ")
 
std::string trim_right_copy (std::string source, std::string const &t=" ")
 
std::string trim_left_copy (std::string source, std::string const &t=" ")
 
std::string trim_copy (std::string source, std::string const &t=" ")
 
template<class E , class C , class D >
void swap (value_ptr< E, C, D > &, value_ptr< E, C, D > &) noexcept
 
template<class E , class C , class D >
bool operator== (value_ptr< E, C, D > const &, value_ptr< E, C, D > const &)
 
template<class E , class C , class D >
bool operator!= (value_ptr< E, C, D > const &, value_ptr< E, C, D > const &)
 
template<class E , class C , class D >
bool operator== (value_ptr< E, C, D > const &, std::nullptr_t const &)
 
template<class E , class C , class D >
bool operator!= (value_ptr< E, C, D > const &, std::nullptr_t const &)
 
template<class E , class C , class D >
bool operator== (std::nullptr_t const &, value_ptr< E, C, D > const &)
 
template<class E , class C , class D >
bool operator!= (std::nullptr_t const &, value_ptr< E, C, D > const &)
 
template<class E , class C , class D >
bool operator< (value_ptr< E, C, D > const &, value_ptr< E, C, D > const &)
 
template<class E , class C , class D >
bool operator> (value_ptr< E, C, D > const &, value_ptr< E, C, D > const &)
 
template<class E , class C , class D >
bool operator<= (value_ptr< E, C, D > const &, value_ptr< E, C, D > const &)
 
template<class E , class C , class D >
bool operator>= (value_ptr< E, C, D > const &, value_ptr< E, C, D > const &)
 

Variables

template<class U >
constexpr std::size_t bit_size_v = bit_size<U>::value
 
template<typename T >
std::string const & PluginTypeDeducer_v = PluginTypeDeducer<T>::value
 
path_tag_t const path_tag
 

Typedef Documentation

template<typename FT , FT f, typename R = void>
using cet::enable_if_function_exists_t = typedef enable_if_same_t<FT, decltype(f), R>

Definition at line 46 of file metaprogramming.h.

template<typename T , typename U , typename R = void>
using cet::enable_if_same_t = typedef std::enable_if_t<std::is_same_v<T, U>, R>

Definition at line 43 of file metaprogramming.h.

using cet::n = typedef std::void_t<T>

Definition at line 28 of file metaprogramming.h.

using cet::no_tag = typedef char (&)[1]

Definition at line 10 of file metaprogramming.h.

using cet::yes_tag = typedef char (&)[2]

Definition at line 11 of file metaprogramming.h.

Function Documentation

template<class FwdCont , class Datum >
bool cet::binary_search_all ( FwdCont const &  s,
Datum const &  d 
)
inline

Definition at line 199 of file container_algorithms.h.

200 {
201  using std::cbegin;
202  using std::cend;
203  return std::binary_search(cbegin(s), cend(s), d);
204 }
decltype(auto) constexpr cend(T &&obj)
ADL-aware version of std::cend.
Definition: StdUtils.h:87
decltype(auto) constexpr cbegin(T &&obj)
ADL-aware version of std::cbegin.
Definition: StdUtils.h:82
static QCString * s
Definition: config.cpp:1042
std::string cet::bold_fontify ( std::string const &  s)
inline

Definition at line 8 of file bold_fontify.h.

9  {
10  return "\033[1m" + s + "\033[0m";
11  }
static QCString * s
Definition: config.cpp:1042
std::ostream& cet::boost_test_print_type ( std::ostream &  os,
value_ptr< int > const  p 
)

Definition at line 16 of file value_ptr_test.cc.

17  {
18  return os << p.get();
19  }
pointer get() const noexcept
Definition: value_ptr.h:288
bool cet::canonical_number ( std::string const &  value,
std::string result 
)

Definition at line 20 of file canonical_number.cc.

20  {
23 
24  // 0x or 0X leaded hex number
25  if (value.size() > 2 && value[0] == '0' && toupper(value[1]) == 'X') {
26  it += 2;
27 
28  // extract the whole part
29  static std::string const hexallowed("0123456789ABCDEFabcdef");
31  for (; it != end && hexallowed.find(*it) != std::string::npos; ++it)
32  hex.append(1, toupper(*it));
33 
34  // consumed all?
35  if (it != end)
36  return false;
37 
38  // convert to decimal
40  try {
41  dec = base_converter::hex_to_dec(hex);
42  }
43  catch (...) {
44  return false;
45  }
46 
47  // canonical form for the unsigned decimal number
48  return canonical_number(dec, result);
49  }
50 
51  // 0b or 0B leaded binary numbers
52  if (value.size() > 2 && value[0] == '0' && toupper(value[1]) == 'B') {
53  it += 2;
54 
55  // extract the whole part
56  static std::string const binallowed("01");
58  for (; it != end && binallowed.find(*it) != std::string::npos; ++it)
59  bin.append(1, *it);
60 
61  // consumed all?
62  if (it != end)
63  return false;
64 
65  // convert to decimal
67  try {
68  dec = base_converter::bin_to_dec(bin);
69  }
70  catch (...) {
71  return false;
72  }
73 
74  // canonical form for the unsigned decimal number
75  return canonical_number(dec, result);
76  }
77 
78  // extract sign, if any
79  std::string sign(*it == '-' ? "-" : "");
80  if (*it == '+' || *it == '-')
81  ++it;
82 
83  // extract optional whole part
84  std::string whole;
85  for (; it != end && std::isdigit(*it); ++it)
86  whole.append(1, *it);
87 
88  // extract fraction part
89  std::string fraction;
90  if (it != end && *it == '.') {
91  while (++it != end && std::isdigit(*it))
92  fraction.append(1, *it);
93  }
94 
95  // exponent part
96  std::string exponent;
97  if (it != end && (*it == 'E' || *it == 'e')) {
98  if (++it == end)
99  return false;
100  if (*it == '+' || *it == '-') {
101  exponent = *it;
102  if (++it == end)
103  return false;
104  }
105  for (; it != end && std::isdigit(*it); ++it)
106  exponent.append(1, *it);
107  }
108 
109  // consumed everything?
110  if (it != end)
111  return false;
112 
113  // require at least one digit
114  std::string digits = whole + fraction;
115  if (digits.empty())
116  return false;
117  std::size_t ndig = digits.size();
118 
119  // calculate exponent as if decimal point were at left
120  long exp = std::atoi(exponent.c_str()) + whole.size();
121 
122  // discard trailing zeroes
123  while (ndig > 1 && digits[ndig - 1] == '0')
124  digits.erase(--ndig, 1);
125  // discard leading zeroes
126  for (; ndig > 1 && digits[0] == '0'; --exp, --ndig)
127  digits.erase(0, 1);
128 
129  // produce result
130  if (digits == "0") {
131  result.append(digits);
132  return true;
133  }
134  result.append(sign);
135  if (long(ndig) <= exp && exp <= 6L) { // non-neg exp < e6?
136  result.append(digits).append(exp - ndig, '0');
137  } else {
138  if (ndig > 1)
139  digits.insert(digits.begin() + 1, '.');
140  --exp;
141  result.append(digits);
142  if (exp != 0) {
143  result.append(1, 'e').append(std::to_string(exp));
144  }
145  }
146  return true;
147 }
148 catch (...) {
149  return false;
150 } // canonical_number()
end
while True: pbar.update(maxval-len(onlies[E][S])) #print iS, "/", len(onlies[E][S]) found = False for...
bool canonical_number(std::string const &value, std::string &result)
static QCString result
std::string string
Definition: nybbler.cc:12
intermediate_table::const_iterator const_iterator
QTextStream & hex(QTextStream &s)
QCString & insert(uint index, const char *s)
Definition: qcstring.cpp:355
QTextStream & dec(QTextStream &s)
int sign(double val)
Definition: UtilFunc.cxx:104
QTextStream & bin(QTextStream &s)
std::string to_string(ModuleType const mt)
Definition: ModuleType.h:34
QCString & append(const char *s)
Definition: qcstring.cpp:383
bool cet::canonical_string ( std::string const &  str,
std::string result 
)
inline

Definition at line 58 of file canonical_string.h.

58  {
59  bool success = false;
60  if (!s.empty()) {
62  success = true;
63  }
64  return success;
65 }
66 catch (...) {
67  return false;
68 } // canonical_string()
static QCString result
static QCString * s
Definition: config.cpp:1042
QCString & append(const char *s)
Definition: qcstring.cpp:383
std::string canonical_string(std::string const &str)
std::string cet::canonical_string ( std::string const &  str)

Definition at line 85 of file canonical_string.cc.

86 {
88  if (!s.empty()) {
91  value = cet::unescape(s.substr(1, s.size() - 2));
92  } else if (is_single_quoted_string(s)) {
93  value = s.substr(1, s.size() - 2);
94  } else {
95  value = s;
96  }
97 
98  result.append(1, '"').append(cet::escape(value)).append(1, '"');
99  }
100  return result;
101 }
static QCString result
std::string string
Definition: nybbler.cc:12
uint size() const
Definition: qcstring.h:201
std::string unescape(std::string const &str)
bool is_double_quoted_string(std::string const &str)
bool is_single_quoted_string(std::string const &str)
std::string escape(std::string const &str)
static QCString * s
Definition: config.cpp:1042
QCString & append(const char *s)
Definition: qcstring.cpp:383
template<class T >
std::enable_if_t< std::is_arithmetic_v< T >, T > cet::checked_hypot ( x,
y 
)

Definition at line 43 of file hypot.h.

44 {
45 
46  if (std::isinf(x) || std::isinf(y))
47  return std::numeric_limits<T>::infinity();
48  else if (std::isnan(x) || std::isnan(y))
49  return std::numeric_limits<T>::quiet_NaN();
50  else
51  return unchecked_hypot(x, y);
52 
53 } // checked_hypot<>(,)
std::enable_if_t< std::is_arithmetic_v< T >, T > unchecked_hypot(T x, T y)
Definition: hypot.h:33
list x
Definition: train.py:276
std::string::size_type cet::column_width ( std::vector< std::string > const &  v)

Definition at line 6 of file column_width.cc.

7 {
8  if (v.empty())
9  return 0ull;
10 
11  auto max_elem =
12  std::max_element(v.begin(), v.end(), [](auto const& a, auto const& b) {
13  return a.size() < b.size();
14  });
15  return max_elem->size();
16 }
const double a
static bool * b
Definition: config.cpp:1043
template<class FwdCont , class FwdIter >
auto cet::copy_all ( FwdCont &  s,
FwdIter  it 
)
inline

Definition at line 132 of file container_algorithms.h.

133 {
134  using std::begin;
135  using std::end;
136  return std::copy(begin(s), end(s), it);
137 }
end
while True: pbar.update(maxval-len(onlies[E][S])) #print iS, "/", len(onlies[E][S]) found = False for...
T copy(T const &v)
decltype(auto) constexpr begin(T &&obj)
ADL-aware version of std::begin.
Definition: StdUtils.h:72
static QCString * s
Definition: config.cpp:1042
template<class FwdCont , class FwdIter >
auto cet::copy_all ( FwdCont const &  s,
FwdIter  it 
)
inline

Definition at line 141 of file container_algorithms.h.

142 {
143  using std::cbegin;
144  using std::cend;
145  return std::copy(cbegin(s), cend(s), it);
146 }
decltype(auto) constexpr cend(T &&obj)
ADL-aware version of std::cend.
Definition: StdUtils.h:87
T copy(T const &v)
decltype(auto) constexpr cbegin(T &&obj)
ADL-aware version of std::cbegin.
Definition: StdUtils.h:82
static QCString * s
Definition: config.cpp:1042
template<class FwdCont , class FwdIter , class Pred >
auto cet::copy_if_all ( FwdCont &  s,
FwdIter  it,
Pred  p 
)
inline

Definition at line 151 of file container_algorithms.h.

152 {
153  using std::cbegin;
154  using std::cend;
155  return std::copy_if(begin(s), end(s), it, p);
156 }
end
while True: pbar.update(maxval-len(onlies[E][S])) #print iS, "/", len(onlies[E][S]) found = False for...
decltype(auto) constexpr cend(T &&obj)
ADL-aware version of std::cend.
Definition: StdUtils.h:87
p
Definition: test.py:223
decltype(auto) constexpr cbegin(T &&obj)
ADL-aware version of std::cbegin.
Definition: StdUtils.h:82
decltype(auto) constexpr begin(T &&obj)
ADL-aware version of std::begin.
Definition: StdUtils.h:72
static QCString * s
Definition: config.cpp:1042
template<class FwdCont , class FwdIter , class Pred >
auto cet::copy_if_all ( FwdCont const &  s,
FwdIter  it,
Pred  p 
)
inline

Definition at line 160 of file container_algorithms.h.

161 {
162  using std::cbegin;
163  using std::cend;
164  return std::copy_if(cbegin(s), cend(s), it, p);
165 }
decltype(auto) constexpr cend(T &&obj)
ADL-aware version of std::cend.
Definition: StdUtils.h:87
p
Definition: test.py:223
decltype(auto) constexpr cbegin(T &&obj)
ADL-aware version of std::cbegin.
Definition: StdUtils.h:82
static QCString * s
Definition: config.cpp:1042
template<class T >
constexpr T cet::cube ( x)

Definition at line 27 of file pow.h.

28  {
29  return pow<3u>(x);
30  }
list x
Definition: train.py:276
template<class T >
constexpr T cet::diff_of_squares ( x,
y 
)

Definition at line 132 of file pow.h.

133 {
134  return (x + y) * (x - y);
135 }
list x
Definition: train.py:276
std::string cet::escape ( std::string const &  str)

Definition at line 16 of file canonical_string.cc.

17 {
19  for (std::string::const_iterator it = str.begin(), e = str.end(); it != e;
20  ++it) {
21  switch (*it) {
22  case '\"':
23  result.append("\\\"");
24  break;
25  case '\'':
26  result.append("\\\'");
27  break;
28  case '\\':
29  result.append("\\\\");
30  break;
31  case '\n':
32  result.append("\\n");
33  break;
34  case '\t':
35  result.append("\\t");
36  break;
37  default:
38  if (std::isprint(*it))
39  result.append(1, *it);
40  else
41  throw cet::exception("unprintable character");
42  }
43  }
44  return result;
45 } // escape()
static QCString result
std::string string
Definition: nybbler.cc:12
intermediate_table::const_iterator const_iterator
const double e
static QCString str
cet::coded_exception< error, detail::translate > exception
Definition: exception.h:33
QCString & append(const char *s)
Definition: qcstring.cpp:383
bool cet::file_exists ( std::string const &  qualified_filename)

Definition at line 14 of file filesystem.cc.

15 {
16  struct stat file_info;
17  return 0 == stat(qualified_filename.c_str(), &file_info);
18 }
template<class FwdCont , class Datum >
auto cet::find_in_all ( FwdCont &  s,
Datum const &  d 
)
inline

Definition at line 170 of file container_algorithms.h.

171 {
172  using std::begin;
173  using std::end;
174  return std::find(begin(s), end(s), d);
175 }
end
while True: pbar.update(maxval-len(onlies[E][S])) #print iS, "/", len(onlies[E][S]) found = False for...
decltype(auto) constexpr begin(T &&obj)
ADL-aware version of std::begin.
Definition: StdUtils.h:72
static QCString * s
Definition: config.cpp:1042
template<class FwdCont , class Datum >
auto cet::find_in_all ( FwdCont const &  s,
Datum const &  d 
)
inline

Definition at line 179 of file container_algorithms.h.

180 {
181  using std::cbegin;
182  using std::cend;
183  return std::find(cbegin(s), cend(s), d);
184 }
decltype(auto) constexpr cend(T &&obj)
ADL-aware version of std::cend.
Definition: StdUtils.h:87
decltype(auto) constexpr cbegin(T &&obj)
ADL-aware version of std::cbegin.
Definition: StdUtils.h:82
static QCString * s
Definition: config.cpp:1042
template<class FwdCont , class Func >
auto cet::for_all ( FwdCont &  s,
Func  f 
)
inline

Definition at line 90 of file container_algorithms.h.

91 {
92  using std::begin;
93  using std::end;
94  return std::for_each(begin(s), end(s), f);
95 }
end
while True: pbar.update(maxval-len(onlies[E][S])) #print iS, "/", len(onlies[E][S]) found = False for...
decltype(auto) constexpr begin(T &&obj)
ADL-aware version of std::begin.
Definition: StdUtils.h:72
static QCString * s
Definition: config.cpp:1042
template<class FwdCont , class Func >
auto cet::for_all ( FwdCont const &  s,
Func  f 
)
inline

Definition at line 99 of file container_algorithms.h.

100 {
101  using std::cbegin;
102  using std::cend;
103  return std::for_each(cbegin(s), cend(s), f);
104 }
decltype(auto) constexpr cend(T &&obj)
ADL-aware version of std::cend.
Definition: StdUtils.h:87
decltype(auto) constexpr cbegin(T &&obj)
ADL-aware version of std::cbegin.
Definition: StdUtils.h:82
static QCString * s
Definition: config.cpp:1042
template<class FwdCont , class Func >
void cet::for_all_with_index ( FwdCont &  s,
Func  f 
)
inline

Definition at line 109 of file container_algorithms.h.

110 {
111  std::size_t i{};
112  for (auto& e : s) {
113  f(i, e);
114  ++i;
115  }
116 }
const double e
static QCString * s
Definition: config.cpp:1042
template<class FwdCont , class Func >
void cet::for_all_with_index ( FwdCont const &  s,
Func  f 
)
inline

Definition at line 120 of file container_algorithms.h.

121 {
122  std::size_t i{};
123  for (auto const& e : s) {
124  f(i, e);
125  ++i;
126  }
127 }
const double e
static QCString * s
Definition: config.cpp:1042
template<class T >
constexpr T cet::fourth ( x)

Definition at line 33 of file pow.h.

34  {
35  return pow<4u>(x);
36  }
list x
Definition: train.py:276
template<typename T >
T & cet::get_underlying ( propagate_const< T > &  iP)

Definition at line 99 of file propagate_const.h.

100  {
101  return iP.m_value;
102  }
template<typename T >
T const & cet::get_underlying ( propagate_const< T > const &  iP)

Definition at line 105 of file propagate_const.h.

106  {
107  return iP.m_value;
108  }
std::string cet::getenv ( std::string const &  name)

Definition at line 15 of file getenv.cc.

16 {
17  char const* p = std::getenv(name.c_str());
18  if (p == nullptr) {
19  throw cet::exception{"getenv"}
20  << "Can't find an environment variable named \"" << name << '\"';
21  }
22  return p;
23 }
static QCString name
Definition: declinfo.cpp:673
std::string getenv(std::string const &name)
Definition: getenv.cc:15
p
Definition: test.py:223
cet::coded_exception< error, detail::translate > exception
Definition: exception.h:33
std::string cet::getenv ( std::string const &  name,
std::nothrow_t   
)

Definition at line 26 of file getenv.cc.

27 {
28  char const* p = std::getenv(name.c_str());
29  if (p == nullptr) {
30  p = "";
31  }
32  return p;
33 }
static QCString name
Definition: declinfo.cpp:673
std::string getenv(std::string const &name)
Definition: getenv.cc:15
p
Definition: test.py:223
template<typename PTR_T >
PTR_T cet::hard_cast ( void *  src)
inline

Definition at line 19 of file hard_cast.h.

20 {
21  PTR_T dest;
22  hard_cast(src, dest);
23  return dest;
24 }
void hard_cast(void *src, PTR_T &dest)
Definition: hard_cast.h:28
template<typename PTR_T >
void cet::hard_cast ( void *  src,
PTR_T &  dest 
)
inline

Definition at line 28 of file hard_cast.h.

29 {
30  memcpy(&dest, &src, sizeof(PTR_T));
31 }
template<class T >
std::enable_if_t< std::is_arithmetic_v< T >, T > cet::hypot ( x,
y 
)
inline

Definition at line 60 of file hypot.h.

61 {
62  return checked_hypot(x, y);
63 }
std::enable_if_t< std::is_arithmetic_v< T >, T > checked_hypot(T x, T y)
Definition: hypot.h:43
list x
Definition: train.py:276
void cet::include ( std::istream &  in,
std::string result 
)

Definition at line 63 of file include.cc.

64 {
65  if (!in)
66  throw include_exception{cant_read};
67 
68  for (auto& line : getlines(in)) {
69  if (line.find(include_lit) != 0) { // ordinary line
70  result.append(line).append(1, '\n');
71  continue;
72  }
73  trim_right(line, "\t\r");
74  if (line.end()[-1] != '\"') // #include is missing trailing quote
75  throw include_exception{malformed} << line;
76 
77  std::string const fname{
78  line.substr(include_sz, line.size() - include_sz - 1)};
79  std::ifstream f{fname.c_str(), std::ios_base::in};
80  if (!f)
81  throw include_exception{cant_open} << fname;
82  include(f, result);
83  } // for
84 
85 } // include()
static QCString result
std::string string
Definition: nybbler.cc:12
std::string & trim_right(std::string &source, std::string const &t=" ")
Definition: trim.h:33
void include(std::istream &in, std::string &result)
Definition: include.cc:63
void line(double t, double *p, double &x, double &y, double &z)
QCString & append(const char *s)
Definition: qcstring.cpp:383
void cet::include ( std::istream &  in,
std::string const &  search_path_arg,
std::string result 
)

Definition at line 90 of file include.cc.

93 {
94  cet::search_path const paths{search_path_arg};
95 
96  if (!in)
97  throw include_exception(cant_read);
98 
99  for (auto const& line : getlines(in)) {
100  if (line.find(include_lit) != 0) { // ordinary line
101  result.append(line).append(1, '\n');
102  continue;
103  }
104 
105  if (line.end()[-1] != '\"') // #include is missing its trailing quote
106  throw include_exception(malformed) << line;
107 
108  std::string const fname{
109  line.substr(include_sz, line.size() - include_sz - 1)};
110 
112  std::ifstream f{fname.c_str(), std::ios_base::in};
113  if (!f)
114  throw include_exception(cant_open) << fname;
115  include(f, search_path_arg, result);
116  } else {
117  std::ifstream f{paths.find_file(fname).c_str(), std::ios_base::in};
118  if (!f) {
119  throw include_exception(cant_open)
120  << fname << "\nusing path: " << paths;
121  }
122  include(f, search_path_arg, result);
123  }
124  } // for
125 
126 } // include()
static QCString result
std::string string
Definition: nybbler.cc:12
bool is_absolute_filepath(std::string const &qualified_filename)
Definition: filesystem.cc:23
void include(std::istream &in, std::string &result)
Definition: include.cc:63
void line(double t, double *p, double &x, double &y, double &z)
QCString & append(const char *s)
Definition: qcstring.cpp:383
bool cet::is_absolute_filepath ( std::string const &  qualified_filename)

Definition at line 23 of file filesystem.cc.

24 {
25  return qualified_filename[0] == '/';
26 }
bool cet::is_double_quoted_string ( std::string const &  str)
inline

Definition at line 46 of file canonical_string.h.

47 {
48  return detail::is_quoted_string(str, '"');
49 }
bool is_quoted_string(std::string const &s, char quot)
static QCString str
bool cet::is_quoted_string ( std::string const &  str)
inline

Definition at line 52 of file canonical_string.h.

53 {
55 }
bool is_double_quoted_string(std::string const &str)
bool is_single_quoted_string(std::string const &str)
static QCString str
bool cet::is_relative_filepath ( std::string const &  qualified_filename)

Definition at line 29 of file filesystem.cc.

30 {
31  return !is_absolute_filepath(qualified_filename);
32 }
bool is_absolute_filepath(std::string const &qualified_filename)
Definition: filesystem.cc:23
bool cet::is_single_quoted_string ( std::string const &  str)
inline

Definition at line 40 of file canonical_string.h.

41 {
42  return detail::is_quoted_string(str, '\'');
43 }
bool is_quoted_string(std::string const &s, char quot)
static QCString str
void cet::loadable_libraries ( std::ostream &  os,
std::string const &  spec,
std::string const &  suffix 
)

Definition at line 30 of file loadable_libraries.cc.

33 {
34  cet::LibraryManager const lm{suffix, pattern(spec + ".*")};
35  auto const& libs = getLibraries(lm);
36 
37  std::string str{};
38  for (auto const& lib : libs) {
39  auto const& libspecs = lm.getSpecsByPath(lib);
40  if (libspecs.first.find(spec) == 0) {
41  str += libspecs.first;
42  str += '\n';
43  }
44  // Not all libraries have a long spec.
45  if (!libspecs.second.empty() && libspecs.second.find(spec) == 0) {
46  str += libspecs.second;
47  str += '\n';
48  }
49  }
50  os << str;
51 }
std::string string
Definition: nybbler.cc:12
std::string pattern
Definition: regex_t.cc:35
static QCString str
template<class FwdCont , class Datum >
auto cet::lower_bound_all ( FwdCont &  s,
Datum const &  d 
)
inline

Definition at line 209 of file container_algorithms.h.

210 {
211  using std::begin;
212  using std::end;
213  return std::lower_bound(begin(s), end(s), d);
214 }
end
while True: pbar.update(maxval-len(onlies[E][S])) #print iS, "/", len(onlies[E][S]) found = False for...
decltype(auto) constexpr begin(T &&obj)
ADL-aware version of std::begin.
Definition: StdUtils.h:72
static QCString * s
Definition: config.cpp:1042
template<class FwdCont , class Datum >
auto cet::lower_bound_all ( FwdCont const &  s,
Datum const &  d 
)
inline

Definition at line 218 of file container_algorithms.h.

219 {
220  using std::cbegin;
221  using std::cend;
222  return std::lower_bound(cbegin(s), cend(s), d);
223 }
decltype(auto) constexpr cend(T &&obj)
ADL-aware version of std::cend.
Definition: StdUtils.h:87
decltype(auto) constexpr cbegin(T &&obj)
ADL-aware version of std::cbegin.
Definition: StdUtils.h:82
static QCString * s
Definition: config.cpp:1042
template<class FwdCont , class Datum , class Pred >
auto cet::lower_bound_all ( FwdCont &  s,
Datum const &  d,
Pred  p 
)
inline

Definition at line 227 of file container_algorithms.h.

228 {
229  using std::begin;
230  using std::end;
231  return std::lower_bound(begin(s), end(s), d, p);
232 }
end
while True: pbar.update(maxval-len(onlies[E][S])) #print iS, "/", len(onlies[E][S]) found = False for...
p
Definition: test.py:223
decltype(auto) constexpr begin(T &&obj)
ADL-aware version of std::begin.
Definition: StdUtils.h:72
static QCString * s
Definition: config.cpp:1042
template<class FwdCont , class Datum , class Pred >
auto cet::lower_bound_all ( FwdCont const &  s,
Datum const &  d,
Pred  p 
)
inline

Definition at line 236 of file container_algorithms.h.

237 {
238  using std::cbegin;
239  using std::cend;
240  return std::lower_bound(cbegin(s), cend(s), d, p);
241 }
decltype(auto) constexpr cend(T &&obj)
ADL-aware version of std::cend.
Definition: StdUtils.h:87
p
Definition: test.py:223
decltype(auto) constexpr cbegin(T &&obj)
ADL-aware version of std::cbegin.
Definition: StdUtils.h:82
static QCString * s
Definition: config.cpp:1042
std::string cet::lpad ( std::string const &  pad_me,
std::string::size_type  wanted_size,
char  char_to_pad_with = ' ' 
)

Definition at line 10 of file lpad.cc.

13 {
14  if (wanted_size <= s.size())
15  return s; // already long enough
16 
17  std::string result(wanted_size - s.size(), char_to_pad_with);
18  return result.append(s);
19 
20 } // lpad()
static QCString result
std::string string
Definition: nybbler.cc:12
uint size() const
Definition: qcstring.h:201
static QCString * s
Definition: config.cpp:1042
QCString & append(const char *s)
Definition: qcstring.cpp:383
template<class E >
constexpr exempt_ptr<E> cet::make_exempt_ptr ( E )
noexcept
bool cet::operator!= ( map_vector_key const &  k1,
map_vector_key const &  k2 
)
inlinenoexcept

Definition at line 309 of file map_vector.h.

310 {
311  return k1.asInt() != k2.asInt();
312 }
bool cet::operator!= ( MD5Result const &  a,
MD5Result const &  b 
)
inline

Definition at line 44 of file MD5Digest.h.

45  {
46  return !(a == b);
47  }
const double a
static bool * b
Definition: config.cpp:1043
template<class E >
constexpr bool cet::operator!= ( exempt_ptr< E x,
exempt_ptr< E y 
)
noexcept

Definition at line 218 of file exempt_ptr.h.

219 {
220  return !operator==(x, y);
221 }
bool operator==(const QString &s1, const QString &s2)
Definition: qstring.cpp:14843
list x
Definition: train.py:276
template<class E >
constexpr bool cet::operator!= ( exempt_ptr< E x,
std::nullptr_t  y 
)
noexcept

Definition at line 232 of file exempt_ptr.h.

233 {
234  return !operator==(x, y);
235 }
bool operator==(const QString &s1, const QString &s2)
Definition: qstring.cpp:14843
list x
Definition: train.py:276
template<class E >
constexpr bool cet::operator!= ( std::nullptr_t  x,
exempt_ptr< E y 
)
noexcept

Definition at line 246 of file exempt_ptr.h.

247 {
248  return !operator==(x, y);
249 }
bool operator==(const QString &s1, const QString &s2)
Definition: qstring.cpp:14843
list x
Definition: train.py:276
template<class E , class C , class D >
bool cet::operator!= ( value_ptr< E, C, D > const &  x,
value_ptr< E, C, D > const &  y 
)

Definition at line 352 of file value_ptr.h.

353 {
354  return !operator==(x, y);
355 }
bool operator==(const QString &s1, const QString &s2)
Definition: qstring.cpp:14843
list x
Definition: train.py:276
template<class E , class C , class D >
bool cet::operator!= ( value_ptr< E, C, D > const &  x,
std::nullptr_t const &  y 
)

Definition at line 366 of file value_ptr.h.

367 {
368  return !operator==(x, y);
369 }
bool operator==(const QString &s1, const QString &s2)
Definition: qstring.cpp:14843
list x
Definition: train.py:276
template<class E , class C , class D >
bool cet::operator!= ( std::nullptr_t const &  x,
value_ptr< E, C, D > const &  y 
)

Definition at line 380 of file value_ptr.h.

381 {
382  return !operator==(x, y);
383 }
bool operator==(const QString &s1, const QString &s2)
Definition: qstring.cpp:14843
list x
Definition: train.py:276
bool cet::operator< ( map_vector_key const &  k1,
map_vector_key const &  k2 
)
inlinenoexcept

Definition at line 315 of file map_vector.h.

316 {
317  return k1.asInt() < k2.asInt();
318 }
template<class E >
constexpr bool cet::operator< ( exempt_ptr< E x,
exempt_ptr< E y 
)

Definition at line 256 of file exempt_ptr.h.

257 {
258  using CT = std::common_type_t<typename exempt_ptr<E>::pointer,
259  typename exempt_ptr<E>::pointer>;
260  return std::less<CT>{}(x.get(), y.get());
261 }
list x
Definition: train.py:276
bool cet::operator< ( MD5Result const &  a,
MD5Result const &  b 
)

Definition at line 109 of file MD5Digest.cc.

110  {
111  return std::lexicographical_compare(
112  a.bytes, a.bytes + sizeof(a.bytes), b.bytes, b.bytes + sizeof(b.bytes));
113  }
const double a
static bool * b
Definition: config.cpp:1043
template<class E , class C , class D >
bool cet::operator< ( value_ptr< E, C, D > const &  x,
value_ptr< E, C, D > const &  y 
)

Definition at line 390 of file value_ptr.h.

391 {
392  using CT = std::common_type_t<typename value_ptr<E, C, D>::pointer,
393  typename value_ptr<E, C, D>::pointer>;
394  return std::less<CT>{}(x.get(), y.get());
395 }
list x
Definition: train.py:276
std::ostream & cet::operator<< ( std::ostream &  os,
cet::map_vector_key const &  key 
)
inline

Definition at line 342 of file map_vector.h.

343 {
344  return os << key.asInt();
345 }
def key(type, name=None)
Definition: graph.py:13
ostream & cet::operator<< ( std::ostream &  os,
search_path const &  p 
)

Definition at line 171 of file search_path.cc.

172 {
173  auto const sz = path.size();
174  if (sz == 0)
175  return os;
176  os << path[0];
177  for (size_t k{1}; k != sz; ++k) {
178  os << ":" << path[k];
179  }
180  return os;
181 }
template<class T >
std::ostream & cet::operator<< ( std::ostream &  os,
maybe_ref< T > const &  item 
)
inline

Definition at line 127 of file maybe_ref.h.

128 {
129  os << &item.ref();
130  return os;
131 }
std::ostream& cet::operator<< ( std::ostream &  os,
MD5Result const &  r 
)
inline

Definition at line 50 of file MD5Digest.h.

51  {
52  os << r.toString();
53  return os;
54  }
template<class charT , class traits >
std::basic_ostream< charT, traits > & cet::operator<< ( std::basic_ostream< charT, traits > &  os,
simple_stats const &  stats 
)

Definition at line 95 of file simple_stats.h.

97 {
98  return os << "( " << stats.size() << ", " << stats.mean() << " +/- "
99  << stats.err_mean() << ", " << stats.rms() << " +/- "
100  << stats.err_rms() << ", " << stats.min() << " " << stats.max()
101  << " )";
102 }
bool cet::operator<= ( map_vector_key const &  k1,
map_vector_key const &  k2 
)
inlinenoexcept

Definition at line 327 of file map_vector.h.

328 {
329  return k1.asInt() <= k2.asInt();
330 }
template<class E >
constexpr bool cet::operator<= ( exempt_ptr< E x,
exempt_ptr< E y 
)

Definition at line 272 of file exempt_ptr.h.

273 {
274  return !(y < x);
275 }
list x
Definition: train.py:276
template<class E , class C , class D >
bool cet::operator<= ( value_ptr< E, C, D > const &  x,
value_ptr< E, C, D > const &  y 
)

Definition at line 406 of file value_ptr.h.

407 {
408  return !(y < x);
409 }
list x
Definition: train.py:276
bool cet::operator== ( map_vector_key const &  k1,
map_vector_key const &  k2 
)
inlinenoexcept

Definition at line 303 of file map_vector.h.

304 {
305  return k1.asInt() == k2.asInt();
306 }
template<class T >
bool cet::operator== ( maybe_ref< T > const &  left,
maybe_ref< T > const &  right 
)
inline

Definition at line 120 of file maybe_ref.h.

121 {
122  return (&left.ref()) == (&right.ref());
123 }
template<class E >
constexpr bool cet::operator== ( exempt_ptr< E x,
exempt_ptr< E y 
)
noexcept

Definition at line 211 of file exempt_ptr.h.

212 {
213  return x.get() == y.get();
214 }
list x
Definition: train.py:276
template<class E >
constexpr bool cet::operator== ( exempt_ptr< E x,
std::nullptr_t  y 
)
noexcept

Definition at line 225 of file exempt_ptr.h.

226 {
227  return x.get() == y;
228 }
list x
Definition: train.py:276
template<class E >
constexpr bool cet::operator== ( std::nullptr_t  x,
exempt_ptr< E y 
)
noexcept

Definition at line 239 of file exempt_ptr.h.

240 {
241  return x == y.get();
242 }
list x
Definition: train.py:276
template<class E , class C , class D >
bool cet::operator== ( value_ptr< E, C, D > const &  x,
value_ptr< E, C, D > const &  y 
)

Definition at line 345 of file value_ptr.h.

346 {
347  return x.get() == y.get();
348 }
list x
Definition: train.py:276
template<class E , class C , class D >
bool cet::operator== ( value_ptr< E, C, D > const &  x,
std::nullptr_t const &  y 
)

Definition at line 359 of file value_ptr.h.

360 {
361  return x.get() == y;
362 }
list x
Definition: train.py:276
bool cet::operator== ( MD5Result const &  a,
MD5Result const &  b 
)

Definition at line 103 of file MD5Digest.cc.

104  {
105  return std::equal(a.bytes, a.bytes + sizeof(a.bytes), b.bytes);
106  }
const double a
static bool * b
Definition: config.cpp:1043
template<class E , class C , class D >
bool cet::operator== ( std::nullptr_t const &  x,
value_ptr< E, C, D > const &  y 
)

Definition at line 373 of file value_ptr.h.

374 {
375  return x == y.get();
376 }
list x
Definition: train.py:276
bool cet::operator> ( map_vector_key const &  k1,
map_vector_key const &  k2 
)
inlinenoexcept

Definition at line 321 of file map_vector.h.

322 {
323  return k1.asInt() > k2.asInt();
324 }
template<class E >
constexpr bool cet::operator> ( exempt_ptr< E x,
exempt_ptr< E y 
)

Definition at line 265 of file exempt_ptr.h.

266 {
267  return y < x;
268 }
list x
Definition: train.py:276
template<class E , class C , class D >
bool cet::operator> ( value_ptr< E, C, D > const &  x,
value_ptr< E, C, D > const &  y 
)

Definition at line 399 of file value_ptr.h.

400 {
401  return y < x;
402 }
list x
Definition: train.py:276
bool cet::operator>= ( map_vector_key const &  k1,
map_vector_key const &  k2 
)
inlinenoexcept

Definition at line 333 of file map_vector.h.

334 {
335  return k1.asInt() >= k2.asInt();
336 }
template<class E >
constexpr bool cet::operator>= ( exempt_ptr< E x,
exempt_ptr< E y 
)

Definition at line 279 of file exempt_ptr.h.

280 {
281  return !(x < y);
282 }
list x
Definition: train.py:276
template<class E , class C , class D >
bool cet::operator>= ( value_ptr< E, C, D > const &  x,
value_ptr< E, C, D > const &  y 
)

Definition at line 413 of file value_ptr.h.

414 {
415  return !(x < y);
416 }
list x
Definition: train.py:276
constexpr char const * cet::os_libpath ( )
inline

Definition at line 12 of file os_libpath.h.

13 {
14 #if __linux__
15  return "LD_LIBRARY_PATH";
16 #elif __APPLE__ && __MACH__
17  return "DYLD_LIBRARY_PATH";
18 #else
19 #error Unknown operating system
20 #endif
21 }
boost::program_options::variables_map cet::parsed_program_options ( int  argc,
char **  argv,
boost::program_options::options_description const &  desc,
boost::program_options::positional_options_description const &  pos = {} 
)
constexpr char const * cet::plugin_libpath ( )
inline

Definition at line 12 of file plugin_libpath.h.

13 {
14  return "CET_PLUGIN_PATH";
15 }
template<unsigned N, class T >
constexpr T cet::pow ( x)

Definition at line 72 of file pow.h.

73 {
74  return detail::pow<N, T>()(x);
75 }
list x
Definition: train.py:276
bool cet::replace_all ( std::string in,
std::string const &  from,
std::string const &  to 
)

Replace all occurrences of from in string with to.

Returns
true if anything has been done to in.
Parameters
[in,out]inThe string to be manipulated.
[in]fromThe string to be replaced.
[in]toThe replacement of from.

Definition at line 4 of file replace_all.cc.

7 {
8  bool result = false;
9  auto const rep_length = from.size();
10  auto const skip_length = to.size();
11  std::string::size_type pos = 0;
12  while ((pos = in.find(from, pos)) != std::string::npos) {
13  result = true;
14  in.replace(pos, rep_length, to);
15  pos += skip_length;
16  }
17  return result;
18 }
static QCString result
uint size() const
Definition: qcstring.h:201
std::string cet::rpad ( std::string const &  pad_me,
std::string::size_type  wanted_size,
char  char_to_pad_with = ' ' 
)

Definition at line 10 of file rpad.cc.

13 {
14  if (wanted_size <= s.size())
15  return s; // already long enough
16 
18  return result.append(wanted_size - s.size(), char_to_pad_with);
19 
20 } // rpad()
static QCString result
std::string string
Definition: nybbler.cc:12
uint size() const
Definition: qcstring.h:201
static QCString * s
Definition: config.cpp:1042
QCString & append(const char *s)
Definition: qcstring.cpp:383
template<class FwdCont , class Datum >
bool cet::search_all ( FwdCont const &  s,
Datum const &  d 
)
inline

Definition at line 189 of file container_algorithms.h.

190 {
191  using std::cbegin;
192  using std::cend;
193  return std::find(cbegin(s), cend(s), d) != s.end();
194 }
decltype(auto) constexpr cend(T &&obj)
ADL-aware version of std::cend.
Definition: StdUtils.h:87
decltype(auto) constexpr cbegin(T &&obj)
ADL-aware version of std::cbegin.
Definition: StdUtils.h:82
static QCString * s
Definition: config.cpp:1042
ostream_handle cet::select_stream ( std::string const &  filename,
std::ostream &  default_os 
)
inline

Definition at line 89 of file ostream_handle.h.

90  {
91  return empty(filename) ? ostream_handle{default_os} :
92  ostream_handle{filename};
93  }
string filename
Definition: train.py:213
decltype(auto) constexpr empty(T &&obj)
ADL-aware version of std::empty.
Definition: StdUtils.h:97
void cet::set_to_default ( MD5Result val)

Definition at line 22 of file MD5Digest.cc.

23  {
24  val.bytes[0] = 0xd4;
25  val.bytes[1] = 0x1d;
26  val.bytes[2] = 0x8c;
27  val.bytes[3] = 0xd9;
28  val.bytes[4] = 0x8f;
29  val.bytes[5] = 0x00;
30  val.bytes[6] = 0xb2;
31  val.bytes[7] = 0x04;
32  val.bytes[8] = 0xe9;
33  val.bytes[9] = 0x80;
34  val.bytes[10] = 0x09;
35  val.bytes[11] = 0x98;
36  val.bytes[12] = 0xec;
37  val.bytes[13] = 0xf8;
38  val.bytes[14] = 0x42;
39  val.bytes[15] = 0x7e;
40  }
std::string cet::shlib_prefix ( )
std::string cet::shlib_suffix ( )
template<class RandCont >
void cet::sort_all ( RandCont &  s)
inline

Definition at line 246 of file container_algorithms.h.

247 {
248  using std::begin;
249  using std::end;
250  std::sort(begin(s), end(s));
251 }
end
while True: pbar.update(maxval-len(onlies[E][S])) #print iS, "/", len(onlies[E][S]) found = False for...
decltype(auto) constexpr begin(T &&obj)
ADL-aware version of std::begin.
Definition: StdUtils.h:72
static QCString * s
Definition: config.cpp:1042
template<class RandCont , class Pred >
void cet::sort_all ( RandCont &  s,
Pred  p 
)
inline

Definition at line 255 of file container_algorithms.h.

256 {
257  using std::begin;
258  using std::end;
259  std::sort(begin(s), end(s), p);
260 }
end
while True: pbar.update(maxval-len(onlies[E][S])) #print iS, "/", len(onlies[E][S]) found = False for...
p
Definition: test.py:223
decltype(auto) constexpr begin(T &&obj)
ADL-aware version of std::begin.
Definition: StdUtils.h:72
static QCString * s
Definition: config.cpp:1042
template<class OutIter >
void cet::split ( std::string const &  s,
char  c,
OutIter  dest 
)

Definition at line 35 of file split.h.

36 {
37  split_if(s, [c](char x) { return x == c; }, dest);
38 }
void split_if(std::string const &s, Pred is_sep, OutIter dest)
Definition: split.h:44
list x
Definition: train.py:276
static QCString * s
Definition: config.cpp:1042
std::vector< std::string > cet::split_by_regex ( std::string const &  str,
std::regex const &  reDelimSet 
)

Definition at line 8 of file split_by_regex.cc.

9  {
10  std::vector<std::string> tokens;
11  std::copy(
12  std::sregex_token_iterator(str.begin(), str.end(), reDelimSet, -1),
13  std::sregex_token_iterator{},
14  std::back_inserter(tokens));
15  return tokens;
16  }
T copy(T const &v)
static QCString str
std::vector< std::string > cet::split_by_regex ( std::string const &  str,
std::string const &  delimSet 
)

Definition at line 19 of file split_by_regex.cc.

20  {
21  std::regex const tmpRegex{delimSet};
22  return split_by_regex(str, tmpRegex);
23  }
std::vector< std::string > split_by_regex(std::string const &str, std::string const &delimSet)
static QCString str
template<class Pred , class OutIter >
void cet::split_if ( std::string const &  s,
Pred  is_sep,
OutIter  dest 
)

Definition at line 44 of file split.h.

45 {
46  auto const e = s.cend();
47  auto const is_not_sep = [is_sep](auto const c) { return !is_sep(c); };
48  auto const new_boi = [is_not_sep, &e](auto const si) {
49  return std::find_if(si, e, is_not_sep);
50  };
51  // invariant: we've found all items in [b..boi)
52  // e is an arbitrary value to use as the initializer
53  for (typename std::remove_const<decltype(e)>::type boi = new_boi(s.cbegin()),
54  eoi = e;
55  boi != e;
56  boi = new_boi(eoi)) // advance to next non-separator
57  {
58  // find end of current item:
59  eoi = std::find_if(boi, e, is_sep);
60 
61  // copy the item formed from characters in [boi..eoi):
62  *dest = std::string(boi, eoi);
63  ++dest;
64  } // for
65 
66 } // split_if<>()
std::string string
Definition: nybbler.cc:12
const double e
static QCString * s
Definition: config.cpp:1042
void cet::split_path ( std::string const &  path,
std::vector< std::string > &  components 
)

Definition at line 13 of file split_path.cc.

14 {
15  if (path.empty())
16  components.clear();
17  else
18  boost::algorithm::split(components, path, boost::algorithm::is_any_of(":"));
19 }
void split(std::string const &s, char c, OutIter dest)
Definition: split.h:35
template<class T >
constexpr T cet::square ( x)

Definition at line 21 of file pow.h.

22  {
23  return pow<2u>(x);
24  }
list x
Definition: train.py:276
template<class RandCont >
void cet::stable_sort_all ( RandCont &  s)
inline

Definition at line 265 of file container_algorithms.h.

266 {
267  using std::begin;
268  using std::end;
269  std::stable_sort(begin(s), end(s));
270 }
end
while True: pbar.update(maxval-len(onlies[E][S])) #print iS, "/", len(onlies[E][S]) found = False for...
decltype(auto) constexpr begin(T &&obj)
ADL-aware version of std::begin.
Definition: StdUtils.h:72
static QCString * s
Definition: config.cpp:1042
template<class RandCont , class Pred >
void cet::stable_sort_all ( RandCont &  s,
Pred  p 
)
inline

Definition at line 274 of file container_algorithms.h.

275 {
276  using std::begin;
277  using std::end;
278  std::stable_sort(begin(s), end(s), p);
279 }
end
while True: pbar.update(maxval-len(onlies[E][S])) #print iS, "/", len(onlies[E][S]) found = False for...
p
Definition: test.py:223
decltype(auto) constexpr begin(T &&obj)
ADL-aware version of std::begin.
Definition: StdUtils.h:72
static QCString * s
Definition: config.cpp:1042
template<class T >
constexpr T cet::sum_of_squares ( x,
y 
)

Definition at line 139 of file pow.h.

140 {
141  return square(x) + square(y);
142 }
constexpr T square(T x)
Definition: pow.h:21
list x
Definition: train.py:276
template<class T >
constexpr T cet::sum_of_squares ( x,
y,
z 
)

Definition at line 146 of file pow.h.

147 {
148  return square(x) + square(y) + square(z);
149 }
constexpr T square(T x)
Definition: pow.h:21
list x
Definition: train.py:276
template<class T >
void cet::swap ( maybe_ref< T > &  r1,
maybe_ref< T > &  r2 
)
inline

Definition at line 113 of file maybe_ref.h.

114 {
115  r1.swap(r2);
116 }
template<class E >
void cet::swap ( exempt_ptr< E > &  x,
exempt_ptr< E > &  y 
)
inlinenoexcept

Definition at line 191 of file exempt_ptr.h.

192 {
193  x.swap(y);
194 }
list x
Definition: train.py:276
template<class E , class C , class D >
void cet::swap ( value_ptr< E, C, D > &  x,
value_ptr< E, C, D > &  y 
)
noexcept

Definition at line 335 of file value_ptr.h.

336 {
337  x.swap(y);
338 }
list x
Definition: train.py:276
template<class Container , class OutputIt , class UnaryOp >
auto cet::transform_all ( Container &  in,
OutputIt  out,
UnaryOp  unary_op 
)
inline

Definition at line 284 of file container_algorithms.h.

285 {
286  using std::begin;
287  using std::end;
288  return std::transform(begin(in), end(in), out, unary_op);
289 }
end
while True: pbar.update(maxval-len(onlies[E][S])) #print iS, "/", len(onlies[E][S]) found = False for...
decltype(auto) constexpr begin(T &&obj)
ADL-aware version of std::begin.
Definition: StdUtils.h:72
template<class Container , class OutputIt , class UnaryOp >
auto cet::transform_all ( Container const &  in,
OutputIt  out,
UnaryOp  unary_op 
)
inline

Definition at line 293 of file container_algorithms.h.

294 {
295  using std::cbegin;
296  using std::cend;
297  return std::transform(cbegin(in), cend(in), out, unary_op);
298 }
decltype(auto) constexpr cend(T &&obj)
ADL-aware version of std::cend.
Definition: StdUtils.h:87
decltype(auto) constexpr cbegin(T &&obj)
ADL-aware version of std::cbegin.
Definition: StdUtils.h:82
template<class Container1 , class Container2 , class OutputIt , class BinaryOp >
auto cet::transform_all ( Container1 &  in1,
Container2 &  in2,
OutputIt  out,
BinaryOp  binary_op 
)
inline

Definition at line 302 of file container_algorithms.h.

306 {
307  using std::begin;
308  using std::end;
309  return std::transform(begin(in1), end(in1), begin(in2), out, binary_op);
310 }
end
while True: pbar.update(maxval-len(onlies[E][S])) #print iS, "/", len(onlies[E][S]) found = False for...
decltype(auto) constexpr begin(T &&obj)
ADL-aware version of std::begin.
Definition: StdUtils.h:72
template<class Container1 , class Container2 , class OutputIt , class BinaryOp >
auto cet::transform_all ( Container1 const &  in1,
Container2 const &  in2,
OutputIt  out,
BinaryOp  binary_op 
)
inline

Definition at line 314 of file container_algorithms.h.

318 {
319  using std::cbegin;
320  using std::cend;
321  return std::transform(cbegin(in1), cend(in1), cbegin(in2), out, binary_op);
322 }
decltype(auto) constexpr cend(T &&obj)
ADL-aware version of std::cend.
Definition: StdUtils.h:87
decltype(auto) constexpr cbegin(T &&obj)
ADL-aware version of std::cbegin.
Definition: StdUtils.h:82
std::string & cet::trim ( std::string source,
std::string const &  t = " " 
)
inline

Definition at line 45 of file trim.h.

46 {
47  return trim_right(source, t), trim_left(source, t);
48 }
std::string & trim_right(std::string &source, std::string const &t=" ")
Definition: trim.h:33
std::string & trim_left(std::string &source, std::string const &t=" ")
Definition: trim.h:39
std::string cet::trim_copy ( std::string  source,
std::string const &  t = " " 
)
inline

Definition at line 66 of file trim.h.

67 {
68  return trim(source, t);
69 }
static std::string trim(const std::string &str, const std::string &whitespace=" \t")
Definition: doxyindexer.cpp:47
std::string & cet::trim_left ( std::string source,
std::string const &  t = " " 
)
inline

Definition at line 39 of file trim.h.

40 {
41  return source.erase(0, source.find_first_not_of(t));
42 }
std::string cet::trim_left_copy ( std::string  source,
std::string const &  t = " " 
)
inline

Definition at line 60 of file trim.h.

61 {
62  return trim_left(source, t);
63 }
std::string & trim_left(std::string &source, std::string const &t=" ")
Definition: trim.h:39
std::string & cet::trim_right ( std::string source,
std::string const &  t = " " 
)
inline

Definition at line 33 of file trim.h.

34 {
35  return source.erase(1 + source.find_last_not_of(t));
36 }
std::string cet::trim_right_copy ( std::string  source,
std::string const &  t = " " 
)
inline

Definition at line 54 of file trim.h.

55 {
56  return trim_right(source, t);
57 }
std::string & trim_right(std::string &source, std::string const &t=" ")
Definition: trim.h:33
template<class T >
std::enable_if_t< std::is_arithmetic_v< T >, T > cet::unchecked_hypot ( x,
y 
)
inline

Definition at line 33 of file hypot.h.

34 {
35  return std::hypot(x, y);
36 }
std::enable_if_t< std::is_arithmetic_v< T >, T > hypot(T x, T y)
Definition: hypot.h:60
list x
Definition: train.py:276
std::string cet::unescape ( std::string const &  str)

Definition at line 50 of file canonical_string.cc.

51 {
53  for (std::string::const_iterator it = str.begin(), e = str.end(); it != e;
54  ++it) {
55  char ch = *it;
56  if (ch == '\\' && it != e - 1) {
57  switch (*++it) {
58  case '\"':
59  ch = '\"';
60  break;
61  case '\'':
62  ch = '\'';
63  break;
64  case '\\':
65  ch = '\\';
66  break;
67  case 'n':
68  ch = '\n';
69  break;
70  case 't':
71  ch = '\t';
72  break;
73  default:
74  throw cet::exception("unknown escape: \\") << *it;
75  }
76  }
77  result.append(1, ch);
78  }
79  return result;
80 } // unescape()
static QCString result
std::string string
Definition: nybbler.cc:12
intermediate_table::const_iterator const_iterator
const double e
static QCString str
cet::coded_exception< error, detail::translate > exception
Definition: exception.h:33

Variable Documentation

template<class U >
constexpr std::size_t cet::bit_size_v = bit_size<U>::value

Definition at line 26 of file bit_manipulation.h.

cet::path_tag_t const cet::path_tag

Definition at line 60 of file search_path.cc.

template<typename T >
std::string const& cet::PluginTypeDeducer_v = PluginTypeDeducer<T>::value

Definition at line 49 of file PluginTypeDeducer.h.