Class: DBus::Systemd::Machined::Machine

Inherits:
Object
  • Object
show all
Includes:
DBus::Systemd::Mixin::MethodMissing, DBus::Systemd::Mixin::Properties
Defined in:
lib/dbus/systemd/machined/machine.rb

Constant Summary collapse

INTERFACE =

machined machine object dbus interface

'org.freedesktop.machine1.Machine'.freeze

Instance Attribute Summary

Attributes included from DBus::Systemd::Mixin::MethodMissing

#object

Instance Method Summary collapse

Methods included from DBus::Systemd::Mixin::Properties

#properties

Methods included from DBus::Systemd::Mixin::MethodMissing

#method_missing, #respond_to_missing?

Constructor Details

#initialize(name, manager = Manager.new) ⇒ Machine

create machined machine dbus proxy object

Parameters:



39
40
41
42
43
44
# File 'lib/dbus/systemd/machined/machine.rb', line 39

def initialize(name, manager = Manager.new)
  machine_path = manager.GetMachine(name).first
  @object = manager.service.object(machine_path)
  @object.default_iface = INTERFACE
  @object.introspect
end

Dynamic Method Handling

This class handles dynamic methods through the method_missing method in the class DBus::Systemd::Mixin::MethodMissing