tasks/ext/FileHashTask.php
fileHash
Calculate either MD5 or SHA hash value of a specified file and retun the value in a property
- Author
- Johan Persson
- Package
- phing.tasks.ext
- Version
- $Id: FileHashTask.php 1084 2011-05-06 09:55:25Z mrook $
\FileHashTask
Package: phing\tasks\ext
Default value
fileHash
Calculate either MD5 or SHA hash value of a specified file and retun the value in a property
- Parent(s)
- \Task < \ProjectComponent
- Author
- Johan Persson
- Version
- $Id: FileHashTask.php 1084 2011-05-06 09:55:25Z mrook $
Properties

integer
$hashtype= '0'
Specify which hash algorithm to use.
0 = MD5 1 = SHA1
0Details- Type
- integer
Methods

setFile(
\PhingFile $file
)
:
voidWhich file to calculate the hash value of
Parameters
| Name | Type | Description |
|---|---|---|
| $file | \PhingFile |

setHashtype(
integer $type
)
:
voidSpecify if MD5 or SHA1 hash should be used
Parameters
| Name | Type | Description |
|---|---|---|
| $type | integer | 0=MD5, 1=SHA1 |

setPropertyName(
$property
)
:
voidSet the name of the property to store the hash value in
Parameters
| Name | Type | Description |
|---|---|---|
| $property |