com.eurotech.framework.linux.usb
Class UsbServiceImpl

java.lang.Object
  extended by com.eurotech.framework.linux.usb.UsbServiceImpl
All Implemented Interfaces:
LinuxUdevListener, UsbService

public class UsbServiceImpl
extends Object
implements UsbService, LinuxUdevListener


Constructor Summary
UsbServiceImpl()
           
 
Method Summary
protected  void activate(org.osgi.service.component.ComponentContext componentContext)
           
 void attached(UsbDevice device)
          Callback for notifications of new UsbDevice ATTACH events
protected  void deactivate(org.osgi.service.component.ComponentContext componentContext)
           
 void detached(UsbDevice device)
          Callback for notifications of new UsbDevice DETACH events
 List<UsbBlockDevice> getUsbBlockDevices()
          Gets the USB block devices on the gateway
 List<? extends UsbDevice> getUsbDevices()
          Gets the USB devices on the gateway
 List<UsbNetDevice> getUsbNetDevices()
          Gets the USB network devices on the gateway
 UsbServices getUsbServices()
          Gets the UsbServices currently available as specified by JSR-80 in the javax.usb
 List<UsbTtyDevice> getUsbTtyDevices()
          Gets the USB TTY devices on the gateway
 void setEventAdmin(org.osgi.service.event.EventAdmin eventAdmin)
           
 void unsetEventAdmin(org.osgi.service.event.EventAdmin eventAdmin)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

UsbServiceImpl

public UsbServiceImpl()
Method Detail

activate

protected void activate(org.osgi.service.component.ComponentContext componentContext)

deactivate

protected void deactivate(org.osgi.service.component.ComponentContext componentContext)

setEventAdmin

public void setEventAdmin(org.osgi.service.event.EventAdmin eventAdmin)

unsetEventAdmin

public void unsetEventAdmin(org.osgi.service.event.EventAdmin eventAdmin)

getUsbServices

public UsbServices getUsbServices()
                           throws EsfException
Description copied from interface: UsbService
Gets the UsbServices currently available as specified by JSR-80 in the javax.usb

Specified by:
getUsbServices in interface UsbService
Returns:
The currently available javax.usb.UsbServices
Throws:
EsfException

getUsbDevices

public List<? extends UsbDevice> getUsbDevices()
Description copied from interface: UsbService
Gets the USB devices on the gateway

Specified by:
getUsbDevices in interface UsbService
Returns:
The currently attached USB devices

getUsbBlockDevices

public List<UsbBlockDevice> getUsbBlockDevices()
Description copied from interface: UsbService
Gets the USB block devices on the gateway

Specified by:
getUsbBlockDevices in interface UsbService
Returns:
The currently attached USB block devices

getUsbNetDevices

public List<UsbNetDevice> getUsbNetDevices()
Description copied from interface: UsbService
Gets the USB network devices on the gateway

Specified by:
getUsbNetDevices in interface UsbService
Returns:
The currently attached USB network devices

getUsbTtyDevices

public List<UsbTtyDevice> getUsbTtyDevices()
Description copied from interface: UsbService
Gets the USB TTY devices on the gateway

Specified by:
getUsbTtyDevices in interface UsbService
Returns:
The currently attached USB TTY devices

attached

public void attached(UsbDevice device)
Description copied from interface: LinuxUdevListener
Callback for notifications of new UsbDevice ATTACH events

Specified by:
attached in interface LinuxUdevListener
Parameters:
device - The UsbDevice that was just attached

detached

public void detached(UsbDevice device)
Description copied from interface: LinuxUdevListener
Callback for notifications of new UsbDevice DETACH events

Specified by:
detached in interface LinuxUdevListener
Parameters:
device - The UsbDevice that was just detached


Copyright © 2013. All Rights Reserved.