<!ELEMENT extension (consolePatternMatchListener*)>
<!ATTLIST extension
point CDATA #REQUIRED
id CDATA #IMPLIED
name CDATA #IMPLIED>
<!ELEMENT consolePatternMatchListener (enablement)>
<!ATTLIST consolePatternMatchListener
id CDATA #REQUIRED
class CDATA #REQUIRED
regex CDATA #REQUIRED
flags CDATA #IMPLIED
qualifier CDATA #IMPLIED>
IPatternMatchListenerDelegate
java.util.regex.Pattern
and should be specified as Strings (eg "Pattern.MULTILINE" or "MULTILINE")regex
. When a line is found containing this expression, a search is performed from the beginning of the line for this pattern matcher's complete regex
. Use of this attribute is optional but can greatly improve performance as lines not containing this expression are disqualified from the search. Since 3.2, this attribute supports string variable substitution.<extension point="org.eclipse.ui.console.consolePatternMatchListeners"> <consolePatternMatchListener class="com.example.ExampleConsolePatternMatcher" id="com.example.ExampleConsolePatternMatcher" regex=".*foo.*"> <enablement> <test property="org.eclipse.ui.console.consoleTypeTest" value="exampleConsole"/> </enablement> </consolePatternMatchListener> </extension>In the above example, the contributed console pattern matcher will be used for consoles with a type of "exampleConsole."
IConsole.getType()
. The property tester's identifier is org.eclipse.ui.console.consoleTypeTest
.
Copyright (c) 2000, 2005 IBM Corporation and others.
This program and the accompanying materials are made
available under the terms of the Eclipse Public License 2.0 which
accompanies this distribution, and is available at
https://www.eclipse.org/legal/epl-v20.html/
SPDX-License-Identifier: EPL-2.0