Exception: Solve::Errors::InvalidVersionFormat

Inherits:
SolveError
  • Object
show all
Defined in:
lib/solve/errors.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(version) ⇒ InvalidVersionFormat

Returns a new instance of InvalidVersionFormat.

Parameters:



12
13
14
# File 'lib/solve/errors.rb', line 12

def initialize(version)
  @version = version
end

Instance Attribute Details

#versionObject (readonly)

Returns the value of attribute version.



9
10
11
# File 'lib/solve/errors.rb', line 9

def version
  @version
end

Instance Method Details

#to_sObject



16
17
18
# File 'lib/solve/errors.rb', line 16

def to_s
  "'#{version}' did not contain a valid version string: 'x.y.z' or 'x.y'."
end