Really ugly hack to handle interfaces in unmarshalling.