classes/phing/tasks/ext/ScpTask.php

Copy files to and from a remote host using scp.

author
Michiel Rook
author
Johan Van den Brande
package
phing.tasks.ext
version
$Id: ScpTask.php 1070 2011-03-25 14:35:06Z mrook $

\ScpTask

Copy files to and from a remote host using scp.

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

Extends from
\Task
author
Michiel Rook
author
Johan Van den Brande
copyright
2001,2002 THYRELL. All rights reserved
package
phing.tasks.ext
version
$Id: ScpTask.php 1070 2011-03-25 14:35:06Z mrook $

Properties

Propertyprotected  $autocreate= 'true'
Default valuetrueDetails
Type
Propertyprotected  $connection= 'null'
Default valuenullDetails
Type
Propertyprotected  $count= '0'
Default value0Details
Type
Propertyprotected  $fetch= 'false'
Default valuefalseDetails
Type
Propertyprotected  $file= ''
Details
Type
Propertyprotected  $filesets= 'array'
Default valuearrayDetails
Type
Propertyprotected  $host= ''
Details
Type
Propertyprotected  $localEndpoint= ''
Details
Type
Propertyprotected  $logLevel= 'Project'
Default valueProjectDetails
Type
Propertyprotected  $mode= 'null'
Default valuenullDetails
Type
Propertyprotected  $password= ''
Details
Type
Propertyprotected  $port= '22'
Default value22Details
Type
Propertyprotected  $privkeyfile= ''
Details
Type
Propertyprotected  $privkeyfilepassphrase= ''
Details
Type
Propertyprotected  $pubkeyfile= ''
Details
Type
Propertyprotected  $remoteEndpoint= ''
Details
Type
Propertyprotected  $sftp= 'null'
Default valuenullDetails
Type
Propertyprotected  $todir= ''
Details
Type
Propertyprotected  $username= ''
Details
Type

Methods

methodprotected  copyFile(  $local,  $remote ) :
Parameters
Name Type Description
$local
$remote
methodpublic  createFileSet( ) : \FileSet
Nested creator, creates a FileSet for this task
Returns
Type Description
\FileSet
methodpublic  getAutocreate( ) :
Returns whether to autocreate remote directories
methodpublic  getFetch( ) :
Returns whether to send (default) or fetch files
methodpublic  getFile( ) :
Returns local filename
methodpublic  getHost( ) :
Returns the remote host
methodpublic  getMode( ) :
Returns the mode value
methodpublic  getPassword( ) :
Returns the password
methodpublic  getPort( ) :
Returns the remote host port
methodpublic  getPrivkeyfile( ) :
Returns the private keyfile
methodpublic  getPrivkeyfilepassphrase(  $privkeyfilepassphrase ) :
Returns the private keyfile passphrase
Parameters
Name Type Description
$privkeyfilepassphrase
methodpublic  getPubkeyfile( ) :
Returns the pubkeyfile
methodpublic  getTodir( ) :
Returns the destination directory
methodpublic  getUsername( ) :
Returns the username
methodpublic  init( ) :
methodpublic  main( ) :
methodpublic  setAutocreate(  $autocreate ) :
Sets whether to autocreate remote directories
Parameters
Name Type Description
$autocreate
methodpublic  setFetch(  $fetch ) :
Sets whether to send (default) or fetch files
Parameters
Name Type Description
$fetch
methodpublic  setFile(  $file ) :
Sets local filename
Parameters
Name Type Description
$file
methodpublic  setHost(  $h ) :
Sets the remote host
Parameters
Name Type Description
$h
methodpublic  setLevel( string $level ) :
Set level of log messages generated (default = verbose)
Parameters
Name Type Description
$level string
methodpublic  setMode(  $value ) :
Sets the mode value
Parameters
Name Type Description
$value
methodpublic  setPassword(  $password ) :
Sets the password of the user to scp
Parameters
Name Type Description
$password
methodpublic  setPort(  $p ) :
Sets the remote host port
Parameters
Name Type Description
$p
methodpublic  setPrivkeyfile(  $privkeyfile ) :
Sets the private key file of the user to scp
Parameters
Name Type Description
$privkeyfile
methodpublic  setPrivkeyfilepassphrase(  $privkeyfilepassphrase ) :
Sets the private key file passphrase of the user to scp
Parameters
Name Type Description
$privkeyfilepassphrase
methodpublic  setPubkeyfile(  $pubkeyfile ) :
Sets the public key file of the user to scp
Parameters
Name Type Description
$pubkeyfile
methodpublic  setTodir(  $todir ) :
Set destination directory
Parameters
Name Type Description
$todir
methodpublic  setUsername(  $username ) :
Sets the username of the user to scp
Parameters
Name Type Description
$username
Documentation was generated by DocBlox 0.13.1.