code: def _ReferenceFromSerialized(serialized):
    
    if not isinstance(serialized, basestring):
      raise TypeError('serialized must be a string; received %r' % serialized)
    elif isinstance(serialized, unicode):
      serialized = serialized.encode('utf8')
    return entity_pb.Reference(serialized)
docs: Construct a Reference from a serialized Reference.