Example #1
0
 private BowlingFrame getActiveFrame()
 {
     if (activeFrame != null && activeFrame.IsDone)
     {
         closeActiveFrame();
     }
     return(activeFrame ?? (activeFrame = new BowlingFrame()));
 }
Example #2
0
 private void closeActiveFrame()
 {
     if (activeFrame == null)
     {
         return;
     }
     Frames.Add(activeFrame);
     activeFrame = null;
 }
 private void FinalizeFrame()
 {
     this._finishedFrames.Add(this._currentFrame);
     this._currentFrame = new BowlingFrame();
 }