In this article, we will discuss how to search files in Eclipse IDE. Files like .java, .xml or .jsp can be easily searched using these shortcut keys
Eclipse files convention standards :
- All files ending .java extension are grouped as Java Types
- Whereas all other files extension like .jsp, .js, .xml, .xslt, .xsd, etc. are collectively referred as resources, which includes .java also
Shortcut commands in Eclipse IDE :
- CTRL + SHIFT + T –> used to search all Java type files (Open Type)
- CTRL + SHIFT + R –> used to search all types of files (Open Resource)
- CTRL + H –> opens dialog box which provides number of options (Search)
Let’s understand each one with simple example in Eclipse IDE,
1. To find Java files
- Step 1: press CTRL + SHIFT + T simultaneously
- Step 2: enter Java filename to be searched
- Step 3: Wildcards can also be used, in case if we don’t remember full name of the Java file
- Note: starting letter of each word typed in Capital helps to find Java files
- Like, for example, to find RemovingAllEntriesGreaterThanByComparingKeys.java file
- To search above file, just type RAEGTBCK after pressing CTRL + SHIFT + T simultaneously
2. To find all types of resources or files
- Step 1: press CTRL + SHIFT + R simultaneously
- Step 2: enter any filename to be searched
- Step 3: Wildcards can also be used, in case if we don’t remember full name of the file
- Note: starting letter of each word typed in Capital helps to find any resource files
- Like, for example, to find SpringApplicationContext.xml or ReadFromFileInJava.java file
- To search above file, just type SAC or RFFIJ after pressing CTRL + SHIFT + R simultaneously
3. Searching files from Search (CTRL + H) menu
This helps to find any phrase from files
- Step 1: press CTRL + H simultaneously
- Step 2: Wildcards can also be used, in case if we don’t remember full name of the file along with their extensions
4. Useful Eclipse IDE shortcuts :
- Eclipse IDE – How to show line numbers ?
- Eclipse IDE – How to GO TO any line number directly ?
- Eclipse IDE – How to remove unused imports ?
- Eclipse IDE – How to clean project ?
- Eclipse IDE – How to build Java project automatically ?
- Eclipse IDE – How to comment and un-comment line & block ?
- Eclipse IDE – How to generate constructor using fields ?
- Eclipse IDE – How to generate getters and setters ?
- Eclipse IDE – How to search files ?
- Eclipse IDE – How to locate methods in Java file ?
- Eclipse IDE – How to open editor using CTRL + E ?
- Eclipse IDE – Java compiler compliance level issue
Related Articles:
- Apache Maven – Introduction
- Apache Maven – Install on Windows 7 OS
- Apache Maven – Settings.xml explanation
- Apache Maven – Proxy setting explanation
- Apache Maven – pom.xml explanation
- Apache Maven – Plugins explanation
- Apache Maven – Changing default Maven repository location in Windows 7 OS
- Apache Maven – Local, Central and Remote Repositories
- Apache Maven – Installing custom library into local repository
- Apache Maven – Transitive dependencies explanation
- Apache Maven – Exclusion of Transitive dependencies
- Apache Maven – Dependency Scopes
- Apache Maven – Skipping unit test using surefire plugin
- Apache Maven – Exclusions and Inclusions of unit test
- Apache Maven – offline execution
- Apache Maven – Co-ordinates explained
- Eclipse + Maven – Integration
- Eclipse + Maven – How to import Maven project with pom.xml ?
- Eclipse + Maven – Setting M2_REPO classpath variable in IDE
- Eclipse + Maven – M2_REPO is Non Modifiable
- Eclipse + Maven – Creating and exploring projects using archetypes
- Eclipse + Maven – Converting Web project to Maven project
- Eclipse + Maven – mvn eclipse:eclipse command
- Eclipse + Maven – Plugin execution not covered by lifecycle configuration
References:
- https://help.eclipse.org/neon/index.jsp?topic=%2Forg.eclipse.platform.doc.user%2Ftasks%2Ftasks-84b.htm
- https://help.eclipse.org/neon/index.jsp?topic=%2Forg.eclipse.platform.doc.user%2Ftasks%2Ftasks-84b.htm
Happy Coding !!
Happy Learning !!