Module: GOffice::Version

Defined in:
lib/goffice/version.rb

Constant Summary collapse

STRING =
[MAJOR, MINOR, MICRO].compact.join(".")

Class Method Summary collapse

Class Method Details

.or_later?(major, minor, micro = nil) ⇒ Boolean

Returns:

  • (Boolean)


22
23
24
25
26
27
28
29
30
# File 'lib/goffice/version.rb', line 22

def or_later?(major, minor, micro=nil)
  micro ||= 0
  version = [
    MAJOR,
    MINOR,
    MICRO || 0,
  ].compact
  (version <=> [major, minor, micro]) >= 0
end