public class DefaultDriverHandler extends Object implements DriverHandler
| Modifier and Type | Field and Description | 
|---|---|
protected static ServiceDirectory | 
serviceDirectory  | 
| Constructor and Description | 
|---|
DefaultDriverHandler(DriverData data)
Creates new driver handler with the attached driver data. 
 | 
| Modifier and Type | Method and Description | 
|---|---|
<T extends Behaviour> | 
behaviour(Class<T> behaviourClass)
Returns the specified facet of behaviour to interact with the device. 
 | 
DriverData | 
data()
Returns the device driver data. 
 | 
Driver | 
driver()
Returns the parent device driver. 
 | 
<T> T | 
get(Class<T> serviceClass)
Returns the reference to the implementation of the specified service. 
 | 
String | 
toString()  | 
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waithasBehaviourprotected static ServiceDirectory serviceDirectory
public DefaultDriverHandler(DriverData data)
data - driver data to attachpublic Driver driver()
DriverHandlerdriver in interface DriverHandlerpublic DriverData data()
DriverHandlerdata in interface DriverHandlerpublic <T extends Behaviour> T behaviour(Class<T> behaviourClass)
DriverHandlerbehaviour in interface DriverHandlerT - type of behaviourbehaviourClass - behaviour classpublic <T> T get(Class<T> serviceClass)
DriverHandlerget in interface DriverHandlerT - type of serviceserviceClass - service class