Gio::MountOperation Class Reference
Authentication methods for mountable locations. More...Inheritance diagram for Gio::MountOperation:

Public Member Functions | |
virtual | ~MountOperation () |
GMountOperation* | gobj () |
Provides access to the underlying C GObject. | |
const GMountOperation* | gobj () const |
Provides access to the underlying C GObject. | |
GMountOperation* | gobj_copy () |
Provides access to the underlying C instance. The caller is responsible for unrefing it. Use when directly setting fields in structs. | |
Glib::ustring | get_username () const |
Get the user name from the mount operation. | |
void | set_username (const Glib::ustring& username) |
Sets the user name within op to username . | |
Glib::ustring | get_password () const |
Gets a password from the mount operation. | |
void | set_password (const Glib::ustring& password) |
Sets the mount operation's password to password . | |
bool | get_anonymous () const |
Check to see whether the mount operation is being used for an anonymous user. | |
void | set_anonymous (bool anonymous=true) |
Sets the mount operation to use an anonymous user if anonymous is true . | |
Glib::ustring | get_domain () const |
Gets the domain of the mount operation. | |
void | set_domain (const Glib::ustring& domain) |
Sets the mount operation's domain. | |
PasswordSave | get_password_save () const |
Gets the state of saving passwords for the mount operation. | |
void | set_password_save (PasswordSave password_save) |
Sets the state of saving passwords for the mount operation. | |
int | get_choice () const |
Gets a choice from the mount operation. | |
void | set_choice (int choice) |
Sets a default choice for the mount operation. | |
void | reply (MountOperationResult result) |
Emits the G::MountOperation::reply signal. | |
Static Public Member Functions | |
static Glib::RefPtr<MountOperation> | create () |
Protected Member Functions | |
MountOperation () | |
Related Functions | |
(Note that these are not member functions.) | |
Glib::RefPtr<Gio::MountOperation> | wrap (GMountOperation* object, bool take_copy=false) |
A Glib::wrap() method for this object. |
Detailed Description
Authentication methods for mountable locations.MountOperation provides a mechanism for authenticating mountable operations, such as loop mounting files, hard drive partitions or server locations.
Mounting operations are handed a MountOperation that they can use if they require any privileges or authentication for their volumes to be mounted (e.g. a hard disk partition or an encrypted filesystem), or if they are implementing a remote server protocol which requires user credentials such as FTP or WebDAV.
Developers should instantiate a subclass of this that implements all the various callbacks to show the required dialogs.
Constructor & Destructor Documentation
virtual Gio::MountOperation::~MountOperation | ( | ) | [virtual] |
Gio::MountOperation::MountOperation | ( | ) | [protected] |
Member Function Documentation
GMountOperation* Gio::MountOperation::gobj | ( | ) | [inline] |
const GMountOperation* Gio::MountOperation::gobj | ( | ) | const [inline] |
GMountOperation* Gio::MountOperation::gobj_copy | ( | ) |
Provides access to the underlying C instance. The caller is responsible for unrefing it. Use when directly setting fields in structs.
static Glib::RefPtr<MountOperation> Gio::MountOperation::create | ( | ) | [static] |
Glib::ustring Gio::MountOperation::get_username | ( | ) | const |
Get the user name from the mount operation.
- Returns:
- A string containing the user name.
void Gio::MountOperation::set_username | ( | const Glib::ustring& | username | ) |
Sets the user name within op to username .
- Parameters:
-
username Input username.
Glib::ustring Gio::MountOperation::get_password | ( | ) | const |
Gets a password from the mount operation.
- Returns:
- A string containing the password within op .
void Gio::MountOperation::set_password | ( | const Glib::ustring& | password | ) |
Sets the mount operation's password to password .
- Parameters:
-
password Password to set.
bool Gio::MountOperation::get_anonymous | ( | ) | const |
Check to see whether the mount operation is being used for an anonymous user.
- Returns:
true
if mount operation is anonymous.
void Gio::MountOperation::set_anonymous | ( | bool | anonymous = true |
) |
Sets the mount operation to use an anonymous user if anonymous is true
.
- Parameters:
-
anonymous Boolean value.
Glib::ustring Gio::MountOperation::get_domain | ( | ) | const |
Gets the domain of the mount operation.
- Returns:
- A string set to the domain.
void Gio::MountOperation::set_domain | ( | const Glib::ustring& | domain | ) |
Sets the mount operation's domain.
- Parameters:
-
domain The domain to set.
PasswordSave Gio::MountOperation::get_password_save | ( | ) | const |
Gets the state of saving passwords for the mount operation.
- Returns:
- A G::PasswordSave flag.
void Gio::MountOperation::set_password_save | ( | PasswordSave | password_save | ) |
Sets the state of saving passwords for the mount operation.
- Parameters:
-
save A set of G::PasswordSave flags.
int Gio::MountOperation::get_choice | ( | ) | const |
Gets a choice from the mount operation.
- Returns:
- An integer containing an index of the user's choice from the choice's list, or 0.
void Gio::MountOperation::set_choice | ( | int | choice | ) |
Sets a default choice for the mount operation.
- Parameters:
-
choice An integer.
void Gio::MountOperation::reply | ( | MountOperationResult | result | ) |
Emits the G::MountOperation::reply signal.
- Parameters:
-
abort Boolean.
Friends And Related Function Documentation
Glib::RefPtr<Gio::MountOperation> wrap | ( | GMountOperation * | object, | |
bool | take_copy = false | |||
) | [related] |
A Glib::wrap() method for this object.
- Parameters:
-
object The C instance. take_copy False if the result should take ownership of the C instance. True if it should take a new copy or ref.
- Returns:
- A C++ instance that wraps this C instance.
The documentation for this class was generated from the following file: