KDE 4.7 PyKDE API Reference

- KDE's Python API

# RunnerPlugin Class Reference

`from PyKDE4.marble import *`

Inherits: QObject,Marble.PluginInterface
Namespace: Marble

## Detailed Description

A plugin for marble to execute a placemark search, reverse geocoding or routing task.

## Enumerations
Capability | { None, Search, ReverseGeocoding, Routing }
## Methods
| __init__ (self, QObject parent=0)
bool | canWork (self, Marble.RunnerPlugin.Capability capability)
bool | canWorkOffline (self)
Marble.RunnerPlugin.Capabilities | capabilities (self)
QString | description (self)
QString | guiString (self)
QIcon | icon (self)
| initialize (self)
bool | isInitialized (self)
QString | name (self)
QString | nameId (self)
Marble.MarbleAbstractRunner | newRunner (self)
| setCanWorkOffline (self, bool canWorkOffline)
| setCapabilities (self, Marble.RunnerPlugin.Capabilities capabilities)
| setDescription (self, QString description)
| setGuiString (self, QString guiString)
| setIcon (self, QIcon icon)
| setName (self, QString name)
| setNameId (self, QString nameId)
| setStatusMessage (self, QString message)
| setSupportedCelestialBodies (self, QStringList celestialBodies)
QString | statusMessage (self)
bool | supports (self, Marble.RunnerPlugin.Capability capability)
bool | supportsCelestialBody (self, QString celestialBodyId)

## Method Documentation

__init__ | ( | self, |
|  | QObject | parent=0
| ) |  |  |

Constructor with optional parent object

bool canWork | ( | self, |
|  | Marble.RunnerPlugin.Capability | capability
| ) |  |  |

Returns true if the plugin can execute a task for the given capability The default implementation returns true iff the plugin supports the given capability. This method can be overriden for example to indicate an incomplete installation.

bool canWorkOffline | ( |  | self ) |

True if the plugin can execute its tasks without network access

Marble.RunnerPlugin.Capabilities capabilities | ( |  | self ) |

Plugin capabilities, i.e. the tasks it supports

QString description | ( |  | self ) |

QString guiString | ( |  | self ) |

QIcon icon | ( |  | self ) |

initialize | ( |  | self ) |

bool isInitialized | ( |  | self ) |

QString name | ( |  | self ) |

QString nameId | ( |  | self ) |

Marble.MarbleAbstractRunner newRunner | ( |  | self ) |

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

Plugin factory method to create a new runner instance. Method caller gets ownership of the returned object

setCanWorkOffline | ( | self, |
|  | bool | canWorkOffline
| ) |  |  |

setCapabilities | ( | self, |
|  | Marble.RunnerPlugin.Capabilities | capabilities
| ) |  |  |

setDescription | ( | self, |
|  | QString | description
| ) |  |  |

setGuiString | ( | self, |
|  | QString | guiString
| ) |  |  |

setIcon | ( | self, |
|  | QIcon | icon
| ) |  |  |

setName | ( | self, |
|  | QString | name
| ) |  |  |

setNameId | ( | self, |
|  | QString | nameId
| ) |  |  |

setStatusMessage | ( | self, |
|  | QString | message
| ) |  |  |

setSupportedCelestialBodies | ( | self, |
|  | QStringList | celestialBodies
| ) |  |  |

QString statusMessage | ( |  | self ) |

A status message showing whether the plugin will be able to deliver results

bool supports | ( | self, |
|  | Marble.RunnerPlugin.Capability | capability
| ) |  |  |

Convenience method to determine whether the plugin support the given capability

bool supportsCelestialBody | ( | self, |
|  | QString | celestialBodyId
| ) |  |  |

True if the plugin supports its tasks on the given planet

## Enumeration Documentation

Capability

Enumerator:

  None = 0x0 |
  Search = 0x1 |
  ReverseGeocoding = 0x2 |
  Routing = 0x4 |