Canadian ex-diplomat detained in China, official confirms