WASHINGTON — Barack Obama spoke directly with his vanquished rival Hillary Rodham Clinton on Wednesday and expressed optimism they could achieve party unity after their bruising battle for the Democratic presidential nomination. He also accused Republican rival John McCain of supporting a "plan for staying, not a plan for victory" in Iraq.

As he traded jabs with McCain over national security policy, Obama visited the Senate where Democrats and Republicans shook his hand and congratulated him. The Illinois senator disclosed he had spoken with Clinton, who was not in the Senate, earlier on the day after he claimed the nomination and she stopped short of conceding.

"I just spoke to her today, and we're going to be having a conversation in coming weeks. And I'm very confident how unified the Democratic party's going to be to win in November," Obama told reporters as he left the Senate.

Asked if Clinton indicated she planned to concede, Obama replied, "It wasn't a detailed conversation. As I said, I'm very confident of how we're going to be able to bring the party together." He dismissed a question about her refusal to concede after the final two primaries Tuesday night by saying she was "understandably focused on her supporters."

Obama and Clinton ran into each other backstage at the American Israel Public Affairs Committee meeting, which they addressed separately Wednesday morning.

A day after welcoming Obama to the general election campaign, McCain said in a morning television interview, "I think he has exercised very bad judgment on national security issues and others."

Obama used his speech at the AIPAC meeting to reassure Jewish voters of his support for Israel and criticize McCain's promise to keep U.S. troops fighting in Iraq.

"Keeping all of our troops tied down indefinitely in Iraq is not the way to weaken Iran, it is precisely what strengthened it," Obama said in a speech in which he said the security of the Jewish state was sacrosanct.

Elsewhere, Obama's accomplish in becoming the first black ever to win a major party presidential nomination drew Secretary of State Condoleezza Rice's attention.

"The United States of America is an extraordinary country. It is a country that has overcome many, many, now years, decades, actually a couple of centuries of trying to make good on its principles," said Rice, the first female black secretary of state in history, serving in a Republican administration.

"And I think what we are seeing is an extraordinary expression of the fact that 'We the people' is beginning to mean to all of us."

On Wednesday, two more fellow senators swung behind Obama after remaining neutral throughout his long nominating battle with Sen. Hillary Rodham Clinton.

"We have a nominee of our party," said Sen. Tom Harkin of Iowa. "The nominee of our party is obviously Barack Obama." Sen. Ken Salazar of Colorado also announced his endorsement.

Former Vice President Walter Mondale, who had been a Clinton supporter, announced he was backing Obama.

It hardly mattered in terms of delegate math — after months of struggle, Obama had more than enough to prevail at the party convention in Denver in August.

But Mondale, Harkin, Salazar and others poised to endorse Obama later in the day were also sending a message to Clinton that her race is over, whether she will admit it or not.

The former first lady has yet to concede defeat in the primary campaign, although she is courting an invitation from Obama to become his vice presidential running mate.

McCain made several appearances on morning television programs, and he said he would be seeking support outside his party's traditional base.

"The key to winning the election is independent voters and Democrats as well," McCain said in an interview shown Wednesday on ABC's "Good Morning America." Even so, asked on CBS whether he'd pick a Democrat as his running mate, he replied, "I don't think so."

He also announced he has sent Obama a letter inviting him to a series of 10 joint town-hall meetings over the summer. "I even suggested we travel them together on the same plane. Probably help on energy savings," McCain said in Baton Rouge, La.

Clinton followed Obama to the podium at AIPAC, delivering a strong defense of Israel — and also of her rival in the nominating race.

"Let me be very clear. I know that Senator Obama will be a good friend to Israel," she said to applause.

Clinton herself made no mention of the question on the minds of Democrats everywhere — her future plans.

But others were not as reticent.

"I think a lot of her supporters would like to see her on the ticket," said her campaign chairman, Terry McAuliffe said.

"There is no deal in the works," said Obama's spokesman, Robert Gibbs.

"When the dust settles and it makes sense for her, he'll meet whenever she wants to," Gibbs said. "She's accumulated a lot of votes throughout this country. We want to make sure that we're appealing to her voters."

In his speech at AIPAC, Obama urged his audience to reject what he said were false e-mails circulating about him, stressed his support for Israel and depicted the war in Iraq as a threat to Israel's security.

"Israel's security is sacrosanct. It is nonnegotiable," he said. He backed a Palestinian state that is "contiguous and cohesive," but also said any agreement must "preserve Israel's identity as a Jewish state, with secure, recognized and defensible borders. Jerusalem will remain the capital of Israel, and it must remain undivided," he said.

Obama said Bush's decision to invade Iraq had enabled the hard-liners in Iran to tighten their grip on power. "And the United States and Israel are less secure," he added.

He said McCain "offers a false choice: stay the course in Iraq or cede the region to Iran. ... It is a policy for staying, not a policy for victory," adding he favors a phased withdrawal of troops from Iraq.

On the final night of the primary season, Clinton won South Dakota on Tuesday while Obama took Montana — and a slew of party superdelegates who declared their support to help him clinch the nomination. He did it, according to The Associated Press tally, based on primary elections, state Democratic caucuses and support from superdelegates. It took 2,118 delegates to clinch the nomination at the convention, and Obama had 2,154 by the AP count.

Pennsylvania Gov. Ed Rendell, a dogged Clinton supporter, recognized the brutality of the arithmetic.

"I am the last of the Mohicans, but it is over," he said.