没有eclipse运行java程序? [英] Run java programs without eclipse?

查看:140
本文介绍了没有eclipse运行java程序?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

嘿伙计们,我已经开始学习java了,而且我正在使用eclipse来编写我的项目代码。当我从eclipse运行我的程序时,在日食中有一个控制台向我显示我所做的一切。但是如何在不使用eclipse的情况下运行我的程序呢?像skype一样。如果其他人将使用我的程序,他们将需要eclipse等,这也不会很好。



另一件事。在c ++中,我可以编写代码,这样我就可以在控制台中编写一个值。例如5.

然后它可以将5乘以10或其他东西并向我显示答案。我可以用java做这个吗?我怎样才能将Minecraft作为正常程序运行,而不是我自己的程序? :S

Hey guys, I''ve started learn java and i''m using eclipse to code my projects. When i "run" my program from eclipse there''s a console in eclipse that show me everything i''ve done. But how can i run my programs without using eclipse? Like skype for example. If other ppl shall use my program they will need eclipse etc and that won''t be good either.

Another thing. In c++ i can write code so I can write a value in the console. for example 5.
And then it can multiply 5 by 10 or something and show me the answer. Can I do this with java? How can i run minecraft as a normal program, but not my own? :S

推荐答案

你到这里之前学到了什么?不多。

Eclipse和Java有什么关系?一件事:Eclipse是许多Java IDE的 这是最常用的列表 [ ^ ],但如果你没有别的东西,你可以用记事本写java源代码。您唯一需要的是使用编译器的环境( JDK [ ^ ])。获得源代码后,编译它,打包它,然后运行它: http:// www .cs.swarthmore.edu / ~newhall / unixhelp / debuggingtips_Java.html [ ^ ]。

根据它的内容,应用程序包或类可以作为控制台和窗口应用程序启动:

What have you learned before you got here? Not much.
What have Eclipse and Java to do with each other? One thing: Eclipse is one of many Java IDEs. Here is a list of the most used ones[^], but you can write java source with notepad if you don''t have anything else. The only thing you need is the environment with the compiler (JDK[^]). Once you have your source, you compile it, package it, and simply run it: http://www.cs.swarthmore.edu/~newhall/unixhelp/debuggingtips_Java.html[^].
Depending on it''s content, the application package or class can be started as console and as windowed application:
Quote:

java和javaw工具通过启动Java运行时环境并加载指定的类来启动Java™应用程序。 />


javaw命令与java相同,只是javaw没有关联的控制台窗口。如果不希望显示命令提示符窗口,请使用javaw。如果失败,javaw启动器会显示一个包含错误信息的窗口。

The java and javaw tools start a Java™ application by starting a Java Runtime Environment and loading a specified class.

The javaw command is identical to java, except that javaw has no associated console window. Use javaw when you do not want a command prompt window to be displayed. The javaw launcher displays a window with error information if it fails.



http://publib.boulder.ibm.com/infocenter/java7sdk/v7r0/index.jsp? topic =%2Fcom.ibm.java.lnx.70.doc%2Fuser%2Fjava.html [ ^ ])


(http://publib.boulder.ibm.com/infocenter/java7sdk/v7r0/index.jsp?topic=%2Fcom.ibm.java.lnx.70.doc%2Fuser%2Fjava.html[^])


这篇关于没有eclipse运行java程序?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆