Class: DBus::Type::HashFactory
Overview
Syntactic helper for constructing a hash Type. You may be looking for Data::Array and Data::DictEntry instead.
Class Method Summary collapse
-
.[](key_type, value_type) ⇒ Type
(frozen).
Methods inherited from Factory
Class Method Details
.[](key_type, value_type) ⇒ Type
Returns (frozen).
352 353 354 355 356 357 358 359 360 361 |
# File 'lib/dbus/type.rb', line 352 def self.[](key_type, value_type) t = Type.new(ARRAY) de = Type.new(DICT_ENTRY, abstract: true) de << make_type(key_type) de << make_type(value_type) de.members.freeze t << de t.members.freeze t end |