hipod 2009-06-11 21:33
浏览 252
已采纳

eclipse的使用问题?

[color=darkred][size=x-large]eclipse运行选项:[/size][/color][img]/upload/attachment/113723/3d89cb16-1164-3ce0-8989-17b34f4b0917.jpg[/img]

[img]/upload/attachment/113725/8fc8735c-f4ef-3941-b988-be3caca1854e.jpg[/img]

[size=x-large]eclipse运行选项:[/size][img]/upload/attachment/113721/b5857807-61be-3ab4-b293-e9e06f1c40ca.jpg[/img]
[size=x-large]这里面好像没有java的有关选项,怎么配置啊?[/size]
[b]问题补充:[/b]
[color=darkred][size=x-large]但是这个程序没有得到理想的结果啊,console显示[/size][/color]Usage: javaw [-options] class args...
or javaw [-options] -jar jarfile args...
where options include:
-d32 use a 32-bit data model if available
-d64 use a 64-bit data model if available
-client to select the "client" VM
-server to select the "server" VM
-hotspot is a synonym for the "client" VM [deprecated]
The default VM is client.

-cp <class search path of directories and zip/jar files>
-classpath <class search path of directories and zip/jar files>
              A ; separated list of directories, JAR archives,
              and ZIP archives to search for class files.
-D<name>=<value>
              set a system property
-verbose[:class|gc|jni]
              enable verbose output
-version      print product version and exit
-version:<value>
              require the specified version to run
-showversion  print product version and continue
-jre-restrict-search | -jre-no-restrict-search
              include/exclude user private JREs in the version search
-? -help      print this help message
-X            print help on non-standard options
-ea[:<packagename>...|:<classname>]
-enableassertions[:<packagename>...|:<classname>]
              enable assertions with specified granularity
-da[:<packagename>...|:<classname>]
-disableassertions[:<packagename>...|:<classname>]
              disable assertions with specified granularity
-esa | -enablesystemassertions
              enable system assertions
-dsa | -disablesystemassertions
              disable system assertions
-agentlib:<libname>[=<options>]
              load native agent library <libname>, e.g. -agentlib:hprof
              see also, -agentlib:jdwp=help and -agentlib:hprof=help
-agentpath:<pathname>[=<options>]
              load native agent library by full pathname
-javaagent:<jarpath>[=<options>]
              load Java programming language agent, see java.lang.instrument
-splash:<imagepath>
              show splash screen with specified image

See http://java.sun.com/javase/reference for more details.

[b]问题补充:[/b]
[size=x-large]程序很简单[/size]
[code="java"]public class Test {
public static void main(){
System.out.println("hello,world");
}
}[/code]
我的eclipse不是安装版的,已配置window/preferences/java/installed jres java路径正确

  • 写回答

7条回答 默认 最新

  • wanghaolovezlq 2009-06-11 22:57
    关注

    晕,你代码写错了main方法

    应该是这样,下面这样就能直接运行了

    [code="java"]
    public class Test {

    public static void main(String[] args){

    System.out.println("hello,world");

    }

    }

    [/code]

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论
查看更多回答(6条)

报告相同问题?

悬赏问题

  • ¥15 程序不包含适用于入口点的静态Main方法
  • ¥15 素材场景中光线烘焙后灯光失效
  • ¥15 请教一下各位,为什么我这个没有实现模拟点击
  • ¥15 执行 virtuoso 命令后,界面没有,cadence 启动不起来
  • ¥50 comfyui下连接animatediff节点生成视频质量非常差的原因
  • ¥20 有关区间dp的问题求解
  • ¥15 多电路系统共用电源的串扰问题
  • ¥15 slam rangenet++配置
  • ¥15 有没有研究水声通信方面的帮我改俩matlab代码
  • ¥15 ubuntu子系统密码忘记