namespace Microsoft.VisualStudio.Text.PatternMatching { /// /// Provides instances of a for a given /// search string and creation options. /// /// This is a MEF component part, and should be imported as follows: /// [Import] /// IPatternMatcherFactory factory = null; /// public interface IPatternMatcherFactory { /// /// Gets an given a search pattern and search options. /// /// Describes the search pattern that candidate strings will be compared against for relevancy. /// Defines parameters for what should be considered relevant in a match. /// /// This pattern matcher uses the concepts of a 'Pattern' and a 'Candidate' to to differentiate between what the user types to search /// and what the system compares against. The pattern and some are specified in here in order to obtain an . /// /// The user can then call repeatedly with multiple candidates to filter out non-matches, and obtain sortable objects to help decide /// what the user actually wanted. /// /// A few examples are useful here. Suppose the user obtains an IPatternMatcher using the following: /// Pattern = "PatMat" /// /// The following calls to TryMatch could expect these results: /// Candidate = "PatternMatcher" /// Returns a match containing . /// /// Candidate = "IPatternMatcher" /// Returns a match containing /// /// Candidate = "patmat" /// Returns a match containing , but will be false. /// /// Candidate = "Not A Match" /// Returns . /// /// To determine sort order, call . /// IPatternMatcher CreatePatternMatcher(string pattern, PatternMatcherCreationOptions creationOptions); } }