China strongly warned a high-level Japanese official around late June that Tokyo should not send Self-Defense Forces to join U.S. operations that test the freedom of navigation in the disputed South China Sea, diplomatic sources said Saturday.

Japan will “cross a red line” if SDF vessels take part in so-called freedom of navigation operations, Ambassador Cheng Yonghua told the official, the sources said. Cheng even hinted at military action.

The warning was issued not long before an international tribunal ruled on conflicting claims in those waters.

The Permanent Court of Arbitration in The Hague ruled July 12 that China’s sweeping claims to most of the South China Sea, which overlap with those of the Philippines and other neighboring countries, have no legal basis. China has rejected the ruling, but the United States and Japan have called on Beijing to respect it.

China is expected to continue warning Japan. Chinese Foreign Minister Wang Yi will likely meet Foreign Minister Fumio Kishida in Tokyo on the fringes of a ministerial meeting between Japan, China and South Korea later this month.

The Japanese government has no plans to join the freedom of navigation operations, in which the United States since October has sent warships near artificial islands that China has built in the South China Sea. But it has left room for sending SDF ships to the disputed waters to protect U.S. ships under new security laws that have expanded SDF roles overseas.

Officials have said Japan can dispatch the SDF as long as the mission contributes to the country’s defense and does not violate restrictions imposed by the war-renouncing Constitution.

According to the sources, Cheng told the high-level official in Tokyo that Japan should not take part in a “joint military action with U.S. forces that is aimed at excluding China in the South China Sea.”

He also said China “will not concede on sovereignty issues and is not afraid of military provocations.”

The comments were apparently aimed at preventing Tokyo from interfering in the territorial dispute in the South China Sea, where Japan has no direct claims.

The official told Cheng that Japan has no plans to join the U.S. operations but strongly criticized China’s construction of outposts in the waters for military purposes.

The exchange took place amid heightened tensions sparked by a territorial dispute between China and Japan over the Japanese-controlled Senkaku Islands in the East China Sea, which China calls the Diaoyus.

On June 9, a Chinese naval ship sailed into waters just outside Japanese territorial waters around the islands, leading Japan to lodge a protest against the unprecedented move.

Then-Vice Foreign Minister Akitaka Saiki summoned Cheng to the ministry and told him Japan would take “necessary actions” if Chinese naval ships entered its territorial waters. This may indicate that such military intrusion is Japan’s “red line” that would lead it to mobilize its Maritime Self-Defense Force.