[Kde-finance-apps] QObject copy constructor

Puneet Goyal puneetgoyal08 at gmail.com
Fri Aug 12 15:56:00 UTC 2011


Hello,
I was making a test class for Backend class and found this error
When i searched on the net about this , I found that the class is private
and the constructor cant be used as such
But i had used the QObject this way a lot of time.
Can you please tell me where's the error?

Here is m compile output

In file included from
/home/puneet/puneet/office/alkimia/payment/backend/backendtest.cpp:4:
/usr/include/qt4/QtCore/qobject.h: In copy constructor
‘Backend::Backend(const Backend&)’:
/usr/include/qt4/QtCore/qobject.h:309: error: ‘QObject::QObject(const
QObject&)’ is private
/home/puneet/puneet/office/alkimia/payment/backend/backend.h:49: error:
within this context
/home/puneet/puneet/office/alkimia/payment/backend/backendtest.cpp: In
member function ‘void BackendTest::test_initialization()’:
/home/puneet/puneet/office/alkimia/payment/backend/backendtest.cpp:25: note:
synthesized method ‘Backend::Backend(const Backend&)’ first required here

I have updated the code in the plaground/office/alkimia/payment/

Thank you

Regards,
Puneet
-- 
-----------------------------------------------------------------------
Puneet Goyal
Student of B. Tech. III Year (Software Engineering)
Delhi Technological University, Delhi
-----------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-finance-apps/attachments/20110812/c4f837a8/attachment.html>


More information about the Kde-finance-apps mailing list