• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

C++ LOG_1函数代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了C++中LOG_1函数的典型用法代码示例。如果您正苦于以下问题:C++ LOG_1函数的具体用法?C++ LOG_1怎么用?C++ LOG_1使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。



在下文中一共展示了LOG_1函数的17个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C++代码示例。

示例1: srcp

bool Path::copy( const QString & src, const QString & dest )
{
	Path srcp( src ), destp( dest );
	if( !srcp.fileExists() || !destp.dir().dirExists() )
		return false;
#ifdef Q_OS_WIN
	bool s_unc = false, d_unc = false;
	
	QString srcw( srcp.path() );
	srcw = srcw.replace( "/", "\\" );
	QString destw( destp.path() );
	destw = destw.replace( "/", "\\" );
	
	if( srcw[0] == '\\' && srcw[1] == '\\' ) s_unc = true;
	if( destw[0] == '\\' && destw[1] == '\\' ) d_unc = true;
	srcw.replace( "\\\\", "\\" );
	if( s_unc ) srcw = "\\" + srcw;
	destw.replace( "\\\\", "\\" );
	if( d_unc ) destw = "\\" + destw;
	
	bool ret = CopyFileA( srcw.toLatin1(), destw.toLatin1(), false ) != 0;
	if( !ret ) {
		DWORD err = GetLastError();
		LOG_1( "Copy failed with error: " + QString::number(err) );
		LOG_1( "Src: " + srcw +  "Dest: " + destw );
	}
	return ret;
#else
	system( QString( "cp " + srcp.path() + " " + destp.path() ).toLatin1() );
	return true;
#endif
}
开发者ID:EntityFXCode,项目名称:arsenalsuite,代码行数:32,代码来源:path.cpp


示例2: LOG_1

// ---------------------------------------------------------------------------
// CLingerConnection::StartLinger
// ---------------------------------------------------------------------------
//
TInt CLingerConnection::StartLinger()
    {
    LOG_1( _L("CLingerConnection::StartLinger") );
    
    if ( !iAttached )
        {    
        // Read settings    
        ReadSettings();
         
        if ( iLingerInterval != 0 )
            {
            TInt err = OpenAndAttach();

            if ( err != KErrNone )
                {
                // Write to log
                LOG_2( _L("OpenAndAttach: err: %d"), err );    
                return( err );
                }
        
            if ( iLingerInterval > 0 )
                {
                // Start timer
                StartTimer( KDataInactivityInterval );
            
                LOG_1( _L("Linger timer started OK") );    
                }
            
            }
        }
        
    return KErrNone;                  
    }
开发者ID:kuailexs,项目名称:symbiandump-mw1,代码行数:37,代码来源:linger.cpp


示例3: LOG_1

// ---------------------------------------------------------------------------
// CVpnSipObserver::RunL
// ---------------------------------------------------------------------------
//             
void CVpnSipObserver::RunL()
    {
    LOG_1( "CVpnSipObserver::RunL iStatus = %d", iStatus.Int());
    if ( iStatus == KErrNone ) 
        {
        TInt val = 0;
        // SIP Profile Server notified completion of SIP deregistration.
        TInt err = iSIPProperty.Get( KPSVpnSipUid, KVpnSipState, val );        
        if ( err == KErrNone && val == ESipDeregisterCompleted )
            {
            // If SIP is deregistered, let the VPN Connection Agent to 
            // proceed VPN session start.
            LOG_( "CVpnSipObserver::RunL SIP is deregistered. VPN Connection Agent continue with VPN start." );
            iAgent.ProceedServiceStart();            
            }
        else
            {
            // Keep monitoring.
            Subscribe();
            }
        }
    // Check if observer can be restarted.
    else if ( iStatus != KErrCancel 
           && iStatus != KErrServerTerminated
           && iStatus != KErrNotSupported )
        {
        // Keep monitoring.
        Subscribe();
        }
    else
        {
        // Error.
        LOG_1( "CVpnSipObserver::RunL Unknown error situation, iStatus = %d", iStatus.Int() );
        }
    }
开发者ID:cdaffara,项目名称:symbiandump-mw4,代码行数:39,代码来源:vpnsipobserver.cpp


示例4: LOG_1

// -----------------------------------------------------------------------------
// CSilenceAction::ConstructL
// Symbian 2nd phase constructor can leave.
// -----------------------------------------------------------------------------
//
void CSilenceAction::ConstructL( )
    {
    LOG_1( _L("->CSilenceAction::ConstructL: START") );     

    iPhoneClient = CPhCltCommandHandler::NewL();

    LOG_1( _L("<-CSilenceAction::ConstructL: END") );
    }
开发者ID:cdaffara,项目名称:symbiandump-ossapps,代码行数:13,代码来源:silenceaction.cpp


示例5: QObject

JobBurner::JobBurner( const JobAssignment & jobAssignment, Slave * slave, int options )
: QObject( slave )
, mSlave( slave )
, mCmd( 0 )
, mJobAssignment( jobAssignment )
, mJob( jobAssignment.job() )
, mLoaded( false )
, mOutputTimer( 0 )
, mMemTimer( 0 )
, mLogFlushTimer( 0 )
, mCheckupTimer( 0 )
, mState( StateNew )
, mOptions( Options(options) )
, mCurrentCopy( 0 )
, mLogFilesReady( false )
, mLogFile( 0 )
, mLogStream( 0 )
, mCmdPid( 0 )
{
	mOutputTimer = new QTimer( this );
	connect( mOutputTimer, SIGNAL( timeout() ), SLOT( updateOutput() ) );

	mMemTimer = new QTimer( this );
	connect( mMemTimer, SIGNAL( timeout() ), SLOT( checkMemory() ) );

	mCheckupTimer = new QTimer( this );
	connect( mCheckupTimer, SIGNAL( timeout() ), SLOT( checkup() ) );
    mCheckupTimer->start(30000);
	
	/* Ensure we are actually assigned some tasks to work on */
	mTaskAssignments = mJobAssignment.jobTaskAssignments();
	if( mTaskAssignments.isEmpty() ) {
		jobErrored( QString("JobAssignment has no assigned tasks, Job Assignment key: %1").arg(mJobAssignment.key()) );
		return;
	}

	// Double check that we are still assigned
	mJobAssignment.reload();
	if( mJobAssignment.jobAssignmentStatus().status() != "ready" ) {
		LOG_1( "JobAssignment no longer ready, cancelling the burn" );
		cancel();
		return;
	}

	/* Make sure each of the tasks are still valid, some could have already been unassigned or cancelled */
	/* Also verify that the jobtask record matches the assignment */
	mTasks = JobTask::table()->records( mTaskAssignments.keys( JobTaskAssignment::schema()->field("fkeyjobtask")->pos() ), /*select=*/true, /*useCache=*/false );
	foreach( JobTaskAssignment jta, mTaskAssignments ) {
		JobTask task = jta.jobTask();
		if( jta.jobAssignmentStatus().status() != "ready" || task.status() != "assigned" || task.host() != Host::currentHost() ) {
			LOG_1( QString("JobTask no longer assigned, discarding. keyJobTask: %1  keyJobTaskAssignment: %2  jobtask status: %3 jobtaskassignment status: %4")
				.arg(task.key()).arg(jta.key()).arg(task.status()).arg(jta.jobAssignmentStatus().status()) );
			mTaskAssignments -= jta;
			mTasks -= task;
		}
	}
开发者ID:kurikaesu,项目名称:arsenalsuite,代码行数:56,代码来源:jobburner.cpp


示例6: LOG_

void CPKCS12Handler::SaveCertificatesToDiskL() 
    {
    LOG_("-> CPKCS12Handler::SaveCertificatesToDiskL()");

    TInt certCount(0);

    // first the CAs (if any; not required necessarily)
    if (iCACerts) 
        {
        certCount = iCACerts->Count();
        LOG_1(" Saving %d CA Certificates", certCount);

        for (TInt i = 0; i < certCount; i++)
            {
            CX509Certificate* cert = iCACerts->At(i);

            // Generate filename with running identifier
            // Use TFileName, because the function isn't stack
            // critical
            TFileName fn;
            fn.Format(KCAFileNameStem(), i+1);

            WriteToFileL(cert->Encoding(), fn);
            }
        }
    LOG(else LOG_(" No CA Certs found!"));

    // Then the user certs
    if (iUserCerts)
        {
        certCount = iUserCerts->Count();
        LOG_1(" Saving %d User Certificates", certCount);

        for (TInt i = 0; i < certCount; i++) 
            {
            CX509Certificate* cert = iUserCerts->At(i);

            TFileName fn;
            fn.Format(KUserCertFileNameStem(), i+1);

            WriteToFileL(cert->Encoding(), fn);
            }
        }

    LOG(else LOG_(" No User Certs found!"));

    LOG_("<- CPKCS12Handler::SaveCertificatesToDiskL()");
    }
开发者ID:cdaffara,项目名称:symbiandump-mw4,代码行数:48,代码来源:pkcs12vpn.cpp


示例7: LOG_1

// ---------------------------------------------------------------------------
// CAORAUManagerImpl::RAUEventSubscribeIssueRequest
// ---------------------------------------------------------------------------
//
void CAORAUManagerImpl::RAUEventSubscribeIssueRequest(
    TRequestStatus& aStatus )
    {
    LOG_1( _L("CAORAUManagerImpl::RAUEventSubscribeIssueRequest") );
    
    iRAUEventProperty.Subscribe( aStatus );
    }
开发者ID:kuailexs,项目名称:symbiandump-mw1,代码行数:11,代码来源:caoraumanagerimplstub.cpp


示例8: LOG_1

// ---------------------------------------------------------------------------
// CAOTimer::StartRetryTimer
// ---------------------------------------------------------------------------
//
void CAOTimer::StartRetryTimer()
    {
    LOG_1( _L("CAOTimer::StartRetryTimer") );
    
    __ASSERT_DEBUG( !iRetryTimer->IsActive(),
        Panic( ERetryTimerAlreadyActive ) );
        
    iRetryTimerCount = 0;
    
    // First check if the current retry timer value is more than 30 minutes
    iCurrentRetryTimerInterval = 0;
    if( iSettings.RetryTimerValue() > KMaxTimerInSeconds )
        {
        // First interval is 30 minutes
        iCurrentRetryTimerInterval = KMaxTimerInSeconds * KSecondsToMicro;
        }
    else
        {
        // use current value
        iCurrentRetryTimerInterval =
            iSettings.RetryTimerValue() * KSecondsToMicro;
        }
    
    TCallBack cb( RetryTimerCallBack, this );
    iRetryTimer->Start(
        iCurrentRetryTimerInterval, iCurrentRetryTimerInterval, cb );
    }
开发者ID:kuailexs,项目名称:symbiandump-mw1,代码行数:31,代码来源:caotimer.cpp


示例9: LOG_1

// --------------------------------------------------------------------------
// TAOState::HandleResetFactorySettingsL
// --------------------------------------------------------------------------
//
TAOState* TAOState::HandleResetFactorySettingsL( TBool aReset )
{
    LOG_1( _L("TAOState::HandleResetFactorySettingsL") );

    TAOState* newState = NULL;
    if ( aReset )
    {
        // Close connection
        CancelAll();

        // Respond to Rfs that connection has been torn down and rfs sequence
        // can continue
        RProperty::Set(
            KPDPContextManager2,
            KPDPContextManagerFactorySettingsReset,
            EPDPContextManagerFactorySettingsResetStartReply );

        newState = iStatePool.ChangeState( EStateResetFactorySettings );
    }
    else
    {
        newState = DoActivatePDPContextL();
    }
    return newState;
}
开发者ID:kuailexs,项目名称:symbiandump-mw1,代码行数:29,代码来源:taostate.cpp


示例10: LOG_1

// ---------------------------------------------------------------------------
// CAOGpds::ConstructL
// ---------------------------------------------------------------------------
//
void CAOGpds::ConstructL()
    {
    LOG_1( _L("CAOGpds::ConstructL") );
    
    // Create active schduler wiat for synchronizing async operations    
    iWait = new( ELeave ) CActiveSchedulerWait;
    }
开发者ID:kuailexs,项目名称:symbiandump-mw1,代码行数:11,代码来源:caogpds.cpp


示例11: exploreFile

void exploreFile( QString path )
{
	QFileInfo fi(path);
	QStringList args;
	QString dirPath = QFileInfo( path ).path();

	QString cmd;
	#ifdef Q_OS_WIN
	cmd = "explorer.exe";
	if( fi.isFile() && fi.exists() ) {
		args << "/select,";
		args << path.replace("/","\\");
	} else
		args << dirPath.replace("/", "\\");
	#endif
	#ifdef Q_OS_LINUX
	args << dirPath.replace('\\', '/');
	cmd = "thunar";
	#endif
	#ifdef Q_OS_MAC
	args << dirPath.replace('\\', '/');
	cmd = "open";
	#endif
	if( !QProcess::startDetached( cmd, args ) ) {
		LOG_1( "Unable to start " + cmd );
	}
}
开发者ID:EntityFXCode,项目名称:arsenalsuite,代码行数:27,代码来源:afcommon.cpp


示例12: LOG_1

// ---------------------------------------------------------------------------
// CAOSettings::LingerTimerValue
// ---------------------------------------------------------------------------
//
TInt CAOSettings::LingerTimerValue( const TUint aIapId ) const
{
    LOG_1( _L("CAOSettings::LingerTimerValue") );

    for ( TInt j=0; j < iLingerSettings.Count(); j++ )
    {
        if ( iLingerSettings[ j ].iIap == aIapId )
        {
            LOG_3( _L("Linger setting found >> iap: %d, interval: %d"),
                   aIapId,
                   iLingerSettings[ j ].iInterval);

            if ( iLingerSettings[ j ].iInterval == 0 )
            {
                return KLingerForEver;
            }
            else
            {
                return ( iLingerSettings[ j ].iInterval );
            }
        }
    }

    LOG_2( _L("LingerTimerValue() not found >> iap: %d"),
           aIapId );

    return KLingerOff; // Linger is off
}
开发者ID:kuailexs,项目名称:symbiandump-mw1,代码行数:32,代码来源:caosettings.cpp


示例13: file

bool IniConfig::writeToFile( const QString & fileName )
{
	QString filePath = fileName;
	if( filePath.isEmpty() )
		filePath = mFile;

	QFile file(filePath);
	if( !file.open(QIODevice::WriteOnly) ) {
		LOG_1( "Unable to open config file for writing at: " + filePath );
		return false;
	}
	QTextStream out(&file);
	QMap<QString, QMap<QString,QString> >::Iterator it;
	for(it = mValMap.begin(); it != mValMap.end(); ++it)
	{
		if( !it.value().isEmpty() ){
			out << '[' << (it.key().isEmpty() ? QString("NO_SECTION") : it.key()) << ']' << '\n';
			for( QMap<QString,QString>::Iterator valit = it.value().begin(); valit!=it.value().end(); ++valit )
				out << valit.key() << '=' << valit.value() << '\n';
			out << "\n";
		}
	}
	LOG_3( "Wrote config file to: " + filePath );
	return true;
}
开发者ID:EntityFXCode,项目名称:arsenalsuite,代码行数:25,代码来源:iniconfig.cpp


示例14: write

void write( QString & input,  QString output )
{
	if( readFile( output ) != input ) {
		if( !writeFullFile( output, input ) )
			LOG_1( "Couldn't open " + output + " for writing" );
	}
}
开发者ID:carriercomm,项目名称:arsenalsuite,代码行数:7,代码来源:sourcegen.cpp


示例15: LOG_1

// ---------------------------------------------------------------------------
// CAOConnectionImpl::DoCancel
// ---------------------------------------------------------------------------
//
void CAOConnectionImpl::DoCancel()
    {
    LOG_1( _L("CAOConnectionImpl::DoCancel") );
    
    ChangeState( EDisconnected );
    CompleteSelf( iStatus, KErrCancel );
    }
开发者ID:kuailexs,项目名称:symbiandump-mw1,代码行数:11,代码来源:caoconnectionimplstub.cpp


示例16: iStateContext

// --------------------------------------------------------------------------
// Constructor
// --------------------------------------------------------------------------
//
TAOState::TAOState( MAOStateContext& aStateContext,
                    MAOStatePool& aStatePool ):
    iStateContext( aStateContext ),
    iStatePool( aStatePool ),
    iFlags( 0 )
{
    LOG_1( _L("TAOState::TAOState") );
}
开发者ID:kuailexs,项目名称:symbiandump-mw1,代码行数:12,代码来源:taostate.cpp


示例17: CActive

// ---------------------------------------------------------------------------
// CAOGpds::CAOGpds
// ---------------------------------------------------------------------------
//
CAOGpds::CAOGpds( RMmCustomAPI& aCustomAPI ):
    CActive( EPriorityStandard ),
    iCustomAPI( aCustomAPI )
    {
    LOG_1( _L("CAOGpds::CAOGpds") );
    
    CActiveScheduler::Add( this );
    }
开发者ID:kuailexs,项目名称:symbiandump-mw1,代码行数:12,代码来源:caogpds.cpp



注:本文中的LOG_1函数示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
C++ LOG_ALL函数代码示例发布时间:2022-05-30
下一篇:
C++ LOGW函数代码示例发布时间:2022-05-30
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap