restructuring with some class