Class: Rust::Options

Inherits:
Hash show all
Defined in:
lib/rust/core/types/language.rb

Class Method Summary collapse

Instance Method Summary collapse

Class Method Details

.from_hash(hash) ⇒ Object



158
159
160
161
162
163
164
# File 'lib/rust/core/types/language.rb', line 158

def self.from_hash(hash)
    options = Options.new
    hash.each do |key, value|
        options[key.to_s] = value
    end
    return options
end

Instance Method Details

#to_RObject



154
155
156
# File 'lib/rust/core/types/language.rb', line 154

def to_R
    return self.map { |k, v| "#{k}=#{v.to_R}" }.join(", ")
end