Clean C++ SDK example "counter"

* Use <iostream> instead of <stdio.h>

Change-Id: I5cc70613c0b183c24bfa73b779dac3b382b31c93
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/123328
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
This commit is contained in:
Hossein
2021-10-09 22:29:58 +02:00
committed by Mike Kaganski
parent 52ad81c748
commit b56abc20eb

View File

@@ -40,7 +40,7 @@
* simple example component implementing a counter
*/
#include <stdio.h>
#include <iostream>
#include <rtl/ustring.hxx>
#include <uno/lbnames.h>
#include <cppuhelper/queryinterface.hxx>
@@ -77,9 +77,9 @@ class MyCounterImpl
public:
MyCounterImpl( const Reference< XMultiServiceFactory > & xServiceManager )
: m_xServiceManager( xServiceManager ), m_nRefCount( 0 )
{ printf( "< MyCounterImpl ctor called >\n" ); }
{ std::cout << "< MyCounterImpl ctor called >" << std::endl; }
~MyCounterImpl()
{ printf( "< MyCounterImpl dtor called >\n" ); }
{ std::cout << "< MyCounterImpl dtor called >" << std::endl; }
// XInterface implementation
virtual void SAL_CALL acquire() throw ()