classes/phing/tasks/ext/jsmin/JsMinTask.php

\JsMinTask

Task to minify javascript files.

Requires JSMin which can be found at http://code.google.com/p/jsmin-php/ but is bundled with Phing so no additional install of JsMin is required.

Extends from
\Task
author
Frank Kleine
copyright
2001,2002 THYRELL. All rights reserved
package
phing.tasks.ext
since
2.3.0
version
$Id: JsMinTask.php 1231 2011-07-25 20:11:53Z mrook $

Properties

Propertyprotectedboolean  $failonerror= 'false'

Whether the build should fail, if errors occured

Default valuefalseDetails
Type
boolean
Propertyprotected\FileSet  $filesets= 'array'

the source files

Default valuearrayDetails
Type
\FileSet
Propertyprotectedboolean  $suffix= '-min'

Define if the target should use or not a suffix -min

Default value-minDetails
Type
boolean
Propertyprotectedstring  $targetDir= ''

directory to put minified javascript files into

Details
Type
string

Methods

methodpublic  createFileSet( ) :
Nested creator, adds a set of files (nested fileset attribute).
methodpublic  init( ) :
The init method: Do init steps.
methodpublic  main( ) :
The main entry point method.
methodpublic  setFailonerror( boolean $value ) :
Whether the build should fail, if an error occured.
Parameters
Name Type Description
$value boolean
methodpublic  setSuffix( string $value ) :
Define if the task should or not use a suffix (-min is the default)
Parameters
Name Type Description
$value string
methodpublic  setTargetDir( string $targetDir ) :
sets the directory where minified javascript files should be put inot
Parameters
Name Type Description
$targetDir string
Documentation was generated by DocBlox 0.13.1.