Package org.jnode.driver

Examples of org.jnode.driver.DriverException


            for (IDEDiskPartitionDevice partition : toStop) {
                devMan.unregister(partition);
            }
        } catch (NameNotFoundException e) {
            throw new DriverException("Problem while stopping this IDE device", e);
        }

        dev.unregisterAPI(BlockDeviceAPI.class);
        this.pt = null;
    }
View Full Code Here


            final long length = dev.getSectors() * SECTOR_SIZE;
            this.mapping = new MappedBlockDeviceSupport(parent, offset, length);
            /* Register the FSBlockDevice API */
            device.registerAPI(FSBlockDeviceAPI.class, this);
        } catch (IOException ex) {
            throw new DriverException("Error in MappedBlockDeviceSupport", ex);
        }
    }
View Full Code Here

    protected void startDevice() throws DriverException {
        try {
            NFS2Device device = (NFS2Device) getDevice();
            device.getManager().rename(device, device.getId(), true);
        } catch (DeviceAlreadyRegisteredException ex) {
            throw new DriverException(ex);
        }
    }
View Full Code Here

    protected void startDevice() throws DriverException {
        try {
            FTPFSDevice device = (FTPFSDevice) getDevice();
            device.getManager().rename(device, device.getId(), true);
        } catch (DeviceAlreadyRegisteredException ex) {
            throw new DriverException(ex);
        }
    }
View Full Code Here

    protected void startDevice() throws DriverException {
        try {
            SMBFSDevice device = (SMBFSDevice) getDevice();
            device.getManager().rename(device, device.getId(), true);
        } catch (DeviceAlreadyRegisteredException ex) {
            throw new DriverException(ex);
        }
    }
View Full Code Here

            devices.clear();
            fdc = FloppyDriverUtils.getFloppyDeviceFactory().createFDC(getDevice());
            bus = new FloppyControllerBus(this);
            registerDevices();
        } catch (FloppyException ex) {
            throw new DriverException("Cannot register drives", ex);
        } catch (ResourceNotFreeException ex) {
            throw new DriverException("Cannot claim all resources", ex);
        } catch (NamingException ex) {
            throw new DriverException("Cannot obtain device factory", ex);
        }
    }
View Full Code Here

                }
            });
        } catch (ResourceNotFreeException ex) {
            throw ex;
        } catch (Exception ex) {
            throw new DriverException("Unknown exception", ex);
        }

    }
View Full Code Here

            // Execute INQUIRY
            try {
                scsiDevice.inquiry();
            } catch (SCSIException ex) {
                throw new DriverException("Cannot INQUIRY device", ex);
            } catch (TimeoutException ex) {
                throw new DriverException("Cannot INQUIRY device : timeout", ex);
            } catch (InterruptedException ex) {
                throw new DriverException("Interrupted while INQUIRY device", ex);
            }
            // Register the generic SCSI device.
            try {
                final DeviceManager dm = usbDevice.getManager();
                dm.rename(scsiDevice, "sg", true);
                dm.register(scsiDevice);
                dm.rename(usbDevice, SCSIHostControllerAPI.DEVICE_PREFIX, true);
            } catch (DeviceAlreadyRegisteredException ex) {
                throw new DriverException(ex);
            }
        } catch (USBException e) {
            throw new DriverException(e);
        }

    }
View Full Code Here

                this.device.registerAPI(BlockDeviceAPI.class, this);
            } else {
                this.device.registerAPI(FSBlockDeviceAPI.class, this);
            }
        } catch (DeviceAlreadyRegisteredException ex) {
            throw new DriverException(ex);
        }
    }
View Full Code Here

                //((USBStorageBulkTransport)USBMassStorage.getTransport()).getMaxLun(usbDev);
                break;
            case US_PR_SCM_ATAPI:
                log.info("*** Set transport protocol to SCM ATAPI");
            default:
                throw new DriverException("Transport protocol not implemented.");
        }

        USBEndPoint ep;
        for (int i = 0; i < intf.getNumEndPoints(); i++) {
            ep = this.usbInterface.getEndPoint(i);
View Full Code Here

TOP

Related Classes of org.jnode.driver.DriverException

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.