Consolidating the Struct attributes in classes