/// <summary>
        /// Gets the selection.
        /// </summary>
        /// <param name="ed">The ed.</param>
        /// <param name="options">The options.</param>
        /// <param name="filter">The filter.</param>
        /// <param name="classFilter">The class filter.</param>
        /// <returns></returns>
        public static PromptSelectionResult GetSelection(this Editor ed, PromptSelectionOptions options, SelectionFilter filter, AllowedClassFilter classFilter)
        {
            AllowedClassPtrs   = classFilter.AllowedClassPtrs;
            ed.SelectionAdded += new SelectionAddedEventHandler(ed_ClassFilterSelectionAdded);

            try
            {
                if (options != null)
                {
                    if (filter != null)
                    {
                        return(ed.GetSelection(options, filter));
                    }
                    else
                    {
                        return(ed.GetSelection(options));
                    }
                }
                else if (filter != null)
                {
                    return(ed.GetSelection(filter));
                }
                else
                {
                    return(ed.GetSelection());
                }
            }
            finally
            {
                ed.SelectionAdded -= new SelectionAddedEventHandler(ed_ClassFilterSelectionAdded);
            }
        }
 /// <summary>
 /// Gets the selection.
 /// </summary>
 /// <param name="ed">The ed.</param>
 /// <param name="classFilter">The class filter.</param>
 /// <returns></returns>
 public static PromptSelectionResult GetSelection(this Editor ed, AllowedClassFilter classFilter)
 {
     return(ed.GetSelection((PromptSelectionOptions)null, (SelectionFilter)null, classFilter));
 }