Module: DBus::Systemd::Helpers
- Defined in:
- lib/dbus/systemd/helpers.rb
Class Method Summary collapse
Class Method Details
.map_array(array, map) ⇒ Object
14 15 16 17 18 19 20 21 22 |
# File 'lib/dbus/systemd/helpers.rb', line 14 def map_array(array, map) mapped = {} array.each_with_index do |item, index| mapped[map.key(index)] = item end mapped end |
.session_bus ⇒ Object
10 11 12 |
# File 'lib/dbus/systemd/helpers.rb', line 10 def session_bus DBus::SessionBus.instance end |
.system_bus ⇒ Object
6 7 8 |
# File 'lib/dbus/systemd/helpers.rb', line 6 def system_bus DBus::SystemBus.instance end |