.Net (Vs) Java

  1.   Java and .Net are two incomparable guided, but by fact that .Net is Framework of simply platform and supports for almost 63 languages and java is just a programming language.
  2. These two technologies have different syntax but gives the same result.Let’s look at some basic imports and usings used in java and .Net.
.Net Java
C# Namespaces usings Java Packages imports
System.IO Java.IO
System.Collections Java.Util
System.Windows.Forms Java.awt, javax.swing
System.Threading Java.lang
System.Drawing Java.awt

Now let’s look at some application based differences.

.Net Java
Windows Applications Net is very popular in desktop development providing both Windows Forms, Windows Presentation Foundation (WPF) and Silverlight. Java uses AWT ( Abstract window toolkit ) and swing libraries to develop windows based applications.
Web Applications For web based applications it uses ASP.NET, MVC. For Web Based applications it uses J2EE and web Server scripting it uses JSP, JSF, Servlets.
Android Applications Xamarin commercially distributes the MonoDroid and MonoTouch framework for Android and iPhone development. And can build with a hybrid container called Apache Cordova.

Windows Phone 7 uses Silverlight.
Windows Phone 8 uses C# and XAML.

Java ME is made up of various profiles that are subsets of the Java desktop environment with additional libraries targeted at mobile and set-top-box development.
Web Services For Web Services it uses JWSDP (Java Web Services Developer pack). It uses web services.

Now let’s look at some basic differences.

Java  .Net
Java is a programming language .Net is a framework
Developed by James gosling at Sun microsystems in 1995 and which is now owned by Oracle Corporation. Developed by Microsoft and its first release in 2002
Is shared by many platforms and platform independent. Is shared by single platform and language independent.
Uses common language and some may argue that Jython is an alternative, but later Jyton creator created its. Net version called IronPython. Can use many languages and generates platform specific code which is called as native code.
Has support to open source platform. Has no direct support for open source platform.
Java is renowed as “Write once run anywhere” .Net is renowed as “Write once and debug anywhere”
One cannot code .net code on java platform One can code java code on .Net Platform
Based on third party tools and server providers. It has the powerful IDE than any Integrated Development Environment.
To create a simple control it takes a lot of programming for the developer. Can easy drag and drop controls process, so that developer no need to worry about designing and can concentrate on development issues a security.
Application Development can be done on very less configuration system. Required High configuration system.
To clean memory, java programmers need to do it manually. Whereas .Net Garbage collector follows AMM (Automatic Memory Management).
Don’t support disconnected architecture where multiple round trips are needed using JDBC. Has most advantages with disconnected architecture using ADO.NET.
C language code cannot get executed by java Can write even C language code and execute using.Net F/w
For Business logic, it uses EJB (Enterprise Java Beans) / Servlets. For Business Logic it uses Code Behind, Remoted Classes.
For XML parsing it uses JAXP and others. It uses Built-in System.XML.
Java source code is converted to bytecode by JVM (java virtual machine). .Net source code is converted to MSIL (Microsoft intermediate language) code by CLR (common language runtime.)
For web Server scripting it uses JSP, JSF, Servlets. For web server scripting it uses ASP.NET or classic ASP.
Object Persistence: Entity Framework, NHibernate. Object Persistence: Hibernate.
For unit testing it uses Junit. For unit testing, it uses Microsoft Unit testing Framework, NUnit
Local server Apache Local server is IIS (Internet Information Service).


Leave a Reply