Skip to main content

GreeterExtManual

Trait GreeterExtManual 

Source
pub trait GreeterExtManual: IsA<Greeter> + 'static {
Show 17 methods // Provided methods fn authenticate(&self, username: Option<&str>) -> Result<(), Error> { ... } fn authenticate_as_guest(&self) -> Result<(), Error> { ... } fn authenticate_autologin(&self) -> Result<(), Error> { ... } fn authenticate_remote( &self, session: &str, username: Option<&str>, ) -> Result<(), Error> { ... } fn cancel_authentication(&self) -> Result<(), Error> { ... } fn connect_sync(&self) -> Result<(), Error> { ... } fn connect_to_daemon<P: FnOnce(Result<(), Error>) + 'static>( &self, cancellable: Option<&impl IsA<Cancellable>>, callback: P, ) { ... } fn connect_to_daemon_future( &self, ) -> Pin<Box_<dyn Future<Output = Result<(), Error>> + 'static>> { ... } fn connect_to_daemon_sync(&self) -> Result<(), Error> { ... } fn ensure_shared_data_dir<P: FnOnce(Result<GString, Error>) + 'static>( &self, username: &str, cancellable: Option<&impl IsA<Cancellable>>, callback: P, ) { ... } fn ensure_shared_data_dir_future( &self, username: &str, ) -> Pin<Box_<dyn Future<Output = Result<GString, Error>> + 'static>> { ... } fn ensure_shared_data_dir_sync( &self, username: &str, ) -> Result<GString, Error> { ... } fn respond(&self, response: &str) -> Result<(), Error> { ... } fn set_language(&self, language: &str) -> Result<(), Error> { ... } fn start_session<P: FnOnce(Result<(), Error>) + 'static>( &self, session: Option<&str>, cancellable: Option<&impl IsA<Cancellable>>, callback: P, ) { ... } fn start_session_future( &self, session: Option<&str>, ) -> Pin<Box_<dyn Future<Output = Result<(), Error>> + 'static>> { ... } fn start_session_sync(&self, session: Option<&str>) -> Result<(), Error> { ... }
}

Provided Methods§

Source

fn authenticate(&self, username: Option<&str>) -> Result<(), Error>

Starts the authentication procedure for a user.

§username

A username or #NULL to prompt for a username.

§Returns

#TRUE if authentication request sent.

Source

fn authenticate_as_guest(&self) -> Result<(), Error>

Starts the authentication procedure for the guest user.

§Returns

#TRUE if authentication request sent.

Source

fn authenticate_autologin(&self) -> Result<(), Error>

Starts the authentication procedure for the automatic login user.

§Returns

#TRUE if authentication request sent.

Source

fn authenticate_remote( &self, session: &str, username: Option<&str>, ) -> Result<(), Error>

Start authentication for a remote session type.

§session

The name of a remote session

§username

A username of #NULL to prompt for a username.

§Returns

#TRUE if authentication request sent.

Source

fn cancel_authentication(&self) -> Result<(), Error>

Cancel the current user authentication.

§Returns

#TRUE if cancel request sent.

Source

fn connect_sync(&self) -> Result<(), Error>

👎Deprecated:

Since 1.11.1

Connects the greeter to the display manager. Will block until connected.

§Deprecated since 1.11.1

Use lightdm_greeter_connect_to_daemon_sync() instead

§Returns

#TRUE if successfully connected

Source

fn connect_to_daemon<P: FnOnce(Result<(), Error>) + 'static>( &self, cancellable: Option<&impl IsA<Cancellable>>, callback: P, )

Asynchronously connects the greeter to the display manager.

When the operation is finished, @callback will be invoked. You can then call lightdm_greeter_connect_to_daemon_finish() to get the result of the operation.

See lightdm_greeter_connect_to_daemon_sync() for the synchronous version.

§cancellable

A #GCancellable or None.

§callback

A #GAsyncReadyCallback to call when completed or None.

Source

fn connect_to_daemon_future( &self, ) -> Pin<Box_<dyn Future<Output = Result<(), Error>> + 'static>>

Source

fn connect_to_daemon_sync(&self) -> Result<(), Error>

Connects the greeter to the display manager. Will block until connected.

§Returns

#TRUE if successfully connected

Source

fn ensure_shared_data_dir<P: FnOnce(Result<GString, Error>) + 'static>( &self, username: &str, cancellable: Option<&impl IsA<Cancellable>>, callback: P, )

Ensure that a shared data dir for the given user is available. Both the greeter user and @username will have write access to that folder. The intention is that larger pieces of shared data would be stored there (files that the greeter creates but wants to give to a user – like camera photos – or files that the user creates but wants the greeter to see – like contact avatars).

LightDM will automatically create these if the user actually logs in, so greeters only need to call this method if they want to store something in the directory themselves.

§username

A username

§cancellable

A #GCancellable or None.

§callback

A #GAsyncReadyCallback to call when completed or None.

Source

fn ensure_shared_data_dir_future( &self, username: &str, ) -> Pin<Box_<dyn Future<Output = Result<GString, Error>> + 'static>>

Source

fn ensure_shared_data_dir_sync(&self, username: &str) -> Result<GString, Error>

Ensure that a shared data dir for the given user is available. Both the greeter user and @username will have write access to that folder. The intention is that larger pieces of shared data would be stored there (files that the greeter creates but wants to give to a user – like camera photos – or files that the user creates but wants the greeter to see – like contact avatars).

LightDM will automatically create these if the user actually logs in, so greeters only need to call this method if they want to store something in the directory themselves.

§username

A username

§Returns

The path to the shared directory, free with g_free.

Source

fn respond(&self, response: &str) -> Result<(), Error>

Provide response to a prompt. May be one in a series.

§response

Response to a prompt

§Returns

#TRUE if response sent.

Source

fn set_language(&self, language: &str) -> Result<(), Error>

Set the language for the currently authenticated user.

§language

The language to use for this user in the form of a locale specification (e.g. “de_DE.UTF-8”).

§Returns

#TRUE if set language request sent.

Source

fn start_session<P: FnOnce(Result<(), Error>) + 'static>( &self, session: Option<&str>, cancellable: Option<&impl IsA<Cancellable>>, callback: P, )

Asynchronously start a session for the authenticated user.

When the operation is finished, @callback will be invoked. You can then call lightdm_greeter_start_session_finish() to get the result of the operation.

See lightdm_greeter_start_session_sync() for the synchronous version.

§session

The session to log into or #NULL to use the default.

§cancellable

A #GCancellable or None.

§callback

A #GAsyncReadyCallback to call when completed or None.

Source

fn start_session_future( &self, session: Option<&str>, ) -> Pin<Box_<dyn Future<Output = Result<(), Error>> + 'static>>

Source

fn start_session_sync(&self, session: Option<&str>) -> Result<(), Error>

Start a session for the authenticated user.

§session

The session to log into or #NULL to use the default.

§Returns

TRUE if the session was started.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§

Source§

impl<O: IsA<Greeter>> GreeterExtManual for O