PathFunctions.

HasExtension(string) Method

Summary

Determines whether a path string includes an extension.
Assembly
NAnt.Core.dll
Namespace
NAnt.Core.Functions
Containing Type
PathFunctions

Syntax

[Function("has-extension")]
public static bool HasExtension(string path)

Attributes

Type Description
FunctionAttribute Indicates that the method should be exposed as a function in NAnt build files.

Parameters

Name Type Description
path string The path to search for an extension.

Return Value

Type Description
bool true. if the characters that follow the last directory separator or volume separator in the path include a period (.) followed by one or more characters; otherwise, false.