classes/phing/tasks/system/TstampTask.php

Sets properties to the current time, or offsets from the current time.

The default properties are TSTAMP, DSTAMP and TODAY;

Based on Ant's Tstamp task.

author
Michiel Rook
package
phing.tasks.system
since
2.2.0
version
$Revision: 557 $

\TstampCustomFormat

package
phing.tasks.system

Properties

Propertyprivate  $locale= ''
Details
Type
Propertyprivate  $pattern= ''
Details
Type
Propertyprivate  $propertyName= ''
Details
Type

Methods

methodpublic  execute( \TstampTask $tstamp ) :
validate parameter and execute the format.
Parameters
Name Type Description
$tstamp \TstampTask reference to task
methodpublic  setLocale(  $locale ) :
The locale used to create date/time string.
Parameters
Name Type Description
$locale locale
methodpublic  setPattern(  $pattern ) :
The date/time pattern to be used. The values are as defined by the PHP strftime() function.
Parameters
Name Type Description
$pattern pattern
methodpublic  setProperty( \propertyName $propertyName ) :
The property to receive the date/time string in the given pattern
Parameters
Name Type Description
$propertyName \propertyName the name of the property.

\TstampTask

Sets properties to the current time, or offsets from the current time.

The default properties are TSTAMP, DSTAMP and TODAY;

Based on Ant's Tstamp task.

Extends from
\Task
author
Michiel Rook
copyright
2001,2002 THYRELL. All rights reserved
package
phing.tasks.system
since
2.2.0
version
$Revision: 557 $

Properties

Propertyprivate  $customFormats= 'array'
Default valuearrayDetails
Type
Propertyprivate  $prefix= ''
Details
Type

Methods

methodpublic  addFormat( \TstampCustomFormat $cf ) :
Adds a custom format
Parameters
Name Type Description
$cf \TstampCustomFormat custom format
methodpublic  main( ) :
Create the timestamps. Custom ones are done before the standard ones.
Details
throws
methodpublic  prefixProperty(  $name,  $value ) :
helper that encapsulates prefix logic and property setting policy (i.e. we use setNewProperty instead of setProperty).
Parameters
Name Type Description
$name
$value
methodpublic  setPrefix( \prefix $prefix ) :
Set a prefix for the properties. If the prefix does not end with a "." one is automatically added.
Parameters
Name Type Description
$prefix \prefix the prefix to use.
Documentation was generated by DocBlox 0.13.1.