async def iter_list_protected_resources_by_backup_vault(
self,
backup_vault_name: "capo_backup.types.backup_vault_name.BackupVaultName",
*,
config_overrides: Optional[AsyncBackupClientConfig] = None,
backup_vault_account_id: Optional[
"capo_backup.types.account_id.AccountId"
] = None,
next_token: Optional["capo_backup.types.string.string"] = None,
max_results: Optional["capo_backup.types.max_results.MaxResults"] = None,
) -> "AsyncIterator[capo_backup.types.protected_resource.ProtectedResource]":
_token = next_token
while True:
_response = await self.list_protected_resources_by_backup_vault(
backup_vault_name,
config_overrides=config_overrides,
backup_vault_account_id=backup_vault_account_id,
next_token=_token,
max_results=max_results,
)
_page = _resolve_path(_response, ("results",))
for _item in _page or []:
yield _item
_token = _resolve_path(_response, ("next_token",))
if not _token:
break