Module: OAuth2::Version
- Defined in:
- lib/oauth2/version.rb
Constant Summary collapse
- VERSION =
to_s
Class Method Summary collapse
-
.major ⇒ Integer
The major version.
-
.minor ⇒ Integer
The minor version.
-
.patch ⇒ Integer
The patch version.
-
.pre ⇒ Integer, NilClass
The pre-release version, if any.
-
.to_a ⇒ Array
The version number as an array.
-
.to_h ⇒ Hash
The version number as a hash.
-
.to_s ⇒ String
The version number as a string.
Class Method Details
.major ⇒ Integer
The major version
10 11 12 |
# File 'lib/oauth2/version.rb', line 10 def major 1 end |
.minor ⇒ Integer
The minor version
17 18 19 |
# File 'lib/oauth2/version.rb', line 17 def minor 4 end |
.patch ⇒ Integer
The patch version
24 25 26 |
# File 'lib/oauth2/version.rb', line 24 def patch 6 end |
.pre ⇒ Integer, NilClass
The pre-release version, if any
31 32 33 |
# File 'lib/oauth2/version.rb', line 31 def pre nil end |
.to_a ⇒ Array
The version number as an array
50 51 52 |
# File 'lib/oauth2/version.rb', line 50 def to_a [major, minor, patch, pre].compact end |
.to_h ⇒ Hash
The version number as a hash
38 39 40 41 42 43 44 45 |
# File 'lib/oauth2/version.rb', line 38 def to_h { :major => major, :minor => minor, :patch => patch, :pre => pre, } end |
.to_s ⇒ String
The version number as a string
57 58 59 |
# File 'lib/oauth2/version.rb', line 57 def to_s to_a.join('.') end |