AbstractPath.GetFileName

AbstractPath.GetFileName method

Returns the file name and extension of this AbstractPath.

public string GetFileName()

Return Value

The characters after the last Separator character in the Location. If the last character is the Separator character, an empty string is returned. If there is no Separator characters in the Location, the Location itself is returned.

Examples

For an AbstractPath with Location equal to "/directory/file.txt" and Separator equal to '/', this method returns "file.txt".

See Also