| 1 | <?php |
||
| 11 | class MockClient implements ClientInterface |
||
| 12 | { |
||
| 13 | /** |
||
| 14 | * @var string |
||
| 15 | */ |
||
| 16 | private $origin; |
||
| 17 | |||
| 18 | /** |
||
| 19 | * @var string |
||
| 20 | */ |
||
| 21 | private $target; |
||
| 22 | |||
| 23 | /** |
||
| 24 | * Sync $origin directory with $target one. |
||
| 25 | * If SSH was configured, you must use absolute path |
||
| 26 | * in the target directory |
||
| 27 | * |
||
| 28 | * @param string $src |
||
| 29 | * @param string $dst |
||
| 30 | * @param Callable $callback |
||
| 31 | * |
||
| 32 | * @throws ClientException |
||
| 33 | * |
||
| 34 | * @return int|null |
||
| 35 | */ |
||
| 36 | 1 | public function sync($src, $dst, $callback = null) |
|
| 40 | |||
| 41 | /** |
||
| 42 | * @param string $origin |
||
| 43 | * |
||
| 44 | * @return $this |
||
| 45 | */ |
||
| 46 | 1 | public function setOrigin($origin) |
|
| 52 | |||
| 53 | /** |
||
| 54 | * @return string |
||
| 55 | */ |
||
| 56 | 1 | public function getOrigin() |
|
| 60 | |||
| 61 | /** |
||
| 62 | * @param string $target |
||
| 63 | * |
||
| 64 | * @return $this |
||
| 65 | */ |
||
| 66 | 1 | public function setTarget($target) |
|
| 72 | |||
| 73 | /** |
||
| 74 | * @return string |
||
| 75 | */ |
||
| 76 | 1 | public function getTarget() |
|
| 80 | } |
||
| 81 |