When being opened up by capitalism, both Japan and China were ruled by declining dynasties. As in Japan, the local mode of production in China was also unable to compete with capitalism. Neither on a commercial, nor above all on a military level was the ruling Manchu dynasty able to resist foreign capitalist penetration. As in Japan, the triumphant march of capitalism did not come through the imposition of a trading capitalist class from within the country, but capitalism was mainly imposed from outside.