module VersionGem::Api
def _to_a
-
(Array
-)
def _to_a @_to_a = self::VERSION.split(".") end
def major
-
(Integer)
-
def major @major ||= _to_a[0].to_i end
def minor
-
(Integer)
-
def minor @minor ||= _to_a[1].to_i end
def patch
-
(Integer)
-
def patch @patch ||= _to_a[2].to_i end
def pre
-
(String, NilClass)
-
def pre @pre ||= _to_a[3] end
def to_a
-
(Array<[Integer, String, NilClass]>)
-
def to_a @to_a ||= [major, minor, patch, pre] end
def to_h
-
(Hash)
-
def to_h @to_h ||= { major: major, minor: minor, patch: patch, pre: pre, } end
def to_s
-
(String)
-
def to_s self::VERSION end