    # File lib/chef/cookbook_loader.rb, line 71
        def [](cookbook)
          if @cookbooks_by_name.has_key?(cookbook.to_sym)
            @cookbooks_by_name[cookbook.to_sym]
          else
            raise Exceptions::CookbookNotFoundInRepo, "Cannot find a cookbook named #{cookbook.to_s}; did you forget to add metadata to a cookbook? (http://wiki.opscode.com/display/chef/Metadata)"
          end
        end