Edit C:\apache-ant-1.8.0\docs\manual\api\org\apache\tools\ant\util\JavaEnvUtils.html
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <!--NewPage--> <HTML> <HEAD> <!-- Generated by javadoc (build 1.5.0_22) on Mon Feb 01 19:35:59 EST 2010 --> <TITLE> JavaEnvUtils (Apache Ant API) </TITLE> <META NAME="keywords" CONTENT="org.apache.tools.ant.util.JavaEnvUtils class"> <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style"> <SCRIPT type="text/javascript"> function windowTitle() { parent.document.title="JavaEnvUtils (Apache Ant API)"; } </SCRIPT> <NOSCRIPT> </NOSCRIPT> </HEAD> <BODY BGCOLOR="white" onload="windowTitle();"> <!-- ========= START OF TOP NAVBAR ======= --> <A NAME="navbar_top"><!-- --></A> <A HREF="#skip-navbar_top" title="Skip navigation links"></A> <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY=""> <TR> <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A NAME="navbar_top_firstrow"><!-- --></A> <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY=""> <TR ALIGN="center" VALIGN="top"> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A> </TD> <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> <FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A> </TD> </TR> </TABLE> </TD> <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM> </EM> </TD> </TR> <TR> <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2"> <A HREF="../../../../../org/apache/tools/ant/util/IdentityStack.html" title="class in org.apache.tools.ant.util"><B>PREV CLASS</B></A> <A HREF="../../../../../org/apache/tools/ant/util/JAXPUtils.html" title="class in org.apache.tools.ant.util"><B>NEXT CLASS</B></A></FONT></TD> <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2"> <A HREF="../../../../../index.html?org/apache/tools/ant/util/JavaEnvUtils.html" target="_top"><B>FRAMES</B></A> <A HREF="JavaEnvUtils.html" target="_top"><B>NO FRAMES</B></A> <SCRIPT type="text/javascript"> <!-- if(window==top) { document.writeln('<A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>'); } //--> </SCRIPT> <NOSCRIPT> <A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A> </NOSCRIPT> </FONT></TD> </TR> <TR> <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2"> SUMMARY: NESTED | <A HREF="#field_summary">FIELD</A> | CONSTR | <A HREF="#method_summary">METHOD</A></FONT></TD> <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2"> DETAIL: <A HREF="#field_detail">FIELD</A> | CONSTR | <A HREF="#method_detail">METHOD</A></FONT></TD> </TR> </TABLE> <A NAME="skip-navbar_top"></A> <!-- ========= END OF TOP NAVBAR ========= --> <HR> <!-- ======== START OF CLASS DATA ======== --> <H2> <FONT SIZE="-1"> org.apache.tools.ant.util</FONT> <BR> Class JavaEnvUtils</H2> <PRE> java.lang.Object <IMG SRC="../../../../../resources/inherit.gif" ALT="extended by "><B>org.apache.tools.ant.util.JavaEnvUtils</B> </PRE> <HR> <DL> <DT><PRE>public final class <B>JavaEnvUtils</B><DT>extends java.lang.Object</DL> </PRE> <P> A set of helper methods related to locating executables or checking conditons of a given Java installation. <P> <P> <DL> <DT><B>Since:</B></DT> <DD>Ant 1.5</DD> </DL> <HR> <P> <!-- =========== FIELD SUMMARY =========== --> <A NAME="field_summary"><!-- --></A> <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY=""> <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"> <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2"> <B>Field Summary</B></FONT></TH> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"> <CODE>static java.lang.String</CODE></FONT></TD> <TD><CODE><B><A HREF="../../../../../org/apache/tools/ant/util/JavaEnvUtils.html#JAVA_1_0">JAVA_1_0</A></B></CODE> <BR> Version constant for Java 1.0</TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"> <CODE>static java.lang.String</CODE></FONT></TD> <TD><CODE><B><A HREF="../../../../../org/apache/tools/ant/util/JavaEnvUtils.html#JAVA_1_1">JAVA_1_1</A></B></CODE> <BR> Version constant for Java 1.1</TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"> <CODE>static java.lang.String</CODE></FONT></TD> <TD><CODE><B><A HREF="../../../../../org/apache/tools/ant/util/JavaEnvUtils.html#JAVA_1_2">JAVA_1_2</A></B></CODE> <BR> Version constant for Java 1.2</TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"> <CODE>static java.lang.String</CODE></FONT></TD> <TD><CODE><B><A HREF="../../../../../org/apache/tools/ant/util/JavaEnvUtils.html#JAVA_1_3">JAVA_1_3</A></B></CODE> <BR> Version constant for Java 1.3</TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"> <CODE>static java.lang.String</CODE></FONT></TD> <TD><CODE><B><A HREF="../../../../../org/apache/tools/ant/util/JavaEnvUtils.html#JAVA_1_4">JAVA_1_4</A></B></CODE> <BR> Version constant for Java 1.4</TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"> <CODE>static java.lang.String</CODE></FONT></TD> <TD><CODE><B><A HREF="../../../../../org/apache/tools/ant/util/JavaEnvUtils.html#JAVA_1_5">JAVA_1_5</A></B></CODE> <BR> Version constant for Java 1.5</TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"> <CODE>static java.lang.String</CODE></FONT></TD> <TD><CODE><B><A HREF="../../../../../org/apache/tools/ant/util/JavaEnvUtils.html#JAVA_1_6">JAVA_1_6</A></B></CODE> <BR> Version constant for Java 1.6</TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"> <CODE>static int</CODE></FONT></TD> <TD><CODE><B><A HREF="../../../../../org/apache/tools/ant/util/JavaEnvUtils.html#VERSION_1_0">VERSION_1_0</A></B></CODE> <BR> Number Version constant for Java 1.0</TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"> <CODE>static int</CODE></FONT></TD> <TD><CODE><B><A HREF="../../../../../org/apache/tools/ant/util/JavaEnvUtils.html#VERSION_1_1">VERSION_1_1</A></B></CODE> <BR> Number Version constant for Java 1.1</TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"> <CODE>static int</CODE></FONT></TD> <TD><CODE><B><A HREF="../../../../../org/apache/tools/ant/util/JavaEnvUtils.html#VERSION_1_2">VERSION_1_2</A></B></CODE> <BR> Number Version constant for Java 1.2</TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"> <CODE>static int</CODE></FONT></TD> <TD><CODE><B><A HREF="../../../../../org/apache/tools/ant/util/JavaEnvUtils.html#VERSION_1_3">VERSION_1_3</A></B></CODE> <BR> Number Version constant for Java 1.3</TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"> <CODE>static int</CODE></FONT></TD> <TD><CODE><B><A HREF="../../../../../org/apache/tools/ant/util/JavaEnvUtils.html#VERSION_1_4">VERSION_1_4</A></B></CODE> <BR> Number Version constant for Java 1.4</TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"> <CODE>static int</CODE></FONT></TD> <TD><CODE><B><A HREF="../../../../../org/apache/tools/ant/util/JavaEnvUtils.html#VERSION_1_5">VERSION_1_5</A></B></CODE> <BR> Number Version constant for Java 1.5</TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"> <CODE>static int</CODE></FONT></TD> <TD><CODE><B><A HREF="../../../../../org/apache/tools/ant/util/JavaEnvUtils.html#VERSION_1_6">VERSION_1_6</A></B></CODE> <BR> Number Version constant for Java 1.6</TD> </TR> </TABLE> <!-- ========== METHOD SUMMARY =========== --> <A NAME="method_summary"><!-- --></A> <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY=""> <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"> <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2"> <B>Method Summary</B></FONT></TH> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"> <CODE>static java.io.File</CODE></FONT></TD> <TD><CODE><B><A HREF="../../../../../org/apache/tools/ant/util/JavaEnvUtils.html#createVmsJavaOptionFile(java.lang.String[])">createVmsJavaOptionFile</A></B>(java.lang.String[] cmd)</CODE> <BR> Writes the command into a temporary DCL script and returns the corresponding File object.</TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"> <CODE>static java.lang.String</CODE></FONT></TD> <TD><CODE><B><A HREF="../../../../../org/apache/tools/ant/util/JavaEnvUtils.html#getJavaHome()">getJavaHome</A></B>()</CODE> <BR> Return the value of ${java.home}</TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"> <CODE>static java.lang.String</CODE></FONT></TD> <TD><CODE><B><A HREF="../../../../../org/apache/tools/ant/util/JavaEnvUtils.html#getJavaVersion()">getJavaVersion</A></B>()</CODE> <BR> Returns the version of Java this class is running under.</TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"> <CODE>static int</CODE></FONT></TD> <TD><CODE><B><A HREF="../../../../../org/apache/tools/ant/util/JavaEnvUtils.html#getJavaVersionNumber()">getJavaVersionNumber</A></B>()</CODE> <BR> Returns the version of Java this class is running under.</TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"> <CODE>static java.lang.String</CODE></FONT></TD> <TD><CODE><B><A HREF="../../../../../org/apache/tools/ant/util/JavaEnvUtils.html#getJdkExecutable(java.lang.String)">getJdkExecutable</A></B>(java.lang.String command)</CODE> <BR> Finds an executable that is part of a JDK installation based on the java.home system property.</TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"> <CODE>static java.lang.String</CODE></FONT></TD> <TD><CODE><B><A HREF="../../../../../org/apache/tools/ant/util/JavaEnvUtils.html#getJreExecutable(java.lang.String)">getJreExecutable</A></B>(java.lang.String command)</CODE> <BR> Finds an executable that is part of a JRE installation based on the java.home system property.</TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"> <CODE>static java.util.Vector</CODE></FONT></TD> <TD><CODE><B><A HREF="../../../../../org/apache/tools/ant/util/JavaEnvUtils.html#getJrePackages()">getJrePackages</A></B>()</CODE> <BR> get a vector of strings of packages built into that platforms runtime jar(s)</TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"> <CODE>static java.util.Vector</CODE></FONT></TD> <TD><CODE><B><A HREF="../../../../../org/apache/tools/ant/util/JavaEnvUtils.html#getJrePackageTestCases()">getJrePackageTestCases</A></B>()</CODE> <BR> Testing helper method; kept here for unification of changes.</TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"> <CODE>static boolean</CODE></FONT></TD> <TD><CODE><B><A HREF="../../../../../org/apache/tools/ant/util/JavaEnvUtils.html#isAtLeastJavaVersion(java.lang.String)">isAtLeastJavaVersion</A></B>(java.lang.String version)</CODE> <BR> Compares the current Java version to the passed in String - assumes the argument is one of the constants defined in this class.</TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"> <CODE>static boolean</CODE></FONT></TD> <TD><CODE><B><A HREF="../../../../../org/apache/tools/ant/util/JavaEnvUtils.html#isJavaVersion(java.lang.String)">isJavaVersion</A></B>(java.lang.String version)</CODE> <BR> Compares the current Java version to the passed in String - assumes the argument is one of the constants defined in this class.</TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"> <CODE>static boolean</CODE></FONT></TD> <TD><CODE><B><A HREF="../../../../../org/apache/tools/ant/util/JavaEnvUtils.html#isKaffe()">isKaffe</A></B>()</CODE> <BR> Checks whether the current Java VM is Kaffe.</TD> </TR> </TABLE> <A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A> <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY=""> <TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor"> <TH ALIGN="left"><B>Methods inherited from class java.lang.Object</B></TH> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD><CODE>clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait</CODE></TD> </TR> </TABLE> <P> <!-- ============ FIELD DETAIL =========== --> <A NAME="field_detail"><!-- --></A> <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY=""> <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"> <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2"> <B>Field Detail</B></FONT></TH> </TR> </TABLE> <A NAME="JAVA_1_0"><!-- --></A><H3> JAVA_1_0</H3> <PRE> public static final java.lang.String <B>JAVA_1_0</B></PRE> <DL> <DD>Version constant for Java 1.0 <P> <DL> <DT><B>See Also:</B><DD><A HREF="../../../../../constant-values.html#org.apache.tools.ant.util.JavaEnvUtils.JAVA_1_0">Constant Field Values</A></DL> </DL> <HR> <A NAME="VERSION_1_0"><!-- --></A><H3> VERSION_1_0</H3> <PRE> public static final int <B>VERSION_1_0</B></PRE> <DL> <DD>Number Version constant for Java 1.0 <P> <DL> <DT><B>See Also:</B><DD><A HREF="../../../../../constant-values.html#org.apache.tools.ant.util.JavaEnvUtils.VERSION_1_0">Constant Field Values</A></DL> </DL> <HR> <A NAME="JAVA_1_1"><!-- --></A><H3> JAVA_1_1</H3> <PRE> public static final java.lang.String <B>JAVA_1_1</B></PRE> <DL> <DD>Version constant for Java 1.1 <P> <DL> <DT><B>See Also:</B><DD><A HREF="../../../../../constant-values.html#org.apache.tools.ant.util.JavaEnvUtils.JAVA_1_1">Constant Field Values</A></DL> </DL> <HR> <A NAME="VERSION_1_1"><!-- --></A><H3> VERSION_1_1</H3> <PRE> public static final int <B>VERSION_1_1</B></PRE> <DL> <DD>Number Version constant for Java 1.1 <P> <DL> <DT><B>See Also:</B><DD><A HREF="../../../../../constant-values.html#org.apache.tools.ant.util.JavaEnvUtils.VERSION_1_1">Constant Field Values</A></DL> </DL> <HR> <A NAME="JAVA_1_2"><!-- --></A><H3> JAVA_1_2</H3> <PRE> public static final java.lang.String <B>JAVA_1_2</B></PRE> <DL> <DD>Version constant for Java 1.2 <P> <DL> <DT><B>See Also:</B><DD><A HREF="../../../../../constant-values.html#org.apache.tools.ant.util.JavaEnvUtils.JAVA_1_2">Constant Field Values</A></DL> </DL> <HR> <A NAME="VERSION_1_2"><!-- --></A><H3> VERSION_1_2</H3> <PRE> public static final int <B>VERSION_1_2</B></PRE> <DL> <DD>Number Version constant for Java 1.2 <P> <DL> <DT><B>See Also:</B><DD><A HREF="../../../../../constant-values.html#org.apache.tools.ant.util.JavaEnvUtils.VERSION_1_2">Constant Field Values</A></DL> </DL> <HR> <A NAME="JAVA_1_3"><!-- --></A><H3> JAVA_1_3</H3> <PRE> public static final java.lang.String <B>JAVA_1_3</B></PRE> <DL> <DD>Version constant for Java 1.3 <P> <DL> <DT><B>See Also:</B><DD><A HREF="../../../../../constant-values.html#org.apache.tools.ant.util.JavaEnvUtils.JAVA_1_3">Constant Field Values</A></DL> </DL> <HR> <A NAME="VERSION_1_3"><!-- --></A><H3> VERSION_1_3</H3> <PRE> public static final int <B>VERSION_1_3</B></PRE> <DL> <DD>Number Version constant for Java 1.3 <P> <DL> <DT><B>See Also:</B><DD><A HREF="../../../../../constant-values.html#org.apache.tools.ant.util.JavaEnvUtils.VERSION_1_3">Constant Field Values</A></DL> </DL> <HR> <A NAME="JAVA_1_4"><!-- --></A><H3> JAVA_1_4</H3> <PRE> public static final java.lang.String <B>JAVA_1_4</B></PRE> <DL> <DD>Version constant for Java 1.4 <P> <DL> <DT><B>See Also:</B><DD><A HREF="../../../../../constant-values.html#org.apache.tools.ant.util.JavaEnvUtils.JAVA_1_4">Constant Field Values</A></DL> </DL> <HR> <A NAME="VERSION_1_4"><!-- --></A><H3> VERSION_1_4</H3> <PRE> public static final int <B>VERSION_1_4</B></PRE> <DL> <DD>Number Version constant for Java 1.4 <P> <DL> <DT><B>See Also:</B><DD><A HREF="../../../../../constant-values.html#org.apache.tools.ant.util.JavaEnvUtils.VERSION_1_4">Constant Field Values</A></DL> </DL> <HR> <A NAME="JAVA_1_5"><!-- --></A><H3> JAVA_1_5</H3> <PRE> public static final java.lang.String <B>JAVA_1_5</B></PRE> <DL> <DD>Version constant for Java 1.5 <P> <DL> <DT><B>See Also:</B><DD><A HREF="../../../../../constant-values.html#org.apache.tools.ant.util.JavaEnvUtils.JAVA_1_5">Constant Field Values</A></DL> </DL> <HR> <A NAME="VERSION_1_5"><!-- --></A><H3> VERSION_1_5</H3> <PRE> public static final int <B>VERSION_1_5</B></PRE> <DL> <DD>Number Version constant for Java 1.5 <P> <DL> <DT><B>See Also:</B><DD><A HREF="../../../../../constant-values.html#org.apache.tools.ant.util.JavaEnvUtils.VERSION_1_5">Constant Field Values</A></DL> </DL> <HR> <A NAME="JAVA_1_6"><!-- --></A><H3> JAVA_1_6</H3> <PRE> public static final java.lang.String <B>JAVA_1_6</B></PRE> <DL> <DD>Version constant for Java 1.6 <P> <DL> <DT><B>See Also:</B><DD><A HREF="../../../../../constant-values.html#org.apache.tools.ant.util.JavaEnvUtils.JAVA_1_6">Constant Field Values</A></DL> </DL> <HR> <A NAME="VERSION_1_6"><!-- --></A><H3> VERSION_1_6</H3> <PRE> public static final int <B>VERSION_1_6</B></PRE> <DL> <DD>Number Version constant for Java 1.6 <P> <DL> <DT><B>See Also:</B><DD><A HREF="../../../../../constant-values.html#org.apache.tools.ant.util.JavaEnvUtils.VERSION_1_6">Constant Field Values</A></DL> </DL> <!-- ============ METHOD DETAIL ========== --> <A NAME="method_detail"><!-- --></A> <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY=""> <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"> <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2"> <B>Method Detail</B></FONT></TH> </TR> </TABLE> <A NAME="getJavaVersion()"><!-- --></A><H3> getJavaVersion</H3> <PRE> public static java.lang.String <B>getJavaVersion</B>()</PRE> <DL> <DD>Returns the version of Java this class is running under. <P> <DD><DL> <DT><B>Returns:</B><DD>the version of Java as a String, e.g. "1.6"</DL> </DD> </DL> <HR> <A NAME="getJavaVersionNumber()"><!-- --></A><H3> getJavaVersionNumber</H3> <PRE> public static int <B>getJavaVersionNumber</B>()</PRE> <DL> <DD>Returns the version of Java this class is running under. This number can be used for comparisions; it will always be <P> <DD><DL> <DT><B>Returns:</B><DD>the version of Java as a number 10x the major/minor, e.g Java1.5 has a value of 15</DL> </DD> </DL> <HR> <A NAME="isJavaVersion(java.lang.String)"><!-- --></A><H3> isJavaVersion</H3> <PRE> public static boolean <B>isJavaVersion</B>(java.lang.String version)</PRE> <DL> <DD>Compares the current Java version to the passed in String - assumes the argument is one of the constants defined in this class. Note that Ant now requires JDK 1.4+ so <A HREF="../../../../../org/apache/tools/ant/util/JavaEnvUtils.html#JAVA_1_0"><CODE>JAVA_1_0</CODE></A> through <A HREF="../../../../../org/apache/tools/ant/util/JavaEnvUtils.html#JAVA_1_3"><CODE>JAVA_1_3</CODE></A> need no longer be tested for. <P> <DD><DL> <DT><B>Parameters:</B><DD><CODE>version</CODE> - the version to check against the current version. <DT><B>Returns:</B><DD>true if the version of Java is the same as the given version.<DT><B>Since:</B></DT> <DD>Ant 1.5</DD> </DL> </DD> </DL> <HR> <A NAME="isAtLeastJavaVersion(java.lang.String)"><!-- --></A><H3> isAtLeastJavaVersion</H3> <PRE> public static boolean <B>isAtLeastJavaVersion</B>(java.lang.String version)</PRE> <DL> <DD>Compares the current Java version to the passed in String - assumes the argument is one of the constants defined in this class. Note that Ant now requires JDK 1.4+ so <A HREF="../../../../../org/apache/tools/ant/util/JavaEnvUtils.html#JAVA_1_0"><CODE>JAVA_1_0</CODE></A> through <A HREF="../../../../../org/apache/tools/ant/util/JavaEnvUtils.html#JAVA_1_3"><CODE>JAVA_1_3</CODE></A> need no longer be tested for. <P> <DD><DL> <DT><B>Parameters:</B><DD><CODE>version</CODE> - the version to check against the current version. <DT><B>Returns:</B><DD>true if the version of Java is the same or higher than the given version.<DT><B>Since:</B></DT> <DD>Ant 1.7</DD> </DL> </DD> </DL> <HR> <A NAME="isKaffe()"><!-- --></A><H3> isKaffe</H3> <PRE> public static boolean <B>isKaffe</B>()</PRE> <DL> <DD>Checks whether the current Java VM is Kaffe. <P> <DD><DL> <DT><B>Returns:</B><DD>true if the current Java VM is Kaffe.<DT><B>Since:</B></DT> <DD>Ant 1.6.3</DD> <DT><B>See Also:</B><DD><a href="http://www.kaffe.org/">http://www.kaffe.org/</a></DL> </DD> </DL> <HR> <A NAME="getJreExecutable(java.lang.String)"><!-- --></A><H3> getJreExecutable</H3> <PRE> public static java.lang.String <B>getJreExecutable</B>(java.lang.String command)</PRE> <DL> <DD>Finds an executable that is part of a JRE installation based on the java.home system property. <p><code>java</code>, <code>keytool</code>, <code>policytool</code>, <code>orbd</code>, <code>rmid</code>, <code>rmiregistry</code>, <code>servertool</code> and <code>tnameserv</code> are JRE executables on Sun based JRE's.</p> <p>You typically find them in <code>JAVA_HOME/jre/bin</code> if <code>JAVA_HOME</code> points to your JDK installation. JDK < 1.2 has them in the same directory as the JDK executables.</p> <P> <DD><DL> <DT><B>Parameters:</B><DD><CODE>command</CODE> - the java executable to find. <DT><B>Returns:</B><DD>the path to the command.<DT><B>Since:</B></DT> <DD>Ant 1.5</DD> </DL> </DD> </DL> <HR> <A NAME="getJdkExecutable(java.lang.String)"><!-- --></A><H3> getJdkExecutable</H3> <PRE> public static java.lang.String <B>getJdkExecutable</B>(java.lang.String command)</PRE> <DL> <DD>Finds an executable that is part of a JDK installation based on the java.home system property. <p>You typically find them in <code>JAVA_HOME/bin</code> if <code>JAVA_HOME</code> points to your JDK installation.</p> <P> <DD><DL> <DT><B>Parameters:</B><DD><CODE>command</CODE> - the java executable to find. <DT><B>Returns:</B><DD>the path to the command.<DT><B>Since:</B></DT> <DD>Ant 1.5</DD> </DL> </DD> </DL> <HR> <A NAME="getJrePackageTestCases()"><!-- --></A><H3> getJrePackageTestCases</H3> <PRE> public static java.util.Vector <B>getJrePackageTestCases</B>()</PRE> <DL> <DD>Testing helper method; kept here for unification of changes. <P> <DD><DL> <DT><B>Returns:</B><DD>a list of test classes depending on the java version.</DL> </DD> </DL> <HR> <A NAME="getJrePackages()"><!-- --></A><H3> getJrePackages</H3> <PRE> public static java.util.Vector <B>getJrePackages</B>()</PRE> <DL> <DD>get a vector of strings of packages built into that platforms runtime jar(s) <P> <DD><DL> <DT><B>Returns:</B><DD>list of packages.</DL> </DD> </DL> <HR> <A NAME="createVmsJavaOptionFile(java.lang.String[])"><!-- --></A><H3> createVmsJavaOptionFile</H3> <PRE> public static java.io.File <B>createVmsJavaOptionFile</B>(java.lang.String[] cmd) throws java.io.IOException</PRE> <DL> <DD>Writes the command into a temporary DCL script and returns the corresponding File object. It is the job of the caller to delete the file on exit. <P> <DD><DL> <DT><B>Parameters:</B><DD><CODE>cmd</CODE> - the command. <DT><B>Returns:</B><DD>the file containing the command. <DT><B>Throws:</B> <DD><CODE>java.io.IOException</CODE> - if there is an error writing to the file.</DL> </DD> </DL> <HR> <A NAME="getJavaHome()"><!-- --></A><H3> getJavaHome</H3> <PRE> public static java.lang.String <B>getJavaHome</B>()</PRE> <DL> <DD>Return the value of ${java.home} <P> <DD><DL> <DT><B>Returns:</B><DD>the java home value.</DL> </DD> </DL> <!-- ========= END OF CLASS DATA ========= --> <HR> <!-- ======= START OF BOTTOM NAVBAR ====== --> <A NAME="navbar_bottom"><!-- --></A> <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A> <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY=""> <TR> <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A NAME="navbar_bottom_firstrow"><!-- --></A> <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY=""> <TR ALIGN="center" VALIGN="top"> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A> </TD> <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> <FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A> </TD> </TR> </TABLE> </TD> <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM> </EM> </TD> </TR> <TR> <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2"> <A HREF="../../../../../org/apache/tools/ant/util/IdentityStack.html" title="class in org.apache.tools.ant.util"><B>PREV CLASS</B></A> <A HREF="../../../../../org/apache/tools/ant/util/JAXPUtils.html" title="class in org.apache.tools.ant.util"><B>NEXT CLASS</B></A></FONT></TD> <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2"> <A HREF="../../../../../index.html?org/apache/tools/ant/util/JavaEnvUtils.html" target="_top"><B>FRAMES</B></A> <A HREF="JavaEnvUtils.html" target="_top"><B>NO FRAMES</B></A> <SCRIPT type="text/javascript"> <!-- if(window==top) { document.writeln('<A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>'); } //--> </SCRIPT> <NOSCRIPT> <A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A> </NOSCRIPT> </FONT></TD> </TR> <TR> <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2"> SUMMARY: NESTED | <A HREF="#field_summary">FIELD</A> | CONSTR | <A HREF="#method_summary">METHOD</A></FONT></TD> <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2"> DETAIL: <A HREF="#field_detail">FIELD</A> | CONSTR | <A HREF="#method_detail">METHOD</A></FONT></TD> </TR> </TABLE> <A NAME="skip-navbar_bottom"></A> <!-- ======== END OF BOTTOM NAVBAR ======= --> <HR> </BODY> </HTML>
Ms-Dos/Windows
Unix
Write backup
jsp File Browser version 1.2 by
www.vonloesch.de