Adding UID support.

A few other miscellaneous additions as well. More to come.