Example #1
0
 public MemberStrategy()
 {
     //不確定是Member還是Coach K:repository型別
     memberRepository = GenericFactory.CreateInastance <IMemberRepository <Member> >(typeof(MemberRepository));
 }
Example #2
0
 public CoachStrategy()
 {
     Repository = GenericFactory.CreateInastance <ICoachRepository <Coach> >(typeof(CoachRepository));
 }
 public ReserveFacade()
 {
     repository = GenericFactory.CreateInastance <IReserveRepository>(typeof(ReserveRepository));
 }
 public MemberService()
 {  //透過工廠建立實體
     _repository = GenericFactory.CreateInastance <IRepository <Human> >(typeof(GenericRepository <Human>));
 }
Example #5
0
 public TdeeStrategy(double deduct)
 {
     _calculate = GenericFactory.CreateInastance <ICalculate>(typeof(CalculateService), new object[] { deduct });
 }
 public SearchFacade()
 {
     repository = GenericFactory.CreateInastance <ISearchRepository>(typeof(SearchRepository));
 }
Example #7
0
 public NutritionService()
 {
     _repository = GenericFactory.CreateInastance <IRepository <Nutrition> >(typeof(GenericRepository <Nutrition>));
 }
Example #8
0
 public MemberApiController()
 {
     _memberservice    = GenericFactory.CreateInastance <IMemberService>(typeof(MemberService));
     _nutritionservice = GenericFactory.CreateInastance <INutritionService>(typeof(NutritionService));
 }