Generic function to test whether a file name conforms to the given a FileFormat instance. Will test for match to data file only
Source: R/all_generic.R, R/file_format.R
data_file_matches-methods.RdValidates whether a file name conforms to the data file format specification.
Usage
data_file_matches(x, file_name)
# S4 method for class 'FileFormat,character'
data_file_matches(x, file_name)Arguments
- x
A FileFormat object specifying the format requirements
- file_name
A character string specifying the file name to validate
Details
The function performs case-sensitive pattern matching to verify that the file name ends with the specified data extension. The match is performed using a regular expression that ensures the extension appears at the end of the file name.
See also
file_matches, header_file_matches for related
file format validation