Package com.diozero.api
Class OutputDeviceCollection
- java.lang.Object
-
- com.diozero.api.OutputDeviceCollection
-
- All Implemented Interfaces:
OutputDeviceInterface
- Direct Known Subclasses:
Servo.Array
public class OutputDeviceCollection extends Object implements OutputDeviceInterface
A collection of output devices to simplify setting the same output value for a number of devices at the same time
-
-
Constructor Summary
Constructors Constructor Description OutputDeviceCollection(OutputDeviceInterface... devices)
OutputDeviceCollection(Collection<OutputDeviceInterface> devices)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Collection<OutputDeviceInterface>
getDevices()
void
setValue(float value)
Set the same value to all output devices in this collection
-
-
-
Constructor Detail
-
OutputDeviceCollection
public OutputDeviceCollection(OutputDeviceInterface... devices)
-
OutputDeviceCollection
public OutputDeviceCollection(Collection<OutputDeviceInterface> devices)
-
-
Method Detail
-
getDevices
public Collection<OutputDeviceInterface> getDevices()
-
setValue
public void setValue(float value)
Set the same value to all output devices in this collection- Specified by:
setValue
in interfaceOutputDeviceInterface
- Parameters:
value
- the value to output
-
-