internal ShelfModule BuildModule() { ShelfModule module = null; switch (EID) { case 1: module = new ShelfModuleOne() { GroupInfo = GroupInfo }; break; case 2: module = new ShelfModuleTwo() { GroupInfos = GroupInfos }; break; case 3: module = new ShelfModuleThree() { GroupInfo = GroupInfo }; break; case 4: module = new ShelfModuleFour() { GroupInfos = GroupInfos }; break; case 5: module = new ShelfModuleFive { GroupInfos = GroupInfos }; break; } if (module == null) { throw new ArgumentException(); } return(module); }
internal ShelfModule BuildModule() { ShelfModule module = null; switch (EID) { case 1: module = new ShelfModuleOne() { GroupInfo = GroupInfo }; break; case 2: module = new ShelfModuleTwo() { GroupInfos = GroupInfos }; break; case 3: module = new ShelfModuleThree() { GroupInfo = GroupInfo }; break; case 4: module = new ShelfModuleFour() { GroupInfos = GroupInfos }; break; case 5: module = new ShelfModuleFive { GroupInfos = GroupInfos }; break; } if (module == null) throw new ArgumentException(); return module; }