KItinerary::JsonLd Namespace Reference


template<typename T >
bool canConvert (const QVariant &value)
template<typename T >
convert (const QVariant &value)
template<typename T >
bool isA (const QVariant &value)
void renameProperty (QJsonObject &obj, const char *oldName, const char *newName)
bool valueIsNull (const QVariant &v)

Detailed Description

JSON-LD data type helper functions.

Function Documentation

◆ canConvert()

template<typename T >
bool KItinerary::JsonLd::canConvert ( const QVariant value)

Checks if the given value can be up-cast to T.

Definition at line 31 of file lib/datatypes/datatypes.h.

◆ convert()

template<typename T >
T KItinerary::JsonLd::convert ( const QVariant value)

Up-cast value to T.

This does not perform any safety checks!
See also

Definition at line 47 of file lib/datatypes/datatypes.h.

◆ isA()

template<typename T >
bool KItinerary::JsonLd::isA ( const QVariant value)

Returns true if value is of type T.

Definition at line 24 of file lib/datatypes/datatypes.h.

◆ renameProperty()

void KItinerary::JsonLd::renameProperty ( QJsonObject obj,
const char *  oldName,
const char *  newName 

Rename a property, if present and the new name isn't in use already.

Definition at line 16 of file jsonldfilterengine.cpp.

◆ valueIsNull()

bool KItinerary::JsonLd::valueIsNull ( const QVariant v)

Checks whether v holds a null-like value.

This is similar to QVariant::isNull in Qt5, but differs from the "shallow" QVariant::isNull in Qt6 which doesn't check the content at all.

Definition at line 354 of file jsonlddocument.cpp.

This file is part of the KDE documentation.
Documentation copyright © 1996-2022 The KDE developers.
Generated on Tue Dec 6 2022 04:04:41 by doxygen 1.8.17 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.