Restructure classes