org.kde.koala
Class KIO

java.lang.Object
  extended by org.kde.koala.KIO

public class KIO
extends java.lang.Object


Field Summary
static int CaseInsensitive
           
static int CC_Cache
           
static int CC_CacheOnly
          Specifies how to use the cache.
static int CC_Refresh
           
static int CC_Reload
           
static int CC_Verify
           
static int CMD_CHMOD
           
static int CMD_CONFIG
           
static int CMD_CONNECT
           
static int CMD_COPY
           
static int CMD_DEL
           
static int CMD_DISCONNECT
           
static int CMD_GET
           
static int CMD_HOST
          Commands that can be invoked by a job.
static int CMD_LISTDIR
           
static int CMD_MESSAGEBOXANSWER
           
static int CMD_META_DATA
           
static int CMD_MIMETYPE
           
static int CMD_MKDIR
           
static int CMD_MULTI_GET
           
static int CMD_NONE
           
static int CMD_PUT
           
static int CMD_RENAME
           
static int CMD_REPARSECONFIGURATION
           
static int CMD_RESUMEANSWER
           
static int CMD_SLAVE_CONNECT
           
static int CMD_SLAVE_HOLD
           
static int CMD_SLAVE_STATUS
           
static int CMD_SPECIAL
           
static int CMD_STAT
           
static int CMD_SUBURL
           
static int CMD_SYMLINK
           
static int CMD_TESTDIR
           
static int CMD_USERPASS
           
static int DAV_COPY
           
static int DAV_LOCK
           
static int DAV_MKCOL
           
static int DAV_MOVE
           
static int DAV_NOTIFY
           
static int DAV_POLL
           
static int DAV_PROPFIND
           
static int DAV_PROPPATCH
           
static int DAV_SEARCH
           
static int DAV_SUBSCRIBE
           
static int DAV_UNLOCK
           
static int DAV_UNSUBSCRIBE
           
static int DEFAULT
           
static int ERR_ABORTED
           
static int ERR_ACCESS_DENIED
           
static int ERR_CANNOT_CHMOD
           
static int ERR_CANNOT_DELETE
           
static int ERR_CANNOT_DELETE_ORIGINAL
           
static int ERR_CANNOT_DELETE_PARTIAL
           
static int ERR_CANNOT_ENTER_DIRECTORY
           
static int ERR_CANNOT_LAUNCH_PROCESS
           
static int ERR_CANNOT_OPEN_FOR_READING
          Error codes that can be emitted by KIO.
static int ERR_CANNOT_OPEN_FOR_WRITING
           
static int ERR_CANNOT_RENAME
           
static int ERR_CANNOT_RENAME_ORIGINAL
           
static int ERR_CANNOT_RENAME_PARTIAL
           
static int ERR_CANNOT_RESUME
           
static int ERR_CANNOT_SYMLINK
           
static int ERR_CONNECTION_BROKEN
           
static int ERR_COULD_NOT_ACCEPT
           
static int ERR_COULD_NOT_AUTHENTICATE
           
static int ERR_COULD_NOT_BIND
           
static int ERR_COULD_NOT_CLOSEDIR
           
static int ERR_COULD_NOT_CONNECT
           
static int ERR_COULD_NOT_CREATE_SOCKET
           
static int ERR_COULD_NOT_LISTEN
           
static int ERR_COULD_NOT_LOGIN
           
static int ERR_COULD_NOT_MKDIR
           
static int ERR_COULD_NOT_MOUNT
           
static int ERR_COULD_NOT_READ
           
static int ERR_COULD_NOT_RMDIR
           
static int ERR_COULD_NOT_STAT
           
static int ERR_COULD_NOT_UNMOUNT
           
static int ERR_COULD_NOT_WRITE
           
static int ERR_CYCLIC_COPY
           
static int ERR_CYCLIC_LINK
           
static int ERR_DIR_ALREADY_EXIST
           
static int ERR_DISK_FULL
           
static int ERR_DOES_NOT_EXIST
           
static int ERR_FILE_ALREADY_EXIST
           
static int ERR_IDENTICAL_FILES
           
static int ERR_INTERNAL
           
static int ERR_INTERNAL_SERVER
           
static int ERR_IS_DIRECTORY
           
static int ERR_IS_FILE
           
static int ERR_MALFORMED_URL
           
static int ERR_NEED_PASSWD
           
static int ERR_NO_CONTENT
           
static int ERR_NO_SOURCE_PROTOCOL
           
static int ERR_NOT_FILTER_PROTOCOL
           
static int ERR_OUT_OF_MEMORY
           
static int ERR_POST_DENIED
           
static int ERR_PROTOCOL_IS_NOT_A_FILESYSTEM
           
static int ERR_SERVER_TIMEOUT
           
static int ERR_SERVICE_NOT_AVAILABLE
           
static int ERR_SLAVE_DEFINED
           
static int ERR_SLAVE_DIED
           
static int ERR_UNKNOWN
           
static int ERR_UNKNOWN_HOST
           
static int ERR_UNKNOWN_INTERRUPT
           
static int ERR_UNKNOWN_PROXY_HOST
           
static int ERR_UNSUPPORTED_ACTION
           
static int ERR_UNSUPPORTED_PROTOCOL
           
static int ERR_UPGRADE_REQUIRED
           
static int ERR_USER_CANCELED
           
static int ERR_WRITE_ACCESS_DENIED
           
static int HTTP_DELETE
           
static int HTTP_GET
          HTTP / DAV method * @short HTTP / DAV method
static int HTTP_HEAD
           
static int HTTP_OPTIONS
           
static int HTTP_POST
           
static int HTTP_PUT
           
static int HTTP_UNKNOWN
           
static int INF_ERROR_PAGE
           
static int INF_GETTING_FILE
           
static int INF_INFOMESSAGE
           
static int INF_MESSAGEBOX
           
static int INF_META_DATA
           
static int INF_MIME_TYPE
           
static int INF_NEED_PASSWD
           
static int INF_NETWORK_STATUS
           
static int INF_PROCESSED_SIZE
           
static int INF_REDIRECTION
           
static int INF_SPEED
           
static int INF_TOTAL_SIZE
          Identifiers for KIO informational messages.
static int INF_WARNING
           
static int LIST
           
static int M_MULTI
           
static int M_NORENAME
           
static int M_OVERWRITE
           
static int M_OVERWRITE_ITSELF
           
static int M_RESUME
           
static int M_SINGLE
           
static int M_SKIP
           
static int MSG_AUTH_KEY
           
static int MSG_CANRESUME
           
static int MSG_CONNECTED
           
static int MSG_DATA
          Identifiers for KIO data messages.
static int MSG_DATA_REQ
           
static int MSG_DEL_AUTH_KEY
           
static int MSG_ERROR
           
static int MSG_FINISHED
           
static int MSG_LIST_ENTRIES
           
static int MSG_NEED_SUBURL_DATA
           
static int MSG_NET_DROP
           
static int MSG_NET_REQUEST
           
static int MSG_RENAMED
           
static int MSG_RESUME
           
static int MSG_SLAVE_ACK
           
static int MSG_SLAVE_STATUS
           
static int MSG_STAT_ENTRY
           
static int R_AUTO_SKIP
           
static int R_CANCEL
           
static int R_OVERWRITE
           
static int R_OVERWRITE_ALL
           
static int R_RENAME
           
static int R_RESUME
          The result of open_RenameDlg().
static int R_RESUME_ALL
           
static int R_SKIP
           
static int S_AUTO_SKIP
           
static int S_CANCEL
           
static int S_SKIP
           
static int STATUSBAR
           
static int SupportsChmod
           
static int SupportsChown
           
static int SupportsSymlinks
           
static int SupportsUTime
           
static int UDS_ACCESS
           
static int UDS_ACCESS_TIME
           
static int UDS_ACL_STRING
           
static int UDS_CREATION_TIME
           
static int UDS_DEFAULT_ACL_STRING
           
static int UDS_EXTENDED_ACL
           
static int UDS_EXTRA
           
static int UDS_FILE_TYPE
           
static int UDS_GROUP
           
static int UDS_GUESSED_MIME_TYPE
           
static int UDS_HIDDEN
           
static int UDS_ICON_NAME
           
static int UDS_LINK_DEST
           
static int UDS_LOCAL_PATH
           
static int UDS_LONG
           
static int UDS_MIME_TYPE
           
static int UDS_MODIFICATION_TIME
           
static int UDS_NAME
           
static int UDS_SIZE
           
static int UDS_SIZE_LARGE
           
static int UDS_STRING
          Constants used to specify the type of a KUDSAtom.
static int UDS_TIME
           
static int UDS_URL
           
static int UDS_USER
           
static int UDS_XML_PROPERTIES
           
 
Constructor Summary
KIO()
           
 
Method Summary
static java.lang.String buildErrorString(int errorCode, java.lang.String errorText)
          Returns a translated error message for errorCode using the additional error information provided by errorText.
static SimpleJob chmod(KURL url, int permissions)
          Changes permissions on a file or directory.
static java.lang.String convertSeconds(int seconds)
          Convert seconds to a string representing number of days, hours, minutes and seconds
static java.lang.String convertSize(long size)
          Converts size from bytes to the string representation.
static java.lang.String convertSizeFromKB(long kbSize)
          Converts size from kilo-bytes to the string representation.
static java.lang.String convertSizeWithBytes(long size)
          Converts size from bytes to a string representation with includes the size in bytes.
static CopyJob copy(java.util.ArrayList src, KURL dest)
           
static CopyJob copy(java.util.ArrayList src, KURL dest, boolean showProgressInfo)
          Copy a list of file/dirs src into a destination directory dest.
static CopyJob copy(KURL src, KURL dest)
           
static CopyJob copy(KURL src, KURL dest, boolean showProgressInfo)
          Copy a file or directory src into the destination dest, which can be a file (including the final filename) or a directory (into which src will be copied).
static CopyJob copyAs(KURL src, KURL dest)
           
static CopyJob copyAs(KURL src, KURL dest, boolean showProgressInfo)
          Copy a file or directory src into the destination dest, which is the destination name in any case, even for a directory.
static DavJob davPropFind(KURL url, org.kde.qt.QDomDocument properties, java.lang.String depth)
           
static DavJob davPropFind(KURL url, org.kde.qt.QDomDocument properties, java.lang.String depth, boolean showProgressInfo)
          Creates a new DavJob that issues a PROPFIND command.
static DavJob davPropPatch(KURL url, org.kde.qt.QDomDocument properties)
           
static DavJob davPropPatch(KURL url, org.kde.qt.QDomDocument properties, boolean showProgressInfo)
          Creates a new DavJob that issues a PROPPATCH command.
static DavJob davSearch(KURL url, java.lang.String nsURI, java.lang.String qName, java.lang.String query)
           
static DavJob davSearch(KURL url, java.lang.String nsURI, java.lang.String qName, java.lang.String query, boolean showProgressInfo)
          Creates a new DavJob that issues a SEARCH command.
static java.lang.String decodeFileName(java.lang.String str)
          Decodes (from the filename to the text displayed) This translates %2[fF] into / and %% into %
static DeleteJob del(java.util.ArrayList src)
           
static DeleteJob del(java.util.ArrayList src, boolean shred)
           
static DeleteJob del(java.util.ArrayList src, boolean shred, boolean showProgressInfo)
          Deletes a list of files or directories.
static DeleteJob del(KURL src)
           
static DeleteJob del(KURL src, boolean shred)
           
static DeleteJob del(KURL src, boolean shred, boolean showProgressInfo)
          Delete a file or directory.
static java.lang.String encodeFileName(java.lang.String str)
          Encodes (from the text displayed to the real filename) This translates % into %% and / into %2f Used by KIO.link, for instance.
static FileCopyJob file_copy(KURL src, KURL dest)
           
static FileCopyJob file_copy(KURL src, KURL dest, int permissions)
           
static FileCopyJob file_copy(KURL src, KURL dest, int permissions, boolean overwrite)
           
static FileCopyJob file_copy(KURL src, KURL dest, int permissions, boolean overwrite, boolean resume)
           
static FileCopyJob file_copy(KURL src, KURL dest, int permissions, boolean overwrite, boolean resume, boolean showProgressInfo)
          Copy a single file.
static SimpleJob file_delete(KURL src)
           
static SimpleJob file_delete(KURL src, boolean showProgressInfo)
          Delete a single file.
static FileCopyJob file_move(KURL src, KURL dest)
           
static FileCopyJob file_move(KURL src, KURL dest, int permissions)
           
static FileCopyJob file_move(KURL src, KURL dest, int permissions, boolean overwrite)
           
static FileCopyJob file_move(KURL src, KURL dest, int permissions, boolean overwrite, boolean resume)
           
static FileCopyJob file_move(KURL src, KURL dest, int permissions, boolean overwrite, boolean resume, boolean showProgressInfo)
          Move a single file.
static MetaInfoJob fileMetaInfo(java.util.ArrayList items)
          Retrieves meta information for the given items.
static PreviewJob filePreview(java.util.ArrayList items, int width)
           
static PreviewJob filePreview(java.util.ArrayList items, int width, int height)
           
static PreviewJob filePreview(java.util.ArrayList items, int width, int height, int iconSize)
           
static PreviewJob filePreview(java.util.ArrayList items, int width, int height, int iconSize, int iconAlpha)
           
static PreviewJob filePreview(java.util.ArrayList items, int width, int height, int iconSize, int iconAlpha, boolean scale)
           
static PreviewJob filePreview(java.util.ArrayList items, int width, int height, int iconSize, int iconAlpha, boolean scale, boolean save)
           
static PreviewJob filePreview(java.util.ArrayList items, int width, int height, int iconSize, int iconAlpha, boolean scale, boolean save, java.lang.String[] enabledPlugins)
          Creates a PreviewJob to generate or retrieve a preview image for the given URL.
static java.lang.String findDeviceMountPoint(java.lang.String device)
          Returns the mount point where device is mounted right now.
static java.lang.String findPathMountPoint(java.lang.String filename)
          Returns the mount point on which resides filename. For instance if /home is a separate partition, findPathMountPoint("/home/user/blah") will return /home
static TransferJob get(KURL url)
           
static TransferJob get(KURL url, boolean reload)
           
static TransferJob get(KURL url, boolean reload, boolean showProgressInfo)
          Get (a.k.a.
static java.lang.String getCacheControlString(int cacheControl)
          Returns a string representation of the given cache control method.
static TransferJob http_post(KURL url, byte[] postData)
           
static TransferJob http_post(KURL url, byte[] postData, boolean showProgressInfo)
          HTTP POST (for form data).
static SimpleJob http_update_cache(KURL url, boolean no_cache, int expireDate)
          HTTP cache update
static boolean isClipboardEmpty()
          Checks whether the clipboard contains any URLs.
static java.lang.String itemsSummaryString(int items, int files, int dirs, long size, boolean showSize)
          Helper for showing information about a set of files and directories
static CopyJob link(java.util.ArrayList src, KURL destDir)
           
static CopyJob link(java.util.ArrayList src, KURL destDir, boolean showProgressInfo)
          Create several links If the protocols and hosts are the same, a Unix symlink will be created.
static CopyJob link(KURL src, KURL destDir)
           
static CopyJob link(KURL src, KURL destDir, boolean showProgressInfo)
          Create a link.
static CopyJob linkAs(KURL src, KURL dest)
           
static CopyJob linkAs(KURL src, KURL dest, boolean showProgressInfo)
          Create a link.
static ListJob listDir(KURL url)
           
static ListJob listDir(KURL url, boolean showProgressInfo)
           
static ListJob listDir(KURL url, boolean showProgressInfo, boolean includeHidden)
          List the contents of url, which is assumed to be a directory.
static ListJob listRecursive(KURL url)
           
static ListJob listRecursive(KURL url, boolean showProgressInfo)
           
static ListJob listRecursive(KURL url, boolean showProgressInfo, boolean includeHidden)
          The same as the previous method, but recurses subdirectories.
static boolean manually_mounted(java.lang.String filename)
          Checks if the path belongs to a filesystem that is manually mounted.
static MimetypeJob mimetype(KURL url)
           
static MimetypeJob mimetype(KURL url, boolean showProgressInfo)
          Find mimetype for one file or directory.
static SimpleJob mkdir(KURL url)
           
static SimpleJob mkdir(KURL url, int permissions)
          Creates a single directory.
static SimpleJob mount(boolean ro, java.lang.String fstype, java.lang.String dev, java.lang.String point)
           
static SimpleJob mount(boolean ro, java.lang.String fstype, java.lang.String dev, java.lang.String point, boolean showProgressInfo)
          Mount filesystem.
static CopyJob move(java.util.ArrayList src, KURL dest)
           
static CopyJob move(java.util.ArrayList src, KURL dest, boolean showProgressInfo)
          Moves a list of files or directories src to the given destination dest.
static CopyJob move(KURL src, KURL dest)
           
static CopyJob move(KURL src, KURL dest, boolean showProgressInfo)
          Moves a file or directory src to the given destination dest.
static CopyJob moveAs(KURL src, KURL dest)
           
static CopyJob moveAs(KURL src, KURL dest, boolean showProgressInfo)
          Moves a file or directory src to the given destination dest. Unlike move() this operation will fail when the directory already exists.
static java.lang.String number(long size)
          Converts a size to a string representation Not unlike String.number(...)
static org.kde.qt.QDataStream op_read(org.kde.qt.QDataStream s, AuthInfo a)
           
static org.kde.qt.QDataStream op_write(org.kde.qt.QDataStream s, AuthInfo a)
           
static int open_RenameDlg(java.lang.String caption, java.lang.String src, java.lang.String dest, int mode, java.lang.StringBuffer newDestPath)
           
static int open_RenameDlg(java.lang.String caption, java.lang.String src, java.lang.String dest, int mode, java.lang.StringBuffer newDestPath, long sizeSrc)
           
static int open_RenameDlg(java.lang.String caption, java.lang.String src, java.lang.String dest, int mode, java.lang.StringBuffer newDestPath, long sizeSrc, long sizeDest)
           
static int open_RenameDlg(java.lang.String caption, java.lang.String src, java.lang.String dest, int mode, java.lang.StringBuffer newDestPath, long sizeSrc, long sizeDest, int ctimeSrc)
           
static int open_RenameDlg(java.lang.String caption, java.lang.String src, java.lang.String dest, int mode, java.lang.StringBuffer newDestPath, long sizeSrc, long sizeDest, int ctimeSrc, int ctimeDest)
           
static int open_RenameDlg(java.lang.String caption, java.lang.String src, java.lang.String dest, int mode, java.lang.StringBuffer newDestPath, long sizeSrc, long sizeDest, int ctimeSrc, int ctimeDest, int mtimeSrc)
           
static int open_RenameDlg(java.lang.String caption, java.lang.String src, java.lang.String dest, int mode, java.lang.StringBuffer newDestPath, long sizeSrc, long sizeDest, int ctimeSrc, int ctimeDest, int mtimeSrc, int mtimeDest)
          RenameDlg related Functions KIO#RenameDlg Construct a modal, parent-less "rename" dialog, and return a result code, as well as the new dest.
static int open_SkipDlg(boolean _multi)
           
static int open_SkipDlg(boolean _multi, java.lang.String _error_text)
           
static int parseCacheControl(java.lang.String cacheControl)
          Parses the string representation of the cache control option.
static java.lang.String pasteActionText()
          Returns the text to use for the Paste action, when the application supports pasting files, urls, and clipboard data, using pasteClipboard().
static Job pasteClipboard(KURL destURL)
           
static Job pasteClipboard(KURL destURL, boolean move)
          Pastes the content of the clipboard to the given destination URL.
static void pasteData(KURL destURL, byte[] data)
          Pastes the given data to the given destination URL.
static CopyJob pasteDataAsync(KURL destURL, byte[] data)
          Pastes the given data to the given destination URL.
static CopyJob pasteDataAsync(KURL destURL, byte[] data, java.lang.String dialogText)
          Pastes the given data to the given destination URL.
static CopyJob pasteMimeSource(org.kde.qt.QMimeSourceInterface data, KURL destURL, java.lang.String dialogText, org.kde.qt.QWidget widget)
           
static CopyJob pasteMimeSource(org.kde.qt.QMimeSourceInterface data, KURL destURL, java.lang.String dialogText, org.kde.qt.QWidget widget, boolean clipboard)
          Save the given mimesource data to the given destination URL after offering the user to choose a data format.
static boolean probably_slow_mounted(java.lang.String filename)
          Checks if the path belongs to a filesystem that is probably slow.
static TransferJob put(KURL url, int permissions, boolean overwrite, boolean resume)
           
static TransferJob put(KURL url, int permissions, boolean overwrite, boolean resume, boolean showProgressInfo)
          Put (a.k.a.
static byte[] rawErrorDetail(int errorCode, java.lang.String errorText)
           
static byte[] rawErrorDetail(int errorCode, java.lang.String errorText, KURL reqUrl)
           
static byte[] rawErrorDetail(int errorCode, java.lang.String errorText, KURL reqUrl, int method)
          Returns translated error details for errorCode using the additional error information provided by errorText , reqUrl (the request URL), and the ioslave method .
static SimpleJob rename(KURL src, KURL dest, boolean overwrite)
          Rename a file or directory.
static SimpleJob rmdir(KURL url)
          Removes a single directory.
static SimpleJob special(KURL url, byte[] data)
           
static SimpleJob special(KURL url, byte[] data, boolean showProgressInfo)
          Execute any command that is specific to one slave (protocol).
static StatJob stat(KURL url)
           
static StatJob stat(KURL url, boolean showProgressInfo)
          Find all details for one file or directory.
static StatJob stat(KURL url, boolean sideIsSource, short details)
           
static StatJob stat(KURL url, boolean sideIsSource, short details, boolean showProgressInfo)
          Find all details for one file or directory.
static StoredTransferJob storedGet(KURL url)
           
static StoredTransferJob storedGet(KURL url, boolean reload)
           
static StoredTransferJob storedGet(KURL url, boolean reload, boolean showProgressInfo)
          Get (a.k.a.
static StoredTransferJob storedPut(byte[] arr, KURL url, int permissions, boolean overwrite, boolean resume)
           
static StoredTransferJob storedPut(byte[] arr, KURL url, int permissions, boolean overwrite, boolean resume, boolean showProgressInfo)
          Put (a.k.a.
static SimpleJob symlink(java.lang.String target, KURL dest, boolean overwrite)
           
static SimpleJob symlink(java.lang.String target, KURL dest, boolean overwrite, boolean showProgressInfo)
          Create or move a symlink.
static boolean testFileSystemFlag(java.lang.String filename, int flag)
          Checks the capabilities of the filesystem to which a given file belongs.
static CopyJob trash(java.util.ArrayList src)
           
static CopyJob trash(java.util.ArrayList src, boolean showProgressInfo)
          Trash a list of files or directories.
static CopyJob trash(KURL src)
           
static CopyJob trash(KURL src, boolean showProgressInfo)
          Trash a file or directory.
static SimpleJob unmount(java.lang.String point)
           
static SimpleJob unmount(java.lang.String point, boolean showProgressInfo)
          Unmount filesystem.
static java.lang.String unsupportedActionErrorString(java.lang.String protocol, int cmd)
          Returns an appropriate error message if the given command cmd is an unsupported action (ERR_UNSUPPORTED_ACTION).
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

S_SKIP

public static final int S_SKIP
See Also:
Constant Field Values

S_AUTO_SKIP

public static final int S_AUTO_SKIP
See Also:
Constant Field Values

S_CANCEL

public static final int S_CANCEL
See Also:
Constant Field Values

M_OVERWRITE

public static final int M_OVERWRITE
See Also:
Constant Field Values

M_OVERWRITE_ITSELF

public static final int M_OVERWRITE_ITSELF
See Also:
Constant Field Values

M_SKIP

public static final int M_SKIP
See Also:
Constant Field Values

M_SINGLE

public static final int M_SINGLE
See Also:
Constant Field Values

M_MULTI

public static final int M_MULTI
See Also:
Constant Field Values

M_RESUME

public static final int M_RESUME
See Also:
Constant Field Values

M_NORENAME

public static final int M_NORENAME
See Also:
Constant Field Values

R_RESUME

public static final int R_RESUME
The result of open_RenameDlg().

See Also:
Constant Field Values

R_RESUME_ALL

public static final int R_RESUME_ALL
See Also:
Constant Field Values

R_OVERWRITE

public static final int R_OVERWRITE
See Also:
Constant Field Values

R_OVERWRITE_ALL

public static final int R_OVERWRITE_ALL
See Also:
Constant Field Values

R_SKIP

public static final int R_SKIP
See Also:
Constant Field Values

R_AUTO_SKIP

public static final int R_AUTO_SKIP
See Also:
Constant Field Values

R_RENAME

public static final int R_RENAME
See Also:
Constant Field Values

R_CANCEL

public static final int R_CANCEL
See Also:
Constant Field Values

CMD_HOST

public static final int CMD_HOST
Commands that can be invoked by a job.

See Also:
Constant Field Values

CMD_CONNECT

public static final int CMD_CONNECT
See Also:
Constant Field Values

CMD_DISCONNECT

public static final int CMD_DISCONNECT
See Also:
Constant Field Values

CMD_SLAVE_STATUS

public static final int CMD_SLAVE_STATUS
See Also:
Constant Field Values

CMD_SLAVE_CONNECT

public static final int CMD_SLAVE_CONNECT
See Also:
Constant Field Values

CMD_SLAVE_HOLD

public static final int CMD_SLAVE_HOLD
See Also:
Constant Field Values

CMD_NONE

public static final int CMD_NONE
See Also:
Constant Field Values

CMD_TESTDIR

public static final int CMD_TESTDIR
See Also:
Constant Field Values

CMD_GET

public static final int CMD_GET
See Also:
Constant Field Values

CMD_PUT

public static final int CMD_PUT
See Also:
Constant Field Values

CMD_STAT

public static final int CMD_STAT
See Also:
Constant Field Values

CMD_MIMETYPE

public static final int CMD_MIMETYPE
See Also:
Constant Field Values

CMD_LISTDIR

public static final int CMD_LISTDIR
See Also:
Constant Field Values

CMD_MKDIR

public static final int CMD_MKDIR
See Also:
Constant Field Values

CMD_RENAME

public static final int CMD_RENAME
See Also:
Constant Field Values

CMD_COPY

public static final int CMD_COPY
See Also:
Constant Field Values

CMD_DEL

public static final int CMD_DEL
See Also:
Constant Field Values

CMD_CHMOD

public static final int CMD_CHMOD
See Also:
Constant Field Values

CMD_SPECIAL

public static final int CMD_SPECIAL
See Also:
Constant Field Values

CMD_USERPASS

public static final int CMD_USERPASS
See Also:
Constant Field Values

CMD_REPARSECONFIGURATION

public static final int CMD_REPARSECONFIGURATION
See Also:
Constant Field Values

CMD_META_DATA

public static final int CMD_META_DATA
See Also:
Constant Field Values

CMD_SYMLINK

public static final int CMD_SYMLINK
See Also:
Constant Field Values

CMD_SUBURL

public static final int CMD_SUBURL
See Also:
Constant Field Values

CMD_MESSAGEBOXANSWER

public static final int CMD_MESSAGEBOXANSWER
See Also:
Constant Field Values

CMD_RESUMEANSWER

public static final int CMD_RESUMEANSWER
See Also:
Constant Field Values

CMD_CONFIG

public static final int CMD_CONFIG
See Also:
Constant Field Values

CMD_MULTI_GET

public static final int CMD_MULTI_GET
See Also:
Constant Field Values

ERR_CANNOT_OPEN_FOR_READING

public static final int ERR_CANNOT_OPEN_FOR_READING
Error codes that can be emitted by KIO.

See Also:
Constant Field Values

ERR_CANNOT_OPEN_FOR_WRITING

public static final int ERR_CANNOT_OPEN_FOR_WRITING
See Also:
Constant Field Values

ERR_CANNOT_LAUNCH_PROCESS

public static final int ERR_CANNOT_LAUNCH_PROCESS
See Also:
Constant Field Values

ERR_INTERNAL

public static final int ERR_INTERNAL
See Also:
Constant Field Values

ERR_MALFORMED_URL

public static final int ERR_MALFORMED_URL
See Also:
Constant Field Values

ERR_UNSUPPORTED_PROTOCOL

public static final int ERR_UNSUPPORTED_PROTOCOL
See Also:
Constant Field Values

ERR_NO_SOURCE_PROTOCOL

public static final int ERR_NO_SOURCE_PROTOCOL
See Also:
Constant Field Values

ERR_UNSUPPORTED_ACTION

public static final int ERR_UNSUPPORTED_ACTION
See Also:
Constant Field Values

ERR_IS_DIRECTORY

public static final int ERR_IS_DIRECTORY
See Also:
Constant Field Values

ERR_IS_FILE

public static final int ERR_IS_FILE
See Also:
Constant Field Values

ERR_DOES_NOT_EXIST

public static final int ERR_DOES_NOT_EXIST
See Also:
Constant Field Values

ERR_FILE_ALREADY_EXIST

public static final int ERR_FILE_ALREADY_EXIST
See Also:
Constant Field Values

ERR_DIR_ALREADY_EXIST

public static final int ERR_DIR_ALREADY_EXIST
See Also:
Constant Field Values

ERR_UNKNOWN_HOST

public static final int ERR_UNKNOWN_HOST
See Also:
Constant Field Values

ERR_ACCESS_DENIED

public static final int ERR_ACCESS_DENIED
See Also:
Constant Field Values

ERR_WRITE_ACCESS_DENIED

public static final int ERR_WRITE_ACCESS_DENIED
See Also:
Constant Field Values

ERR_CANNOT_ENTER_DIRECTORY

public static final int ERR_CANNOT_ENTER_DIRECTORY
See Also:
Constant Field Values

ERR_PROTOCOL_IS_NOT_A_FILESYSTEM

public static final int ERR_PROTOCOL_IS_NOT_A_FILESYSTEM
See Also:
Constant Field Values

ERR_CYCLIC_LINK

public static final int ERR_CYCLIC_LINK
See Also:
Constant Field Values

ERR_USER_CANCELED

public static final int ERR_USER_CANCELED
See Also:
Constant Field Values

ERR_CYCLIC_COPY

public static final int ERR_CYCLIC_COPY
See Also:
Constant Field Values

ERR_COULD_NOT_CREATE_SOCKET

public static final int ERR_COULD_NOT_CREATE_SOCKET
See Also:
Constant Field Values

ERR_COULD_NOT_CONNECT

public static final int ERR_COULD_NOT_CONNECT
See Also:
Constant Field Values

ERR_CONNECTION_BROKEN

public static final int ERR_CONNECTION_BROKEN
See Also:
Constant Field Values

ERR_NOT_FILTER_PROTOCOL

public static final int ERR_NOT_FILTER_PROTOCOL
See Also:
Constant Field Values

ERR_COULD_NOT_MOUNT

public static final int ERR_COULD_NOT_MOUNT
See Also:
Constant Field Values

ERR_COULD_NOT_UNMOUNT

public static final int ERR_COULD_NOT_UNMOUNT
See Also:
Constant Field Values

ERR_COULD_NOT_READ

public static final int ERR_COULD_NOT_READ
See Also:
Constant Field Values

ERR_COULD_NOT_WRITE

public static final int ERR_COULD_NOT_WRITE
See Also:
Constant Field Values

ERR_COULD_NOT_BIND

public static final int ERR_COULD_NOT_BIND
See Also:
Constant Field Values

ERR_COULD_NOT_LISTEN

public static final int ERR_COULD_NOT_LISTEN
See Also:
Constant Field Values

ERR_COULD_NOT_ACCEPT

public static final int ERR_COULD_NOT_ACCEPT
See Also:
Constant Field Values

ERR_COULD_NOT_LOGIN

public static final int ERR_COULD_NOT_LOGIN
See Also:
Constant Field Values

ERR_COULD_NOT_STAT

public static final int ERR_COULD_NOT_STAT
See Also:
Constant Field Values

ERR_COULD_NOT_CLOSEDIR

public static final int ERR_COULD_NOT_CLOSEDIR
See Also:
Constant Field Values

ERR_COULD_NOT_MKDIR

public static final int ERR_COULD_NOT_MKDIR
See Also:
Constant Field Values

ERR_COULD_NOT_RMDIR

public static final int ERR_COULD_NOT_RMDIR
See Also:
Constant Field Values

ERR_CANNOT_RESUME

public static final int ERR_CANNOT_RESUME
See Also:
Constant Field Values

ERR_CANNOT_RENAME

public static final int ERR_CANNOT_RENAME
See Also:
Constant Field Values

ERR_CANNOT_CHMOD

public static final int ERR_CANNOT_CHMOD
See Also:
Constant Field Values

ERR_CANNOT_DELETE

public static final int ERR_CANNOT_DELETE
See Also:
Constant Field Values

ERR_SLAVE_DIED

public static final int ERR_SLAVE_DIED
See Also:
Constant Field Values

ERR_OUT_OF_MEMORY

public static final int ERR_OUT_OF_MEMORY
See Also:
Constant Field Values

ERR_UNKNOWN_PROXY_HOST

public static final int ERR_UNKNOWN_PROXY_HOST
See Also:
Constant Field Values

ERR_COULD_NOT_AUTHENTICATE

public static final int ERR_COULD_NOT_AUTHENTICATE
See Also:
Constant Field Values

ERR_ABORTED

public static final int ERR_ABORTED
See Also:
Constant Field Values

ERR_INTERNAL_SERVER

public static final int ERR_INTERNAL_SERVER
See Also:
Constant Field Values

ERR_SERVER_TIMEOUT

public static final int ERR_SERVER_TIMEOUT
See Also:
Constant Field Values

ERR_SERVICE_NOT_AVAILABLE

public static final int ERR_SERVICE_NOT_AVAILABLE
See Also:
Constant Field Values

ERR_UNKNOWN

public static final int ERR_UNKNOWN
See Also:
Constant Field Values

ERR_UNKNOWN_INTERRUPT

public static final int ERR_UNKNOWN_INTERRUPT
See Also:
Constant Field Values

ERR_CANNOT_DELETE_ORIGINAL

public static final int ERR_CANNOT_DELETE_ORIGINAL
See Also:
Constant Field Values

ERR_CANNOT_DELETE_PARTIAL

public static final int ERR_CANNOT_DELETE_PARTIAL
See Also:
Constant Field Values

ERR_CANNOT_RENAME_ORIGINAL

public static final int ERR_CANNOT_RENAME_ORIGINAL
See Also:
Constant Field Values

ERR_CANNOT_RENAME_PARTIAL

public static final int ERR_CANNOT_RENAME_PARTIAL
See Also:
Constant Field Values

ERR_NEED_PASSWD

public static final int ERR_NEED_PASSWD
See Also:
Constant Field Values

ERR_CANNOT_SYMLINK

public static final int ERR_CANNOT_SYMLINK
See Also:
Constant Field Values

ERR_NO_CONTENT

public static final int ERR_NO_CONTENT
See Also:
Constant Field Values

ERR_DISK_FULL

public static final int ERR_DISK_FULL
See Also:
Constant Field Values

ERR_IDENTICAL_FILES

public static final int ERR_IDENTICAL_FILES
See Also:
Constant Field Values

ERR_SLAVE_DEFINED

public static final int ERR_SLAVE_DEFINED
See Also:
Constant Field Values

ERR_UPGRADE_REQUIRED

public static final int ERR_UPGRADE_REQUIRED
See Also:
Constant Field Values

ERR_POST_DENIED

public static final int ERR_POST_DENIED
See Also:
Constant Field Values

UDS_STRING

public static final int UDS_STRING
Constants used to specify the type of a KUDSAtom.

See Also:
Constant Field Values

UDS_LONG

public static final int UDS_LONG
See Also:
Constant Field Values

UDS_TIME

public static final int UDS_TIME
See Also:
Constant Field Values

UDS_SIZE

public static final int UDS_SIZE
See Also:
Constant Field Values

UDS_SIZE_LARGE

public static final int UDS_SIZE_LARGE
See Also:
Constant Field Values

UDS_USER

public static final int UDS_USER
See Also:
Constant Field Values

UDS_ICON_NAME

public static final int UDS_ICON_NAME
See Also:
Constant Field Values

UDS_GROUP

public static final int UDS_GROUP
See Also:
Constant Field Values

UDS_EXTRA

public static final int UDS_EXTRA
See Also:
Constant Field Values

UDS_NAME

public static final int UDS_NAME
See Also:
Constant Field Values

UDS_LOCAL_PATH

public static final int UDS_LOCAL_PATH
See Also:
Constant Field Values

UDS_HIDDEN

public static final int UDS_HIDDEN
See Also:
Constant Field Values

UDS_EXTENDED_ACL

public static final int UDS_EXTENDED_ACL
See Also:
Constant Field Values

UDS_ACL_STRING

public static final int UDS_ACL_STRING
See Also:
Constant Field Values

UDS_DEFAULT_ACL_STRING

public static final int UDS_DEFAULT_ACL_STRING
See Also:
Constant Field Values

UDS_ACCESS

public static final int UDS_ACCESS
See Also:
Constant Field Values

UDS_MODIFICATION_TIME

public static final int UDS_MODIFICATION_TIME
See Also:
Constant Field Values

UDS_ACCESS_TIME

public static final int UDS_ACCESS_TIME
See Also:
Constant Field Values

UDS_CREATION_TIME

public static final int UDS_CREATION_TIME
See Also:
Constant Field Values

UDS_FILE_TYPE

public static final int UDS_FILE_TYPE
See Also:
Constant Field Values

UDS_LINK_DEST

public static final int UDS_LINK_DEST
See Also:
Constant Field Values

UDS_URL

public static final int UDS_URL
See Also:
Constant Field Values

UDS_MIME_TYPE

public static final int UDS_MIME_TYPE
See Also:
Constant Field Values

UDS_GUESSED_MIME_TYPE

public static final int UDS_GUESSED_MIME_TYPE
See Also:
Constant Field Values

UDS_XML_PROPERTIES

public static final int UDS_XML_PROPERTIES
See Also:
Constant Field Values

CC_CacheOnly

public static final int CC_CacheOnly
Specifies how to use the cache.

See Also:
parseCacheControl(java.lang.String), getCacheControlString(int), Constant Field Values

CC_Cache

public static final int CC_Cache
See Also:
Constant Field Values

CC_Verify

public static final int CC_Verify
See Also:
Constant Field Values

CC_Refresh

public static final int CC_Refresh
See Also:
Constant Field Values

CC_Reload

public static final int CC_Reload
See Also:
Constant Field Values

SupportsChmod

public static final int SupportsChmod
See Also:
Constant Field Values

SupportsChown

public static final int SupportsChown
See Also:
Constant Field Values

SupportsUTime

public static final int SupportsUTime
See Also:
Constant Field Values

SupportsSymlinks

public static final int SupportsSymlinks
See Also:
Constant Field Values

CaseInsensitive

public static final int CaseInsensitive
See Also:
Constant Field Values

HTTP_GET

public static final int HTTP_GET
HTTP / DAV method * @short HTTP / DAV method

See Also:
Constant Field Values

HTTP_PUT

public static final int HTTP_PUT
See Also:
Constant Field Values

HTTP_POST

public static final int HTTP_POST
See Also:
Constant Field Values

HTTP_HEAD

public static final int HTTP_HEAD
See Also:
Constant Field Values

HTTP_DELETE

public static final int HTTP_DELETE
See Also:
Constant Field Values

HTTP_OPTIONS

public static final int HTTP_OPTIONS
See Also:
Constant Field Values

DAV_PROPFIND

public static final int DAV_PROPFIND
See Also:
Constant Field Values

DAV_PROPPATCH

public static final int DAV_PROPPATCH
See Also:
Constant Field Values

DAV_MKCOL

public static final int DAV_MKCOL
See Also:
Constant Field Values

DAV_COPY

public static final int DAV_COPY
See Also:
Constant Field Values

DAV_MOVE

public static final int DAV_MOVE
See Also:
Constant Field Values

DAV_LOCK

public static final int DAV_LOCK
See Also:
Constant Field Values

DAV_UNLOCK

public static final int DAV_UNLOCK
See Also:
Constant Field Values

DAV_SEARCH

public static final int DAV_SEARCH
See Also:
Constant Field Values

DAV_SUBSCRIBE

public static final int DAV_SUBSCRIBE
See Also:
Constant Field Values

DAV_UNSUBSCRIBE

public static final int DAV_UNSUBSCRIBE
See Also:
Constant Field Values

DAV_POLL

public static final int DAV_POLL
See Also:
Constant Field Values

DAV_NOTIFY

public static final int DAV_NOTIFY
See Also:
Constant Field Values

HTTP_UNKNOWN

public static final int HTTP_UNKNOWN
See Also:
Constant Field Values

INF_TOTAL_SIZE

public static final int INF_TOTAL_SIZE
Identifiers for KIO informational messages.

See Also:
Constant Field Values

INF_PROCESSED_SIZE

public static final int INF_PROCESSED_SIZE
See Also:
Constant Field Values

INF_SPEED

public static final int INF_SPEED
See Also:
Constant Field Values

INF_REDIRECTION

public static final int INF_REDIRECTION
See Also:
Constant Field Values

INF_MIME_TYPE

public static final int INF_MIME_TYPE
See Also:
Constant Field Values

INF_ERROR_PAGE

public static final int INF_ERROR_PAGE
See Also:
Constant Field Values

INF_WARNING

public static final int INF_WARNING
See Also:
Constant Field Values

INF_GETTING_FILE

public static final int INF_GETTING_FILE
See Also:
Constant Field Values

INF_NEED_PASSWD

public static final int INF_NEED_PASSWD
See Also:
Constant Field Values

INF_INFOMESSAGE

public static final int INF_INFOMESSAGE
See Also:
Constant Field Values

INF_META_DATA

public static final int INF_META_DATA
See Also:
Constant Field Values

INF_NETWORK_STATUS

public static final int INF_NETWORK_STATUS
See Also:
Constant Field Values

INF_MESSAGEBOX

public static final int INF_MESSAGEBOX
See Also:
Constant Field Values

MSG_DATA

public static final int MSG_DATA
Identifiers for KIO data messages.

See Also:
Constant Field Values

MSG_DATA_REQ

public static final int MSG_DATA_REQ
See Also:
Constant Field Values

MSG_ERROR

public static final int MSG_ERROR
See Also:
Constant Field Values

MSG_CONNECTED

public static final int MSG_CONNECTED
See Also:
Constant Field Values

MSG_FINISHED

public static final int MSG_FINISHED
See Also:
Constant Field Values

MSG_STAT_ENTRY

public static final int MSG_STAT_ENTRY
See Also:
Constant Field Values

MSG_LIST_ENTRIES

public static final int MSG_LIST_ENTRIES
See Also:
Constant Field Values

MSG_RENAMED

public static final int MSG_RENAMED
See Also:
Constant Field Values

MSG_RESUME

public static final int MSG_RESUME
See Also:
Constant Field Values

MSG_SLAVE_STATUS

public static final int MSG_SLAVE_STATUS
See Also:
Constant Field Values

MSG_SLAVE_ACK

public static final int MSG_SLAVE_ACK
See Also:
Constant Field Values

MSG_NET_REQUEST

public static final int MSG_NET_REQUEST
See Also:
Constant Field Values

MSG_NET_DROP

public static final int MSG_NET_DROP
See Also:
Constant Field Values

MSG_NEED_SUBURL_DATA

public static final int MSG_NEED_SUBURL_DATA
See Also:
Constant Field Values

MSG_CANRESUME

public static final int MSG_CANRESUME
See Also:
Constant Field Values

MSG_AUTH_KEY

public static final int MSG_AUTH_KEY
See Also:
Constant Field Values

MSG_DEL_AUTH_KEY

public static final int MSG_DEL_AUTH_KEY
See Also:
Constant Field Values

DEFAULT

public static final int DEFAULT
See Also:
Constant Field Values

STATUSBAR

public static final int STATUSBAR
See Also:
Constant Field Values

LIST

public static final int LIST
See Also:
Constant Field Values
Constructor Detail

KIO

public KIO()
Method Detail

open_SkipDlg

public static int open_SkipDlg(boolean _multi,
                               java.lang.String _error_text)

open_SkipDlg

public static int open_SkipDlg(boolean _multi)

open_RenameDlg

public static int open_RenameDlg(java.lang.String caption,
                                 java.lang.String src,
                                 java.lang.String dest,
                                 int mode,
                                 java.lang.StringBuffer newDestPath,
                                 long sizeSrc,
                                 long sizeDest,
                                 int ctimeSrc,
                                 int ctimeDest,
                                 int mtimeSrc,
                                 int mtimeDest)
  • RenameDlg related Functions
  • KIO#RenameDlg Construct a modal, parent-less "rename" dialog, and return a result code, as well as the new dest. Much easier to use than the class RenameDlg directly.

    Parameters:
    caption - the caption for the dialog box
    src - the URL of the file/dir we're trying to copy, as it's part of the text message
    dest - the URL of the destination file/dir, i.e. the one that already exists
    mode - parameters for the dialog (which buttons to show...), see RenameDlg_Mode
    newDest - the new destination path, valid if R_RENAME was returned.
    sizeSrc - size of source file
    sizeDest - size of destination file
    ctimeSrc - creation time of source file
    ctimeDest - creation time of destination file
    mtimeSrc - modification time of source file
    mtimeDest - modification time of destination file
    Returns:
    the result

    open_RenameDlg

    public static int open_RenameDlg(java.lang.String caption,
                                     java.lang.String src,
                                     java.lang.String dest,
                                     int mode,
                                     java.lang.StringBuffer newDestPath,
                                     long sizeSrc,
                                     long sizeDest,
                                     int ctimeSrc,
                                     int ctimeDest,
                                     int mtimeSrc)

    open_RenameDlg

    public static int open_RenameDlg(java.lang.String caption,
                                     java.lang.String src,
                                     java.lang.String dest,
                                     int mode,
                                     java.lang.StringBuffer newDestPath,
                                     long sizeSrc,
                                     long sizeDest,
                                     int ctimeSrc,
                                     int ctimeDest)

    open_RenameDlg

    public static int open_RenameDlg(java.lang.String caption,
                                     java.lang.String src,
                                     java.lang.String dest,
                                     int mode,
                                     java.lang.StringBuffer newDestPath,
                                     long sizeSrc,
                                     long sizeDest,
                                     int ctimeSrc)

    open_RenameDlg

    public static int open_RenameDlg(java.lang.String caption,
                                     java.lang.String src,
                                     java.lang.String dest,
                                     int mode,
                                     java.lang.StringBuffer newDestPath,
                                     long sizeSrc,
                                     long sizeDest)

    open_RenameDlg

    public static int open_RenameDlg(java.lang.String caption,
                                     java.lang.String src,
                                     java.lang.String dest,
                                     int mode,
                                     java.lang.StringBuffer newDestPath,
                                     long sizeSrc)

    open_RenameDlg

    public static int open_RenameDlg(java.lang.String caption,
                                     java.lang.String src,
                                     java.lang.String dest,
                                     int mode,
                                     java.lang.StringBuffer newDestPath)

    op_write

    public static org.kde.qt.QDataStream op_write(org.kde.qt.QDataStream s,
                                                  AuthInfo a)

    op_read

    public static org.kde.qt.QDataStream op_read(org.kde.qt.QDataStream s,
                                                 AuthInfo a)

    convertSize

    public static java.lang.String convertSize(long size)
    Converts size from bytes to the string representation.

    Parameters:
    size - size in bytes
    Returns:
    converted size as a string - e.g. 123.4 kB , 12.0 MB

    convertSizeWithBytes

    public static java.lang.String convertSizeWithBytes(long size)
    Converts size from bytes to a string representation with includes the size in bytes. e.g. 90 B, 240 B, 1.4 KB (1495 B), 2.6MB (2,734,344 B), 0 B

    Parameters:
    size - size in bytes
    Returns:
    converted size as a string - e.g. 1.4 KB (1495 B), 45 B

    number

    public static java.lang.String number(long size)
    Converts a size to a string representation Not unlike String.number(...)

    Parameters:
    size - size in bytes
    Returns:
    converted size as a string - e.g. 123456789

    convertSizeFromKB

    public static java.lang.String convertSizeFromKB(long kbSize)
    Converts size from kilo-bytes to the string representation.

    Parameters:
    kbSize - size in kilo-bytes
    Returns:
    converted size as a string - e.g. 123.4 kB , 12.0 MB

    convertSeconds

    public static java.lang.String convertSeconds(int seconds)
    Convert seconds to a string representing number of days, hours, minutes and seconds

    Parameters:
    seconds - number of seconds to convert
    Returns:
    string representation in a locale depending format

    itemsSummaryString

    public static java.lang.String itemsSummaryString(int items,
                                                      int files,
                                                      int dirs,
                                                      long size,
                                                      boolean showSize)
    Helper for showing information about a set of files and directories

    Parameters:
    items - the number of items (= files + dirs + number of symlinks :)
    files - the number of files
    dirs - the number of dirs
    size - the sum of the size of the files
    showSize - whether to show the size in the result
    Returns:
    the summary string

    encodeFileName

    public static java.lang.String encodeFileName(java.lang.String str)
    Encodes (from the text displayed to the real filename) This translates % into %% and / into %2f Used by KIO.link, for instance.

    Parameters:
    str - the file name to encode
    Returns:
    the encoded file name

    decodeFileName

    public static java.lang.String decodeFileName(java.lang.String str)
    Decodes (from the filename to the text displayed) This translates %2[fF] into / and %% into %

    Parameters:
    str - the file name to decode
    Returns:
    the decoded file name

    buildErrorString

    public static java.lang.String buildErrorString(int errorCode,
                                                    java.lang.String errorText)
    Returns a translated error message for errorCode using the additional error information provided by errorText.

    Parameters:
    errorCode - the error code
    errorText - the additional error text
    Returns:
    the created error string

    rawErrorDetail

    public static byte[] rawErrorDetail(int errorCode,
                                        java.lang.String errorText,
                                        KURL reqUrl,
                                        int method)
    Returns translated error details for errorCode using the additional error information provided by errorText , reqUrl (the request URL), and the ioslave method .

    Parameters:
    errorCode - the error code
    errorText - the additional error text
    reqUrl - the request URL
    method - the ioslave method
  • String errorName - the name of the error
  • String techName - if not null, the more technical name of the error
  • String description - a description of the error
  • ArrayList causes - a list of possible causes of the error
  • ArrayList solutions - a liso of solutions for the error
  • @return the following data:

    rawErrorDetail

    public static byte[] rawErrorDetail(int errorCode,
                                        java.lang.String errorText,
                                        KURL reqUrl)

    rawErrorDetail

    public static byte[] rawErrorDetail(int errorCode,
                                        java.lang.String errorText)

    unsupportedActionErrorString

    public static java.lang.String unsupportedActionErrorString(java.lang.String protocol,
                                                                int cmd)
    Returns an appropriate error message if the given command cmd is an unsupported action (ERR_UNSUPPORTED_ACTION).

    Parameters:
    protocol - name of the protocol
    cmd - given command
    See Also:
    #enum, Command

    parseCacheControl

    public static int parseCacheControl(java.lang.String cacheControl)
    Parses the string representation of the cache control option.

    Parameters:
    cacheControl - the string representation
    Returns:
    the cache control value
    See Also:
    getCacheControlString(int)

    getCacheControlString

    public static java.lang.String getCacheControlString(int cacheControl)
    Returns a string representation of the given cache control method.

    Parameters:
    cacheControl - the cache control method
    Returns:
    the string representation
    See Also:
    parseCacheControl(java.lang.String)

    findDeviceMountPoint

    public static java.lang.String findDeviceMountPoint(java.lang.String device)
    Returns the mount point where device is mounted right now. This means, it has to be mounted, not just defined in fstab.


    findPathMountPoint

    public static java.lang.String findPathMountPoint(java.lang.String filename)
    Returns the mount point on which resides filename. For instance if /home is a separate partition, findPathMountPoint("/home/user/blah") will return /home

    Parameters:
    filename - the file name to check
    Returns:
    the mount point of the given filename

    probably_slow_mounted

    public static boolean probably_slow_mounted(java.lang.String filename)
    Checks if the path belongs to a filesystem that is probably slow. It checks for NFS or for paths belonging to automounted paths not yet mounted

    Parameters:
    filename - the file name to check
    Returns:
    true if the filesystem is probably slow

    manually_mounted

    public static boolean manually_mounted(java.lang.String filename)
    Checks if the path belongs to a filesystem that is manually mounted.

    Parameters:
    filename - the file name to check
    Returns:
    true if the filesystem is manually mounted

    testFileSystemFlag

    public static boolean testFileSystemFlag(java.lang.String filename,
                                             int flag)
    Checks the capabilities of the filesystem to which a given file belongs. given feature (e.g. chmod).

    Parameters:
    filename - the file name to check
    flag - the flag to check The availables flags are:
  • SupportsChmod: returns true if the filesystem supports chmod (e.g. msdos filesystems return false)
  • SupportsChown: returns true if the filesystem supports chown (e.g. msdos filesystems return false)
  • SupportsUtime: returns true if the filesystems supports utime (e.g. msdos filesystems return false)
  • SupportsSymlinks: returns true if the filesystems supports symlinks (e.g. msdos filesystems return false)
  • CaseInsensitive: returns true if the filesystem treats "foo" and "FOO" as being the same file (true for msdos systems)
  • Returns:
    true if the filesystem has that flag, false if not (or some error occurred)

    filePreview

    public static PreviewJob filePreview(java.util.ArrayList items,
                                         int width,
                                         int height,
                                         int iconSize,
                                         int iconAlpha,
                                         boolean scale,
                                         boolean save,
                                         java.lang.String[] enabledPlugins)
    Creates a PreviewJob to generate or retrieve a preview image for the given URL.

    Parameters:
    items - files to get previews for
    width - the maximum width to use
    height - the maximum height to use, if this is 0, the same value as width is used.
    iconSize - the size of the mimetype icon to overlay over the preview or zero to not overlay an icon. This has no effect if the preview plugin that will be used doesn't use icon overlays.
    iconAlpha - transparency to use for the icon overlay
    scale - if the image is to be scaled to the requested size or returned in its original size
    save - if the image should be cached for later use
    enabledPlugins - if non-zero, this points to a list containing the names of the plugins that may be used.
    Returns:
    the new PreviewJob
    See Also:
    PreviewJob.availablePlugins()

    filePreview

    public static PreviewJob filePreview(java.util.ArrayList items,
                                         int width,
                                         int height,
                                         int iconSize,
                                         int iconAlpha,
                                         boolean scale,
                                         boolean save)

    filePreview

    public static PreviewJob filePreview(java.util.ArrayList items,
                                         int width,
                                         int height,
                                         int iconSize,
                                         int iconAlpha,
                                         boolean scale)

    filePreview

    public static PreviewJob filePreview(java.util.ArrayList items,
                                         int width,
                                         int height,
                                         int iconSize,
                                         int iconAlpha)

    filePreview

    public static PreviewJob filePreview(java.util.ArrayList items,
                                         int width,
                                         int height,
                                         int iconSize)

    filePreview

    public static PreviewJob filePreview(java.util.ArrayList items,
                                         int width,
                                         int height)

    filePreview

    public static PreviewJob filePreview(java.util.ArrayList items,
                                         int width)

    davPropFind

    public static DavJob davPropFind(KURL url,
                                     org.kde.qt.QDomDocument properties,
                                     java.lang.String depth,
                                     boolean showProgressInfo)
    Creates a new DavJob that issues a PROPFIND command. PROPFIND retrieves the properties of the resource identified by the given url.

    Parameters:
    url - the URL of the resource
    properties - a propfind document that describes the properties that should be retrieved
    depth - the depth of the request. Can be "0", "1" or "infinity"
    showProgressInfo - true to show progress information
    Returns:
    the new DavJob

    davPropFind

    public static DavJob davPropFind(KURL url,
                                     org.kde.qt.QDomDocument properties,
                                     java.lang.String depth)

    davPropPatch

    public static DavJob davPropPatch(KURL url,
                                      org.kde.qt.QDomDocument properties,
                                      boolean showProgressInfo)
    Creates a new DavJob that issues a PROPPATCH command. PROPPATCH sets the properties of the resource identified by the given url.

    Parameters:
    url - the URL of the resource
    properties - a PROPPACTCH document that describes the properties that should be modified and its new values
    showProgressInfo - true to show progress information
    Returns:
    the new DavJob

    davPropPatch

    public static DavJob davPropPatch(KURL url,
                                      org.kde.qt.QDomDocument properties)

    davSearch

    public static DavJob davSearch(KURL url,
                                   java.lang.String nsURI,
                                   java.lang.String qName,
                                   java.lang.String query,
                                   boolean showProgressInfo)
    Creates a new DavJob that issues a SEARCH command.

    Parameters:
    url - the URL of the resource
    nsURI - the URI of the search method's qualified name
    qName - the local part of the search method's qualified name
    query - the search string
    showProgressInfo - true to show progress information
    Returns:
    the new DavJob

    davSearch

    public static DavJob davSearch(KURL url,
                                   java.lang.String nsURI,
                                   java.lang.String qName,
                                   java.lang.String query)

    fileMetaInfo

    public static MetaInfoJob fileMetaInfo(java.util.ArrayList items)
    Retrieves meta information for the given items.

    Parameters:
    items - files to get metainfo for
    Returns:
    the MetaInfoJob to retrieve the items

    mkdir

    public static SimpleJob mkdir(KURL url,
                                  int permissions)
    Creates a single directory.

    Parameters:
    url - The URL of the directory to create.
    permissions - The permissions to set after creating the directory (unix-style), -1 for default permissions.
    Returns:
    A pointer to the job handling the operation.

    mkdir

    public static SimpleJob mkdir(KURL url)

    rmdir

    public static SimpleJob rmdir(KURL url)
    Removes a single directory. The directory is assumed to be empty.

    Parameters:
    url - The URL of the directory to remove.
    Returns:
    A pointer to the job handling the operation.

    chmod

    public static SimpleJob chmod(KURL url,
                                  int permissions)
    Changes permissions on a file or directory. See the other chmod below for changing many files or directories.

    Parameters:
    url - The URL of file or directory.
    permissions - The permissions to set.
    Returns:
    the job handling the operation.

    rename

    public static SimpleJob rename(KURL src,
                                   KURL dest,
                                   boolean overwrite)
    Rename a file or directory. Warning: this operation fails if a direct renaming is not possible (like with files or dirs on separate partitions) Use move or file_move in this case.

    Parameters:
    src - The original URL
    dest - The final URL
    overwrite - whether to automatically overwrite if the dest exists
    Returns:
    the job handling the operation.

    symlink

    public static SimpleJob symlink(java.lang.String target,
                                    KURL dest,
                                    boolean overwrite,
                                    boolean showProgressInfo)
    Create or move a symlink. This is the lowlevel operation, similar to file_copy and file_move. It doesn't do any check (other than those the slave does) and it doesn't show rename and skip dialogs - use KIO.link for that.

    Parameters:
    target - The string that will become the "target" of the link (can be relative)
    dest - The symlink to create.
    overwrite - whether to automatically overwrite if the dest exists
    showProgressInfo - true to show progress information
    Returns:
    the job handling the operation.

    symlink

    public static SimpleJob symlink(java.lang.String target,
                                    KURL dest,
                                    boolean overwrite)

    special

    public static SimpleJob special(KURL url,
                                    byte[] data,
                                    boolean showProgressInfo)
    Execute any command that is specific to one slave (protocol). Examples are : HTTP POST, mount and unmount (kio_file)

    Parameters:
    url - The URL isn't passed to the slave, but is used to know which slave to send it to :-)
    data - Packed data. The meaning is completely dependent on the slave, but usually starts with an int for the command number.
    showProgressInfo - true to show progress information
    Returns:
    the job handling the operation.

    special

    public static SimpleJob special(KURL url,
                                    byte[] data)

    mount

    public static SimpleJob mount(boolean ro,
                                  java.lang.String fstype,
                                  java.lang.String dev,
                                  java.lang.String point,
                                  boolean showProgressInfo)
    Mount filesystem. Special job for kio_file.

    Parameters:
    ro - Mount read-only if true.
    fstype - File system type (e.g. "ext2", can be null).
    dev - Device (e.g. /dev/sda0).
    point - Mount point, can be null.
    showProgressInfo - true to show progress information
    Returns:
    the job handling the operation.

    mount

    public static SimpleJob mount(boolean ro,
                                  java.lang.String fstype,
                                  java.lang.String dev,
                                  java.lang.String point)

    unmount

    public static SimpleJob unmount(java.lang.String point,
                                    boolean showProgressInfo)
    Unmount filesystem. Special job for kio_file.

    Parameters:
    point - Point to unmount.
    showProgressInfo - true to show progress information
    Returns:
    the job handling the operation.

    unmount

    public static SimpleJob unmount(java.lang.String point)

    http_update_cache

    public static SimpleJob http_update_cache(KURL url,
                                              boolean no_cache,
                                              int expireDate)
    HTTP cache update

    Parameters:
    url - Url to update, protocol must be "http".
    no_cache - If true, cache entry for url is deleted.
    expireDate - Local machine time indicating when the entry is supposed to expire.
    Returns:
    the job handling the operation.

    stat

    public static StatJob stat(KURL url,
                               boolean showProgressInfo)
    Find all details for one file or directory.

    Parameters:
    url - the URL of the file
    showProgressInfo - true to show progress information
    Returns:
    the job handling the operation.

    stat

    public static StatJob stat(KURL url)

    stat

    public static StatJob stat(KURL url,
                               boolean sideIsSource,
                               short details,
                               boolean showProgressInfo)
    Find all details for one file or directory. This version of the call includes two additional booleaneans, sideIsSource and details.

    Parameters:
    url - the URL of the file
    sideIsSource - is true when stating a source file (we will do a get on it if the stat works) and false when stating a destination file (target of a copy). The reason for this parameter is that in some cases the kioslave might not be able to determine a file's existence (e.g. HTTP doesn't allow it, FTP has issues with case-sensitivity on some systems). When the slave can't reliably determine the existence of a file, it will:
  • be optimistic if sideIsSource=true, i.e. it will assume the file exists, and if it doesn't this will appear when actually trying to download it
  • be pessimistic if sideIsSource=false, i.e. it will assume the file doesn't exist, to prevent showing "about to overwrite" errors to the user. If you simply want to check for existence without downloading/uploading afterwards, then you should use sideIsSource=false.
  • details - selects the level of details we want. By default this is 2 (all details wanted, including modification time, size, etc.), setDetails(1) is used when deleting: we don't need all the information if it takes too much time, no need to follow symlinks etc. setDetails(0) is used for very simple probing: we'll only get the answer "it's a file or a directory, or it doesn't exist". This is used by KRun.
    showProgressInfo - true to show progress information
    Returns:
    the job handling the operation.

    stat

    public static StatJob stat(KURL url,
                               boolean sideIsSource,
                               short details)

    get

    public static TransferJob get(KURL url,
                                  boolean reload,
                                  boolean showProgressInfo)
    Get (a.k.a. read). The slave emits the data through data().

    Parameters:
    url - the URL of the file
    reload - true to reload the file, false if it can be taken from the cache
    showProgressInfo - true to show progress information
    Returns:
    the job handling the operation.

    get

    public static TransferJob get(KURL url,
                                  boolean reload)

    get

    public static TransferJob get(KURL url)

    put

    public static TransferJob put(KURL url,
                                  int permissions,
                                  boolean overwrite,
                                  boolean resume,
                                  boolean showProgressInfo)
    Put (a.k.a. write)

    Parameters:
    url - Where to write data.
    permissions - May be -1. In this case no special permission mode is set.
    overwrite - If true, any existing file will be overwritten.
    resume - true to resume an operation. Warning, setting this to true means that the data will be appended to dest if dest exists.
    showProgressInfo - true to show progress information
    Returns:
    the job handling the operation.
    See Also:
    #multi_get

    put

    public static TransferJob put(KURL url,
                                  int permissions,
                                  boolean overwrite,
                                  boolean resume)

    http_post

    public static TransferJob http_post(KURL url,
                                        byte[] postData,
                                        boolean showProgressInfo)
    HTTP POST (for form data). Example:
                        job = KIO.http_post( url, postData, false );
                        job.addMetaData("content-type", contentType );
                        job.addMetaData("referrer", referrerURL);
                     
    postData is the data that you want to send and contentType is the complete HTTP header line that specifies the content's MIME type, for example "Content-Type: text/xml". You MUST specify content-type! Often contentType is "Content-Type: application/x-www-form-urlencoded" and the postData is then an ASCII string (without null-termination!) with characters like space, linefeed and percent escaped like %20, %0A and %25.

    Parameters:
    url - Where to write the data.
    postData - Encoded data to post.
    showProgressInfo - true to display
    Returns:
    the job handling the operation.

    http_post

    public static TransferJob http_post(KURL url,
                                        byte[] postData)

    storedGet

    public static StoredTransferJob storedGet(KURL url,
                                              boolean reload,
                                              boolean showProgressInfo)
    Get (a.k.a. read), into a single byte[].

    Parameters:
    url - the URL of the file
    reload - true to reload the file, false if it can be taken from the cache
    showProgressInfo - true to show progress information
    Returns:
    the job handling the operation.
    See Also:
    StoredTransferJob

    storedGet

    public static StoredTransferJob storedGet(KURL url,
                                              boolean reload)

    storedGet

    public static StoredTransferJob storedGet(KURL url)

    storedPut

    public static StoredTransferJob storedPut(byte[] arr,
                                              KURL url,
                                              int permissions,
                                              boolean overwrite,
                                              boolean resume,
                                              boolean showProgressInfo)
    Put (a.k.a. write) data from a single byte[].

    Parameters:
    arr - The data to write
    url - Where to write data.
    permissions - May be -1. In this case no special permission mode is set.
    overwrite - If true, any existing file will be overwritten.
    resume - true to resume an operation. Warning, setting this to true means that the data will be appended to dest if dest exists.
    showProgressInfo - true to show progress information
    Returns:
    the job handling the operation.
    See Also:
    StoredTransferJob

    storedPut

    public static StoredTransferJob storedPut(byte[] arr,
                                              KURL url,
                                              int permissions,
                                              boolean overwrite,
                                              boolean resume)

    mimetype

    public static MimetypeJob mimetype(KURL url,
                                       boolean showProgressInfo)
    Find mimetype for one file or directory.

    Parameters:
    url - the URL of the file
    showProgressInfo - true to show progress information
    Returns:
    the job handling the operation.

    mimetype

    public static MimetypeJob mimetype(KURL url)

    file_copy

    public static FileCopyJob file_copy(KURL src,
                                        KURL dest,
                                        int permissions,
                                        boolean overwrite,
                                        boolean resume,
                                        boolean showProgressInfo)
    Copy a single file. Uses either SlaveBase.copy() if the slave supports that or get() and put() otherwise.

    Parameters:
    src - Where to get the file.
    dest - Where to put the file.
    permissions - May be -1. In this case no special permission mode is set.
    overwrite - If true, any existing file will be overwritten.
    resume - true to resume an operation. Warning, setting this to true means that src will be appended to dest if dest exists. You probably don't want that, so leave it to false :)
    showProgressInfo - true to show progress information
    Returns:
    the job handling the operation.

    file_copy

    public static FileCopyJob file_copy(KURL src,
                                        KURL dest,
                                        int permissions,
                                        boolean overwrite,
                                        boolean resume)

    file_copy

    public static FileCopyJob file_copy(KURL src,
                                        KURL dest,
                                        int permissions,
                                        boolean overwrite)

    file_copy

    public static FileCopyJob file_copy(KURL src,
                                        KURL dest,
                                        int permissions)

    file_copy

    public static FileCopyJob file_copy(KURL src,
                                        KURL dest)

    file_move

    public static FileCopyJob file_move(KURL src,
                                        KURL dest,
                                        int permissions,
                                        boolean overwrite,
                                        boolean resume,
                                        boolean showProgressInfo)
    Move a single file. Use either SlaveBase.rename() if the slave supports that, or copy() and del() otherwise, or eventually get() & put() & del()

    Parameters:
    src - Where to get the file.
    dest - Where to put the file.
    permissions - May be -1. In this case no special permission mode is set.
    overwrite - If true, any existing file will be overwritten.
    resume - true to resume an operation. Warning, setting this to true means that src will be appended to dest if dest exists. You probably don't want that, so leave it to false :)
    showProgressInfo - true to show progress information
    Returns:
    the job handling the operation.

    file_move

    public static FileCopyJob file_move(KURL src,
                                        KURL dest,
                                        int permissions,
                                        boolean overwrite,
                                        boolean resume)

    file_move

    public static FileCopyJob file_move(KURL src,
                                        KURL dest,
                                        int permissions,
                                        boolean overwrite)

    file_move

    public static FileCopyJob file_move(KURL src,
                                        KURL dest,
                                        int permissions)

    file_move

    public static FileCopyJob file_move(KURL src,
                                        KURL dest)

    file_delete

    public static SimpleJob file_delete(KURL src,
                                        boolean showProgressInfo)
    Delete a single file.

    Parameters:
    src - File to delete.
    showProgressInfo - true to show progress information
    Returns:
    the job handling the operation.

    file_delete

    public static SimpleJob file_delete(KURL src)

    listDir

    public static ListJob listDir(KURL url,
                                  boolean showProgressInfo,
                                  boolean includeHidden)
    List the contents of url, which is assumed to be a directory. "." and ".." are returned, filter them out if you don't want them.

    Parameters:
    url - the url of the directory
    showProgressInfo - true to show progress information
    includeHidden - true for all files, false to cull out UNIX hidden files/dirs (whose names start with dot)
    Returns:
    the job handling the operation.

    listDir

    public static ListJob listDir(KURL url,
                                  boolean showProgressInfo)

    listDir

    public static ListJob listDir(KURL url)

    listRecursive

    public static ListJob listRecursive(KURL url,
                                        boolean showProgressInfo,
                                        boolean includeHidden)
    The same as the previous method, but recurses subdirectories. Directory links are not followed. "." and ".." are returned but only for the toplevel directory. Filter them out if you don't want them.

    Parameters:
    url - the url of the directory
    showProgressInfo - true to show progress information
    includeHidden - true for all files, false to cull out UNIX hidden files/dirs (whose names start with dot)
    Returns:
    the job handling the operation.

    listRecursive

    public static ListJob listRecursive(KURL url,
                                        boolean showProgressInfo)

    listRecursive

    public static ListJob listRecursive(KURL url)

    copy

    public static CopyJob copy(KURL src,
                               KURL dest,
                               boolean showProgressInfo)
    Copy a file or directory src into the destination dest, which can be a file (including the final filename) or a directory (into which src will be copied). This emulates the cp command completely.

    Parameters:
    src - the file or directory to copy
    dest - the destination
    showProgressInfo - true to show progress information
    Returns:
    the job handling the operation
    See Also:
    copyAs(org.kde.koala.KURL, org.kde.koala.KURL, boolean)

    copy

    public static CopyJob copy(KURL src,
                               KURL dest)

    copyAs

    public static CopyJob copyAs(KURL src,
                                 KURL dest,
                                 boolean showProgressInfo)
    Copy a file or directory src into the destination dest, which is the destination name in any case, even for a directory. As opposed to copy(), this doesn't emulate cp, but is the only way to copy a directory, giving it a new name and getting an error box if a directory already exists with the same name.

    Parameters:
    src - the file or directory to copy
    dest - the destination
    showProgressInfo - true to show progress information
    Returns:
    the job handling the operation

    copyAs

    public static CopyJob copyAs(KURL src,
                                 KURL dest)

    copy

    public static CopyJob copy(java.util.ArrayList src,
                               KURL dest,
                               boolean showProgressInfo)
    Copy a list of file/dirs src into a destination directory dest.

    Parameters:
    src - the list of files and/or directories
    dest - the destination
    showProgressInfo - true to show progress information
    Returns:
    the job handling the operation

    copy

    public static CopyJob copy(java.util.ArrayList src,
                               KURL dest)

    move

    public static CopyJob move(KURL src,
                               KURL dest,
                               boolean showProgressInfo)
    Moves a file or directory src to the given destination dest.

    Parameters:
    src - the file or directory to copy
    dest - the destination
    showProgressInfo - true to show progress information
    Returns:
    the job handling the operation
    See Also:
    copy(org.kde.koala.KURL, org.kde.koala.KURL, boolean), moveAs(org.kde.koala.KURL, org.kde.koala.KURL, boolean)

    move

    public static CopyJob move(KURL src,
                               KURL dest)

    moveAs

    public static CopyJob moveAs(KURL src,
                                 KURL dest,
                                 boolean showProgressInfo)
    Moves a file or directory src to the given destination dest. Unlike move() this operation will fail when the directory already exists.

    Parameters:
    src - the file or directory to copy
    dest - the destination
    showProgressInfo - true to show progress information
    Returns:
    the job handling the operation
    See Also:
    copyAs(org.kde.koala.KURL, org.kde.koala.KURL, boolean)

    moveAs

    public static CopyJob moveAs(KURL src,
                                 KURL dest)

    move

    public static CopyJob move(java.util.ArrayList src,
                               KURL dest,
                               boolean showProgressInfo)
    Moves a list of files or directories src to the given destination dest.

    Parameters:
    src - the list of files or directories to copy
    dest - the destination
    showProgressInfo - true to show progress information
    Returns:
    the job handling the operation
    See Also:
    copy(org.kde.koala.KURL, org.kde.koala.KURL, boolean)

    move

    public static CopyJob move(java.util.ArrayList src,
                               KURL dest)

    link

    public static CopyJob link(KURL src,
                               KURL destDir,
                               boolean showProgressInfo)
    Create a link. If the protocols and hosts are the same, a Unix symlink will be created. Otherwise, a .desktop file of Type Link and pointing to the src URL will be created.

    Parameters:
    src - The existing file or directory, 'target' of the link.
    destDir - Destination directory where the link will be created.
    showProgressInfo - true to show progress information
    Returns:
    the job handling the operation

    link

    public static CopyJob link(KURL src,
                               KURL destDir)

    link

    public static CopyJob link(java.util.ArrayList src,
                               KURL destDir,
                               boolean showProgressInfo)
    Create several links If the protocols and hosts are the same, a Unix symlink will be created. Otherwise, a .desktop file of Type Link and pointing to the src URL will be created.

    Parameters:
    src - The existing files or directories, 'targets' of the link.
    destDir - Destination directory where the links will be created.
    showProgressInfo - true to show progress information
    Returns:
    the job handling the operation
    See Also:
    link(org.kde.koala.KURL, org.kde.koala.KURL, boolean)

    link

    public static CopyJob link(java.util.ArrayList src,
                               KURL destDir)

    linkAs

    public static CopyJob linkAs(KURL src,
                                 KURL dest,
                                 boolean showProgressInfo)
    Create a link. Unlike link() this operation will fail when the directory already exists. If the protocols and hosts are the same, a Unix symlink will be created. Otherwise, a .desktop file of Type Link and pointing to the src URL will be created.

    Parameters:
    src - The existing file or directory, 'target' of the link.
    dest - Destination directory where the link will be created.
    showProgressInfo - true to show progress information
    Returns:
    the job handling the operation
    See Also:
    link(org.kde.koala.KURL, org.kde.koala.KURL, boolean), copyAs(org.kde.koala.KURL, org.kde.koala.KURL, boolean)

    linkAs

    public static CopyJob linkAs(KURL src,
                                 KURL dest)

    trash

    public static CopyJob trash(KURL src,
                                boolean showProgressInfo)
    Trash a file or directory. This is currently only supported for local files and directories. Use "KURL src; src.setPath( path );" to create a URL from a path.

    Parameters:
    src - file to delete
    showProgressInfo - true to show progress information
    Returns:
    the job handling the operation

    trash

    public static CopyJob trash(KURL src)

    trash

    public static CopyJob trash(java.util.ArrayList src,
                                boolean showProgressInfo)
    Trash a list of files or directories. This is currently only supported for local files and directories.

    Parameters:
    src - the files to delete
    showProgressInfo - true to show progress information
    Returns:
    the job handling the operation

    trash

    public static CopyJob trash(java.util.ArrayList src)

    del

    public static DeleteJob del(KURL src,
                                boolean shred,
                                boolean showProgressInfo)
    Delete a file or directory.

    Parameters:
    src - file to delete
    shred - obsolete (TODO remove in KDE4)
    showProgressInfo - true to show progress information
    Returns:
    the job handling the operation

    del

    public static DeleteJob del(KURL src,
                                boolean shred)

    del

    public static DeleteJob del(KURL src)

    del

    public static DeleteJob del(java.util.ArrayList src,
                                boolean shred,
                                boolean showProgressInfo)
    Deletes a list of files or directories.

    Parameters:
    src - the files to delete
    shred - obsolete (TODO remove in KDE4)
    showProgressInfo - true to show progress information
    Returns:
    the job handling the operation

    del

    public static DeleteJob del(java.util.ArrayList src,
                                boolean shred)

    del

    public static DeleteJob del(java.util.ArrayList src)

    pasteClipboard

    public static Job pasteClipboard(KURL destURL,
                                     boolean move)
    Pastes the content of the clipboard to the given destination URL. URLs are treated separately (performing a file copy) from other data (which is saved into a file after asking the user to choose a filename and the preferred data format)

    Parameters:
    destURL - the URL to receive the data
    move - true to move the data, false to copy
    Returns:
    the job that handles the operation
    See Also:
    pasteData(org.kde.koala.KURL, byte[])

    pasteClipboard

    public static Job pasteClipboard(KURL destURL)

    pasteData

    public static void pasteData(KURL destURL,
                                 byte[] data)
    Pastes the given data to the given destination URL. NOTE: This method is blocking (uses NetAccess for saving the data). Please consider using pasteDataAsync instead.

    Parameters:
    destURL - the URL of the directory where the data will be pasted. The filename to use in that directory is prompted by this method.
    data - the data to copy
    See Also:
    pasteClipboard(org.kde.koala.KURL, boolean)

    pasteDataAsync

    public static CopyJob pasteDataAsync(KURL destURL,
                                         byte[] data)
    Pastes the given data to the given destination URL. Note that this method requires the caller to have chosen the byte[] to paste before hand, unlike pasteClipboard and pasteMimeSource.

    Parameters:
    destURL - the URL of the directory where the data will be pasted. The filename to use in that directory is prompted by this method.
    data - the data to copy
    See Also:
    pasteClipboard(org.kde.koala.KURL, boolean)

    pasteDataAsync

    public static CopyJob pasteDataAsync(KURL destURL,
                                         byte[] data,
                                         java.lang.String dialogText)
    Pastes the given data to the given destination URL. Note that this method requires the caller to have chosen the byte[] to paste before hand, unlike pasteClipboard and pasteMimeSource.

    Parameters:
    destURL - the URL of the directory where the data will be pasted. The filename to use in that directory is prompted by this method.
    data - the data to copy
    dialogText - the text to show in the dialog
    See Also:
    pasteClipboard(org.kde.koala.KURL, boolean)

    pasteMimeSource

    public static CopyJob pasteMimeSource(org.kde.qt.QMimeSourceInterface data,
                                          KURL destURL,
                                          java.lang.String dialogText,
                                          org.kde.qt.QWidget widget,
                                          boolean clipboard)
    Save the given mimesource data to the given destination URL after offering the user to choose a data format. This is the method used when handling drops (of anything else than URLs) onto kdesktop and konqueror.

    Parameters:
    data - the QMimeSource (e.g. a QDropEvent)
    destURL - the URL of the directory where the data will be pasted. The filename to use in that directory is prompted by this method.
    dialogText - the text to show in the dialog
    widget - parent widget to use for dialogs
    clipboard - whether the QMimeSource comes from QClipboard. If you use pasteClipboard for that case, you never have to worry about this parameter.
    See Also:
    pasteClipboard(org.kde.koala.KURL, boolean)

    pasteMimeSource

    public static CopyJob pasteMimeSource(org.kde.qt.QMimeSourceInterface data,
                                          KURL destURL,
                                          java.lang.String dialogText,
                                          org.kde.qt.QWidget widget)

    isClipboardEmpty

    public static boolean isClipboardEmpty()
    Checks whether the clipboard contains any URLs.

    Returns:
    true if not Not used anymore, wrong method name, so it will disappear in KDE4.

    pasteActionText

    public static java.lang.String pasteActionText()
    Returns the text to use for the Paste action, when the application supports pasting files, urls, and clipboard data, using pasteClipboard().

    Returns:
    a string suitable for KAction.setText, or an empty string if pasting isn't possible right now.