org.kde.koala
Interface KDirListerSignals


public interface KDirListerSignals


Method Summary
 void canceled()
          Tell the view that the user canceled the listing.
 void canceled(KURL _url)
          Tell the view that the listing of the directory _url was canceled.
 void clear()
          Signal to clear all items.
 void clear(KURL _url)
          Signal to empty the directory _url. It is only emitted if the lister is holding more than one directory.
 void completed()
          Tell the view that listing is finished.
 void completed(KURL _url)
          Tell the view that the listing of the directory _url is finished.
 void deleteItem(KFileItem _fileItem)
          Signal an item to remove.
 void infoMessage(java.lang.String msg)
          Emitted to display information about running jobs.
 void itemsFilteredByMime(java.util.ArrayList items)
          Send a list of items filtered-out by mime-type.
 void newItems(java.util.ArrayList items)
          Signal new items.
 void percent(int percent)
          Progress signal showing the overall progress of the KDirLister.
 void processedSize(long size)
          Regularly emitted to show the progress of this KDirLister.
 void redirection(KURL _url)
          Signal a redirection.
 void redirection(KURL oldUrl, KURL newUrl)
          Signal a redirection.
 void refreshItems(java.util.ArrayList items)
          Signal an item to refresh (its mimetype/icon/name has changed).
 void speed(int bytes_per_second)
          Emitted to display information about the speed of the jobs.
 void started(KURL _url)
          Tell the view that we started to list _url. NOTE: this does _not_ imply that there is really a job running! I.e.
 void totalSize(long size)
          Emitted when we know the size of the jobs.
 

Method Detail

started

void started(KURL _url)
Tell the view that we started to list _url. NOTE: this does _not_ imply that there is really a job running! I.e. KDirLister.jobs() may return an empty list. In this case the items are taken from the cache. The view knows that openURL should start it, so it might seem useless, but the view also needs to know when an automatic update happens.

Parameters:
_url - the URL to list

completed

void completed()
Tell the view that listing is finished. There are no jobs running anymore.


completed

void completed(KURL _url)
Tell the view that the listing of the directory _url is finished. There might be other running jobs left. This signal is only emitted if KDirLister is watching more than one directory.

Parameters:
_url - the directory URL

canceled

void canceled()
Tell the view that the user canceled the listing. No running jobs are left.


canceled

void canceled(KURL _url)
Tell the view that the listing of the directory _url was canceled. There might be other running jobs left. This signal is only emitted if KDirLister is watching more than one directory.

Parameters:
_url - the directory URL

redirection

void redirection(KURL _url)
Signal a redirection. Only emitted if there's just one directory to list, i.e. most probably openURL() has been called with _keep == false.

Parameters:
_url - the new URL

redirection

void redirection(KURL oldUrl,
                 KURL newUrl)
Signal a redirection.

Parameters:
oldUrl - the original URL
newUrl - the new URL

clear

void clear()
Signal to clear all items. It must always be connected to this signal to avoid doubled items!


clear

void clear(KURL _url)
Signal to empty the directory _url. It is only emitted if the lister is holding more than one directory.

Parameters:
_url - the directory that will be emptied

newItems

void newItems(java.util.ArrayList items)
Signal new items.

Parameters:
items - a list of new items

itemsFilteredByMime

void itemsFilteredByMime(java.util.ArrayList items)
Send a list of items filtered-out by mime-type.

Parameters:
items - the list of filtered items

deleteItem

void deleteItem(KFileItem _fileItem)
Signal an item to remove. ATTENTION: if _fileItem == rootItem() the directory this lister is holding was deleted and you HAVE to release especially the rootItem() of this lister, otherwise your app will CRASH!! The clear() signals have been emitted already.

Parameters:
_fileItem - the fileItem to delete

refreshItems

void refreshItems(java.util.ArrayList items)
Signal an item to refresh (its mimetype/icon/name has changed). Note: KFileItem.refresh has already been called on those items.

Parameters:
items - the items to refresh

infoMessage

void infoMessage(java.lang.String msg)
Emitted to display information about running jobs. Examples of message are "Resolving host", "Connecting to host...", etc.

Parameters:
msg - the info message

percent

void percent(int percent)
Progress signal showing the overall progress of the KDirLister. This allows using a progress bar very easily. (see KProgress)

Parameters:
percent - the progress in percent

totalSize

void totalSize(long size)
Emitted when we know the size of the jobs.

Parameters:
size - the total size in bytes

processedSize

void processedSize(long size)
Regularly emitted to show the progress of this KDirLister.

Parameters:
size - the processed size in bytes

speed

void speed(int bytes_per_second)
Emitted to display information about the speed of the jobs.

Parameters:
bytes_per_second - the speed in bytes/s