Function systemd::login::get_unit
[−]
[src]
pub fn get_unit(unit_type: UnitType, pid: Option<pid_t>) -> Result<String>
Determines the systemd unit (i.e. service or scope unit) identifier of a process.
Specific processes can be optionally targeted via their PID. When no PID is specified, operation is executed for the calling process. This method can be used to retrieve either a system or an user unit identifier.