WASHINGTON — A federal appeals court appeared divided Thursday over whether to revive a lawsuit that claims President Donald Trump's ownership of a luxury hotel in Washington, D.C., violates the Constitution's ban on receiving financial benefits from the states or foreign leaders.

During lively arguments before the Fourth Circuit Court of Appeals in Richmond, Virginia, one judge called the lawsuit "a lemon" that should be tossed out, while another said the court must decide the issue for all presidents to come, not just Trump.

The case was brought two years ago by the attorney general of Maryland and the District of Columbia, claiming that Trump's hotel ownership violates the Constitution's emoluments clause.

That provision forbids the president to receive "any present, emolument, office or title of any kind whatever from any king, prince, or foreign state" or any state in the United States. The suit contends Trump improperly benefits financially whenever foreign or state governments patronize the Trump Hotel on Pennsylvania Avenue.

The suit claims that the Trump Hotel was unfairly competing with D.C.'s convention center and Maryland's National Harbor development, both of which earn local tax revenue and help area businesses. A three-judge panel ordered the case dismissed in July. But the full appeals court agreed to re-hear the case.

"This case is a lemon," said Judge J. Harvie Wilkinson, because the courts have never given a definitive explanation of what an emolument actually is. Noting that the Constitution says no office holder can accept an emolument without the consent of Congress, he added, "What concerns me is that Congress is wholly absent from this."

Justice Department lawyer Hashim Mooppan said the case should be thrown out precisely because Congress has played no role in the lawsuit. "You cannot sue the president in his individual capacity without express permission of Congress," Mooppan argued.

But Judge James Wynn said the court had a duty to keep the lawsuit alive in order to define emoluments and declare what they mean to office holders.

"The worst case scenario, the president gets up there and says out on a loudspeaker to everybody, 'If you come to my hotel, it's a good thing, and I need you to come here and advertise and just be here.' Nothing can be done?" Wynn asked.

Loren AliKhan, District of Columbia's solicitor general, said the "cleanest remedy" for violating the Constitution would be an order requiring the president to divest himself of the hotel. Foreign dignitaries would then know they could not provide any financial benefit to the president by taking their business to his hotel instead of a facility operated by D.C. or Maryland.

AliKhan said if the appeals court rules that the lawsuit can continue, it would go back to a federal judge in Maryland, who would supervise the discovery or fact-finding phase of the case, which she said could take six months to complete. D.C. Attorney General Karl Racine has said he would seek the president's tax returns in addition to other financial records.

Two other emoluments clause lawsuits against Trump are working their way through the courts. In September, the Second Circuit Court of Appeals revived a suit that claims he unconstitutionally profits from restaurants and hotels patronized by government officials. And the federal appeals court in Washington, D.C., heard arguments Monday in a lawsuit brought by congressional Democrats.