Mr. Qin said that the visit by Mr. Abe “betrayed” previous agreements and understandings that had been reached by China and Japan and damaged “the political foundation between the two countries.”

“It is Abe himself who closed the door of conversation with Chinese leaders,” Mr. Qin added.

The Yasukuni shrine, an institution of the Shinto religion, honors ordinary soldiers who died fighting in World War II but has long generated enmity among the Chinese because among its honorees are Class A war criminals. These former officials were convicted by the International Military Tribunal for the Far East after Japan’s defeat in the war, and the Class A designation means that they had taken part in top-level decisions on the war’s execution.

“Since Abe stepped into power, he has made many mistakes in his relations with China, especially in his visit to the shrine where many Class A war criminals are worshiped,” Mr. Qin said. “They are the historic sinners of the Far East Military Tribunal. Their hands are stained with the blood of the people of victimized nations. They are fascists. They are the Nazis of Asia.”

Mr. Abe, in formal dress, visited the shrine on Thursday, with news helicopters flying overhead. The event was broadcast live on television, though TV cameras were not allowed into the shrine’s inner sanctum.