Results 1 to 5 of 5
  1. #1
    ankitmcgill is offline Member
    Join Date
    Nov 2008
    Posts
    22
    Rep Power
    0

    Default Read contents of CD/DVD

    Hi all,

    Wondering how would I go about reading the contents of a cd/dvd using java.

    by contents I mean the following information:
    - files + folders
    - file size/folder size
    - disk label

    any help would be much appreciated.

    -ankit

  2. #2
    angryboy's Avatar
    angryboy is offline Senior Member
    Join Date
    Jan 2009
    Posts
    742
    Rep Power
    6

    Default

    the File and FileSystemView class gives you info on file/folder.
    Get the volume label - Real's Java How-to
    USE CODE TAGS--> [CODE]...[/CODE]
    Get NotePad++ (free)

  3. #3
    markw8500's Avatar
    markw8500 is offline Senior Member
    Join Date
    Jul 2008
    Location
    Pennsylvania, USA
    Posts
    136
    Rep Power
    0

    Default

    What operating system are you using, because if you are using linux you can mount the drive with a system command (Process Findspace = Runtime.getRuntime().exec(Command)) and read the directory that you mount it to... Not sure about windows...
    Who Cares... As Long As It Works...

  4. #4
    ankitmcgill is offline Member
    Join Date
    Nov 2008
    Posts
    22
    Rep Power
    0

    Default

    Quote Originally Posted by markw8500 View Post
    What operating system are you using, because if you are using linux you can mount the drive with a system command (Process Findspace = Runtime.getRuntime().exec(Command)) and read the directory that you mount it to... Not sure about windows...
    idealy i would prefer the app to be platform independent. so if i could somehow
    detect what os the app is running on and then execute code based on that tha would be perfect ...

  5. #5
    markw8500's Avatar
    markw8500 is offline Senior Member
    Join Date
    Jul 2008
    Location
    Pennsylvania, USA
    Posts
    136
    Rep Power
    0

    Default

    You can get the os by:
    Java Code:
    .String os = System.getProperty( "os.name" );
    .
    Who Cares... As Long As It Works...

Similar Threads

  1. Replies: 2
    Last Post: 05-11-2009, 11:07 AM
  2. plugin help contents
    By janpol1 in forum Eclipse
    Replies: 0
    Last Post: 03-03-2009, 01:52 PM
  3. Replies: 5
    Last Post: 10-17-2008, 03:13 PM
  4. Concatenation file contents
    By Java Tip in forum Java Tip
    Replies: 1
    Last Post: 02-07-2008, 02:29 PM
  5. Reading web contents
    By javaplus in forum Networking
    Replies: 2
    Last Post: 11-29-2007, 11:28 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •