Sha256: 870ecfcf1ed408dc6ad1e6ae313b64dab7da460155b9c496a83e500aff124099

Contents?: true

Size: 405 Bytes

Versions: 1

Compression:

Stored size: 405 Bytes

Contents

# -*- encoding: utf-8 -*-

require 'webgen/content_processor'

module Webgen
  class ContentProcessor

    # Processes the content that is valid Ruby to generate new content.
    module Ruby

      # Process the content of +context+ which needs to be valid Ruby code.
      def self.call(context)
        eval(context.content, binding, context.ref_node.alcn)
        context
      end

    end

  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
webgen-1.0.0.beta1 lib/webgen/content_processor/ruby.rb