Move the string to type parsing into UniqueIdType