Plasma
IonInterface Class Reference
#include <ion.h>

Detailed Description
The idea is that you can have multiple ions which provide weather information from different services to the engine from which an applet will request the data from.
Basically an ion is a Plasma::DataEngine, which is queried by the WeatherEngine instead of some applet.
Definition at line 36 of file ion.h.
Public Types | |
typedef QHash< QString, IonInterface * > | IonDict |
Public Slots | |
bool | updateSourceEvent (const QString &source) |
Public Member Functions | |
void | deref () |
IonInterface (QObject *parent=0, const QVariantList &args=QVariantList()) | |
bool | isUsed () const |
virtual bool | metricUnit (void)=0 |
void | ref () |
virtual bool | timezone (void)=0 |
virtual | ~IonInterface () |
Protected Member Functions | |
void | setInitialized (bool initialized) |
bool | sourceRequestEvent (const QString &source) |
virtual bool | updateIonSource (const QString &source)=0 |
Properties | |
QString | timezone |
QString | unit |
Member Typedef Documentation
typedef QHash<QString, IonInterface*> IonInterface::IonDict |
Constructor & Destructor Documentation
IonInterface::IonInterface | ( | QObject * | parent = 0 , |
|
const QVariantList & | args = QVariantList() | |||
) | [explicit] |
virtual IonInterface::~IonInterface | ( | ) | [inline, virtual] |
Member Function Documentation
void IonInterface::deref | ( | ) |
bool IonInterface::isUsed | ( | ) | const |
virtual bool IonInterface::metricUnit | ( | void | ) | [pure virtual] |
Reimplement to check whether the measurement is metric or not.
- Returns:
- true if metric is used, false if not.
Implemented in UKMETIon, EnvCanadaIon, and NOAAIon.
void IonInterface::ref | ( | ) |
void IonInterface::setInitialized | ( | bool | initialized | ) | [protected] |
bool IonInterface::sourceRequestEvent | ( | const QString & | source | ) | [protected] |
Reimplemented from Plasma::DataEngine.
If the ion is not initialized just set the initial data source up even if it's empty, we'll retry once the initialization is done.
- Parameters:
-
source The datasource being requested
virtual bool IonInterface::timezone | ( | void | ) | [pure virtual] |
Reimplement to check if timeformat is UTC or not.
- Returns:
- true if UTC, false if local time.
Implemented in UKMETIon, EnvCanadaIon, and NOAAIon.
virtual bool IonInterface::updateIonSource | ( | const QString & | source | ) | [protected, pure virtual] |
Reimplement to fetch the data from the ion.
- source the name of the datasource.
- Returns:
- true if update was successful, false if failed
Implemented in UKMETIon, EnvCanadaIon, and NOAAIon.
bool IonInterface::updateSourceEvent | ( | const QString & | source | ) | [slot] |
Reimplemented from Plasma::DataEngine.
Update the ion's datasource.
- Parameters:
-
source the name of the datasource to be updated
Property Documentation
The documentation for this class was generated from the following files: