コード例 #1
0
ファイル: BenchBrewing.cs プロジェクト: kuffert/Brewers-Bench
 /// <summary>
 /// Retrieves the Bench Brewing instance, constructing a new one if the instance
 /// does not yet exist.
 /// </summary>
 /// <returns></returns>
 public static BenchBrewing GetBenchBrewingInstance()
 {
     if (instance == null)
     {
         instance = new BenchBrewing();
     }
     return(instance);
 }
コード例 #2
0
 /// <summary>
 /// Standard Constructor for the Facade BrewersBenchSystem.
 /// </summary>
 private BrewersBenchSystem()
 {
     benchStock   = BenchStock.GetBenchStockInstance();
     benchBrewing = BenchBrewing.GetBenchBrewingInstance();
     // need to init benchBrewing as Singleton
 }