powered by
Checks the existence of elements inside a GTFS object that represent specific GTFS text files.
check_file_exists(x, files)assert_file_exists(x, files)
assert_file_exists(x, files)
check_file_exists returns TRUE if the check is successful, and FALSE otherwise.
check_file_exists
TRUE
FALSE
assert_file_exists returns x invisibly if the check is successful, and throws an error otherwise.
assert_file_exists
x
A GTFS object.
A character vector. The files to check the existence of.
Other checking functions: check_field_class(), check_field_exists()
check_field_class()
check_field_exists()
gtfs_path <- system.file("extdata/ggl_gtfs.zip", package = "gtfsio") gtfs <- import_gtfs(gtfs_path) check_file_exists(gtfs, c("calendar", "agency")) check_file_exists(gtfs, c("calendar", "oi"))
Run the code above in your browser using DataLab