TOKYO — Japan’s prime minister, Shinzo Abe, did not take long to recover from the shock of Donald J. Trump’s victory. By Thursday morning — Wednesday night in the United States — Mr. Abe had called the president-elect and arranged to meet him in New York next week.

In hustling to be one of the first world leaders to meet with Mr. Trump since the election, Mr. Abe is seeking to gauge the sincerity of Mr. Trump’s campaign rhetoric on Japan. As a candidate, he repeatedly excoriated the country, along with other American allies, for not paying what he called its fair share to support American military bases, and he suggested he might withdraw troops unless Japan agreed to pay more.

Mr. Abe will also probably want to discuss the Trans-Pacific Partnership, the trade deal between the United States and several Asian countries, including Japan, that Mr. Trump has said he would consign to the dustbin. The Abe administration considers the pact, which moved closer to ratification on Thursday with approval in Japan’s lower house of Parliament, an important plank in his economic policy.