Enhancement: KLineBufferedProcess

Rolf Eike Beer kde at opensource.sf-tec.de
Fri Mar 7 15:13:40 GMT 2008


Hi,

I'd like to introduce my example of KLineBufferedProcess, which should ease 
the handling of line oriented output of processes. Users would be for example 
KGpg where the interaction with gpg is line based. Also K3b could be a 
potential user as it parses the output of several different command line 
tools.

The idea behind this class is to receive the data from the process and buffer 
it. A signal is emitted only if a complete line of data is available. 
Everything else (program arguments, start, finished signal, writing data to 
the process' stdin) is unmodified from KProcess.

Please have a look at the code and give me feedback.

Greetings,

Eike

P.S.: please CC me on replies, I'm not on the list.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: klineprocess.cpp
Type: text/x-c++src
Size: 3260 bytes
Desc: not available
URL: <http://mail.kde.org/pipermail/kde-core-devel/attachments/20080307/aeaf74da/attachment.cpp>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: klineprocess.h
Type: text/x-c++hdr
Size: 4217 bytes
Desc: not available
URL: <http://mail.kde.org/pipermail/kde-core-devel/attachments/20080307/aeaf74da/attachment.h>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 194 bytes
Desc: This is a digitally signed message part.
URL: <http://mail.kde.org/pipermail/kde-core-devel/attachments/20080307/aeaf74da/attachment.sig>


More information about the kde-core-devel mailing list