The Gaudi Framework  v41r0 (bdbe7744)
Loading...
Searching...
No Matches
Gaudi::Utils::RegEx::matchList Class Reference

#include </builds/gaudi/Gaudi/GaudiUtils/include/GaudiUtils/RegEx.h>

Collaboration diagram for Gaudi::Utils::RegEx::matchList:

Public Member Functions

template<typename C>
 matchList (const C &c)
bool Or (const std::string &test) const
bool And (const std::string &test) const

Private Attributes

std::vector< boost::regex > m_regs

Detailed Description

Definition at line 33 of file RegEx.h.

Constructor & Destructor Documentation

◆ matchList()

template<typename C>
Gaudi::Utils::RegEx::matchList::matchList ( const C & c)
inline

Definition at line 38 of file RegEx.h.

38 {
39 m_regs.reserve( c.size() );
40 std::transform( std::begin( c ), std::end( c ), std::back_inserter( m_regs ),
41 []( typename C::const_reference i ) { return boost::regex{ i }; } );
42 }
std::vector< boost::regex > m_regs
Definition RegEx.h:34

Member Function Documentation

◆ And()

bool Gaudi::Utils::RegEx::matchList::And ( const std::string & test) const
inline

Definition at line 48 of file RegEx.h.

48 {
49 return std::all_of( std::begin( m_regs ), std::end( m_regs ),
50 [&]( const boost::regex& r ) { return boost::regex_match( test, r ); } );
51 }

◆ Or()

bool Gaudi::Utils::RegEx::matchList::Or ( const std::string & test) const
inline

Definition at line 44 of file RegEx.h.

44 {
45 return std::any_of( std::begin( m_regs ), std::end( m_regs ),
46 [&]( const boost::regex& r ) { return boost::regex_match( test, r ); } );
47 }

Member Data Documentation

◆ m_regs

std::vector<boost::regex> Gaudi::Utils::RegEx::matchList::m_regs
private

Definition at line 34 of file RegEx.h.


The documentation for this class was generated from the following file:
  • GaudiUtils/include/GaudiUtils/RegEx.h