You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: handlers.rb
    path of file: ./repos/jsonapi_parameters/lib/jsonapi_parameters
    
    the code of the file until where you have to start completion: require_relative 'default_handlers/nil_relation_handler'
r
    
      def set_resource_handler(resource_key, handler_key)
        unless handlers.key?(handler_key)
          raise NotImplementedError.new(
            'handler_key does not match any registered handlers'
          )
        end

        resource_handlers[resource_key.to_sym] = handler_key.to_sym
      end