/****************************************************************************
**
** DCOP Skeleton generated by dcopidl2cpp from protocolview.kidl
**
** WARNING! All changes made in this file will be lost!
**
*****************************************************************************/

#include "/tmp/buildd/tde-packaging/arch/tde-devel/tde-tdesdk/src/tdesdk-trinity-14.1.6/cervisia/protocolview.h"

#include <kdatastream.h>


static const char* const ProtocolView_ftable[3][3] = {
    { "void", "slotReceivedOutput(TQString)", "slotReceivedOutput(TQString buffer)" },
    { "void", "slotJobExited(bool,int)", "slotJobExited(bool normalExit,int exitStatus)" },
    { 0, 0, 0 }
};
static const int ProtocolView_ftable_hiddens[2] = {
    0,
    0,
};

bool ProtocolView::process(const TQCString &fun, const TQByteArray &data, TQCString& replyType, TQByteArray &replyData)
{
    if ( fun == ProtocolView_ftable[0][1] ) { // void slotReceivedOutput(TQString)
	TQString arg0;
	TQDataStream arg( data, IO_ReadOnly );
	if (arg.atEnd()) return false;
	arg >> arg0;
	replyType = ProtocolView_ftable[0][0]; 
	slotReceivedOutput(arg0 );
    } else if ( fun == ProtocolView_ftable[1][1] ) { // void slotJobExited(bool,int)
	bool arg0;
	int arg1;
	TQDataStream arg( data, IO_ReadOnly );
	if (arg.atEnd()) return false;
	arg >> arg0;
	if (arg.atEnd()) return false;
	arg >> arg1;
	replyType = ProtocolView_ftable[1][0]; 
	slotJobExited(arg0, arg1 );
    } else {
	return DCOPObject::process( fun, data, replyType, replyData );
    }
    return true;
}

QCStringList ProtocolView::interfaces()
{
    QCStringList ifaces = DCOPObject::interfaces();
    ifaces += "ProtocolView";
    return ifaces;
}

QCStringList ProtocolView::functions()
{
    QCStringList funcs = DCOPObject::functions();
    for ( int i = 0; ProtocolView_ftable[i][2]; i++ ) {
	if (ProtocolView_ftable_hiddens[i])
	    continue;
	TQCString func = ProtocolView_ftable[i][0];
	func += ' ';
	func += ProtocolView_ftable[i][2];
	funcs << func;
    }
    return funcs;
}


