Sha256: d48c3784b25ed969972106735848ceaf77ec0ac79e9736ce0510b72a2ca416f5

Contents?: true

Size: 709 Bytes

Versions: 3

Compression:

Stored size: 709 Bytes

Contents

module VirtualBox
  module Version
    # Returns a boolean denoting whether the current VirtualBox
    # version is supported or not. This will return `false` if the
    # version is invalid, the version is not detected, etc. That means
    # that even if VirtualBox is not installed, this will simply
    # return `false`.
    #
    # @return [Boolean]
    def supported?
      !version.nil?
    end

    # Returns the version string of the VirtualBox installed, ex. "3.1.6"
    def version
      Lib.lib.virtualbox.version
    rescue Exception
      nil
    end

    # Returns the revision string of the VirtualBox installed, ex. "51742"
    def revision
      Lib.lib.virtualbox.revision
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
virtualbox-0.7.2 lib/virtualbox/version.rb
virtualbox-0.7.1 lib/virtualbox/version.rb
virtualbox-0.7.0 lib/virtualbox/version.rb