Module: Headdesk::Apk::ExtraMethods

Defined in:
lib/headdesk/apk/field.rb

Overview

Extra methods for ‘value’

Instance Method Summary collapse

Instance Method Details

#to_versionObject



23
24
25
# File 'lib/headdesk/apk/field.rb', line 23

def to_version
  /^(\d+\.)?(\d+\.)?(\*|\d+)$/.match(self).captures.map(&:to_i)
end