lib/nanoc/base/compilation/rules_collection.rb
def routing_rules_for(rep)
      rules = {}
      @item_routing_rules.each do |rule|
        next if !rule.applicable_to?(rep.item)
        next if rule.rep_name != rep.name
        next if rules.has_key?(rule.snapshot_name)

        rules[rule.snapshot_name] = rule
      end
      rules
    end
# Returns the list of routing rules that can be applied to the given item
# representation. For each snapshot, the first matching rule will be
# returned. The result is a hash containing the corresponding rule for
# each snapshot.
#
# @param [Nanoc::ItemRep] rep The item rep for which to fetch the rules
#
# @return [Hash<Symbol, Nanoc::Rule>] The routing rules for the given rep
Returns the list of routing rules that can be applied to the given item
representation. For each snapshot, the first matching rule will be
returned. The result is a hash containing the corresponding rule for
each snapshot.
Returns the list of routing rules that can be applied to the given item representation . For each snapshot the first matching rule will be returned . The result is a hash containing the corresponding rule for each snapshot .
def routing_rules_for(rep)
      rules = {}
      @item_routing_rules.each do |rule|
        next if !rule.applicable_to?(rep.item)
        next if rule.rep_name != rep.name
        next if rules.has_key?(rule.snapshot_name)
        rules[rule.snapshot_name] = rule
      end
      rules
    end
def routing_rules_for ( rep ) rules = { } @item_routing_rules . each do | rule | next if ! rule . applicable_to? ( rep . item ) next if rule . rep_name != rep . name next if rules . has_key? ( rule . snapshot_name ) rules [ rule . snapshot_name ] = rule end rules end
Returns the list of routing rules that can be applied to the given item
representation.
Returns the list of routing rules that can be applied to the given item representation .
The routing rules for the given rep
The routing rules for the given rep
Hash<Symbol, Nanoc::Rule>
rep
rep The item rep for which to fetch the rules
rep The item rep for which to fetch the rules