tags:

views:

160

answers:

5

I mean using and IDE of course.

Does Java come with a toolbox like control that has drag and drop controls, that you can move around, etc?

Also, if I make an application in Java, will it run on any machine that has the Java Runtime Environment? I wouldn't mind learning some Java because of this single trait. :)

Say I build a simple calculator, will it run on Linux/Mac/Windows?

+1  A: 

Does Java come with a toolbox like control that has drag and drop controls, that you can move around, etc?

Java itself not. However, there are several IDEs such as Eclipse and Netbeans with a drag&drop-enabled designer.

will it run on any machine that has the Java Runtime Environment?

If you do not anything platform specific (normally not neccessary): Yes.

winSharp93
Can you give me an example of something platform specific?
Sergio Tapia
Well - it is actually possible to do WinAPI calls in Java programs. However, in most situations they are not necessary.
winSharp93
Platform specific would be running shell commands via Runtime.exec(), or calling native C code via JNI.
Michael Borgwardt
@Michael Borgward, it's not necessarily true that spawning a process via `Runtime.exe` will make your app OS dependant.
Geo
Although calling native code can actually be done as long as you ship different native libraries for each OS.
matt b
+2  A: 
  1. There are visual Java GUI designers which can be found on Google
  2. If you build a Java app it will run on any machine with the correct version of the JRE -- just like in .NET, you can target a certain version
  3. If you build a simple calculator, you should be able to get it to work on Linux/Mac/Windows
statichippo
and, as winSharp93 mentions (and beat me to the chase), you obviously can't do anything platform specific if you want it to run on other platforms. But if you need something platform specific for some reason (can't imaging why a calculator would) you can have just that code differ for each platform.
statichippo
+1  A: 

One big difference between Java and MS IDEs is that with Java IDEs you will not get the support for data binding via drag and drop as with MS IDEs. This is actually discouraged in the Java camps because it results in tough to maintain code.

So while the Java IDEs do tend to have very complete toolboxes, don't expect anything that favors RAD over OOP.

Paul Sasik
+5  A: 

I think you are confusing programming languages and software development tools.

Both C# and Java have available development toolkits and libraries which can be used to create applications. However, their source code and function calls will not be interchangeable.

If you build a simplistic application in Java, you will most likely be able to run it on any machine with a Java Virtual Machine. Writing more specialized, platform-specific code that will not run everywhere is still possible. You can probably ignore this for now.

I think this is a pretty important distinction to make. In the .NET world, Microsoft supplies just about every tool you'll use, at least as far as the IDE goes. In the Java world, there are at least 3 very popular IDEs, only one of which is made by / affliated with Sun.
matt b
A: 

I for the most part agree with the answers that have been given but I want to put a slightly different spin on this.

You sound like a .NET developer who is looking at Java. I am a Java developer who has started getting into .NET. One thing that is very different from the .NET world and the Java world is the IDEs. If you go into a .NET shop you may see VB coders, C# coders and such all developing .NET using Visual Studio. If you go into a Java shop you'll see coders all coding Java but they may be using different IDEs (Eclipse, RAD, NetBeans, etc) and even within those you may see different functionality within the IDEs (in Eclipse for example you add functionality via plug-ins).

That being said there are plug-ins in IDEs such as Eclipse that are similar to what you see in Visual Studio. The main difference I see is that these are more fundamental to Visual Studio than any IDE I've seen that Java developers use (many Java developers I know don't drag-and-drop anything past the initial screen creation).

Hope this helps.

SOA Nerd