Class: OutputType
- Inherits:
-
Object
- Object
- OutputType
- Defined in:
- lib/raka/output_type.rb
Defined Under Namespace
Class Method Summary collapse
Instance Method Summary collapse
Class Method Details
.parse_option(opt) ⇒ Object
33 34 35 |
# File 'lib/raka/output_type.rb', line 33 def self.parse_option(opt) opt.map { |obj| obj.class == Symbol ? create(obj) : obj } end |
Instance Method Details
#create(sym) ⇒ Object
29 30 31 |
# File 'lib/raka/output_type.rb', line 29 def create(sym) self.class.const_get(sym.capitalize).new || Default.new end |