1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-04-29 19:45:01 +02:00
Find a file
Doug Schaefer b97611936d Patch for Andrew Niefer:
core:
- created new search pattern OrPattern, which returns a match if any of 
its constituent pattens return a match.

To use it, do something like:
OrPattern orPattern = new OrPattern();
orPattern.addPattern( SearchEngine.createSearchPattern( "::NS::B::e", 
ENUM, REFERENCES, true ) );
orPattern.addPattern( SearchEngine.createSearchPattern( "Hea*", CLASS, 
DECLARATIONS, true ) );

Searching for all occurences of something now uses the OrPattern. ie, 
SearchEngine.createSearchPattern( "A", TYPE, ALL_OCCURENCES, true );
is the same as
OrPattern orPattern = new OrPattern();
orPattern.addPattern( SearchEngine.createSearchPattern( "f", FUNCTION, 
DECLARATIONS, true ) );
orPattern.addPattern( SearchEngine.createSearchPattern( "f", FUNCTION, 
REFERENCES, true ) );
orPattern.addPattern( SearchEngine.createSearchPattern( "f", FUNCTION, 
DEFINITIONS, true ) );

For large projects this is much more efficient than the old method of 
finding all occurences

core.tests:
- added ClassDeclarationPatternTests.testAllOccurences
- added OtherPatternTests.testOrPattern
2003-08-07 14:52:18 +00:00
core Patch for Andrew Niefer: 2003-08-07 14:52:18 +00:00
debug update. 2003-08-07 03:32:15 +00:00
doc/org.eclipse.cdt.doc.user July 25, 2003 delivery 2003-07-25 16:32:44 +00:00
launch/org.eclipse.cdt.launch 2003-08-05 Mikhail Khodjaiants 2003-08-05 17:06:19 +00:00
releng *** empty log message *** 2003-07-25 20:17:57 +00:00