public BraceCompletionSession(
     ITextView textView, ITextBuffer subjectBuffer,
     SnapshotPoint openingPoint, char openingBrace, char closingBrace, ITextUndoHistory undoHistory,
     IEditorOperationsFactoryService editorOperationsFactoryService, IBraceCompletionService service,
     IThreadingContext threadingContext)
     : base(threadingContext, assertIsForeground: true)
 {
     this.TextView      = textView;
     this.SubjectBuffer = subjectBuffer;
     this.OpeningBrace  = openingBrace;
     this.ClosingBrace  = closingBrace;
     this.ClosingPoint  = SubjectBuffer.CurrentSnapshot.CreateTrackingPoint(openingPoint.Position, PointTrackingMode.Positive);
     _undoHistory       = undoHistory;
     _editorOperations  = editorOperationsFactoryService.GetEditorOperations(textView);
     _service           = service;
 }
 public BraceCompletionSession(
     ITextView textView, ITextBuffer subjectBuffer,
     SnapshotPoint openingPoint, char openingBrace, char closingBrace, ITextUndoHistory undoHistory,
     IEditorOperationsFactoryService editorOperationsFactoryService, IBraceCompletionService service,
     IGlobalOptionService globalOptions, IThreadingContext threadingContext)
 {
     TextView          = textView;
     SubjectBuffer     = subjectBuffer;
     OpeningBrace      = openingBrace;
     ClosingBrace      = closingBrace;
     ClosingPoint      = SubjectBuffer.CurrentSnapshot.CreateTrackingPoint(openingPoint.Position, PointTrackingMode.Positive);
     _undoHistory      = undoHistory;
     _editorOperations = editorOperationsFactoryService.GetEditorOperations(textView);
     _service          = service;
     _threadingContext = threadingContext;
     _globalOptions    = globalOptions;
 }