AppInfoImpl

data class AppInfoImpl(val gioAppInfoPointer: <Error class: unknown class><<Error class: unknown class>>) : AppInfo

The AppInfoImpl type represents a native instance of the AppInfo interface.

Constructors

Link copied to clipboard
constructor(gioAppInfoPointer: <Error class: unknown class><<Error class: unknown class>>)

Creates a new instance of AppInfo for the provided CPointer.

Properties

Link copied to clipboard
open override val gioAppInfoPointer: <Error class: unknown class><<Error class: unknown class>>
Link copied to clipboard
abstract val gioProxyPointer: <Error class: unknown class><<Error class: unknown class>>

Functions

Link copied to clipboard
open fun addSupportsType(contentType: String): <Error class: unknown class><Boolean>

Adds a content type to the application information to indicate the application is capable of opening files with the given content type.

Link copied to clipboard
open fun canDelete(): Boolean

Obtains the information whether the iface@Gio.AppInfo can be deleted. See method@Gio.AppInfo.delete.

Link copied to clipboard

Checks if a supported content type can be removed from an application.

Link copied to clipboard
open fun connect(connection: IoStream, proxyAddress: ProxyAddress, cancellable: Cancellable? = null): <Error class: unknown class><IoStream>

Given @connection to communicate with a proxy (eg, a #GSocketConnection that is connected to the proxy server), this does the necessary handshake to connect to @proxy_address, and if required, wraps the #GIOStream to handle proxy payload.

Link copied to clipboard
open fun connectAsync(connection: IoStream, proxyAddress: ProxyAddress, cancellable: Cancellable? = null, callback: AsyncReadyCallback?)

Asynchronous version of g_proxy_connect().

Link copied to clipboard
open fun connectFinish(result: AsyncResult): <Error class: unknown class><IoStream>

See g_proxy_connect().

Link copied to clipboard
open fun delete(): Boolean

Tries to delete a iface@Gio.AppInfo.

Link copied to clipboard
open fun dup(): AppInfo

Creates a duplicate of a iface@Gio.AppInfo.

Link copied to clipboard
open fun equal(appinfo2: AppInfo): Boolean

Checks if two iface@Gio.AppInfos are equal.

Link copied to clipboard
open fun getCommandline(): String?

Gets the commandline with which the application will be started.

Link copied to clipboard
open fun getDescription(): String?

Gets a human-readable description of an installed application.

Link copied to clipboard

Gets the display name of the application. The display name is often more descriptive to the user than the name itself.

Link copied to clipboard
open fun getExecutable(): String

Gets the executable’s name for the installed application.

Link copied to clipboard
open fun getIcon(): Icon?

Gets the icon for the application.

Link copied to clipboard
open fun getId(): String?

Gets the ID of an application. An id is a string that identifies the application. The exact format of the id is platform dependent. For instance, on Unix this is the desktop file id from the xdg menu specification.

Link copied to clipboard
open fun getName(): String

Gets the installed name of the application.

Link copied to clipboard

Retrieves the list of content types that @app_info claims to support. If this information is not provided by the environment, this function will return NULL.

Link copied to clipboard
open fun launch(files: <Error class: unknown class>? = null, context: AppLaunchContext? = null): <Error class: unknown class><Boolean>

Launches the application. Passes @files to the launched application as arguments, using the optional @context to get information about the details of the launcher (like what screen it is on). On error, @error will be set accordingly.

Link copied to clipboard
open fun launchUris(uris: <Error class: unknown class>? = null, context: AppLaunchContext? = null): <Error class: unknown class><Boolean>

Launches the application. This passes the @uris to the launched application as arguments, using the optional @context to get information about the details of the launcher (like what screen it is on). On error, @error will be set accordingly. If the application only supports one URI per invocation as part of their command-line, multiple instances of the application will be spawned.

Link copied to clipboard
open fun launchUrisAsync(uris: <Error class: unknown class>? = null, context: AppLaunchContext? = null, cancellable: Cancellable? = null, callback: AsyncReadyCallback?)

Async version of method@Gio.AppInfo.launch_uris.

Link copied to clipboard
open fun launchUrisFinish(result: AsyncResult): <Error class: unknown class><Boolean>

Finishes a method@Gio.AppInfo.launch_uris_async operation.

Link copied to clipboard
open fun removeSupportsType(contentType: String): <Error class: unknown class><Boolean>

Removes a supported type from an application, if possible.

Link copied to clipboard
open fun setAsDefaultForExtension(extension: String): <Error class: unknown class><Boolean>

Sets the application as the default handler for the given file extension.

Link copied to clipboard
open fun setAsDefaultForType(contentType: String): <Error class: unknown class><Boolean>

Sets the application as the default handler for a given type.

Link copied to clipboard
open fun setAsLastUsedForType(contentType: String): <Error class: unknown class><Boolean>

Sets the application as the last used application for a given type. This will make the application appear as first in the list returned by func@Gio.AppInfo.get_recommended_for_type, regardless of the default application for that content type.

Link copied to clipboard
open fun shouldShow(): Boolean

Checks if the application info should be shown in menus that list available applications.

Link copied to clipboard

Checks if the application accepts files as arguments.

Link copied to clipboard

Some proxy protocols expect to be passed a hostname, which they will resolve to an IP address themselves. Others, like SOCKS4, do not allow this. This function will return false if @proxy is implementing such a protocol. When false is returned, the caller should resolve the destination hostname first, and then pass a #GProxyAddress containing the stringified IP address to g_proxy_connect() or g_proxy_connect_async().

Link copied to clipboard
open fun supportsUris(): Boolean

Checks if the application supports reading files and directories from URIs.