KDE 4.9 PyKDE API Reference

- KDE's Python API

# FileInfoExtension Class Reference

`from PyKDE4.kparts import *`

Inherits: QObject
Namespace: KParts

## Detailed Description

an extension for obtaining file information from the part.

This extension provides information about file and directory resources that are present in the part the implements it.

The main purpose of for this extension is to provide information about files and directories located on remote servers so that download managers such as kget can easily retrieve these resources.

Since:
  4.6

## Enumerations
QueryMode | { None, AllItems, SelectedItems }
## Methods
| __init__ (self, KParts.ReadOnlyPart parent)
bool | hasSelection (self)
KFileItemList | queryFor (self, KParts.FileInfoExtension.QueryMode mode)
KParts.FileInfoExtension.QueryModes | supportedQueryModes (self)
## Static Methods
KParts.FileInfoExtension | childObject (QObject obj)

## Method Documentation

__init__ | ( | self, |
|  | KParts.ReadOnlyPart | parent
| ) |  |  |

bool hasSelection | ( |  | self ) |

Returns true if any of the items in the current view of the part that implements this extension are selected.

By default this function returns false.

KFileItemList queryFor | ( | self, |
|  | KParts.FileInfoExtension.QueryMode | mode
| ) |  |  |

Abstract method:
  This method is abstract and can be overridden but not called directly.

Returns a information for files that match the specified query mode.

If the mode specified by mode is not supported or cannot be handled, then an empty list is returned.

KParts.FileInfoExtension.QueryModes supportedQueryModes | ( |  | self ) |

Returns the file information retrieve modes supported by the part that implements this extension.

By default this function returns None.

## Static Method Documentation

KParts.FileInfoExtension childObject | ( | QObject | obj
| ) |  |  |

Queries obj for a child object which inherits from this class.

## Enumeration Documentation

QueryMode

Supported file information retrieval modes.

Enumerator:

  None = 0x00 |
  AllItems = 0x01 |
  SelectedItems = 0x02 |