![]() | Title.id Property |
The id uniquely identifies a Title in the collection database. The id is used as the database primary key. The id string has the format T-XXXXXXXXXXXX where the 12 X characters are strongly random and taken from a pool of 34 easily identifiable alphanumeric uppercase characters. There are therefore about 2.4×1018 possible Ids assuming a flat distribution, which is about 61 bits of entropy. The chance of a birthday collision rises to 0.1% at around 68 million, and rises to 1% at around 215 million. Since the total number of titles in the database is around 6700, the probability of a collision is about 10-11 (see Birthday Attack).
Note that the default id value is the special sentinel value UnassignedId so that this class can be passed into the web service and pass validation on the property. The service layer will recognise the special value and convert it into a valid random id before the Title is saved.