Amazing Books
Temporary Blank

Sunday, February 27, 2011

NetBeans The Definitive Guide







Publisher : O'Reilly
ISBN : 0-596-00280-7
Pages : 672

In NetBeans: The Definitive Guide, you'll find out how to use this IDE to its fullest, making your Java programming more efficient and productive than ever before. You'll understand the basics of the IDE, and quickly be utilizing the various editor and explorer windows. You'll also master many of NetBeans advanced features, and be working with XML documents, CVS repositories, Javadoc trees, and web applications, all within the NetBeans framework.

Table of Content
Table of Content .................................................................................................................. i
Preface.............................................................................................................................. viii
Is NetBeans for You? ................................................................................................. viii
Is This Book for You? ................................................................................................. viii
NetBeans and Java ...................................................................................................... ix
NetBeans as the "Visual JDK" .................................................................................... xi
NetBeans as a Tools Platform ................................................................................... xii
NetBeans as an Open Source Community.............................................................. xii
Contents of the Accompanying Sources ................................................................. xiv
Licensing of the Code Examples in This Book ....................................................... xiv
Writing Conventions in This Book............................................................................. xiv
Comments and Questions ......................................................................................... xiv
Acknowledgments........................................................................................................ xv
Chapter 1. Getting and Installing the IDE ....................................................................... 1
1.1 Platforms and Requirements ................................................................................. 1
1.2 Getting and Installing a JDK .................................................................................. 2
1.3 Which IDE Distribution?.......................................................................................... 3
1.4 Installing Binary Distributions ................................................................................ 5
1.5 Building the IDE from Source (Simple Builds) .................................................... 5
1.6 Running the IDE ...................................................................................................... 8
1.7 Updating the IDE Automatically .......................................................................... 14
1.8 You're Now Running NetBeans........................................................................... 15
Chapter 2. Concepts and Paradigms ............................................................................ 16
2.1 NetBeans and the Java Abstract Model of Computing.................................... 16
2.2 Explorer................................................................................................................... 17
2.3 Creating Packages and Classes......................................................................... 33
2.4 Services .................................................................................................................. 36
2.5 Workspaces............................................................................................................ 38
2.6 Project Management............................................................................................. 40
2.7 Object Browser ...................................................................................................... 42
2.8 Summary................................................................................................................. 45
Chapter 3. Working with the Source Editor .................................................................. 46
3.1 Why Learn a New Editor? .................................................................................... 46
3.2 Opening the Source Editor................................................................................... 46
3.3 Context Menus....................................................................................................... 47
3.4 Closing the Source Editor .................................................................................... 47
3.5 Code Completion................................................................................................... 47
3.6 Editor Colorings ..................................................................................................... 51
3.7 Shortcuts................................................................................................................. 52
3.8 Word Matching....................................................................................................... 52
3.9 Indentation Engines and Code Formatting........................................................ 52
3.10 Automatic Edits.................................................................................................... 53
3.11 Other Editor Functionality .................................................................................. 54
3.12 A Simple Example............................................................................................... 55
Chapter 4. Debugging...................................................................................................... 58
4.1 Debugger Types .................................................................................................... 58
4.2 Breakpoint Types................................................................................................... 59
4.3 Adding and Removing Breakpoints .................................................................... 60
4.4 Setting Watches..................................................................................................... 63
4.5 Starting the Debugger........................................................................................... 63
4.6 The Debugger Window......................................................................................... 65
4.7 The Variables View ............................................................................................... 66
4.8 Remote Debugging in NetBeans ........................................................................ 67
Chapter 5. Compilation and Execution Services ......................................................... 70
5.1 Using Custom Compilation and Execution Services........................................ 70
5.2 Associating Services with Java Files.................................................................. 77
5.3 Building with Ant .................................................................................................... 77
Chapter 6. Customizing the Environment..................................................................... 82
6.1 The Setup Wizard.................................................................................................. 82
6.2 The Tools Options Dialog............................................................................... 85
6.3 Configuring Toolbars............................................................................................. 86
6.4 Configuring Menus ................................................................................................ 87
6.5 Configuring Editors................................................................................................ 88
6.6 Command Line Options........................................................................................ 95
6.7 Modules................................................................................................................... 96
Chapter 7. Using Source Control (CVS)..................................................................... 100
7.1 What Is CVS?....................................................................................................... 100
7.2 The How, When, and Why of CVS in NetBeans............................................. 102
7.3 Mounting CVS Sources ...................................................................................... 104
7.4 Exploring Versioned Sources ............................................................................ 105
7.5 Common CVS Operations.................................................................................. 105
7.6 Unexpected Results............................................................................................ 109
7.7 Uncommon CVS Operations ............................................................................. 110
7.8 Mounting a Generic Versioning System........................................................... 110
7.9 One Final Tip........................................................................................................ 112
Chapter 8. GUI Building................................................................................................. 114
8.1 Creating a GUI Frame or Panel ........................................................................ 114
8.2 Adding Components to a GUI Container ......................................................... 116
8.3 Configuring Components.................................................................................... 117
8.4 Building Menus .................................................................................................... 118
8.5 Changing a Container's Layout......................................................................... 119
8.6 Working with Borders.......................................................................................... 119
8.7 Accessibility.......................................................................................................... 120
8.8 Copying a Source Object ................................................................................... 121
8.9 The Connection Wizard...................................................................................... 121
8.10 The GridBagLayout Customizer...................................................................... 122
8.11 Adding Event Handlers..................................................................................... 125
8.12 Using the Code Generation Properties.......................................................... 127
8.13 Working Around Code Generation ................................................................. 129
8.14 Containers Within Containers.......................................................................... 130
8.15 Building Complex GUIs .................................................................................... 131
Chapter 9. JavaBeans ................................................................................................... 133
9.1 Why Should I Make Beans? .............................................................................. 133
9.2 Creating JavaBeans............................................................................................ 133
9.3 Component Palette ............................................................................................. 143
Chapter 10. Using Javadoc........................................................................................... 146
10.1 Javadoc Support in NetBeans......................................................................... 146
10.2 Mounting Javadocs ........................................................................................... 146
10.3 The Javadoc Search Tool................................................................................ 147
10.4 Creating Javadoc .............................................................................................. 149
Chapter 11. Working with XML..................................................................................... 157
11.1 Installing XML Support ..................................................................................... 157
11.2 Overview............................................................................................................. 157
11.3 XML Editors........................................................................................................ 158
11.4 Beyond Editing XML ......................................................................................... 160
11.5 Generating Java Classes................................................................................. 165
Chapter 12. Developing Web Applications................................................................. 173
12.1 Why the IDE Supports Web Application Development ............................... 173
12.2 How the IDE Provides Web Application Support ......................................... 173
12.3 Creating a Web Application ............................................................................. 174
12.4 Working with JSP and HTML Files................................................................. 176
12.5 Advanced Web Applications Features........................................................... 178
12.6 Packaging and Deploying Web Applications ................................................ 180
Chapter 13. Extending NetBeans ................................................................................ 182
13.1 What's Different About NetBeans?................................................................. 182
13.2 The Core and the Open APIs.......................................................................... 183
13.3 NetBeans for Bean Counters .......................................................................... 188
13.4 Getting and Installing the Open APIs Support Module................................ 188
13.5 Life Is Change.................................................................................................... 189
13.6 Source Code for the Examples ....................................................................... 189
Chapter 14. Understanding the NetBeans APIs........................................................ 190
14.1 Design Philosophy of NetBeans ..................................................................... 190
14.2 User-Level Customization................................................................................ 201
14.3 Modules—Overview.......................................................................................... 204
14.4 Interacting with the IDE .................................................................................... 208
Chapter 15. The Open APIs ......................................................................................... 211
15.1 APIs versus Core versus Modules ................................................................. 211
15.2 Service Provider Interfaces and Client APIs................................................. 213
15.3 Overview of the APIs and Their Purposes .................................................... 213
15.4 Modules, JARs, and Class Loaders ............................................................... 241
15.5 Threading, Deadlocks, andHow to Avoid Them........................................... 244
Chapter 16. Developing Modules—the New Module Wizard .................................. 247
16.1 The HelloWorld Module.................................................................................... 247
Chapter 17. Internals of the Running IDE................................................................... 251
17.1 The Activated Node(s)...................................................................................... 251
17.2 Cookies............................................................................................................... 251
17.3 A Peek under the Hood.................................................................................... 252
17.4 Touring NetBeans with the Bean Browser .................................................... 253
17.5 Data Objects, Nodes, and Cookies ................................................................ 255
17.6 Filesystems and the Repository...................................................................... 256
17.7 Services .............................................................................................................. 256
17.8 Lookup ................................................................................................................ 257
17.9 Options................................................................................................................ 258
17.10 UI Components ............................................................................................... 259
17.11 Localization ...................................................................................................... 266
17.12 Wizards............................................................................................................. 266
17.13 Jumping-off Places ......................................................................................... 267
17.14 Special Folders in the System Filesystem .................................................. 268
Chapter 18. Creating the QuickPanel Module ........................................................... 271
18.1 Abstractions Covered in This Chapter ........................................................... 271
18.2 Creating the Project Files Drop-Down ........................................................... 272
18.3 FilterNode—Filtering Which Children of a Node Are Displayed ................ 276
18.4 Creating the Methods Drop-Down.................................................................. 278
18.5 Improving the Methods Drop-Down................................................................ 280
18.6 Creating the Module.......................................................................................... 284
18.7 A Little Homework ............................................................................................. 287
Chapter 19. A Mail-Based Filesystem......................................................................... 288
19.1 Building a Mail Reader in the NetBeans Paradigm...................................... 288
19.2 Implementing MailFileSystem Using AbstractFileSystem and JavaMail .. 288
19.3 Creating Folder Objects for Attachments ...................................................... 297
19.4 Using FileSystem.Status Annotations to Mark Unread Messages............ 298
19.5 BeanInfo—Displaying Filesystem Properties................................................ 300
19.6 Using the Wizard Framework to Set Up Mail Accounts .............................. 301
Chapter 20. Creating the User Interfacefor the Mail Client...................................... 311
20.1 Creating a DataLoader for Messages ............................................................ 311
20.2 Creating a Threaded Mail View Using Filter Nodes..................................... 317
20.3 Creating a Mail Workspace.............................................................................. 330
Chapter 21. Score File Support.................................................................................... 335
21.1 Overview—Functionality to be Implemented ................................................ 335
21.2 Creating the Minicomposer Module................................................................ 335
21.3 Creating a UniFileLoader and MultiDataObject for *.score Files ............... 337
21.4 Creating an Editor Support for Scores........................................................... 341
21.5 Creating a Fixed ExecCookie to Play Scores............................................... 343
21.6 Creating a Simple Template............................................................................ 346
Chapter 22. Creating a Structural View of the Score................................................ 349
22.1 Creating a ScoreCookie to Represent a Sequence of Notes..................... 349
22.2 Creating a ScoreSupport.................................................................................. 351
22.3 Lifecycle of the Score ....................................................................................... 356
22.4 An OpenSupport................................................................................................ 357
22.5 Indicating Parse Errors on the Node.............................................................. 364
Chapter 23. Compiling Scores ..................................................................................... 368
23.1 Creating the Compilers..................................................................................... 368
23.2 Creating and Using the Compiler Cookie ...................................................... 373
23.3 Displaying an Out-of-Date Badge on Score Icons ....................................... 377
Chapter 24. Executing Scores...................................................................................... 380
24.1 Creating the .au Player Executor.................................................................... 380
24.2 Creating Player Configuration Support.......................................................... 390
24.3 Creating a SystemOption for the Default Executor...................................... 393
Chapter 25. Better Score Support in the Explorer..................................................... 399
25.1 The Clip Length Property ................................................................................. 399
25.2 Representing Notes as Subnodes Using Children.Keys............................. 402
25.3 Permitting Subnodes to Be Renamed or Deleted ........................................ 408
25.4 Permitting Subnodes to Be Added ................................................................. 411
25.5 Making Read/Write Properties on Subnodes................................................ 413
25.6 Reordering Subnodes....................................................................................... 416
25.7 Data Transfer—Cut, Copy, and Paste of Notes and Sequences .............. 420
Chapter 26. Tuning Modules for Performance & Memory Footprint....................... 431
26.1 Startup Performance vs. Runtime Performance........................................... 431
26.2 Operating Principles ......................................................................................... 432
26.3 Techniques......................................................................................................... 433
Chapter 27. Producing Modules (Packaging & Distribution) ................................... 441
27.1 Versioning........................................................................................................... 441
27.2 Upgrading User Settings.................................................................................. 447
27.3 Bundling Extension Libraries........................................................................... 452
27.4 Internationalization and Accessibility ............................................................. 457
27.5 JavaHelp—Writing and Distributing................................................................ 460
27.6 Supporting User-Level Java APIs................................................................... 466
27.7 Creating the Module JAR File Within the IDE............................................... 470
27.8 Creating a Build Script Using Ant ................................................................... 471
27.9 Producing the .nbm File ................................................................................... 472
27.10 Publishing Using the Update Center............................................................ 474
27.11 Using ErrorManager to Log Problems ......................................................... 477
27.12 Testing .............................................................................................................. 479
Chapter 28. Building Your Distribution of NetBeans................................................. 480
28.1 Do You Need Your Own Distribution? ........................................................... 480
28.2 Licensing............................................................................................................. 481
28.3 Selecting a Baseline ......................................................................................... 481
28.4 Getting the Sources .......................................................................................... 482
28.5 Customizing the Build Process ....................................................................... 483
28.6 Adding Modules to a "Stock" Distribution ...................................................... 484
28.7 Creating Preconfigured Settings..................................................................... 486
28.8 Branding ............................................................................................................. 487
Appendix A. A Tour of Existing Modules .................................................................... 499
A.1 Modules That Expose Functionality You Might Need ................................... 499
A.2 Incidental APIs, Utilities, and Extensions........................................................ 503
A.3 Modules That Make Good Examples for Things You May Need to
Implement.................................................................................................................... 504
Appendix B. Useful Utility Classes............................................................................... 510
B.1 XML Utilities ......................................................................................................... 510
B.2 Visual Components and Extensions to Standard Swing Components....... 510
B.3 Lookup Implementations.................................................................................... 511
B.4 Threading ............................................................................................................. 511
B.5 Miscellaneous Utility Classes inorg.openide.util ............................................ 511
B.6 Serialization Helpers........................................................................................... 512
Appendix C. Resources................................................................................................. 513
C.1 CVSHome ............................................................................................................ 513
C.2 Java Environments............................................................................................. 513
C.3 Java Tools............................................................................................................ 514
C.4 Secure Shell (SSH) Resources ........................................................................ 514
C.5 Cygwin for Windows........................................................................................... 515
C.6 Newsgroups and Mailing Lists.......................................................................... 515
C.7 Web Sites............................................................................................................. 515
C.8 NetBeans Open Source Projects with Design Forms in the Distribution ... 516
C.9 Java-Oriented IDEs Other Than NetBeans .................................................... 516
Appendix D. Future Plans ............................................................................................. 518
D.1 Declarative Instantiation .................................................................................... 518
D.2 Uniform Lookup................................................................................................... 518
D.3 Datasystems II..................................................................................................... 519
D.4 The Looks API..................................................................................................... 519
D.5 Declarative Actions............................................................................................. 520
D.6 Deprecation of IDE-Specific Functionality in the Open APIs ....................... 520
D.7 The Metadata Repository .................................................................................. 521
D.8 Project Support ................................................................................................... 522
Appendix E. Working with Open Source and NetBeans .......................................... 525
E.1 Practices............................................................................................................... 525
E.2 Resources ............................................................................................................ 533
E.3 Interacting Effectively on Mailing Lists............................................................. 536
Appendix F. Additional Modules and Where to Find Them ..................................... 538
F.1 Open Source Modules Available Via the Update Center.............................. 539
F.2 The Modules Marketplace on Flashline........................................................... 540
F.3 IDEs That Are Distributions of the NetBeans IDE.......................................... 542
F.4 Open Source Application Projects Based on NetBeans ............................... 543
F.5 Commercial Applications Built on the NetBeans Platform............................ 544
F.6 Commercial Modules Available for NetBeans ................................................ 545
F.7 Should You Create Your Own Update Server?.............................................. 547
Colophon.......................................................................................................................... 549


Another Netbeans Books
Download

2 comments:

  1. Nice article ,Remote Debugging was the single most feature which is very useful while developing larget enterprise application, specially
    if your applicaiton is live and you don't have proper development environment setup in your dev box.

    Thanks
    Javin
    How to setup remote debugging in Eclipse

    ReplyDelete

Related Posts with Thumbnails
There was an error in this gadget

Put Your Ads Here!
There was an error in this gadget