# classes/phing/tasks/ext/svn/SvnBaseTask.php

Base class for Subversion tasks

author
  Michiel Rook
author
  Andrew Eddie
package
  phing.tasks.ext.svn
see
  \VersionControl_SVN
since
  2.2.0
version
  $Id: SvnBaseTask.php 808 2010-08-12 18:44:39Z mrook $

## \SvnBaseTask
jump to top

Base class for Subversion tasks

Use {@link Project#createTask} to register a new Task.

Extends from
  \Task
see
  \VersionControl_SVN
author
  Michiel Rook
author
  Andrew Eddie
copyright
  2001,2002 THYRELL. All rights reserved
package
  phing.tasks.ext.svn
since
  2.2.0
version
  $Id: SvnBaseTask.php 808 2010-08-12 18:44:39Z mrook $

### Properties

`$mode= ''`
Details

Type

`$repositoryUrl= ''`
Details

Type

`$svn= 'NULL'`
Default value `NULL` Details

Type

`$svnArgs= 'array'`
Default value `array` Details

Type

`$svnPath= '/usr/bin/svn'`
Default value`/usr/bin/svn` Details

Type

`$svnSwitches= 'array'`
Default value `array` Details

Type

`$toDir= ''`
Details

Type

`$workingCopy= ''`
Details

Type

### Methods

`getForce( ) :`
Returns the force switch
`getIgnoreExternals( ) :`
Returns the ignore-externals switch
`getNoCache( ) :`
Returns the no-auth-cache switch
`getPassword( ) :`
Returns the password
`getRecursive( ) :`
Returns the non-recursive switch
`getRepositoryUrl( ) :`
Returns the path/URI to the repository
`getSvnPath( ) :`
Returns the path to the SVN executable
`getToDir( ) :`
Returns the path to export/checkout to
`getUsername( ) :`
Returns the username
`getWorkingCopy( ) :`
Returns the path to the workingcopy
`init( ) :`
Initialize Task.

This method includes any necessary SVN libraries and triggers appropriate error if they cannot be found. This is not done in header because we may want this class to be loaded w/o triggering an error.

`run( array $args = array, array $switches = array ) : string`
Executes the constructed VersionControl_SVN instance
Parameters

Name | Type | Description
--- | --- | ---
$args | array | Additional arguments to pass to SVN.
$switches | array | Switches to pass to SVN.

Returns

Type | Description
--- | ---
string |

`setForce( $value ) :`
Sets the force switch
Parameters

Name | Type | Description
--- | --- | ---
$value |  |

`setIgnoreExternals( $value ) :`
Sets the ignore-externals switch
Parameters

Name | Type | Description
--- | --- | ---
$value |  |

`setNoCache( $value ) :`
Sets the no-auth-cache switch
Parameters

Name | Type | Description
--- | --- | ---
$value |  |

`setPassword( $value ) :`
Sets the password of the user to export
Parameters

Name | Type | Description
--- | --- | ---
$value |  |

`setRecursive( $value ) :`
Sets the non-recursive switch
Parameters

Name | Type | Description
--- | --- | ---
$value |  |

`setRepositoryUrl( $repositoryUrl ) :`
Sets the path/URI to the repository
Parameters

Name | Type | Description
--- | --- | ---
$repositoryUrl |  |

`setSvnPath( $svnPath ) :`
Sets the path to the SVN executable
Parameters

Name | Type | Description
--- | --- | ---
$svnPath |  |

`setToDir( $toDir ) :`
Sets the path to export/checkout to
Parameters

Name | Type | Description
--- | --- | ---
$toDir |  |

`setUsername( $value ) :`
Sets the username of the user to export
Parameters

Name | Type | Description
--- | --- | ---
$value |  |

`setWorkingCopy( $workingCopy ) :`
Sets the path to the workingcopy
Parameters

Name | Type | Description
--- | --- | ---
$workingCopy |  |

`setup( string $mode ) :`
Creates a VersionControl_SVN class based on $mode
Parameters

Name | Type | Description
--- | --- | ---
$mode | string | The SVN mode to use (info, export, checkout, ...)

Details

throws

Documentation was generated by DocBlox 0.13.1.