Learn R Programming

ospsuite.utils (version 1.2.0)

isFileExtension: Check if the provided path has required extension

Description

Check if the provided path has required extension

Usage

isFileExtension(file, extension)

Arguments

file

A name of the file or full path.

extension

A required extension of the file.

Value

TRUE if the file name (or full path) includes the extension.

Examples

Run this code
# NOT RUN {
isFileExtension("enum.R", "R") # TRUE
isFileExtension("enum.R", "pkml") # FALSE
# }

Run the code above in your browser using DataLab