Polkit.UnixUser

g GObject.GInterface GObject.GInterface Polkit.Identity Polkit.Identity GObject.GInterface->Polkit.Identity GObject.Object GObject.Object Polkit.UnixUser Polkit.UnixUser GObject.Object->Polkit.UnixUser Polkit.Identity->Polkit.UnixUser

Subclasses:

None

Methods

Inherited:

GObject.Object (37), Polkit.Identity (4)

Structs:

GObject.ObjectClass (5)

class

new (uid)

class

new_for_name (name)

get_name ()

get_uid ()

set_uid (uid)

Virtual Methods

Inherited:

GObject.Object (7), Polkit.Identity (3)

Properties

Name

Type

Flags

Short Description

uid

int

r/w/c

The UNIX user ID

Signals

Inherited:

GObject.Object (1)

Fields

Inherited:

GObject.Object (1)

Class Details

class Polkit.UnixUser(**kwargs)
Bases:

GObject.Object, Polkit.Identity

Abstract:

No

Structure:

Polkit.UnixUserClass

An object representing a user identity on a UNIX system.

classmethod new(uid)
Parameters:

uid (int) – A UNIX user id.

Returns:

A Polkit.UnixUser object. Free with GObject.Object.unref().

Return type:

Polkit.Identity

Creates a new Polkit.UnixUser object for uid.

classmethod new_for_name(name)
Parameters:

name (str) – A UNIX user name.

Raises:

GLib.Error

Returns:

A Polkit.UnixUser object or None if error is set.

Return type:

Polkit.Identity or None

Creates a new Polkit.UnixUser object for a user with the user name name.

get_name()
Returns:

User name string or None if user uid not found.

Return type:

str or None

Get the user’s name.

get_uid()
Returns:

A UNIX user id.

Return type:

int

Gets the UNIX user id for self.

set_uid(uid)
Parameters:

uid (int) – A UNIX user id.

Sets uid for self.

Property Details

Polkit.UnixUser.props.uid
Name:

uid

Type:

int

Default Value:

-1

Flags:

READABLE, WRITABLE, CONSTRUCT

The UNIX user id.