module Snippr::Processor

Public Class Methods

process(content, opts, including_snippet) click to toggle source

Sends the given content and opts to all the configured processors and returns the result.

# File lib/snippr/processor.rb, line 13
def self.process(content, opts, including_snippet)
  opts[:_parent] = including_snippet
  @processors.inject(content) {|c, processor| processor.process c, opts}
end
processors() click to toggle source

Returns a (modifiable) list of processors that'll be used to process the content.

# File lib/snippr/processor.rb, line 8
def self.processors
  @processors ||= []
end