KItinerary
jsapi/jsonld.cpp
203 return m_engine->toScriptValue(ReservationConverter::trainToBus(QJsonValue::fromVariant(trainRes.toVariant()).toObject()));
208 return m_engine->toScriptValue(ReservationConverter::busToTrain(QJsonValue::fromVariant(busRes.toVariant()).toObject()));
211QDateTime JsApi::JsonLd::toDateTime(const QString &dtStr, const QString &format, const QString &localeName) const
217 // QLocale expects the exact string in QLocale::shortMonthName(), while we often encounter a three
218 // letter month identifier. For en_US that's the same, for Swedish it isn't though for example. So
366 const auto lhsVar = JsonLdDocument::fromJsonSingular(QJsonValue::fromVariant(lhs.toVariant()).toObject());
367 const auto rhsVar = JsonLdDocument::fromJsonSingular(QJsonValue::fromVariant(rhs.toVariant()).toObject());
Q_INVOKABLE QJSValue newEventReservation() const
Convenience method that generates a full EventReservation JS object.
Definition jsapi/jsonld.cpp:133
Q_INVOKABLE QJSValue toGeoCoordinates(const QString &mapUrl)
Parses geo coordinates from a given mapping service URLs.
Definition jsapi/jsonld.cpp:337
Q_INVOKABLE QJSValue newLodgingReservation() const
Convenience method that generates a full LodgingReservation JS object.
Definition jsapi/jsonld.cpp:121
Q_INVOKABLE QJSValue newBusReservation() const
Convenience method that generates a full BusReservation JS object.
Definition jsapi/jsonld.cpp:98
Q_INVOKABLE QJSValue busToTrainReservation(const QJSValue &busRes) const
Convert a bus reservation to a train reservation.
Definition jsapi/jsonld.cpp:206
Q_INVOKABLE QJSValue newObject(const QString &typeName) const
Create a new JSON-LD object of type typeName.
Definition jsapi/jsonld.cpp:33
Q_INVOKABLE QJSValue apply(const QJSValue &lhs, const QJSValue &rhs) const
Definition jsapi/jsonld.cpp:364
Q_INVOKABLE QJSValue clone(const QJSValue &v) const
Clones the given JS object.
Definition jsapi/jsonld.cpp:332
Q_INVOKABLE QJSValue toJson(const QVariant &v) const
Convert object v to a JSON-LD object.
Definition jsapi/jsonld.cpp:321
Q_INVOKABLE QJSValue newRentalCarReservation() const
Convenience method that generates a full RentalCarReservation JS object.
Definition jsapi/jsonld.cpp:163
Q_INVOKABLE QDateTime toDateTime(const QString &dtStr, const QJSValue &format, const QJSValue &localeName) const
Convert a date/time string to a date/time value.
Definition jsapi/jsonld.cpp:293
Q_INVOKABLE QJSValue readQDateTime(const QVariant &obj, const QString &propName) const
Read a QDateTime property and return a JSON-LD serialization of it.
Definition jsapi/jsonld.cpp:348
Q_INVOKABLE QJSValue newFoodEstablishmentReservation() const
Convenience method that generates a full FoodEstablishmentReservation JS object.
Definition jsapi/jsonld.cpp:151
Q_INVOKABLE QJSValue newTrainReservation() const
Convenience method that generates a full TrainReservation JS object.
Definition jsapi/jsonld.cpp:74
Q_INVOKABLE QJSValue newFlightReservation() const
Convenience method that generates a full FlightReservation JS object.
Definition jsapi/jsonld.cpp:52
Q_INVOKABLE QJSValue newBoatReservation() const
Convenience method that generates a full BoatReservation JS object.
Definition jsapi/jsonld.cpp:182
Q_INVOKABLE QJSValue trainToBusReservation(const QJSValue &trainRes) const
Convert a train reservation to a bus reservation.
Definition jsapi/jsonld.cpp:201
static QJsonValue toJsonValue(const QVariant &data)
JSON-LD serrialization of an invidividual data value.
Definition jsonlddocument.cpp:405
static QVariant apply(const QVariant &lhs, const QVariant &rhs)
Apply all properties of rhs on to lhs.
Definition jsonlddocument.cpp:564
static QJsonArray toJson(const QList< QVariant > &data)
Serialize instantiated data types to JSON-LD.
Definition jsonlddocument.cpp:497
static QVariant fromJsonSingular(const QJsonObject &obj)
Convert a single JSON-LD object into an instantiated data type.
Definition jsonlddocument.cpp:361
GeoCoordinates geoFromUrl(const QUrl &url)
Parses geo coordinates from a given mapping service URLs, such as Google Maps links.
Definition locationutil.cpp:131
QJsonObject trainToBus(const QJsonObject &trainRes)
Convert a train reservation to a bus reservation.
Definition reservationconverter.cpp:27
QJsonObject busToTrain(const QJsonObject &busRes)
Convert a bus reservation to a train reservation.
Definition reservationconverter.cpp:52
Classes for reservation/travel data models, data extraction and data augmentation.
Definition berelement.h:17
const char * constData() const const
char32_t toCaseFolded(char32_t ucs4)
QJSValue newObject()
QJsonValue fromVariant(const QVariant &variant)
QJsonObject toObject() const const
bool isArray() const const
bool isString() const const
QJSValue property(const QString &name) const const
void setProperty(const QString &name, const QJSValue &value)
qint32 toInt() const const
QString toString() const const
QVariant toVariant() const const
ShortFormat
int indexOfProperty(const char *name) const const
const QMetaObject * metaObject() const const
const QChar at(qsizetype position) const const
bool contains(QChar ch, Qt::CaseSensitivity cs) const const
qsizetype indexOf(QChar ch, qsizetype from, Qt::CaseSensitivity cs) const const
qsizetype size() const const
QByteArray toUtf8() const const
CaseInsensitive
bool canConvert() const const
const void * constData() const const
int userType() const const
T value() const const
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Sat Dec 21 2024 16:56:36 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006
Documentation copyright © 1996-2024 The KDE developers.
Generated on Sat Dec 21 2024 16:56:36 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.