Tailoring the structure of nanomaterials formed by light-induced synthesis