R/MsBackend-functions.R

Defines functions .valid_ms_backend_files_exist .valid_ms_backend_data_storage

#' @include hidden_aliases.R
NULL

.valid_ms_backend_data_storage <- function(x) {
    if (anyNA(x))
        return("'NA' values in dataStorage are not allowed.")
    NULL
}

.valid_ms_backend_files_exist <- function(x) {
    x <- x[!is.na(x)]
    if (length(x) && !all(file.exists(x)))
        return(paste0("File(s) ", paste(x[!file.exists(x)], collapse = ", "),
                      " not found"))
    NULL
}
lgatto/Spectra documentation built on July 4, 2021, 5:53 p.m.