org.apache.tools.ant.taskdefs

Class Dirname

public class Dirname extends Task

Determines the directory name of the specified file. This task can accept the following attributes: Both file and property are required.

When this task executes, it will set the specified property to the value of the specified file up to, but not including, the last path element. If file is a file, the directory will be the current directory.

Since: Ant 1.5

UNKNOWN: category="property"

Method Summary
voidexecute()
Execute this task.
voidsetFile(File file)
Path to take the dirname of.
voidsetProperty(String property)
The name of the property to set.

Method Detail

execute

public void execute()
Execute this task.

Throws: BuildException on error

setFile

public void setFile(File file)
Path to take the dirname of.

Parameters: file a File value

setProperty

public void setProperty(String property)
The name of the property to set.

Parameters: property the name of the property