Module: Textpow
- Defined in:
- lib/textpow.rb,
lib/textpow/syntax.rb,
lib/textpow/syntax.rb,
lib/textpow/version.rb,
lib/textpow/score_manager.rb,
lib/textpow/debug_processor.rb,
lib/textpow/recording_processor.rb
Defined Under Namespace
Classes: DebugProcessor, ParsingError, RecordingProcessor, ScoreManager, SyntaxNode, SyntaxProxy
Constant Summary
collapse
- RUBY_19 =
(RUBY_VERSION > "1.9.0")
- VERSION =
Version = "1.2.5"
- @@syntax =
{}
Class Method Summary
collapse
Class Method Details
.syntax(syntax_name) ⇒ Object
16
17
18
19
20
21
22
23
|
# File 'lib/textpow.rb', line 16
def self.syntax(syntax_name)
syntax_name = syntax_name.downcase
if @@syntax.has_key?(syntax_name)
@@syntax[syntax_name]
else
@@syntax[syntax_name] = uncached_syntax(syntax_name)
end
end
|
.syntax_path ⇒ Object
11
12
13
|
# File 'lib/textpow.rb', line 11
def self.syntax_path
File.join(File.dirname(__FILE__), 'textpow', 'syntax')
end
|