Add function to extract a single file
ClosedPublic

Authored by ltoscano on Feb 26 2017, 10:01 PM.

Details

Summary

Extract a single file from a QString which contains the generated
content.
The usage of this function by kio_help reduces the number of the
functions from xslt.* used by KIO.

Test Plan

Compiles, no functional changes (tested with a dependent change in KIO).

Diff Detail

Repository
R238 KDocTools
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.
ltoscano created this revision.Feb 26 2017, 10:01 PM
Restricted Application added projects: Frameworks, Documentation. · View Herald TranscriptFeb 26 2017, 10:01 PM
Restricted Application added subscribers: Documentation, Frameworks. · View Herald Transcript
dfaure added a subscriber: dfaure.Feb 26 2017, 11:33 PM

The code looks ok, I'm just not sure this is "nice" exported API though. ("do", no documentation, ...)

ltoscano updated this revision to Diff 11873.Feb 26 2017, 11:56 PM

More meaningful name for the new function

dfaure accepted this revision.Feb 27 2017, 12:16 AM

Looks good, just some nitpicks. Feel free to push directly.

src/xslt.cpp
365

QLatin1String would be better (because it's a comparison, and there's a QLatin1String overload for this purpose)

368

I like the value added by the comment :-)

src/xslt.h
17

I think doxygen needs /** here, no?

This revision is now accepted and ready to land.Feb 27 2017, 12:16 AM
This revision was automatically updated to reflect the committed changes.
ltoscano marked 3 inline comments as done.Feb 27 2017, 12:23 AM

Thank you! Comments addressed (with a bit more comment than null)