Stratfor's George Friedman is a realist on what it would really mean:
Destroying Iran’s nuclear capability does not involve a one-day raid, nor is Iran without the ability to retaliate. Its nuclear facilities are in a number of places and Iran has had years to harden those facilities. Destroying the facilities might take an extended air campaign and might even require the use of special operations units to verify battle damage and complete the mission. In addition, military action against Iran’s naval forces would be needed to protect the oil routes through the Persian Gulf from small boat swarms and mines, anti-ship missile launchers would have to be attacked and Iranian air force and air defenses taken out.
This would not solve the problem of the rest of Iran’s conventional forces, which would represent a threat to the region, so these forces would have to be attacked and reduced as well. An attack on Iran would not be an invasion, nor would it be a short war. Like Yugoslavia in 1999, it would be an extended air war lasting an unknown number of months.
There would be American POWs from aircraft that were shot down or suffered mechanical failure over Iranian territory.
There would be many civilian casualties, which the international media would focus on. It would not be an antiseptic campaign, but it would likely (though it is important to reiterate not certainly) destroy Iran’s nuclear capability and profoundly weaken its conventional forces. It would be a war based on American strengths in aerial warfare and technology, not on American weaknesses in counterinsurgency. It would strengthen the Iranian regime (as aerial bombing usually does) by rallying the Iranian public to its side against the aggression. If the campaign were successful, the Iranian regime would be stronger politically, at least for a while, but eviscerated militarily.
This doesn't even account for the impact of another Western attack on a Muslim nation and what that would do for Jihadist recruitment or wider terrorism. For all the differences between Shia and Sunni, and the very complicated shadings of Islamist and Jihadist coalitions and factions, a US attack would surely serve to unite and corral the enemy at home and abroad.
Friedman posits nonetheless that a successful campaign could help Obama politically. I don't believe the president is that cynical or that reckless. To entertain what would amount to a second term Bay of Pigs combined with a Cuban Missile Crisis is not exactly good political judgment. As in the economy, Obama may well be remembered for what he managed to prevent rather than what he accomplished. But prudent restraint and structural change are often much deeper achievements than, say, the reckless, deeply damaging agenda of the Bush-Cheney years.
It's the difference between morally responsible statesmanship and reckless, fear-driven politicking.