in favor of KApplicationTrader (for app desktop files), KParts::PartLoader for parts and KPluginLoader for general plugins.
Description
Status | Assigned | Task | ||
---|---|---|---|---|
Open | None | T12171 Meta task: KService | ||
Open | None | T12177 KService: deprecate KMimeTypeTrader |
Is there a replacement that features the full trader language? We expose that in ktraderclient: https://invent.kde.org/plasma/kde-cli-tools/-/blob/master/ktraderclient/ktraderclient.cpp
No, we determined that the trader language wasn't the best way to write C++ code.
ktraderclient was mostly written as a debugging helper. I suggest to strip out the constraint functionality from ktraderclient.
I've hit a minor problem while porting:
In https://invent.kde.org/frameworks/kio/-/blob/master/src/core/kprotocolmanager.cpp#L729 KIO uses KMimeTypeTrader to find the preferred browser part and extracts the default user agent from it.
The idiomatic solution would be to port to KParts::PartLoader, but since KParts depends on KIO that would create a cyclic dependency between KIO and KParts
My thoughts on that code are the following: T14307. But actually I just realized something.... I'll add a comment there.