Skip to content

Commit c8856c3

Browse files
committed
DirectoryInterface documentation
1 parent eb991bf commit c8856c3

1 file changed

Lines changed: 30 additions & 13 deletions

File tree

src/Node/DirectoryInterface.php

Lines changed: 30 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -3,53 +3,70 @@
33
namespace React\Filesystem\Node;
44

55
use React\Filesystem\AdapterInterface;
6+
use React\Promise\PromiseInterface;
67

78
interface DirectoryInterface extends NodeInterface
89
{
910
/**
10-
* @return \React\Promise\PromiseInterface
11+
* Create the directory, fails when directory already exists or when parent doesn't exist.
12+
*
13+
* @return PromiseInterface
1114
*/
1215
public function create($mode = AdapterInterface::CREATION_MODE);
1316

1417
/**
15-
* @return \React\Promise\PromiseInterface
18+
* Create the directory, creating any parent that doesn't exist.
19+
*
20+
* @return PromiseInterface
1621
*/
1722
public function createRecursive($mode = AdapterInterface::CREATION_MODE);
1823

1924
/**
20-
* @return \React\Promise\PromiseInterface
25+
* Remove the directory, fails when it has contents.
26+
*
27+
* @return PromiseInterface
2128
*/
2229
public function remove();
2330

2431
/**
25-
* @return \React\Promise\PromiseInterface
32+
* List contents of the directory.
33+
*
34+
* @return PromiseInterface
2635
*/
2736
public function ls();
2837

2938
/**
39+
* List contents of the directory and any child directories recursively.
40+
*
41+
* @return PromiseInterface
42+
*/
43+
public function lsRecursive();
44+
45+
/**
46+
* Change mode recursively.
47+
*
3048
* @param int $mode
31-
* @return \React\Promise\PromiseInterface
49+
* @return PromiseInterface
3250
*/
3351
public function chmodRecursive($mode);
3452

3553
/**
36-
* @return \React\Promise\PromiseInterface
54+
* Change owner recursively.
55+
*
56+
* @return PromiseInterface
3757
*/
3858
public function chownRecursive();
3959

4060
/**
41-
* @return \React\Promise\PromiseInterface
61+
* Remove the directory and all its contents recursively.
62+
*
63+
* @return PromiseInterface
4264
*/
4365
public function removeRecursive();
4466

45-
/**
46-
* @return \React\Promise\PromiseInterface
47-
*/
48-
public function lsRecursive();
49-
5067
/**
5168
* @param DirectoryInterface $directory
52-
* @return \React\Promise\PromiseInterface
69+
* @return PromiseInterface
5370
*/
5471
//public function rsync(DirectoryInterface $directory);
5572
}

0 commit comments

Comments
 (0)