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.



143
144
145
146
147
148
149
# File 'lib/fontist/errors.rb', line 143

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.



141
142
143
# File 'lib/fontist/errors.rb', line 141

def current_platform
  @current_platform
end

#required_platformsObject (readonly)

Returns the value of attribute required_platforms.



141
142
143
# File 'lib/fontist/errors.rb', line 141

def required_platforms
  @required_platforms
end