finalizing the structure