def items
      if provider.is_a?(Symbol)
        SimpleNavigation.context_for_eval.send(provider)
      elsif provider.respond_to?(:items)
        provider.items
      elsif provider.respond_to?(:each)
        provider
      else
        fail('items_provider either must be a symbol specifying the '         \
             'helper-method to call, an object with an items-method defined ' \
             'or an enumerable representing the items')
      end
    end
def items
      if provider.is_a?(Symbol)
        SimpleNavigation.context_for_eval.send(provider)
      elsif provider.respond_to?(:items)
        provider.items
      elsif provider.respond_to?(:each)
        provider
      else
        fail('items_provider either must be a symbol specifying the '         \
             'helper-method to call, an object with an items-method defined ' \
             'or an enumerable representing the items')
      end
    end
It accepts the following types of provider:
 * methodname as symbol - the specified method should return the relevant
   items and has to be available in the view (a helper method)
 * object that responds to :items
 * enumerable object that represents the items

 See SimpleNavigation::ItemAdapter for the requirements that need to be
 fulfilled by the provided items.

 Returns the navigation items