PSCF v1.3
|
Class to modify selected Records in a file of records. More...
Public Member Functions | |
__init__ (self) | |
Constructor. | |
setFilter (self, filter, field=0) | |
Set filter string. | |
setNew (self, new, field) | |
Set new string. | |
setIsTest (self, isTest) | |
Set isTest flag, to decide whether to perform a dry run. | |
editFile (self, filename) | |
Open and edit the specified file of records. |
Class to modify selected Records in a file of records.
The editFile function searches for records in which one field matches a regular expression, and resets the value of another.
pscfpp.text.RecordEditor.__init__ | ( | self | ) |
pscfpp.text.RecordEditor.setFilter | ( | self, | |
filter, | |||
field = 0 ) |
pscfpp.text.RecordEditor.setNew | ( | self, | |
new, | |||
field ) |
pscfpp.text.RecordEditor.setIsTest | ( | self, | |
isTest ) |
Set isTest flag, to decide whether to perform a dry run.
isTest | if true, perform a dry run (no modificatin) |
Definition at line 186 of file text.py.
References pscfpp.make.MakeMaker.isTest, and isTest.
pscfpp.text.RecordEditor.editFile | ( | self, | |
filename ) |
Open and edit the specified file of records.
filename | name of file |
Definition at line 194 of file text.py.
References dataField, filter, filterField, isReady, pscfpp.make.MakeMaker.isTest, isTest, and new.