PCART  v1.4
Automated Repair of Python API Parameter Compatibility Issues
Public Member Functions | List of all members
RegexMatch Class Reference

Regular expression match class 正则表达式匹配类 More...

Public Member Functions

def __init__ (self, code_text, pattern)
 The constructor 构造函数 More...
 
def get_result (self)
 Return the match result 返回匹配结果 More...
 
def regex_match (self)
 Perform the regular expression match 执行正则表达式匹配 More...
 

Detailed Description

Regular expression match class 正则表达式匹配类

Match a given pattern from code text

Definition at line 26 of file getDef.py.

Constructor & Destructor Documentation

◆ __init__()

def __init__ (   self,
  code_text,
  pattern 
)

The constructor 构造函数

Parameters
code_textSource code text to search
patternRegular expression pattern

Definition at line 32 of file getDef.py.

Member Function Documentation

◆ get_result()

def get_result (   self)

Return the match result 返回匹配结果

Returns
List of regex match results

Definition at line 40 of file getDef.py.

◆ regex_match()

def regex_match (   self)

Perform the regular expression match 执行正则表达式匹配

Returns
1 if a match is found, otherwise 0

Definition at line 46 of file getDef.py.


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