China’s President Xi Jinping said his country would not waive its claims to the contested waters of the South China Sea in a speech delivered Friday marking the 95th anniversary of the Communist Party. The remarks appeared to be targeted at the U.S. and Philippines over freedom of navigation patrols and competing claims in the waters.

“China does not covet any interests of other nations, but we’ll never waive our legitimate rights,” Xi said, the South China Morning News reported. “Other nations should not expect us to haggle about our core interests or take the consequences of undermining our interests concerning sovereignty, security and development.”

Xi's remarks come ahead of a July 12 ruling from the Permanent Court of Arbitration in The Hague in a case between China and Philippines. The Philippines brought the case challenging China’s territorial claims in the contested waters in 2013, arguing they are illegal under the United Nations Convention on the Law of the Sea, the New York Times reported.

Beijing has already said it would not respect the court's decision.

“China does not accept any means of third-party dispute settlement or any solution imposed on China,” said Foreign Ministry spokesman Hong Lei. “The Chinese government will continue to abide by international law and basic norms governing international relations as enshrined in the Charter of the United Nations, and will continue to work with states directly concerned to resolve the relevant disputes in the South China Sea through negotiation and consultation on the basis of respecting historical facts and in accordance with international law, so as to maintain peace and stability in the South China Sea.’’

Brunei, China, Malaysia, the Philippines, Taiwan and Vietnam have all laid claim to parts of the South China Sea. Over $5 trillion worth of trade passes through the area’s resource rich waters every year.

In what appeared to be a warning to the U.S. and other countries in the region conducting freedom of navigation patrols, Xi said confrontation should be replaced by cooperation.

“China will continue the military approach of active national defense,” Xi said in his speech Friday. “We will not seek frequent threats of using military force or show off military strength at other’s doorsteps.”