Rahul's Blog

Archive for the ‘NetBeans’ Category

Difference Between NetBeans IDE & NetBeans Platform

In the last NetBeans User Group, Nagpur (NUGNagpur) Skype chat meet I’ve seen most of the members were confused between the NetBeans IDE & NetBeasn Platform.

So  I have decided to write a post on “NetBeans IDE & NetBeans Platform”

What is IDE?

Most of the people don’t know what basically is an IDE. An integrated development environment (IDE) also known as integrated design environment or integrated debugging environment is a software application that provides comprehensive facilities to software programmers  developers for software development. An IDE normally consists of:

  • a source code editor
  • a compiler and/or an interpreter
  • build automation tools
  • a debugger

Sometimes a version control system and various tools are integrated to simplify the construction of a GUI. Many modern IDEs also have a class browser, an object inspector, and a class hierarchy diagram, for use with object-oriented software development

Some open-source IDEs such as Code::Blocks, Eclipse, Lazarus, KDevelop and Netbeans, which themselves are developed using a cross-platform language (e.g., Free Pascal or Java), run on multiple platforms including Windows, GNU/Linux, and Mac OS.

What is Platform?

In computers, a platform is an underlying computer system on which application programs can run. On personal computers, Windows 2000,XP,Vista, Linux and the Mac OS X are examples of different platforms.

In other words a platform is any base of technologies on which other technologies or processes are built.

Now its clear from the above the what is the meaning of the IDE & Platform. Let’s take a look on the difference between NetBeans IDE & NetBeans Platform

NetBeans IDE

The NetBeans IDE is an open-source integrated development environment. NetBeans IDE supports development of all Java application types (Java SE including JavaFX, (Java ME, web, EJB andmobile applications) out of the box. Among other features are an Ant-based project system, Maven support, refactorings, version control (supporting CVS, Subversion, Mercurial and Clearcase).

Modularity: All the functions of the IDE are provided by modules. Each module provides a well defined function, such as support for the Java language, editing, or support for the CVS versioning system, and SVN. NetBeans contains all the modules needed for Java development in a single download, allowing the user to start working immediately. Modules also allow NetBeans to be extended. New features, such as support for other programming languages, can be added by installing additional modules. For instance, Sun Studio, Sun Java Studio Enterprise, and Sun Java Studio Creatorfrom Sun Microsystems are all based on the NetBeans IDE.

License: From July 2006 through 2007, NetBeans IDE was licensed under Sun’s Common Development and Distribution License (CDDL), a license based on the Mozilla Public License (MPL). In October 2007, Sun announced that NetBeans would henceforth be offered under a dual license of the CDDL and the GPL version 2 licenses, with the GPL linking exception for GNU Classpath.

NetBeans Platform:

The NetBeans Platform is a reusable framework for simplifying the development of Java Swing desktop applications. The NetBeans IDE bundle for Java SE contains what is needed to start developing NetBeans plugins and NetBeans Platform based applications; no additional SDK is required.

Applications can install modules dynamically. Any application can include the Update Center module to allow users of the application to download digitally-signed upgrades and new features directly into the running application. Reinstalling an upgrade or a new release does not force users to download the entire application again.

The platform offers reusable services common to desktop applications, allowing developers to focus on the logic specific to their application. Among the features of the platform are:

  • User interface management (e.g. menus and toolbars)
  • User settings management
  • Storage management (saving and loading any kind of data)
  • Window management
  • Wizard framework (supports step-by-step dialogs)
  • NetBeans Visual Library

The NetBeans Platform offers, aside from the generic advantages of a rich client platform,

numerous frameworks and several further specifics that can be particularly useful to your

applications.

What Is a Rich Client?

In a client server architecture the term “rich client” is used for clients where the data processing occurs mainly on the client side. The client also provides the graphical user interface. Often rich clients are applications that are extendable via plugins and modules. In this way, rich clients are able to solve more than one problem.

Rich clients have the advantage that they are easy to distribute and update, such as via an automatic online update function within the client itself or through a mechanism that enables the rich client to start over the Internet (for example, via Java Web Start).

The important characterstics of the rich client are:

• Flexible and modular application architecture

• Platform independence

• Adaptability to the end user

• Ability to work online as well as offline

• Simplified distribution to the end user

• Simplified updating of the client

What Is a Rich Client Platform?

A rich client platform is an application lifecycle environment, a basis for desktop applications.

Most desktop applications have similar features, such as menus, toolbars, status bars, progress

visualizations, data displays, customization settings, the saving and loading of user-specific

data and configurations, splash screens, About boxes, internationalization, help systems, and

so on. For these and other typical client application features, a rich client platform provides a

framework with which the features can quickly and simply be put together.

Advantages of a Rich Client Platform

Aside from the modularity offered by a rich client architecture, which simultaneously implies

a high degree of robustness and end user value, the extensive development support it provides

needs to be highlighted as well. These and other advantages of rich client platforms are briefly

described here:

• Reduction in development time

• User interface consistency

• Updating

• Platform independence

• Reusability and reliability

Let’s look each in turn,

Reduction in Development Time

A rich client platform provides a multitude of APIs for desktop application development. For

example, these can be used by developers to manage windows and menus or support the

display of customization options. Through the reusability of many predefined components,

developers are able to concentrate very closely on the business logic of the application in

question.

User Interface Consistency

Usability of an application is always of crucial concern, in particular when the application is

intended to be used by professionals of a particular domain. A rich client platform makes available a framework for the display of user interfaces, while taking particular care of its

consistency, accessibility, and usability.

Updating

Using a rich client platform, it becomes possible to quickly and efficiently distribute new or

updated modules to end users. As a result, not all the clients of an application need be informed by developers to switch to a new version. Updates can be distributed and installed in the form of modules, so distinct features can be developed and delivered by independently operating teams. The modular architecture of the application ensures that completed modules can be distributed without having to wait for other modules to be finalized.

Platform Independence

Rich client platforms are based on international standards and reusable components. As a

result, Java applications based on them can be automatically deployed to multiple different

systems, such as Windows or Linux, so long as an implementation of the Java Runtime Environment is available. Since the feature set and the applicability of applications keep changing, it is very important that they are developed in such a way that they are extendable and can be deployed to different target systems. All this is provided by a rich client platform, saving time and money. Applications based on rich client platforms do not require further libraries or components, other than the Java Runtime Environment.

Reusability and Reliability

Rich client platforms make a range of features and modules available, which can be used in the

developer’s own applications. If the module does not completely match the application’s

requirements, it is entirely possible to use it as a starting point, while extending it or changing

it as needed. Since most platforms also make their source code available, it may also, in some

cases, be worth considering changing or extending the platform itself. These factors imply a

high degree of reliability and freedom.

I attended the First meetup of NetBeans User Group, Nagpur with  passionate people of Netbeans Platform were present in the meetup and we enjoyed the meet together.

First I would like to introduce you with the NetBeans User Group, NUG nagpur is a group of nagpur users who are passionate about Netbeans platform . This group focuses mainly on enhancing the skills of using netbeans platform for creating the java projects.

In the first meet of the NUG Nagpur, we discussed the following points:

  • History of NetBeans
  • Why is NetBeans IDE /Platform and how much it is used to the developers?
  • Why NetBeans User Group, Nagpur

HISTORY OF NetBeans:

A story of Jarda Tulach (NetBeans founder & architect), about how he started developing NetBeans as his Final Year Project and many of the colleagues  joined him later on. They started with their own company “NetBeans”  in 1998 with the release of the NetBeans IDE as the first commercial product and it then, Sun Microsystems took over that company and all the members of NetBeans joined Sun Microsystems for the later development of the product.

NetBeans began in 1996 as Xelfi (word play on Delphi), a Java IDE student project under the guidance of the Faculty of Mathematics and Physics at Charles Universityin Prague. In 1997 Roman Staněk formed a company around the project and produced commercial versions of the NetBeans IDE until it was bought by Sun Microsystemsin 1999. Sun open-sourced the NetBeans IDE in June of the following year. The NetBeans community has since continued to grow, thanks to individuals and companies using and contributing to the project. The below figure shows the different year wise releases of the NetBeans IDE

Why there is need of NetBeans IDE /Platform:

NetBeans Platform

The NetBeans Platform is a reusable framework for simplifying the development of Java Swing desktop applications. The NetBeans IDE bundle for Java SE contains what is needed to start developing NetBeans plugins and NetBeans Platform based applications; no additional SDK is required.

Applications can install modules dynamically. Any application can include the Update Center module to allow users of the application to download digitally-signedupgrades and new features directly into the running application. Reinstalling an upgrade or a new release does not force users to download the entire application again.

The platform offers reusable services common to desktop applications, allowing developers to focus on the logic specific to their application. Among the features of the platform are:

  • User interface management (e.g. menus and toolbars)
  • User settings management
  • Storage management (saving and loading any kind of data)
  • Window management
  • Wizard framework (supports step-by-step dialogs)
  • NetBeans Visual Library

NetBeans IDE

The NetBeans IDE is an open-source integrated development environment. NetBeans IDE supports development of all Java application types (Java SE including JavaFX, (Java ME, web, EJB andmobile applications) out of the box. Among other features are an Ant-based project system, Maven support, refactorings, version control (supporting CVS, Subversion, Mercurial and Clearcase).

Modularity: All the functions of the IDE are provided by modules. Each module provides a well defined function, such as support for the Java language, editing, or support for the CVS versioning system, and SVN. NetBeans contains all the modules needed for Java development in a single download, allowing the user to start working immediately. Modules also allow NetBeans to be extended. New features, such as support for other programming languages, can be added by installing additional modules. For instance, Sun Studio, Sun Java Studio Enterprise, and Sun Java Studio Creatorfrom Sun Microsystems are all based on the NetBeans IDE.

License: From July 2006 through 2007, NetBeans IDE was licensed under Sun’s Common Development and Distribution License (CDDL), a license based on the Mozilla Public License (MPL). In October 2007, Sun announced that NetBeans would henceforth be offered under a dual license of the CDDL and the GPL version 2 licenses, with the GPL linking exception for GNU Classpath.

Why NetBeans User Group, Nagpur:

We recently had our 1st NUG meet. This meet was held at Beans and Buddies, North Ambazari Road , Nagpur on 23rd Sept. This meet was headed by Tushar Joshi sir.

We really thank Tushar Joshi sir for motivating all of us for joining this group.

The things which motivated us for joining this group was the promise of NetBeans platform. The benefits given to us by netbeans are awesome. There are lot of benefits which we could have used it earlier but we were unaware of those. I really thank Tushar sir for making us aware about those benefits.

The benefits of NetBeans are:

NetBeans is a successful open source project which is being carried out since 10 years. we have facility to actually see the source code of the netbeans which is developed by brilliant engineers. so that’s the first benefit, where we get a chance to see the code written by the most experienced and brilliant engineer.

And that’s not enough! we even have a chance of communicating with all those engineers which helps us in improving our self.  and moreover,  the addon to all this things is that we can contribute our work in netbeans by creating a patch or plugin for the netbeans.

so all this benefits really motivated me for joining this group of brilliant engineers.

The best thing about this group is that NetBeans weekly Newsletter  covered our user group this week  . We are also offered  free 2 days training for learning the NetBeans platform. All the attendees will get Netbeans Certified Associates certificate on attending this training program. And after training we will be given a task and completion of that task would give us Netbeans Certified Engineers certificate.

Below are some happy moments which were captured in the First Meet of NetBeans User Group, Nagpur

After attending the meet I thought that it was not Beans & Buddies, it was NetBeans & Buddies 🙂

If any one want to join the NetBeans User Group, Nagpur you may join the group using following links:

Google Group – http://groups.google.com/group/nugnagpur

Facebook – http://www.facebook.com/pages/NetBeans-User-Group-Nagpur/136762186370301

LinkedIn – http://www.linkedin.com/groups?mostPopular=&gid=3450030

Orkut – http://www.orkut.co.in/Main#Community?cmm=106643010

Wikispaces- http://nugnagpur.wikispaces.com/

First Program in NetBeans IDE:

This post provides step wise procedure to create first program in the NetBeans IDE through the creation of a simple “Hello World” Java console application. Once you have gone with this post, you will have a general knowledge of how to create, build, and run applications in the IDE.

Setting Up the Project

To create an IDE project:

  1. Start NetBeans IDE
  2. In the IDE choose File -> New Project, as shown in the screenshot below.

3. In the New Project wizard, expand the Java category and select Java Application as shown below. Then click Next.

5. In the Name and Location page of the wizard, do the following (as shown in the figure below):

  • In the Project Name field, type MyFirstApplication.
  • Leave the Use Dedicated Folder for Storing Libraries checkbox unselected.
  • In the Create Main Class field, type myfirstapplication.MyFirstApplication.
  • Leave the Set as Main Project checkbox selected.

5. Click Finish

The project is created and opened in the IDE. You should see the following components:

  • The Projects window, which contains a tree view of the components of the project, including source files, libraries that your code depends on, and so on.
  • The Source Editor window with a file called MyFirstApplication.java open.
  • The Navigator window, which you can use to quickly navigate between elements within the selected class.

Adding Code to the Generated Source File

Because you have left the Create Main Class checkbox selected in the New Project wizard, the IDE has created a skeleton class for you. You can add the “Hello World!” message to the skeleton code by replacing the line:

// TODO code application logic here

with the line:

System.out.println(“Hello NetBeans User Group, Nagpur!”);

System.out.println(“This is my first application in NetBeans IDE”);

Save the change by choosing File > Save.

The file should look something like the following:

/*

* To change this template, choose Tools | Templates

* and open the template in the editor.

*/

package myfirstapplication;

/**

*

* @author Administrator

*/

public class MyFirstApplication {

/**

* @param args the command line arguments

*/

public static void main(String[] args) {

System.out.println(“Hello NetBeans User Group, Nagpur!”);

System.out.println(“This is my first application in NetBeans IDE”);

}

}

Compiling the Source File

To compile your source file, choose Run > Build Main Project from the IDE’s main menu or just press F11 shortcut key.

You can view the output of the build process by choosing Window > Output > Output.

The Output window opens and displays output similar to what you see in the following screen.

If the build output concludes with the statement BUILD SUCCESSFUL, congratulations! You have successfully compiled your program!

If the build output concludes with the statement BUILD FAILED, you probably have a syntax error in your code. Errors are reported in the Output window as hyper-linked text. Click such a hyper-link to navigate to the source of an error. You can then fix the error and once again compile your code.

When you build the project, the bytecode file MyFirstApplication.class is generated. You can see where the new file is generated by opening the Files window and expanding the MyFirstApplication/build/classes/myfirstapplication node as shown in the following figure:

Now that you have built the project, you can run your program.

Running the Program

From the IDE’s menu bar, choose Run > Run Main Project or press the shortcut key F6.

The next figure shows what you should now see.

Congratulations! Your first program in NetBeans IDE works!

Downloading  Netbeans IDE:

In this post we will download & install stable version of NetBeans

To download NetBeans, go through the following link:

http://netbeans.org/downloads/index.html

The page will show the different NetBeans IDE Bundles which are available for download. It will be better to select the bundle which has already all the plugins. The below is the screenshot to download NetBeans 6.9.1 version

Installing NetBeans IDE:

After the download is completed, now it’s time to install the NetBeans IDE. Just open the downloaded setup of NetBeans IDE. In this post I am installing NetBeans IDE 6.8, the window will appear:

The NetBeans IDE 6.8 installs various packs and runtimes on your system. By default NetBeans IDE installs “Sun GlassFish Enterprise Server”. If you want to install or uninstall any packs aur runtimes in your system, just click on the Customize button and Customize installation window appears:

Select the required packs from the list and click OK button

Click Next Button & Accept the license agreement and click Next. The next window will appear, the next window shows two field:

  1. 1. First field is the path where the NetBeans IDE 6.8 will install on your hard drive
  2. 2. Second field is the path of the Java Development Kit for the NetBeans

Note: It is important to first install the latest version of the Java Development Kit (JDK) on your system before installing any version of NetBeans.

After the click on the Install button the NetBeans IDE will start its installation on your system

After the installation gets complete click on the Finish button.

Congratulations! You have successfully installed NetBeans IDE in your system.

Introduction:

NetBeans refers to both a platform framework for Java desktop applications, and an integrated development environment (IDE) for developing with Java,JavaScript, PHP, Python, Ruby, Groovy, C, C++, Scala, Clojure, and others.

The NetBeans IDE is written in Java and runs everywhere where a JVM is installed, including Windows, Mac OS, Linux, and Solaris. A JDK is required for Java development functionality, but is not required for development in other programming languages.

Netbeans IDE logo

Current Versions:

NetBeans IDE 6.0 introduced support for developing IDE modules and rich client applications based on the NetBeans platform, a Java Swing GUI builder (formerly known as “Project Matisse”), improved CVS support, Weblogic 9 and JBoss 4 support, and many editor enhancements. NetBeans 6 is available in official repositories of major Linux distributions.

NetBeans IDE 6.5, released in November 2008, extended the existing Java EE features (including Java Persistence support, EJB 3 and JAX-WS). Additionally, theNetBeans Enterprise Pack supports development of Java EE 5 enterprise applications, including SOA visual design tools, XML schema tools, web services orchestration (for BPEL), and UML modeling. The NetBeans IDE Bundle for C/C++ supports C/C++ development.

The NetBeans IDE 6.8 is the first IDE to provide complete support of Java EE 6 and the GlassFish Enterprise Server v3. Developers hosting their open-source projects onkenai.com additionally benefit from instant messaging and issue tracking integration and navigation right in the IDE, support for web application development with PHP 5.3 and the Symfony framework, and improved code completion, layouting, hints and navigation in JavaFX projects.

NetBeans IDE 6.9, released in June 2010, added support for OSGi, Spring Framework 3.0, Java EE dependency injection (JSR-299), Zend Framework for PHP, and easier code navigation (such as “Is Overridden/Implemented” annotations), formatting, hints, and refactoring across several languages.

Features:

The NetBeans IDE is an open-source integrated development environment. NetBeans IDE supports development of all Java application types (Java SE including JavaFX, (Java ME, web, EJB andmobile applications) out of the box. Among other features are an Ant-based project system, Maven support, refactorings, version control (supporting CVS, Subversion, Mercurial and Clearcase).

Modularity: All the functions of the IDE are provided by modules. Each module provides a well defined function, such as support for the Java language, editing, or support for the CVS versioning system, and SVN. NetBeans contains all the modules needed for Java development in a single download, allowing the user to start working immediately. Modules also allow NetBeans to be extended. New features, such as support for other programming languages, can be added by installing additional modules. For instance, Sun Studio, Sun Java Studio Enterprise, and Sun Java Studio Creatorfrom Sun Microsystems are all based on the NetBeans IDE.

License:

From July 2006 through 2007, NetBeans IDE was licensed under Sun’s Common Development and Distribution License (CDDL), a license based on the Mozilla Public License (MPL). In October 2007, Sun announced that NetBeans would henceforth be offered under a dual license of the CDDL and the GPL version 2 licenses, with the GPL linking exception for GNU Classpath.


Categories:

May 2024
M T W T F S S
 12345
6789101112
13141516171819
20212223242526
2728293031  

My Blog Stats

  • 5,999 hits