• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Is there an API to access sytem hardware information?

 
Matt Kidd
Ranch Hand
Posts: 267
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm currently working on a diagnostic page and it needs to report as much system information as possible.

Is there an API for this?

If I have to hand code this where would I start?

Addendum: okay I just found System.getProperties but that so far doesn't seem to tell me how to check drive space. I'll update in a couple hours what I've determined I can actually get information on.

Just found the Runtime class which will allow me to run commands at hte command line.

FYI, I'm coding this within the WebObjects Framework.
[ February 22, 2007: Message edited by: Matt Kidd ]
[ February 22, 2007: Message edited by: Matt Kidd ]
 
Jesper de Jong
Java Cowboy
Saloon Keeper
Posts: 15205
36
Android IntelliJ IDE Java Scala Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Which Java version are you using?

In Java 6, some methods were added in class java.io.File such as getFreeSpace() and getUsableSpace() which you can use to find out how much space is available on a partition.
 
Matt Kidd
Ranch Hand
Posts: 267
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Jesper Young:
Which Java version are you using?

In Java 6, some methods were added in class java.io.File such as getFreeSpace() and getUsableSpace() which you can use to find out how much space is available on a partition.


1.5.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic