Remy Maucherat wrote:

Jean-Francois Arcand wrote:

Hi Remy,

the servlet doesn't compile with JDK 1.3.x :

StatusManagerServlet.java:274: cannot resolve symbol
   [javac] symbol  : method maxMemory  ()
   [javac] location: class java.lang.Runtime
   [javac]         writer.print(Runtime.getRuntime().maxMemory());
   [javac]                                        ^
   [javac] Note: Some input files use or override a deprecated API.
   [javac] Note: Recompile with -deprecation for details.
   [javac] 1 error

This method is only available with JDK 1.4 +.


Any ideas of alternatives ?

I've just look at the jdk souce code and this method is native :-(, so I don't see an easy way to port it....Maybe you can use reflection and return |Long.MAX_VALUE| <http://java.sun.com/j2se/1.4.1/docs/api/java/lang/Long.html#MAX_VALUE> if jdk < 1.4?


-- Jeanfrancois



Remy


--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]




---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to