The Trump administration announced late Friday that Manhattan U.S. Attorney Geoffrey Berman, who has overseen a number of investigations involving the president and his political campaign, will be leaving that job, though Berman fired back that he had not resigned and intends to stay in the job to ensure the cases continue unimpeded.

The surreal standoff marks the latest battle over the administration’s management of the Justice Department. Democrats have decried what they charge has been the politicization of the agency under President Trump and his attorney general, William P. Barr.

Barr announced the personnel change in a statement, saying the president plans to nominate the current chairman of the Securities and Exchange Commission, Jay Clayton, for the job.

Berman’s office has been conducting a criminal investigation of President Trump’s personal lawyer, Rudolph W. Giuliani, in a campaign finance case that has already led to charges against two of Giuliani’s associates.

One Justice Department official, speaking on the condition of anonymity due to the situation’s volatility, said the change arose because Clayton was preparing to leave the SEC later this year and had also expressed interest in the New York prosecutor job. Barr liked Clayton and liked the idea, the official said. Barr offered Berman the chance to become the head of the Justice Department’s Civil Division, but he declined, the official said.

Berman issued a blistering public statement.

“I learned in a press release from the Attorney General tonight that I was ‘stepping down’ as United States Attorney. I have not resigned, and have no intention of resigning, my position, to which I was appointed by the Judges of the United States District Court for the Southern District of New York,” Berman said.

“I will step down when a presidentially appointed nominee is confirmed by the Senate. Until then, our investigations will move forward without delay or interruption. I cherish every day that I work with the men and women of this Office to pursue justice without fear or favor — and intend to ensure that this Office’s important cases continue unimpeded.”

Unlike many other U.S. attorneys, Berman is almost uniquely positioned to resist efforts to oust him, at least for a while. U.S. attorneys are typically nominated by the president and confirmed by the Senate, but in Berman’s case he was appointed to the job by the federal court in his district, and there is some legal precedent indicating that only the court, not the Justice Department, can remove him until a replacement is confirmed by the Senate.

By Saturday morning, it remained far from clear whether Clayton, who was confirmed to his SEC position in May 2017 on a 61-37 vote, could clear the Republican-controlled Senate, with one of Trump’s closest allies signaling he would give home-state senators what amounts to veto power.

Senate Judiciary Committee Chairman Lindsey O. Graham (R-S.C.), whose panel oversees U.S. attorney nominations, said he would honor the so-called blue-slip rule for the Southern District of New York seat, which means the nomination would not advance without approval of both home-state senators, who are Democrats already deeply skeptical of Barr’s management of the Justice Department.

“As to processing U.S. Attorney nominations, it has always been the policy of the Judiciary Committee to receive blue slips from the home state senators before proceeding to the nomination,” Graham said. “As chairman, I have honored that policy and will continue to do so.”

One of the New York senators, Senate Minority Leader Charles E. Schumer, called on Clayton to withdraw from consideration. Schumer’s spokesman on Saturday declined to say whether he would refuse to return a blue slip.

“Jay Clayton has a similar choice today: He can allow himself to be used in the brazen Trump-Barr scheme to interfere in investigations by the U.S. Attorney for the Southern District of New York,” Schumer said. “Or he can stand up to this corruption, withdraw his name from consideration, and save his own reputation from overnight ruin.

It was Sen. Kirsten Gillibrand, New York’s other senator, who in 2018 threatened to block Berman’s confirmation by not returning her blue slip, a move that prompted an interim appointment eventually made permanent by the judges. In a statement, she echoed Schumer’s call for Clayton to withdraw from consideration.

“I will not be complicit in helping President Trump and Attorney General Barr fire a U.S. attorney who is reportedly investigating corruption in this administration,” she said. “... President Trump cannot be allowed to desecrate our nominations process further.”

Graham said the administration had not told him of its intent to replace Berman, but said Clayton is a “fine man and accomplished lawyer.”

Rep. Jerrold Nadler (D-N.Y.), chairman of the House Judiciary Committee, wants Berman testify at a previously scheduled hearing next week to examine Barr’s leadership of the agency.

“America is right to expect the worst of Bill Barr, who has repeatedly interfered in criminal investigations on Trump’s behalf,” Nadler tweeted late Friday. “We have a hearing on this topic on Wednesday. We welcome Mr. Berman’s testimony and will invite him to testify.”

A spokesman for Berman declined to comment.

Barr said in his statement that while the Senate considers Clayton’s nomination, the job will be filled by Craig Carpenito, the U.S. attorney in New Jersey. Carpenito will take over the job on July 3, Barr said.

“Geoff has done an excellent job leading one of our nation’s most significant U.S. Attorney’s Offices, achieving many successes on consequential civil and criminal matters,” Barr said.

Federal prosecutors in Manhattan handle some of the most sensitive financial, political and national security cases in the Justice Department, and Berman’s office has a long tradition of charting its own course on high-profile cases.

People familiar with the Giuliani case have said investigators are scrutinizing the former New York mayor’s consulting business and eyeing donations made to America First Action, the main pro-Trump super PAC set up by his advisers and allies after his election, as well as a nonprofit affiliated with the super PAC.

Under Berman, federal prosecutors in the Southern District of New York have pursued cases against Trump’s former attorney and fixer Michael Cohen and sex offender Jeffrey Epstein, who was found dead in his Manhattan jail cell last summer.

Seung Min Kim contributed to this report.