public class BluetoothUuid
extends java.lang.Object
BluetoothUuid
class represents the UUID of a service or attribute.
UUIDs may be created from a string representing a 128-bit UUID or from an integer containing a 16-bit UUID.
A string representation of a UUID may be retrieved by calling the method toString()
of the object.
Constructor and Description |
---|
BluetoothUuid(int value)
Creates a UUID from an integer.
|
BluetoothUuid(java.lang.String string)
Creates a UUID from a string.
|
public BluetoothUuid(java.lang.String string)
string
- a string representing a 128-bit UUID.java.lang.IllegalArgumentException
- if the given string is null or if is does not represent a 128-bit UUID.public BluetoothUuid(int value)
value
- an integer representing a 16-bit UUID.java.lang.IllegalArgumentException
- if the given value does not represent a 16-bit UUID.