Module: Nanite::Identity

Defined in:
lib/nanite/identity.rb

Class Method Summary collapse

Class Method Details

.generateObject



3
4
5
6
7
8
9
10
11
12
13
14
# File 'lib/nanite/identity.rb', line 3

def self.generate
  values = [
    rand(0x0010000),
    rand(0x0010000),
    rand(0x0010000),
    rand(0x0010000),
    rand(0x0010000),
    rand(0x1000000),
    rand(0x1000000),
  ]
  "%04x%04x%04x%04x%04x%06x%06x" % values
end