C# Class GSF.IO.PathHelpers

Helper methods for path strings.
Mostrar archivo Open project: GridProtectionAlliance/openHistorian

Public Methods

Method Description
FormatExtension ( string extension ) : string

ensures that the provided extension is in the provided format: .exe

throws a series of exceptions if the extension is invalid.

ValidateFileName ( string fileName ) : void

Ensures the supplied file name is valid.

throws a series of exceptions if the fileName is invalid.

ValidatePathName ( string pathName ) : void

Ensures the supplied path name is valid.

throws a series of exceptions if the pathName is invalid.

Method Details

FormatExtension() public static method

ensures that the provided extension is in the provided format: .exe
throws a series of exceptions if the extension is invalid.
public static FormatExtension ( string extension ) : string
extension string the extension to format. Can be *.exe, or .exe, or exe
return string

ValidateFileName() public static method

Ensures the supplied file name is valid.
throws a series of exceptions if the fileName is invalid.
public static ValidateFileName ( string fileName ) : void
fileName string any filename.
return void

ValidatePathName() public static method

Ensures the supplied path name is valid.
throws a series of exceptions if the pathName is invalid.
public static ValidatePathName ( string pathName ) : void
pathName string any path.
return void