Just an hour after President Trump spoke at the Department of Homeland Security, State Senate Democrats held a news conference in Sacramento, announcing that they were prepared to take the fight over sanctuary cities to court. Earlier this month, the Democratic-led Legislature hired former Attorney General Eric H. Holder Jr. to represent them in any legal battle with the White House. They said Mr. Trump’s order violated the 10th Amendment by forcing local governments to enforce federal statutes.

Image Kevin de Leon, the Democratic leader of the State Senate, denounced President Trump’s executive orders on immigration. Credit... Rich Pedroncelli/Associated Press

“These are spiteful and meanspirited directives that will only instill fear in the hearts of millions of people who pay taxes, contribute to the economy and our way of life,” Kevin de Leon, the Democratic leader of the State Senate, said.

By some definitions, the entire state of California is a sanctuary state. A law passed in 2014 prohibits local jails from holding immigrants any longer than required by criminal law, with exceptions for violent and other serious crimes. And most counties in the state also prohibit holding immigrants beyond their sentence if federal immigration agents do not have a judicial order. And legislation currently making its way through the Legislature would further expand the law, by prohibiting all state and local law enforcement agencies to respond to requests from immigration authorities.

The mayors of San Francisco, San Jose, Oakland and Berkeley released a joint statement vowing to keep their existing policies in place. Mayor Eric Garcetti of Los Angeles, who has long shied away from the term sanctuary city, said the Police Department would continue its four-decades-old policy that prohibits officers from questioning people for the purpose of determining their immigration status and arresting them for illegal entry to the United States.