NAnt SDK Documentation - v0.85-nightly-2005-11-09

PropertyFunctions.Exists Method 

[This is preliminary documentation and subject to change.]

Checks whether the specified property exists.

[Visual Basic]
<Function(Name:="exists")>
Public Function Exists( _
   ByVal name As String _
) As Boolean
[C#]
[Function(Name="exists")]
public bool Exists(
   string name
);

Parameters

name
The property to test.

Return Value

true if the specified property exists; otherwise, false.

Remarks

Missing <remarks> documentation for M:NAnt.Core.Functions.PropertyFunctions.Exists(System.String)

Example

Execute a set of tasks if the "build.debug" property exists.

                
            <if test="${property::exists('build.debug')}">
                <echo message="Starting debug build" />
                <call target="init-debug" />
                <call target="build" />
            </if>
                
              

See Also

PropertyFunctions Class | NAnt.Core.Functions Namespace