class Ghundle::HookVersion
Attributes
major[R]
minor[R]
patch[R]
Public Class Methods
new(string)
click to toggle source
# File lib/ghundle/hook_version.rb, line 5 def initialize(string) @major, @minor, @patch = string.split('.').map(&:to_i) end
Public Instance Methods
<=>(other)
click to toggle source
# File lib/ghundle/hook_version.rb, line 19 def <=>(other) to_s <=> other.to_s end
==(other)
click to toggle source
# File lib/ghundle/hook_version.rb, line 13 def ==(other) to_s == other.to_s end
to_s()
click to toggle source
# File lib/ghundle/hook_version.rb, line 9 def to_s "#{major}.#{minor}.#{patch}" end