Factor out UUID handling into new uuid class