Class DeviceList
Object
|
+--DeviceList
- class
DeviceList
A list of devices.
DeviceList is exposed as the opera.nearbyDevices property.
You can access elements in the list as you would access a dictionary, either through the index or the identifier of a device.
device = opera.nearbyDevices[3];
service = opera.nearbyDevices[deviceId];
Defined in service-discovery.js
|
Field Summary |
int |
size
Number of devices in this list. |
|
Constructor Summary |
DeviceList()
This class has no public constructor.
|
size
int size
Number of devices in this list. Readonly.
DeviceList
DeviceList()
This class has no public constructor.
getDeviceByID
DeviceDescriptor getDeviceByID( <String> id )
Get the device with the given id from the list.
Parameters:
id - Identifier of the device to retrieve.
Returns:
Device with the given identifier, or undefined if no device has the given identifier.
getDeviceByIndex
DeviceDescriptor getDeviceByIndex( <int> index )
Get the device at the given position in the list
Parameters:
index - Positive integer denoting the position of the device in the list.
Returns:
Device at the given position, or undefined if the index is out of bounds.
Documentation generated by
JSDoc on Fri Aug 14 11:46:31 2009