tasks/system/DeleteTask.php

Show: inherited
Table of Contents

Deletes a file or directory, or set of files defined by a fileset.

Package
phing.tasks.system  
Version
$Revision: 552 $  

\DeleteTask

Package: phing\tasks\system

Deletes a file or directory, or set of files defined by a fileset.

Parent(s)
\Task < \ProjectComponent
Version
$Revision: 552 $  

Properties

Propertyprotected  $dir= ''
Details
Type
n/a
Propertyprotected  $failonerror= 'true'
Default valuetrueDetails
Type
n/a
Propertyprotected  $file= ''
Details
Type
n/a
Propertyprivate  $filelists= 'array()'

Any filelists of files that should be deleted.

Default valuearray()Details
Type
n/a
Propertyprotected  $filesets= 'array()'
Default valuearray()Details
Type
n/a
Propertyprotected  $includeEmpty= 'false'
Default valuefalseDetails
Type
n/a
Propertyprotected  $quiet= 'false'
Default valuefalseDetails
Type
n/a
Propertyprotected  $verbosity= 'Project::MSG_VERBOSE'
Default valueProject::MSG_VERBOSEDetails
Type
n/a

Methods

methodpubliccreateFileList( ) : void

Nested creator, adds a set of files (nested fileset attribute).

methodpubliccreateFileSet( ) : void

Nested creator, adds a set of files (nested fileset attribute).

methodpublicgetDescription( ) : void

methodpublicgetLocation( ) : void

methodpublicgetOwningTarget( ) : void

methodpublicgetProject( ) : void

methodprotectedgetRegisterSlot( ) : void

methodpublicgetRuntimeConfigurableWrapper( ) : void

methodpublicgetTaskName( ) : void

methodpublicgetTaskType( ) : void

methodpublicinit( ) : void

methodpubliclog( ) : void

methodpublicmain( ) : void

Delete the file(s).

methodpublicmaybeConfigure( ) : void

methodpublicperform( ) : void

methodprivateremoveDir( \PhingFile $d ) : void

Recursively removes a directory.

Parameters
Name Type Description
$d \PhingFile

The directory to remove.

methodprivateremoveFiles( \PhingFile $d, array $files, array $dirs ) : void

remove an array of files in a directory, and a list of subdirectories which will only be deleted if 'includeEmpty' is true

Parameters
Name Type Description
$d \PhingFile

directory to work from

$files array

&$files array of files to delete; can be of zero length

$dirs array

&$dirs array of directories to delete; can of zero length

methodpublicsetDescription( ) : void

methodpublicsetDir( \PhingFile $dir ) : void

Set the directory from which files are to be deleted.

Parameters
Name Type Description
$dir \PhingFile
methodpublicsetFailOnError(  $bool ) : void

this flag means 'note errors to the output, but keep going'

Parameters
Name Type Description
$bool
methodpublicsetFile( \PhingFile $file ) : void

Set the name of a single file to be removed.

Parameters
Name Type Description
$file \PhingFile
methodpublicsetIncludeEmptyDirs(  $includeEmpty ) : void

Used to delete empty directories.

Parameters
Name Type Description
$includeEmpty
methodpublicsetLocation( ) : void

methodpublicsetOwningTarget( ) : void

methodpublicsetProject( ) : void

methodpublicsetQuiet(  $bool ) : void

If the file does not exist, do not display a diagnostic message or modify the exit status to reflect an error.

This means that if a file or directory cannot be deleted, then no error is reported. This setting emulates the -f option to the Unix rm command. Default is false meaning things are verbose

Parameters
Name Type Description
$bool
methodpublicsetRuntimeConfigurableWrapper( ) : void

methodpublicsetTaskName( ) : void

methodpublicsetTaskType( ) : void

methodpublicsetVerbose( boolean $verbosity ) : void

Used to force listing of all names of deleted files.

Parameters
Name Type Description
$verbosity boolean
Documentation was generated by DocBlox 0.17.1.