Exception: Safer::Protocol::Error::InstanceError

Inherits:
Safer::Protocol::Error show all
Defined in:
lib/safer/protocol.rb

Overview

Error generated when an instance object does not conform to a desired protocol.

Instance Method Summary collapse

Methods inherited from Safer::Protocol::Error

#==, #self

Constructor Details

#initialize(error_object, protocol, class_violations, instance_violations) ⇒ InstanceError

Create a Safer::Protocol::Error::InstanceError object.



324
325
326
327
328
329
# File 'lib/safer/protocol.rb', line 324

def initialize(error_object, protocol, class_violations, instance_violations)
  super(
    "Instance of #{error_object.class} does not implement protocol" +
      "#{protocol.name}.",
    error_object, protocol, class_violations, instance_violations)
end