Exception: Dataset::RecordNotFound

Inherits:
StandardError
  • Object
show all
Defined in:
lib/dataset/session_binding.rb

Overview

An error that will be raised when an attempt is made to load a named model that doesn’t exist. For example, if you do people(:jenny), and yet no record was ever created with the symbolic name :jenny, this error will be raised.

Instance Method Summary collapse

Constructor Details

#initialize(record_heirarchy, symbolic_name) ⇒ RecordNotFound

Returns a new instance of RecordNotFound.



8
9
10
# File 'lib/dataset/session_binding.rb', line 8

def initialize(record_heirarchy, symbolic_name)
  super "There is no '#{record_heirarchy.base_class.name}' found for the symbolic name ':#{symbolic_name}'."
end