public interface DriverHandler
Modifier and Type | Method and Description |
---|---|
<T extends Behaviour> |
behaviour(java.lang.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(java.lang.Class<T> serviceClass)
Returns the reference to the implementation of the specified service.
|
default boolean |
hasBehaviour(java.lang.Class<? extends Behaviour> behaviourClass)
Indicates whether or not the driver, or any of its parents, support
the specified class of behaviour.
|
Driver driver()
DriverData data()
<T extends Behaviour> T behaviour(java.lang.Class<T> behaviourClass)
T
- type of behaviourbehaviourClass
- behaviour classdefault boolean hasBehaviour(java.lang.Class<? extends Behaviour> behaviourClass)
behaviourClass
- behaviour class<T> T get(java.lang.Class<T> serviceClass)
T
- type of serviceserviceClass
- service classServiceNotFoundException
- if service is unavailable