# File sql-list.rb, line 40 def [] (key) # create a new instance obj = instance_eval(@classname + ".new") # set the primary key obj.instance_eval("@" + @symbol + " = ObjectSpace._id2ref(" + key.id.to_s + ")") # load the object from the database obj.select (@dbi) return obj end