File tree Expand file tree Collapse file tree 5 files changed +51
-0
lines changed Expand file tree Collapse file tree 5 files changed +51
-0
lines changed Original file line number Diff line number Diff line change 4
4
5
5
use IteratorIterator ;
6
6
7
+ /**
8
+ * CollectionInfoIterator for listCollections command results.
9
+ *
10
+ * This iterator may be used to wrap a Cursor returned by the listCollections
11
+ * command.
12
+ *
13
+ * @internal
14
+ * @see MongoDB\Database::listCollections()
15
+ * @see https://github.com/mongodb/specifications/blob/master/source/enumerate-collections.rst
16
+ * @see http://docs.mongodb.org/manual/reference/command/listCollections/
17
+ */
7
18
class CollectionInfoCommandIterator extends IteratorIterator implements CollectionInfoIterator
8
19
{
9
20
/**
Original file line number Diff line number Diff line change 4
4
5
5
use Iterator ;
6
6
7
+ /**
8
+ * CollectionInfoIterator interface.
9
+ *
10
+ * This iterator is used for enumerating collections in a database.
11
+ *
12
+ * @api
13
+ * @see MongoDB\Database::listCollections()
14
+ */
7
15
interface CollectionInfoIterator extends Iterator
8
16
{
9
17
/**
Original file line number Diff line number Diff line change 7
7
use IteratorIterator ;
8
8
use Traversable ;
9
9
10
+ /**
11
+ * CollectionInfoIterator for legacy "system.namespaces" query results.
12
+ *
13
+ * This iterator may be used to wrap a Cursor returned for queries on the
14
+ * "system.namespaces" collection. It includes logic to filter out internal
15
+ * collections and modify the collection name to be consistent with results from
16
+ * the listCollections command.
17
+ *
18
+ * @internal
19
+ * @see MongoDB\Database::listCollections()
20
+ * @see https://github.com/mongodb/specifications/blob/master/source/enumerate-collections.rst
21
+ * @see http://docs.mongodb.org/manual/reference/command/listCollections/
22
+ * @see http://docs.mongodb.org/manual/reference/system-collections/
23
+ */
10
24
class CollectionInfoLegacyIterator extends FilterIterator implements CollectionInfoIterator
11
25
{
12
26
/**
Original file line number Diff line number Diff line change 4
4
5
5
use Iterator ;
6
6
7
+ /**
8
+ * DatabaseInfoIterator interface.
9
+ *
10
+ * This iterator is used for enumerating databases on a server.
11
+ *
12
+ * @api
13
+ * @see MongoDB\Client::listDatabases()
14
+ */
7
15
interface DatabaseInfoIterator extends Iterator
8
16
{
9
17
/**
Original file line number Diff line number Diff line change 2
2
3
3
namespace MongoDB \Model ;
4
4
5
+ /**
6
+ * DatabaseInfoIterator for inline listDatabases command results.
7
+ *
8
+ * This iterator may be used to wrap the array returned within the listDatabases
9
+ * command's single-document result.
10
+ *
11
+ * @internal
12
+ * @see MongoDB\Client::listDatabases()
13
+ * @see http://docs.mongodb.org/manual/reference/command/listDatabases/
14
+ */
5
15
class DatabaseInfoLegacyIterator implements DatabaseInfoIterator
6
16
{
7
17
private $ databases ;
You can’t perform that action at this time.
0 commit comments