Skip to contents

add a file as a record in the RRASSLED structure

Usage

disk_ingest_record(
  in_file = NULL,
  path_to_ras_dbase = NULL,
  code_to_place_in_source = NULL,
  proj_override = NULL,
  apply_vdat_trans = FALSE,
  is_quiet = FALSE,
  is_verbose = FALSE,
  overwrite = FALSE
)

Arguments

in_file

the path to the file on disk that we want to ingest, Default: NULL

code_to_place_in_source

a code to place in the metadata as the owner of the model, Default: NULL

proj_override

a string to override projection information should none be found, Default: NULL

apply_vdat_trans

Should VDATUM be applied to the HEC-RAS model geometry. See https://vdatum.noaa.gov/, Default: FALSE

is_quiet

flag to determine whether print statements are suppressed, TRUE to suppress messages and FALSE to show them, Default: FALSE

is_verbose

flag to determine whether internal print statements (i.e. cross section parsing, vdat trans, file info) are suppressed, TRUE to show these messages and FALSE to suppress them, Default: FALSE

overwrite

overwrite files if we find identical models, Default: FALSE

ras_dbase

A path to a directory to write your RRASSLED catalog to., Default: NULL

Value

a set of files in a newly RRASSLE'd record.

Details

the disk version of the ingest process

Examples

if (FALSE) { # \dontrun{
if(interactive()){
 #EXAMPLE1
 # ras_dbase <- "./inst/extdata/sample_output/ras_catalog/"
 # dir_to_scrape <- "./inst/extdata/sample_ras/FEMA-R6-BLE-sample-dataset/"
 dir_to_scrape <- fs::path_package("extdata/shapes.fgb", package = "mypkg")
 list_of_prj_files <- list.files(dir_to_scrape,pattern = glob2rx("*.prj$"),full.names = TRUE,ignore.case = TRUE,recursive = TRUE)
 disk_ingest_record(in_file = list_of_prj_files[1], path_to_ras_dbase = ras_dbase,code_to_place_in_source = "test",proj_override = "EPSG:2277",apply_vdat_trans = FALSE,is_quiet = FALSE,is_verbose = FALSE,overwrite = FALSE)

 #EXAMPLE2
 dir_to_scrape <- "./inst/extdata/sample_ras/ras2fim-sample-dataset/"
 list_of_prj_files <- list.files(dir_to_scrape,pattern = glob2rx("*.prj$"),full.names = TRUE,ignore.case = TRUE,recursive = TRUE)
 disk_ingest_record(in_file = list_of_prj_files[1], path_to_ras_dbase = ras_dbase,code_to_place_in_source = "test",proj_override = "EPSG:26915",apply_vdat_trans = FALSE,is_quiet = FALSE,is_verbose = TRUE,overwrite = FALSE)
 }
} # }