Set the this UID, or generates a new UID, if uid is null or an empty string.
uid
an ComponentAlarm
a UID to set, or null or empty string to generate new