File: uuid.rb

package info (click to toggle)
ruby-fog-core 2.6.0-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 684 kB
  • sloc: ruby: 4,812; makefile: 5
file content (16 lines) | stat: -rw-r--r-- 298 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
require "securerandom"

module Fog
  class UUID
    class << self
      def uuid
        SecureRandom.uuid
      end

      # :nodoc: This method is used by other plugins, so preserve it for the compatibility
      def supported?
        SecureRandom.respond_to?(:uuid)
      end
    end
  end
end