Module: ORB
- Extended by:
- ActiveSupport::Autoload
- Defined in:
- lib/orb/rails_derp.rb,
lib/orb.rb,
lib/orb/ast.rb,
lib/orb/token.rb,
lib/orb/errors.rb,
lib/orb/parser.rb,
lib/orb/temple.rb,
lib/orb/railtie.rb,
lib/orb/version.rb,
lib/orb/document.rb,
lib/orb/patterns.rb,
lib/orb/template.rb,
lib/orb/tokenizer.rb,
lib/orb/utils/erb.rb,
lib/orb/utils/orb.rb,
lib/orb/tokenizer2.rb,
lib/orb/ast/tag_node.rb,
lib/orb/ast/attribute.rb,
lib/orb/ast/root_node.rb,
lib/orb/ast/text_node.rb,
lib/orb/temple/engine.rb,
lib/orb/temple/parser.rb,
lib/orb/ast/block_node.rb,
lib/orb/rails_template.rb,
lib/orb/render_context.rb,
lib/orb/temple/filters.rb,
lib/orb/temple/compiler.rb,
lib/orb/temple/identity.rb,
lib/orb/ast/newline_node.rb,
lib/orb/ast/abstract_node.rb,
lib/orb/temple/generators.rb,
lib/orb/ast/public_comment_node.rb,
lib/orb/ast/private_comment_node.rb,
lib/orb/temple/attributes_compiler.rb,
lib/orb/ast/control_expression_node.rb,
lib/orb/ast/printing_expression_node.rb
Overview
TODO: This class is a WIP and not used in production code, yet.
Eventually this class will be used to generate the Ruby code from the AST. It tries to match the behaviour of the rails ERB Template handler as close as possible.
Defined Under Namespace
Modules: AST, Patterns, Temple, Utils Classes: CompilerError, Document, Error, Parser, ParserError, RailsDerp, RailsTemplate, Railtie, RenderContext, SyntaxError, Template, Token, Tokenizer, Tokenizer2
Constant Summary collapse
- VERSION =
"0.1.0"
Class Method Summary collapse
Class Method Details
.html_escape(str) ⇒ Object
44 45 46 |
# File 'lib/orb.rb', line 44 def self.html_escape(str) CGI.escapeHTML(str.to_s) end |
.lookup_component(name) ⇒ Object
35 36 37 38 39 40 41 42 |
# File 'lib/orb.rb', line 35 def self.lookup_component(name) namespaces.each do |namespace| klass = "#{namespace}::#{name}" return klass if Object.const_defined?(klass) end nil end |