When this task executes, it will set the specified property to the value of the last element in the specified file. If file is a directory, the basename will be the last directory element. If file is a full-path filename, the basename will be the simple file name. If a suffix is specified, and the specified file ends in that suffix, the basename will be the simple file name without the suffix.
| Modifier and Type | Field and Description |
|---|---|
| private File | |
| private String | |
| private String |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public void | |
| private String | |
| public void | |
| public void | |
| public void |
| file | back to summary |
|---|---|
| private File file | |
| property | back to summary |
|---|---|
| private String property | |
| suffix | back to summary |
|---|---|
| private String suffix | |
| Basename | back to summary |
|---|---|
| public Basename() | |
| execute | back to summary |
|---|---|
| public void execute() throws BuildException Overrides org. do the work
| |
| removeExtension | back to summary |
|---|---|
| private String removeExtension(String s, String ext) | |
| setFile | back to summary |
|---|---|
| public void setFile(File file) file or directory to get base name from
| |
| setProperty | back to summary |
|---|---|
| public void setProperty(String property) Property to set base name to.
| |
| setSuffix | back to summary |
|---|---|
| public void setSuffix(String suffix) Optional suffix to remove from base name.
| |