New York City Mayor Michael R. Bloomberg, at the lectern, is joined by local officials at an event Tuesday.

Mayor Michael Bloomberg on Friday lauded a federal appeals ruling to block sweeping court-ordered changes to New York City’s stop-and-frisk policy, declaring he will continue to run the New York Police Department during his final two months in office as he sees fit.

Mr. Bloomberg, who was stung by U.S. District Judge Shira Scheindlin’s ruling that found the NYPD’s use of stop and frisk violated the constitution, reveled on his radio show Friday morning in Thursday’s 3-0 ruling from the Court of Appeals for the Second Circuit that removed Judge Scheindlin from the case and halted the changes she ordered.

On the campaign trail, Republican mayoral nominee Joe Lhota suggested on Friday that the court’s ruling blew a hole in Democratic frontrunner Bill de Blasio’s entire campaign, which prominently featured criticism of the tactic and plans to change the policy. If elected to succeed Mr. Bloomberg, Mr. de Blasio has pledged to order immediate changes to stop and frisk.

The ruling has significant political ramifications, especially for the outgoing mayor who is seeking to burnish his legacy before he leaves office on Dec. 31.

Speaking on his weekly radio show, Mr. Bloomberg said he was “very satisfied” with the appeals court decision and believes it reflects a “high probability” that the city’s appeal of Judge Scheindlin’s ruling will be successful. The mayor also made clear that under his watch, the Police Department will be run in accordance with his views and that of his police commissioner, Raymond Kelly.

“Commissioner Kelly can run the department the way he has been running it, with my approval and support for the last 12 years,” he said. “It will be up to the next mayor to decide what to do and a different judge.”

Mr. Bloomberg insisted that the NYPD’s practices are in “conformity” with the law, and he sought Friday to use the appeals court decision to pour water on the notion that the department acted in an unconstitutional manner. The appeals court issued no judgment on the merits of the case.

“It is not unconstitutional until the courts have a final say,” Mr. Bloomberg said. “Unless you take the appeal through the process, you really don’t know.”

For Messrs. Bloomberg and Kelly, the appeals court decision is a major political victory because both had been tarnished by a decision that painted them as overseeing an unconstitutional practice that violated the rights of black and Latino men. This week, Mr. Kelly was booed and prevented from delivering a speech at Brown University because of student opposition to stop and frisk.

Mr. Kelly on Friday described Judge Scheindlin’s decision as “grossly unfair,” saying it “unfairly blemished” the NYPD mostly for “sheer political purposes.”

“Maybe this clears up some of that,” Mr. Kelly said, referring to the appeals court ruling. “We’ll see.”

In her ruling, Judge Scheindlin wrote that the city acted with “deliberate indifference” toward the New York Police Department’s practice of conducting “unconstitutional” stop and frisks. The city adopted a policy of “indirect racial profiling” that resulted in the “disproportionate and discriminatory” stopping of millions of black and Hispanic men, she wrote.

The judge appointed a federal monitor, Peter Zimroth, a former Manhattan chief assistant district attorney, to develop a set of changes to the NYPD’s policies, training and supervision of stop-and-frisk. The appeals court decision now prevents Mr. Zimroth from moving forward.

“For the next 60 days we don’t want an outsider coming in who doesn’t know anything about crime fighting, putting the lives of our police officers and the lives of the public on the line,” Mr. Bloomberg said.

In a slap at Mr. de Blasio, who has said he would work with a federal monitor, Mr. Bloomberg said he doesn’t know why any mayor would want an outside monitor, even if there was agreement that changes needed to be made, because the mayor should want to be in charge.

Mr. Bloomberg said police officers, most of whom are minority, have been “dragged through the mud.” He pointed out that the decision was unanimous and “unequivocal.” He described the decision to remove Judge Scheindlin from the case as rare, but suggested it was warranted.

“We have said a number of times we thought the judge was not giving us the opportunity to present our case and to explain what the Police Department does, how we decide who to stop, question and sometimes frisk.”

If the incoming mayor decides to withdraw the appeal, as Mr. de Blasio said he would do, the judge’s ruling would go into effect, Mr. Bloomberg said Friday. But Mr. de Blasio, who has an overwhelming lead in the polls, has said, whether there is a federal monitor or not, he plans to make changes to the policy.

Mr. de Blasio’s opponent on Friday sought to score political points from the appeals ruling, noting that Mr. de Blasio has based much of his campaign on his pledge to reform stop and frisk.

“The entire core of his campaign just fell apart yesterday because he ran the entire Democratic primary on stop, question and frisk,” Mr. Lhota charged.

On Thursday night, Mr. de Blasio said he was disappointed with the appeals court decision and that he was surprised by it. “Further delay is not going to help this city heal,” he said.

Mr. de Blasio said he believes Judge Scheindlin’s ruling was “correct” and that the remedies she ordered were “fair.”

“My hope is that we can get on the same page with the judiciary about making the reforms we need,” he said.