Package org.eclipse.jface.text
Interface MultiStringMatcher.Builder
- Enclosing class:
- MultiStringMatcher
public static interface MultiStringMatcher.Builder
A Builder for creating a
MultiStringMatcher
.-
Method Summary
Modifier and TypeMethodDescriptionAdds search strings to be looked for.build()
Returns theMultiStringMatcher
built by this builder.
-
Method Details
-
add
Adds search strings to be looked for.null
and empty strings in the arguments are ignored.- Parameters:
searchStrings
- to add to be looked for by the matcher.- Returns:
- this
- Throws:
IllegalStateException
- if theMultiStringMatcher
was already built.
-
build
MultiStringMatcher build()Returns theMultiStringMatcher
built by this builder.Note that a
MultiStringMatcher.Builder
instance can build only oneMultiStringMatcher
instance. This is by design; otherwise the builder would have to store all the searchStrings somewhere, which may be rather memory intensive if a lot of search strings are added.- Returns:
- the
MultiStringMatcher
- Throws:
IllegalStateException
- if theMultiStringMatcher
was already built.
-