定義
- MongoDB\Model\CollectionInfo::getOptions()
- コレクション オプションを返します。 これは、 - MongoDB\Database::createCollection()の オプションと相関しますが、サーバーによって設定された追加のフィールドが含まれる場合があります。- function getOptions(): array 
Return Values
コレクションオプション これは、 listCollectionsコマンドの応答で返されるoptionsフィールドに対応します。
例
// Creates a capped collection $db->createCollection(    'myCappedCollection',    ['capped' => true, 'size' => 1048576] ); // Retrieves the options for the collection foreach ($db->listCollections(['filter' => ['name' => 'myCappedCollection']]) as $info) {    var_dump($info->getOptions()); } 
出力は次のようになります。
array(2) {   ["capped"]=>   bool(true)   ["size"]=>   int(1048576) } 
その他の参照
- MongoDB マニュアルのlistCollectionsコマンド参照