1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
use super::systemd_dbus::*;

pub struct SystemdConnection {
	dbus_connection: DbusConnection,
}

impl SystemdConnection {

	pub fn new (
	) -> Result <SystemdConnection, String> {

		let dbus_connection =
			DbusConnection::get_private (
				DbusBusType::System,
			).unwrap ();

		Ok (SystemdConnection {
			dbus_connection: dbus_connection,
		})

	}

	pub fn dbus_connection (& self) -> & DbusConnection {
		& self.dbus_connection
	}

}

// ex: noet ts=4 filetype=rust