class String
Public Instance Methods
crc32()
click to toggle source
# File lib/core-extensions/uids.rb, line 4 def crc32 Zlib.crc32(self) end
md5()
click to toggle source
# File lib/core-extensions/uids.rb, line 8 def md5 Digest::MD5.hexdigest(self) end
uid64()
click to toggle source
return a 64 bit uid
# File lib/core-extensions/uids.rb, line 13 def uid64 md5.unpack("LL").inject { |a,b| (a << 31) + b } end