--- /dev/null
+<?php
+
+namespace Cubist\Net\Server;
+
+use Cubist\Net\Transfer\IServer;
+
+class SFTP implements IServer
+{
+
+ protected $host;
+ protected $username;
+ protected $password;
+ protected $port;
+ protected $path;
+
+ public function __construct($host, $username, $password, $path, $port = 22)
+ {
+ $this->host = $host;
+ $this->username = $username;
+ $this->password = $password;
+ $this->port = $port;
+ $this->path = $path;
+ }
+
+ public function getProtocol()
+ {
+ return "SFTP";
+ }
+
+ public function getHost()
+ {
+ return $this->host;
+ }
+
+ public function getPort()
+ {
+ return $this->port;
+ }
+
+ public function getUsername()
+ {
+ return $this->username;
+ }
+
+ public function getPassword()
+ {
+ return $this->password;
+ }
+
+ public function getBasePath()
+ {
+ return $this->path;
+ }
+
+ public function getBaseURL()
+ {
+ // TODO: Implement getBaseURL() method.
+ }
+
+ public function getSettings()
+ {
+ // TODO: Implement getSettings() method.
+ }
+
+ public function makeURL($path)
+ {
+ // TODO: Implement makeURL() method.
+ }
+}
\ No newline at end of file
const DEFAULT_PORT = 22;
+ public static function getInstance($host, $username, $password, $path, $port = self::DEFAULT_PORT)
+ {
+ return new SFTP(new \Cubist\Net\Server\SFTP($host, $username, $password, $path, $port));
+ }
+
protected function synchronizeFiles($source, $dest, $mirror = false, $dryrun = false)
{
$rclone = new Rclone();