/plugins/Console/tags/release-4-3-7/console/commands/java.xml

# · XML · 175 lines · 125 code · 18 blank · 32 comment · 0 complexity · e7dfdc14b7d3288d2b5ea2a408d1382c MD5 · raw file

  1. <?xml version="1.0" ?>
  2. <!-- This was based around Sun JRE 1.3.1. It will work with earlier Java
  3. versions, or versions from other vendors, but some of the
  4. non-standard options might not be supported. -->
  5. <!DOCTYPE COMMANDO SYSTEM "commando.dtd">
  6. <COMMANDO>
  7. <UI>
  8. <CAPTION LABEL="Application settings">
  9. <ENTRY LABEL="Main class or JAR file" VARNAME="jar"
  10. EVAL="console.ConsolePlugin.getClassName(buffer)"
  11. />
  12. <ENTRY LABEL="Application parameters" VARNAME="args" />
  13. </CAPTION>
  14. <CAPTION LABEL="VM settings">
  15. <!-- <CHOICE LABEL="Virtual machine" VARNAME="vm" DEFAULT="client">
  16. <OPTION LABEL="Client HotSpot" VALUE="client" />
  17. <OPTION LABEL="Server HotSpot" VALUE="server" />
  18. <OPTION LABEL="Classic" VALUE="classic" />
  19. </CHOICE> -->
  20. <ENTRY LABEL="Class path" VARNAME="classpath"
  21. EVAL="getBufferClassPath(buffer)" />
  22. <!-- <TOGGLE LABEL="Verbose class loading" VARNAME="verbose_class" />
  23. <TOGGLE LABEL="Verbose garbage collection" VARNAME="verbose_gc" />
  24. <TOGGLE LABEL="Verbose JNI calls" VARNAME="verbose_jni" /> -->
  25. <!-- <CHOICE LABEL="Virtual machine type" VARNAME="vm_X" DEFAULT="mixed">
  26. <OPTION LABEL="Mixed mode" VALUE="mixed" />
  27. <OPTION LABEL="Interpreter only" VALUE="interp" />
  28. </CHOICE>
  29. <CHOICE LABEL="Boot class path mode" VARNAME="bootclasspath_mode">
  30. <OPTION LABEL="Set" VALUE="set" />
  31. <OPTION LABEL="Append" VALUE="append" />
  32. <OPTION LABEL="Prepend" VALUE="prepend" />
  33. </CHOICE>
  34. <ENTRY LABEL="Boot class path" VARNAME="bootclasspath" />
  35. <TOGGLE LABEL="Class garbage collection" VARNAME="classgc" />
  36. <TOGGLE LABEL="Incremental garbage collection" VARNAME="incgc" />
  37. <TOGGLE LABEL="Background compilation" VARNAME="nobatch"
  38. DEFAULT="TRUE" />
  39. <TOGGLE LABEL="Output profiling data" VARNAME="prof" />
  40. <TOGGLE LABEL="Strict class format checks (-Xfuture)"
  41. VARNAME="future" />
  42. <TOGGLE LABEL="Reduce OS signal use (-Xrs)" VARNAME="rs" /> -->
  43. <ENTRY LABEL="Initial heap size (Mb)" VARNAME="ms" DEFAULT="32" />
  44. <ENTRY LABEL="Maximum heap size (Mb)" VARNAME="mx" DEFAULT="32" />
  45. <ENTRY LABEL="Thread stack size (Kb)" VARNAME="ss" />
  46. <ENTRY LABEL="Additional VM parameters" VARNAME="extra" />
  47. </CAPTION>
  48. </UI>
  49. <COMMANDS>
  50. <COMMAND SHELL="System" CONFIRM="FALSE">
  51. buf = new StringBuffer();
  52. buf.append("java");
  53. /* if(vm.equals("client"))
  54. ; // default
  55. else if(vm.equals("server"))
  56. buf.append(" -server");
  57. else if(vm.equals("classic"))
  58. buf.append(" -classic"); */
  59. if(!classpath.equals(""))
  60. {
  61. buf.append(" -classpath \"");
  62. buf.append(classpath);
  63. buf.append('"');
  64. }
  65. /* if(verbose_class)
  66. buf.append(" -verbose:class");
  67. if(verbose_gc)
  68. buf.append(" -verbose:gc");
  69. if(verbose_jni)
  70. buf.append(" -verbose:jni");
  71. if(vm_X.equals("interp"))
  72. buf.append(" -Xint");
  73. if(!bootclasspath.equals(""))
  74. {
  75. buf.append(" -Xbootclasspath");
  76. if(bootclasspath_mode.equals("append"))
  77. buf.append("/a");
  78. else if(bootclasspath_mode.equals("prepend"))
  79. buf.append("/p");
  80. buf.append(':');
  81. buf.append(bootclasspath);
  82. }
  83. if(classgc)
  84. buf.append(" -Xclassgc");
  85. if(incgc)
  86. buf.append(" -Xincgc");
  87. if(!nobatch)
  88. buf.append(" -Xbatch");
  89. if(prof)
  90. buf.append(" -Xprof");
  91. if(future)
  92. buf.append(" -Xfuture");
  93. if(rs)
  94. buf.append(" -Xrs"); */
  95. if(!ms.equals(""))
  96. {
  97. buf.append(" -ms");
  98. buf.append(ms);
  99. buf.append('m');
  100. }
  101. if(!mx.equals(""))
  102. {
  103. buf.append(" -mx");
  104. buf.append(mx);
  105. buf.append('m');
  106. }
  107. if(!ss.equals(""))
  108. {
  109. buf.append(" -ss");
  110. buf.append(ss);
  111. buf.append('k');
  112. }
  113. if(!extra.equals(""))
  114. {
  115. buf.append(' ');
  116. buf.append(extra);
  117. }
  118. if(jar.endsWith(".jar"))
  119. {
  120. buf.append(" -jar \"");
  121. buf.append(jar);
  122. buf.append('"');
  123. }
  124. else
  125. {
  126. buf.append(' ');
  127. buf.append(jar);
  128. }
  129. if(!args.equals(""))
  130. {
  131. buf.append(' ');
  132. buf.append(args);
  133. }
  134. // return value
  135. buf.toString();
  136. </COMMAND>
  137. </COMMANDS>
  138. </COMMANDO>