These verses contain rhetorical questions that emphasize that David realizes that Yahweh has allowed this to happen.