casacore
Public Member Functions | Private Attributes | List of all members

More...

#include <ExprNodeRep.h>

Public Member Functions

 TaqlRegex (const Regex &regex)
 Construct from a regex. More...
 
 TaqlRegex (const StringDistance &dist)
 Construct from a StringDistance. More...
 
Bool match (const String &str) const
 Does the regex or maximum string distance match? More...
 
const Regexregex () const
 Return the regular expression. More...
 

Private Attributes

Regex itsRegex
 
StringDistance itsDist
 

Detailed Description

Class to handle a Regex or StringDistance.

Intended use:

Internal

Review Status

Reviewed By:
UNKNOWN
Date Reviewed:
before2004/08/25

Prerequisite

Synopsis

A StringDistance (Levensthein distance) in TaQL is given in the same way as a Regex. This class is needed to have a single object in the parse tree objects containing them (in class TableExprNodeConstRegex).

Definition at line 81 of file ExprNodeRep.h.

Constructor & Destructor Documentation

◆ TaqlRegex() [1/2]

casacore::TaqlRegex::TaqlRegex ( const Regex regex)
inlineexplicit

Construct from a regex.

Definition at line 85 of file ExprNodeRep.h.

◆ TaqlRegex() [2/2]

casacore::TaqlRegex::TaqlRegex ( const StringDistance dist)
inlineexplicit

Construct from a StringDistance.

Definition at line 90 of file ExprNodeRep.h.

Member Function Documentation

◆ match()

Bool casacore::TaqlRegex::match ( const String str) const
inline

Does the regex or maximum string distance match?

Definition at line 95 of file ExprNodeRep.h.

References casacore::String::empty(), itsDist, itsRegex, casacore::StringDistance::match(), casacore::String::matches(), and casacore::Regex::regexp().

◆ regex()

const Regex& casacore::TaqlRegex::regex ( ) const
inline

Return the regular expression.

Definition at line 101 of file ExprNodeRep.h.

References itsRegex.

Member Data Documentation

◆ itsDist

StringDistance casacore::TaqlRegex::itsDist
private

Definition at line 106 of file ExprNodeRep.h.

Referenced by match().

◆ itsRegex

Regex casacore::TaqlRegex::itsRegex
private

Definition at line 105 of file ExprNodeRep.h.

Referenced by match(), and regex().


The documentation for this class was generated from the following file: