Exception: Fontist::Errors::PlatformMismatchError

Inherits:
FontError show all
Defined in:
lib/fontist/errors.rb

Instance Attribute Summary collapse

Attributes inherited from FontError

#font, #style

Instance Method Summary collapse

Methods inherited from FontError

#name

Constructor Details

#initialize(font_name, required_platforms, current_platform) ⇒ PlatformMismatchError

Returns a new instance of PlatformMismatchError.



156
157
158
159
160
161
162
# File 'lib/fontist/errors.rb', line 156

def initialize(font_name, required_platforms, current_platform)
  @required_platforms = Array(required_platforms)
  @current_platform = current_platform

  msg = build_message(font_name)
  super(msg, font_name)
end

Instance Attribute Details

#current_platformObject (readonly)

Returns the value of attribute current_platform.



154
155
156
# File 'lib/fontist/errors.rb', line 154

def current_platform
  @current_platform
end

#required_platformsObject (readonly)

Returns the value of attribute required_platforms.



154
155
156
# File 'lib/fontist/errors.rb', line 154

def required_platforms
  @required_platforms
end