Method: Uv::RenderProcessor#options

Defined in:
lib/uv/render_processor.rb

#options(stack) ⇒ Object



119
120
121
122
123
124
125
126
127
128
# File 'lib/uv/render_processor.rb', line 119

def options stack
   ref = stack.join ' '
   return @options[ref] if @options.has_key? ref
   
   result = @render_options['tags'].max do |a, b| 
      @score_manager.score( a['selector'], ref ) <=> @score_manager.score( b['selector'], ref )
   end
   result = nil if @score_manager.score( result['selector'], ref ) == 0
   @options[ref] = result
end