Method: BOAST::CKernel#initialize
- Defined in:
- lib/BOAST/CKernel.rb
#initialize(options = {}) ⇒ CKernel
Returns a new instance of CKernel.
105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 |
# File 'lib/BOAST/CKernel.rb', line 105 def initialize(={}) if [:code] then @code = [:code] elsif BOAST::get_chain_code @code = BOAST::get_output @code.seek(0,SEEK_END) else @code = StringIO::new end BOAST::set_output( @code ) if [:kernels] then @kernels = [:kernels] else @kernels = [] end if [:lang] then @lang = [:lang] else @lang = BOAST::get_lang end end |