| |
| |
Preface | |
| |
| |
Acknowledgments | |
| |
| |
About this book | |
| |
| |
| |
Getting started with IDEA | |
| |
| |
| |
Installing and running IDEA | |
| |
| |
Downloading the latest version | |
| |
| |
Installing IDEA | |
| |
| |
Running IDEA for the first time | |
| |
| |
| |
Reviewing the IDEA interface | |
| |
| |
The main IDEA workspace | |
| |
| |
The main menu bar | |
| |
| |
The IDEA toolbar | |
| |
| |
The source code editor | |
| |
| |
The tool windows | |
| |
| |
| |
Implementing "Hello, World" | |
| |
| |
Creating a project | |
| |
| |
Making a Java class | |
| |
| |
Building the project | |
| |
| |
Running the project | |
| |
| |
| |
The plot thickens | |
| |
| |
Welcome to ACME Incorporated | |
| |
| |
Starting the ACME project | |
| |
| |
| |
Summary | |
| |
| |
| |
Introducing the IDEA editor | |
| |
| |
| |
Exploring the IDEA interface | |
| |
| |
Hanging out in the gutter | |
| |
| |
Using the marker bar | |
| |
| |
Using the editor tabs | |
| |
| |
Exploring the status bar | |
| |
| |
Exploring the tool windows | |
| |
| |
| |
Using the IDEA editor | |
| |
| |
Writing the first ACME classes and interfaces | |
| |
| |
Opening files into the editor | |
| |
| |
Saving your work | |
| |
| |
Printing your file | |
| |
| |
Navigating in the editor | |
| |
| |
Making text selections | |
| |
| |
Using IDEA's undo and redo mechanism | |
| |
| |
Cutting, copying, and pasting | |
| |
| |
Searching for and replacing text | |
| |
| |
| |
Summary | |
| |
| |
| |
Using the IDEA editor | |
| |
| |
| |
What makes IDEA the intelligent editor? | |
| |
| |
| |
Using code folding | |
| |
| |
| |
Navigating through your Java code | |
| |
| |
Navigating between methods | |
| |
| |
Navigating to a symbol's declaration | |
| |
| |
Navigating to a symbol by name | |
| |
| |
Navigating with the structure view pop-up | |
| |
| |
Navigating to an overridden/implemented or overriding/implementing method | |
| |
| |
| |
Analyzing your Java code in real-time | |
| |
| |
How IDEA alerts you to problems in your code | |
| |
| |
Monitoring the status of the current document | |
| |
| |
Navigating between problems in the current file | |
| |
| |
Controlling the reparse delay | |
| |
| |
Configuring IDEA's warning levels | |
| |
| |
| |
Getting help from the JavaDoc and API references | |
| |
| |
Viewing method parameters | |
| |
| |
Viewing the JavaDoc | |
| |
| |
Creating JavaDoc comments | |
| |
| |
Generating your project's JavaDoc reference | |
| |
| |
| |
Code completion | |
| |
| |
Using IDEA's code-completion features to do your work for you | |
| |
| |
Completing brackets, braces, parentheses, and quotation marks with smart completion | |
| |
| |
Commenting out code | |
| |
| |
Reformatting code | |
| |
| |
Customizing IDEA's code completion settings | |
| |
| |
| |
Using IDEA's code-generation tools | |
| |
| |
Generating constructors | |
| |
| |
Generating accessor and mutator methods | |
| |
| |
Generating hashCode and equals methods | |
| |
| |
Overriding methods in your superclass | |
| |
| |
Implementing methods of an interface | |
| |
| |
Creating delegation methods | |
| |
| |
Enclosing a block of code | |
| |
| |
Customizing code generated by IDEA | |
| |
| |
| |
Programming by intention | |
| |
| |
What are intention actions? | |
| |
| |
Why and when IDEA suggests intention actions | |
| |
| |
Using intention actions to fix errors | |
| |
| |
Using intention actions for code completion | |
| |
| |
Choosing an intention action to execute | |
| |
| |
Disabling intention alerts | |
| |
| |
Exploring some common intention actions | |
| |
| |
| |
Continuing the ACME project | |
| |
| |
| |
Summary | |
| |
| |
| |
Managing projects | |
| |
| |
| |
Understanding IDEA's project strategy | |
| |
| |
Examining the IDEA project hierarchy | |
| |
| |
Selecting different types of modules | |
| |
| |
Selecting a project structure | |
| |
| |
| |
Working with projects | |
| |
| |
Creating a new project | |
| |
| |
Managing project settings | |
| |
| |
Working with project files | |
| |
| |
| |
Working with modules | |
| |
| |
Managing project modules | |
| |
| |
Creating a Java module with the module wizard | |
| |
| |
Managing Java module settings | |
| |
| |
| |
Working with libraries | |
| |
| |
Understanding library basics | |
| |
| |
Adding libraries to the project | |
| |
| |
Migrating projects from IDEA 3.x | |
| |
| |
Sharing projects with others | |
| |
| |
Using path variables | |
| |
| |
| |
Using the Project tool window | |
| |
| |
Understanding the Project and Packages views | |
| |
| |
Configuring the Project window | |
| |
| |
| |
Summary | |
| |
| |
| |
Building and running applications | |
| |
| |
| |
Building a project | |
| |
| |
How IDEA builds your project | |
| |
| |
Setting up a compiler | |
| |
| |
Building an application under IDEA | |
| |
| |
Reviewing the results of the build | |
| |
| |
| |
Extending IDEA's build system with Ant | |
| |
| |
Introducing Ant | |
| |
| |
Improving your build process with Ant | |
| |
| |
Working with Ant build files | |
| |
| |
Executing Ant targets | |
| |
| |
Following Ant's progress in the Messages window | |
| |
| |
Controlling Ant's behavior | |
| |
| |
| |
Running your project | |
| |
| |
Managing Run/Debug configuration profiles | |
| |
| |
Executing a Run configuration | |
| |
| |
Using the Run window console | |
| |
| |
| |
Expanding the ACME project | |
| |
| |
Adding a library to the ACME project | |
| |
| |
Improving and running the ACME project | |
| |
| |
| |
Summary | |
| |
| |
| |
Debugging applications | |
| |
| |
| |
Introducing the debugging process | |
| |
| |
Finding and fixing bugs with a debugger | |
| |
| |
Preparing your code for debugging | |
| |
| |
Debugging your source code | |
| |
| |
| |
Working with breakpoints | |
| |
| |
Managing breakpoints | |
| |
| |
Working with line number breakpoints | |
| |
| |
Working with method breakpoints | |
| |
| |
Working with exception breakpoints | |
| |
| |
Working with field watchpoints | |
| |
| |
Setting conditional breakpoints | |
| |
| |
Configuring breakpoint actions | |
| |
| |
| |
Debugging an application | |
| |
| |
Executing an application under the debugger | |
| |
| |
Debugging an application on a remote server | |
| |
| |
Stepping through the program | |
| |
| |
Working with threads | |
| |
| |
| |
Viewing runtime data in the debugger | |
| |
| |
Understanding the Java call stack | |
| |
| |
Inspecting a stack frame | |
| |
| |
Working with watches | |
| |
| |
Altering your program while debugging | |
| |
| |
| |
Configuring the debugger | |
| |
| |
Managing display preferences | |
| |
| |
Limiting the scope of debugging | |
| |
| |
Customizing the data display view | |
| |
| |
Improving the speed of the debugger | |
| |
| |
| |
Improving the quality of the ACME project | |
| |
| |
| |
Summary | |
| |
| |
| |
Testing applications with JUnit | |
| |
| |
| |
Testing applications with JUnit | |
| |
| |
Understanding the JUnit philosophy | |
| |
| |
Exploring the JUnit API | |
| |
| |
| |
Adding test cases to your project | |
| |
| |
Creating a test case from a file template | |
| |
| |
Adding the JUnit library to your Classpath | |
| |
| |
| |
Running test cases in IDEA | |
| |
| |
Creating a Run/Debug configuration for your test | |
| |
| |
Running your unit test configuration | |
| |
| |
| |
Working with IDEA's JUnit test runner | |
| |
| |
Exploring the JUnit tool window | |
| |
| |
Monitoring testing progress | |
| |
| |
Managing the testing session | |
| |
| |
Analyzing test results | |
| |
| |
| |
Improving the quality of the ACME project | |
| |
| |
| |
Summary | |
| |
| |
| |
Using version control | |
| |
| |
| |
Configuring your project for version control | |
| |
| |
Understanding version control basics | |
| |
| |
Enabling version control support in IDEA | |
| |
| |
Configuring IDEA to use CVS | |
| |
| |
Configuring other types of version control systems | |
| |
| |
| |
Working with files under CVS | |
| |
| |
Retrieving files from the repository | |
| |
| |
Working with files under CVS control | |
| |
| |
Committing your changes | |
| |
| |
Working with branches and tags | |
| |
| |
Viewing change history | |
| |
| |
| |
Using IDEA's Local History | |
| |
| |
Understanding IDEA's Local History | |
| |
| |
How IDEA tracks your changes | |
| |
| |
Exploring your Local History | |
| |
| |
| |
Summary | |
| |
| |
| |
Analyzing and refactoring applications | |
| |
| |
| |
Analyzing your code | |
| |
| |
Tracking down dependencies | |
| |
| |
Exploring code with the Structure view | |
| |
| |
Exploring the code hierarchy | |
| |
| |
| |
Locating potential problems with the code inspector | |
| |
| |
Launching the inspector | |
| |
| |
Specifying inspections to perform | |
| |
| |
Viewing the inspection results | |
| |
| |
| |
Other advanced code analysis features | |
| |
| |
Using Structural Search and Replace | |
| |
| |
Analyzing dependencies | |
| |
| |
Locating duplicate code | |
| |
| |
| |
Improving code design through refactoring | |
| |
| |
Performing a refactoring | |
| |
| |
Renaming code symbols to improve readability | |
| |
| |
Refactoring to improve class or package organization | |
| |
| |
Working with fields, variables, and constants | |
| |
| |
Refactoring method calls to improve usability | |
| |
| |
Restructuring class hierarchies | |
| |
| |
Migrating source code to new package or class names | |
| |
| |
| |
Summary | |
| |
| |
| |
Developing Swing applications | |
| |
| |
| |
Understanding the GUI Designer | |
| |
| |
The GUI-building process | |
| |
| |
Working with the user interface | |
| |
| |
| |
Working with forms | |
| |
| |
Creating a new form | |
| |
| |
Placing components into the workspace | |
| |
| |
Setting component properties | |
| |
| |
Laying out a form | |
| |
| |
| |
Designing an ACME GUI | |
| |
| |
Creating a new GUI form in IDEA | |
| |
| |
Manually creating the basic layout | |
| |
| |
Applying the grid layout | |
| |
| |
Setting component properties | |
| |
| |
Touching up the final interface | |
| |
| |
| |
Understanding properties | |
| |
| |
Spanning rows and columns | |
| |
| |
Setting an anchor point (cell alignment) | |
| |
| |
Using spacers to control layout | |
| |
| |
Controlling the grid spacing | |
| |
| |
Setting container margins | |
| |
| |
Setting sizing policies | |
| |
| |
Setting fill policies | |
| |
| |
Adding borders | |
| |
| |
| |
Adding functionality to forms | |
| |
| |
Binding forms and their components | |
| |
| |
Creating a constructor | |
| |
| |
Generating getter/setter methods for fields bound to data | |
| |
| |
Invoking your form | |
| |
| |
| |
Adding functionality to the ACME GUI | |
| |
| |
Binding the ACME GUI to a form class | |
| |
| |
Creating a constructor | |
| |
| |
Implementing the Convert functionality | |
| |
| |
Providing an entry point | |
| |
| |
| |
Building and running your form | |
| |
| |
Generating the GUI to binary or source | |
| |
| |
Including the forms library | |
| |
| |
Compiling with Ant. | |
| |
| |
| |
Summary | |
| |
| |
| |
Developing J2EE applications | |
| |
| |
| |
Working with web applications | |
| |
| |
Understanding web modules | |
| |
| |
Creating a new web module | |
| |
| |
Configuring a web module | |
| |
| |
Using the J2EE tab of the Project tool window | |
| |
| |
Working with servlets and filters | |
| |
| |
Working with JavaServer Pages | |
| |
| |
Implementing an ACME web application | |
| |
| |
| |
Working with EJBs | |
| |
| |
Working with EJB modules | |
| |
| |
Working with J2EE application modules | |
| |
| |
| |
Understanding application server integration | |
| |
| |
Integrating IDEA with Tomcat | |
| |
| |
Integrating IDEA with WebLogic | |
| |
| |
Integrating IDEA with generic application servers | |
| |
| |
Installing Tomcat to support the ACME web application | |
| |
| |
| |
Running and debugging web applications | |
| |
| |
Running your web application | |
| |
| |
Running the ACME web application on Tomcat | |
| |
| |
Debugging your web application | |
| |
| |
| |
Working with web content (IDEA 5.0 and higher) | |
| |
| |
Supported file types and content | |
| |
| |
Basic editor features | |
| |
| |
Coding assistance for web content | |
| |
| |
Navigating through web content files | |
| |
| |
Refactoring web content | |
| |
| |
| |
Summary | |
| |
| |
| |
Customizing IDEA | |
| |
| |
| |
Configuring IDEA's options and settings | |
| |
| |
Customizing the interface | |
| |
| |
| |
Customizing your code style | |
| |
| |
How IDEA uses your code style | |
| |
| |
Variable naming and general formatting | |
| |
| |
Controlling indentation and braces | |
| |
| |
Controlling whitespace | |
| |
| |
Customizing import statements | |
| |
| |
Controlling line wraps | |
| |
| |
Adherence to a code standard-made easy | |
| |
| |
| |
Customizing your color scheme | |
| |
| |
How IDEA uses color schemes | |
| |
| |
Editor properties | |
| |
| |
Changing font settings | |
| |
| |
| |
Customizing keyboard shortcuts | |
| |
| |
Using keyboard shortcuts | |
| |
| |
Navigating the interface with the keyboard | |
| |
| |
Selecting a keymap | |
| |
| |
Creating a new keymap | |
| |
| |
Defining keyboard shortcuts | |
| |
| |
Defining mouse shortcuts | |
| |
| |
Defining quick lists | |
| |
| |
| |
Working with non-Java file types | |
| |
| |
Modifying file types settings | |
| |
| |
Registering file extensions | |
| |
| |
Creating a custom file type | |
| |
| |
| |
Using file templates | |
| |
| |
Creating a new file from a template | |
| |
| |
Working with template includes | |
| |
| |
| |
Increasing the amount of memory allocated to IDEA | |
| |
| |
| |
Summary | |
| |
| |
| |
Extending IDEA | |
| |
| |
| |
Working with bookmarks | |
| |
| |
Placing and using numbered bookmarks | |
| |
| |
Placing and using anonymous bookmarks | |
| |
| |
Managing your bookmarks collection | |
| |
| |
| |
Working with To Do lists | |
| |
| |
Creating custom ToDo list items | |
| |
| |
Using ToDo filters | |
| |
| |
| |
The IDEA Commander | |
| |
| |
Working with the IDEA Commander | |
| |
| |
File operations | |
| |
| |
| |
Integrating external tools with IDEA | |
| |
| |
Managing the tool list | |
| |
| |
Accessing external tools from within IDEA | |
| |
| |
Reacting to the results of external tools | |
| |
| |
| |
Using IDEA's open APIs | |
| |
| |
| |
Summary | |
| |
| |
| |
Getting help with IDEA | |
| |
| |
Index | |