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