windows底下实现有现成的API调用, java说是与底层无关,就不知它如何实现了
帮你顶.

解决方案 »

  1.   

    看好了,j   
    private void loadDrivers(JComboBox cmbBox)
    {
       File currentPath=new File(".");
       File[] drivers=currentPath.listRoots();
       for(int i=0;i<drivers.length-1;i++)
         {
             comBox.addItem(driver[i].toString());
         }
       String path=currentPath.getAbsolutePath();
       if(path.indexOf(cmbBox.getItemAt(i).toString().trim())>=0
    {}
      

  2.   

    1.不知道2.分区信息?
    linux:
    open(deviceName, O_RDWR)
    windows:不知道,但是应该差不多。