Code
<?php

$m 
= new MongoClient();

/* @var $test MongoDB */
$test $m->selectDb('test');

/* @var $coll MongoCollection */
$coll $test->selectCollection('my_table');

$results $coll->find();

foreach(
$results as $result) {
    
dump($result);
}
Result
^ array:4 [
"_id" => MongoId {#1393
+id: "54204806895f69383a8b4567"
}
"name" => "name54204806e512e"
"value" => "value54204806e5187"
"object" => []
]

^ array:3 [
"_id" => MongoId {#1394
+id: "54204815895f693e3a8b4567"
}
"name" => "name54204815300aa"
"value" => "value54204815300e5"
]

^ array:4 [
"_id" => MongoId {#1395
+id: "5421399f895f69524d8b4567"
}
"name" => "myname"
"value" => "myvalue"
"object" => []
]
Used Versions
PHP 8.0, Laminas MVC 3.2, Symfony 5.2, Laravel 8.28, PHPUnit 9.5, Doctrine ORM 2.8