CloseFile |
|
Close the open file with the file number provided | |||||
CopyFile |
|
Copy the specified filename to the target filename. | |||||
CopyMatchingFiles |
|
Copy multiple files/sub-directories, based on matching the provided pattern, from one directory to another. | |||||
CreateDirectory |
|
Create the directory for the provided directory pathname | |||||
CreateFile |
|
Open a new file with the filename, mode and access provided.TID Note: Three ways to create a file: Mode=Input, Access=ReadMode=Output, Access=WriteMode=Append, Access=Write | |||||
DeleteDirectory |
|
Delete the directory for the provided directory pathname | |||||
DeleteDirectoryContents |
|
Delete the contents (files and sub-directories) of a provided directory and optionally, the directory itself. | |||||
DeleteFile |
|
Delete the file for the file name provided | |||||
FilterImage |
|
Filter out specific parts of an image. | |||||
FilterTextFile |
|
Filter a text file based on the given parameters. | |||||
FindSqaFile |
|
Find the file for the SQA relative path and file name provided. If a full file path is provided the file will be located using the full file path and name. | |||||
GetFileDateTime |
|
Determine the date and time the file created/last changed/last accessed for file name provided and assign it to a DDV variable. | |||||
GetFileProtections |
|
Save the file attributes for the file name to the variable provided. | |||||
GetFiles |
|
Search the directory provided for files according to possible attribute and write the list of filenames found into the output file. | |||||
GetFileSize |
|
Determine the file size for file name provided and assign it to a DDV variable. | |||||
GetINIFileValue |
|
Get value from INI file. | |||||
GetStringCountInFile |
|
Count the number of occurrences of a target string in a File. | |||||
GetSubstringsInFile |
|
Extract dynamic substrings from a file using regular expressions. | |||||
GetTextFromImage |
|
Incorporate OCR technology to detect the text in an image file and save the text to a variable. | |||||
IfExistDir |
|
If the specified directory exists, then execute the following driver command. | |||||
IfExistFile |
|
If the specified file exists, then execute the following driver command. | |||||
IsEndOfFile |
|
If the specified file is at the end of file, a 'variable' gets true assigned, otherwise it gets false | |||||
OpenFile |
|
Open an existing file with the filename, mode and access provided.TID Note: Multiple ways to open a file: Mode=Input, Access=ReadMode=Output, Access=WriteMode=Append, Access=WriteMode=AppendRaw, Access=Write | |||||
OpenUTF8File |
|
Open an existing UTF-8 file with the filename, mode and access provided.TID Note: Multiple ways to open a file: Mode=Input, Access=ReadMode=Output, Access=WriteMode=Append, Access=WriteMode=AppendRaw, Access=Write | |||||
PrintToFile |
|
Write output to a sequential file already opened for writing. | |||||
ReadFileChars |
|
Read the number of characters from the file defined by file number and assign a string containing the characters read to a DDV variable. | |||||
ReadFileLine |
|
Read a line from the file defined by file number and assign a string containing the line read to a DDV variable. | |||||
ReadFileString |
|
Read a comma-separated value from a file and store it in a DDVariable. | |||||
RenameFile |
|
Rename the file from the old file name to the new filename | |||||
SaveTextFromImage |
|
Incorporate OCR technology to detect the text in an image file and save the text to a text file. | |||||
SetFileProtections |
|
Change the file attribute for the file name provided to the value of the new file protection provided. | |||||
WriteFileChars |
|
Write the specified number of characters to a file already opened for writing. |
RC | RJ | TID | SDC | SE2 |
RC | RJ | TID | SDC | SE2 |
If the filenames provided are not full absolute paths then we will attempt to deduce a full Project-relative or Datapool\Test-relative path from the relative path provided. If the relative path already contains path separators (ex: "\subpath\filename.ext") then we attempt to deduce a fullpath relative to the SAFS Project. If no path separators exist (ex: "filename.txt") then we attempt to deduce a fullpath relative to the project's Datapool\Test directory. We do not actually attempt to see if the directories or files exists before executing the command.
RJ | TID | SDC | SE2 |
FilterMode | Comments |
WILDCARD | Default. Includes support for * and ? wildcard characters |
REGEXP | Includes support for Regular Expression pattern matching |
RC | RJ | TID | SDC | SE2 |
RC | RJ | TID | SDC | SE2 |
RC | RJ | TID | SDC | SE2 |
RJ | TID | SDC | SE2 |
RC | RJ | TID | SDC | SE2 |
RJ | TID | SDC | SE2 |
Specific Notes:
This command requires that Java Advanced Imaging (JAI) be installed
on the test machine.
Note: Java-based engines like RFT should support using either a comma (,) or a semi-colon (;) as the Coords item separator. Also, there should be a space char separating each set of rectangle coordinates.
RC | RJ | TID | SDC | SE2 |
This command can be used to process a text file based on the provided parameters, such as replacing text in a file that matches a specific pattern. This command is experimental. command name/parameters are subject to change without notice.
FILTERMODE | FIELDS | COMMENTS |
Default(empty) | (None) | Default filtering. File is unchanged. |
"RegExp" | 5 - PATTERN (Required) | REGEXP pattern to match for filtering. All occurrences of text in a file that match regular expression PATTERN will be removed and replaced with the REPLACE string (if any). |
6 - REPLACE (Optional) | Default value for REPLACE is "" (empty string). This tells REGEXP to remove matching PATTERN text from the file. Specifying a REPLACE string will remove matching PATTERN text from the file and insert the REPLACE string in its place. | |
7 - CASE (Optional) | CASE specifies the case-sensitivity used when searching for matching
text in the file. Use "CaseInsensitive" to ignore case when searching. If not specified the default implementation is a CaseSensitive compare. |
RC | TID | SDC |
RC | RJ | TID | SDC | SE2 |
RJ | TID | SDC | SE2 |
0 - Normal file
1 - Read Only file
2 - Hidden file
4 - System file (Windows OS Only)
16 - Directory
32 - Archive file (Windows OS: attrib with 'A'; Other OS: file suffix is .jar, .tar, .rar, .gz etc.)
RC | RJ | TID | SDC | SE2 |
Search directory using following file attributes. Default value is 0 - normal file.
0 - Normal file, returns only files without other attributes set
1 - Read Only file
2 - Hidden file
4 - System file (Window OS Only)
8 - Volume Label (Exclusive, if set, no other attribute counts.)
16 - Directory
32 - Archive file (Windows OS: attrib with 'A'; Other OS: file suffix is .jar, .tar, .rar, .gz etc.)
The values in the table can be added together to select multiple attributes.
For example, to list hidden and system files in addition to normal files set FileAttributes to 6 (6=2+4).
If FileAttributes is set to 8 (Volume Label), then returns the volume label of the drive specified in the pathname$, or of the current drive if drive is not explicitly specified.
If volume label attribute is set, all other attributes are ignored.
Directory C:/Test is searched for files with normal and directory attributes set and list of files found is written to file D:/Test/filelist.txt
RC | RJ | TID | SDC | SE2 |
RJ | TID | SDC | SE2 |
RJ | TID | SDC | SE2 |
RJ | TID | SDC | SE2 |
This command opens the file, reads it line by line, and sets DDVariables (based on rootname) for each occurrence of string identified by the substring formed between regexstart and regexstop (1 match per line, currently). regexstart and regexstop must both be valid, non-empty strings or no matching substrings will be found.
Fully qualified filename is opened and read line by line. Each line is parsed, searching for a match to the substring formed between regexstart and regexstop.
When a match is found, the string between regexstart and regexstop is saved in a newly created DDVariable based on rootname and the number of occurrences. There will be one DDVariable for each match found and a unique "Count" variable specifying how many matches were found.
The rootname is used as a base to build the DDVariable names which contain the located substring(s) and Count. For example, if rootname is "Chart" and two substring matches are found, then 2 DDVariables are created to store those substrings and another is created to store the count of matches:
RJ | SDC | TID | SE2 |
TOCR 2.0.4 and GOCR 0.48 are the latest release. They are available in SAFS and only support English. Both two OCR owners claim to support more languages in next release. Chinese, Japanese, and Korean are going to be supported in TOCR's next release 3.00.
The extension of the image file can be .bmp, .jpg, .gif, .tif, .png or .pnm.
Note: Seems TOCR performs a bit better than GOCR (personal experience).
LangId Language "en" --- English "cn" --- Chinese
If LangId is not specified with blank or empty string, the language of System locale will be used as default.
RJ | TID | SDC | SE2 |
RJ | TID | SDC | SE2 |
RJ | TID | SDC | SE2 |
RC | RJ | TID | SDC | SE2 |
Append Mode generally rewrites existing file contents with a NEWLINE between textual lines--stripping out OS-specific newline characters and making the file the same regardless of the platform.
AppendRaw Mode rewrites existing file contents without modification before appending any new data to the file.
RJ | TID | SDC | SE2 |
Append Mode generally rewrites existing file contents with a NEWLINE between textual lines--stripping out OS-specific newline characters and making the file the same regardless of the platform.
AppendRaw Mode rewrites existing file contents without modification before appending any new data to the file.
RC | RJ | TID | SDC | SE2 |
RC | RJ | TID | SDC | SE2 |
RC | RJ | TID | SDC | SE2 |
RC |
RC | RJ | TID | SDC | SE2 |
RJ | SDC | TID | SE2 |
TOCR 2.0.4 and GOCR 0.48 are the latest release. They are available in SAFS and only support English. Both two OCR owners claim to support more languages in next release. Chinese, Japanese, and Korean are going to be supported in TOCR's next release 3.00.
The extension of the image file can be .bmp, .jpg, .gif, .tif, .png or .pnm.
Note: Seems TOCR performs a bit better than GOCR (personal experience).
LangId Language "en" --- English "cn" --- Chinese
If LangId is not specified with blank or empty string, the language of System locale will be used as default.
RC | RJ | TID | SDC | SE2 |
0 Normal file (Windows PC Only)
1 Read-only file
2 Hidden file (Windows PC Only)
4 System file (Windows PC Only)
32 Archive - file has changed since last backup (Windows PC Only)
Note: Java-based support like RJ, TID, SDC currently only support setting one file protection at a time--0, 1, 2, 3, 32. They do not yet support Integer values OR'd together to combine settings in a single call.
Note: On platforms other than windows we currently only support setting the READ-ONLY attribute.
RJ | TID | SDC | SE2 |