Donald Trump is clearly no stranger to legal battles, given his high-profile businesses and now because of his presidential policies.

Before he became U.S. president, he and his businesses had been involved in at least 3,500 legal actions over three decades — about evenly divided between lawsuits filed by him and his companies and those filed against him — according to a USA Today analysis of filings released in June 2016.

EPA Methane

In May, EPA administrator Scott Pruitt decided to suspend for 90 days an Obama-era rule aimed at cutting methane emissions from landfills. (Pablo Martinez Monsivais/Associated Press)

The latest ruling in the Trump loss column involves his pick for head of the Environmental Protection Agency. On Monday, a federal appeals court ruled that Scott Pruitt cannot delay an EPA rule from the previous Obama administration requiring oil and gas companies to monitor and reduce methane pollution.

Pruitt had announced in April that he would delay by 90 days the deadline for oil and gas producers to follow the new rule, so that the agency could reconsider the measure.

Pruitt was previously described as a climate-change denier, but during hearings on his cabinet nomination in January, the Republican from Oklahoma said he disagreed with Trump's assertion that climate change was a "concept" created by China to harm U.S. competitiveness in manufacturing.

Here are some of the other legal wins and losses for Trump after his election win and during his time in office:

Trump University class action suits

Trump admitted no wrongdoing, but agreed, just days after winning the presidency, to pay $25 million US to resolve two class-action cases started by former students of Trump University.

52959849MT003_Donald_Trump

One complaint against Trump University alleged that its instructors were supposed to be 'handpicked' by Trump but didn't know anything about real estate. (Mario Tama/Getty Images)

It wasn't a huge win for the plaintiffs who, as is usual in cases of this kind, were only granted partial reimbursement. Plus, they must pay taxes on the payouts, and the deal says they can't opt out of the settlement in order to individually sue Trump for taking real estate courses they said were useless.

The resolution could be perceived as a partial win for Trump, because most business settlements in the U.S. are tax deductible — and he himself said he settled "for a small fraction of the potential award."

Mixed rulings on travel ban

In his first week in office, Trump tried to ban immigrants and refugees from several Muslim-majority countries and later had his executive orders blocked by federal judges.

USA-TRUMP/IMMIGRATION

Beth Kohn protests outside the Ninth U.S. Circuit Court of Appeals courthouse in San Francisco on Feb. 7 while the court hears arguments regarding Donald Trump's temporary travel ban on people from several Muslim-majority countries. (Noah Berger/Reuters)

Last month, the U.S. Supreme Court handed him a partial win in a challenge to the lower court rulings, paving the way for parts of the ban to be imposed over the summer.

The high court justices will hear full arguments in the case in October.

Fight over funding sanctuary cities

As Trump was coming up to his first 100 days in office in April, a U.S. judge in California blocked his executive order that sought to withhold federal funds from so-called sanctuary cities.

Although there is no single definition for a sanctuary, these jurisdictions generally provide services to undocumented immigrants without reporting their lack of legal status to immigration officials.

Trump made his way back into the win column, at least partially, on June 29 when the Republican-dominated House of Representatives passed a bill that would allow his administration to withhold certain law enforcement grants as punishment for sanctuary cities protecting people who are in the country illegally. 

The bill has yet to be put to a vote in the Senate.

Chefs balk at anti-immigration talk, then settle

During the election campaign, Trump filed two lawsuits against two celebrity chefs for pulling out of agreements to build restaurants in the Trump International Hotel, which is just blocks away from the White House. Both had objected to Trump's derogatory remarks about Mexican immigrants and countersued.

Chef José Andrés and the Trump Organization reached a settlement in April, the terms of which have not been disclosed. However, the chef said he was "excited" about working with the organization in future.

A few days later, Trump and chef Geoffrey Zakarian also settled their lawsuits, with the terms remaining under wraps.

Storms brewing on emoluments, university deal

One legal headache Trump still faces involves what those legally pursuing the president say is an unconstitutional mix of business and politics.

Two days after Trump's inauguration in January, his D.C. hotel became part of a lawsuit by a group of legal scholars and ethics experts called Citizens for Responsibility and Ethics in Washington. They allege that because the hotel plays host to foreign leaders, Trump is in violation of the Emoluments Clause of the U.S. constitution, which bars government officials from accepting payments from foreign governments.

On April 18, restaurant lobby group ROC United said it would be joining the lawsuit, saying the Trump administration's "conflicts of interest are glaring and dangerous."

Lawsuits over foreign payments grow

On June 12, the attorneys general of Maryland and the District of Columbia filed a lawsuit of their own, claiming Trump is profiting from the presidency. Since taking office, he has turned day-to-day control of his real estate empire over to a trust managed by two of his sons.

On June 14, almost 200 Democratic senators and representatives filed a lawsuit alleging Trump is violating the Emoluments Clause. The plaintiffs argue they have standing to sue, because the clause says only Congress may approve foreign gifts and payments.

Another case from the past that is resurfacing involves Trump University. Lawyers for Sherri Simpson, a member of the class-action lawsuits, filed an appeal last month against the settlement. She said she should be able to opt out of the deal and in fact was told she would be able to do that.

The Florida bankruptcy lawyer says her goal is to sue the president independently for alleged fraud.