PSCF v1.1
|
Class to search for text in a file. More...
Public Member Functions | |
def | __init__ (self) |
Constructor. More... | |
def | addFilter (self, filter) |
Add a regular expression string to the list. More... | |
def | clearResults (self) |
Clear results list (but not filters) More... | |
def | grep (self, filename) |
Search for lines in the file that match any filter. More... | |
Class to search for text in a file.
Attributes:
def pscfpp.text.Grep.__init__ | ( | self | ) |
Constructor.
Definition at line 288 of file text.py.
References pscfpp.text.Grep.filters, pscfpp.text.Grep.nFilter, and pscfpp.text.Grep.results.
def pscfpp.text.Grep.addFilter | ( | self, | |
filter | |||
) |
Add a regular expression string to the list.
filter | regular expression string |
Definition at line 298 of file text.py.
References pscfpp.text.Grep.filters, pscfpp.text.Grep.nFilter, and pscfpp.text.Grep.results.
def pscfpp.text.Grep.clearResults | ( | self | ) |
Clear results list (but not filters)
Definition at line 306 of file text.py.
References pscfpp.text.Grep.nFilter, and pscfpp.text.Grep.results.
def pscfpp.text.Grep.grep | ( | self, | |
filename | |||
) |
Search for lines in the file that match any filter.
filename | name of file to search |
Definition at line 315 of file text.py.
References pscfpp.text.Grep.filters, pscfpp.text.Grep.nFilter, and pscfpp.text.Grep.results.