public interface UIDesktop
UIProvider| Modifier and Type | Method and Description |
|---|---|
void |
browse(URI uri)
Launches the default browser to display a
URI. |
void |
edit(File file)
Launches the associated editor application and opens a file for editing.
|
void |
mail()
Launches the mail composing window of the user default mail client.
|
void |
mail(URI mailtoURI)
Launches the mail composing window of the user default mail client, filling the message fields specified by a
mailto: URI. |
void |
open(File file)
Launches the associated application to open the file.
|
void |
print(File file)
Prints a file with the native desktop printing facility, using the associated application's print command.
|
void open(File file) throws IOException
If the specified file is a directory, the file manager of the current platform is launched to open it.
file - the file to be opened with the associated applicationIOException - if the specified file has no associated application or the associated application fails to be
launchedvoid edit(File file) throws IOException
file - the file to be opened for editingIOException - if the specified file has no associated editor, or the associated application fails to be
launchedvoid print(File file) throws IOException
file - the file to be printedIOException - if the specified file has no associated application that can be used to print itvoid browse(URI uri) throws IOException
URI. If the default browser is not able to handle the specified
URI, the application registered for handling URIs of the specified type is invoked. The
application is determined from the protocol and path of the URI, as defined by the URI class.
uri - the URI to be displayed in the user default browserIOException - if the user default browser is not found, or it fails to be launched, or the default handler
application failed to be launchedURI,
AWTPermission,
AppletContextvoid mail()
throws IOException
IOException - if the user default mail client is not found, or it fails to be launchedvoid mail(URI mailtoURI) throws IOException
mailto: URI.
A mailto: URI can specify message fields including "to", "cc", "subject",
"body", etc. See The mailto URL scheme (RFC 2368) for the
mailto: URI specification details.
mailtoURI - the specified mailto: URIIOException - if the user default mail client is not found or fails to be launchedCopyright © 2015 JBoss by Red Hat. All rights reserved.