org.apache.tools.ant.taskdefs.optional

Class RenameExtensions

Implemented Interfaces:
SelectorContainer

public class RenameExtensions
extends MatchingTask

Version:
1.2

Field Summary

Fields inherited from class org.apache.tools.ant.taskdefs.MatchingTask

fileset

Fields inherited from class org.apache.tools.ant.Task

description, location, target, taskName, taskType, wrapper

Fields inherited from class org.apache.tools.ant.ProjectComponent

project

Constructor Summary

RenameExtensions()
Creates new RenameExtensions

Method Summary

void
execute()
Executes the task.
void
setFromExtension(String from)
The string that files must end in to be renamed
void
setReplace(boolean replace)
store replace attribute - this determines whether the target file should be overwritten if present
void
setSrcDir(File srcDir)
Set the source dir to find the files to be renamed.
void
setToExtension(String to)
The string that renamed files will end with on completion

Methods inherited from class org.apache.tools.ant.taskdefs.MatchingTask

XsetIgnore, XsetItems, add, addAnd, addContains, addContainsRegexp, addCustom, addDate, addDepend, addDepth, addDifferent, addFilename, addMajority, addModified, addNone, addNot, addOr, addPresent, addSelector, addSize, addType, appendSelector, createExclude, createExcludesFile, createInclude, createIncludesFile, createPatternSet, getDirectoryScanner, getImplicitFileSet, getSelectors, hasSelectors, selectorCount, selectorElements, setCaseSensitive, setDefaultexcludes, setExcludes, setExcludesfile, setFollowSymlinks, setIncludes, setIncludesfile, setProject

Methods inherited from class org.apache.tools.ant.Task

execute, getDescription, getLocation, getOwningTarget, getRuntimeConfigurableWrapper, getTaskName, getTaskType, getWrapper, handleErrorFlush, handleErrorOutput, handleFlush, handleInput, handleOutput, init, isInvalid, log, log, maybeConfigure, perform, reconfigure, setDescription, setLocation, setOwningTarget, setRuntimeConfigurableWrapper, setTaskName, setTaskType

Methods inherited from class org.apache.tools.ant.ProjectComponent

getProject, log, log, setProject

Constructor Details

RenameExtensions

public RenameExtensions()
Creates new RenameExtensions

Method Details

execute

public void execute()
            throws BuildException
Executes the task.
Overrides:
execute in interface Task
Throws:
BuildException - is there is a problem in the task execution.

setFromExtension

public void setFromExtension(String from)
The string that files must end in to be renamed
Parameters:
from - the extension of files being renamed.

setReplace

public void setReplace(boolean replace)
store replace attribute - this determines whether the target file should be overwritten if present
Parameters:
replace - if true overwrite any target files that exist.

setSrcDir

public void setSrcDir(File srcDir)
Set the source dir to find the files to be renamed.
Parameters:
srcDir - the source directory.

setToExtension

public void setToExtension(String to)
The string that renamed files will end with on completion
Parameters:
to - the extension of the renamed files.

Copyright © 2000-2006 Apache Software Foundation. All Rights Reserved.