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

C++ TName类代码示例

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

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



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

示例1: DoConnect

TInt RConsoleProxy::DoConnect(TServerParams* aParams, const TDesC& aThreadNameBase, TInt aStackSize, TInt aHeapMinSize, TInt aHeapMaxSize, RServer2& aServer, RThread& aServerThread)
	{
	TName threadName;
	RThread server;
	TInt threadId = 0;
	_LIT(KThreadIdFmt, "%08x");
	TInt err;
	do
		{
		threadName = aThreadNameBase.Left(threadName.MaxLength()-8);
		threadName.AppendFormat(KThreadIdFmt, threadId);
		err = server.Create(threadName, &ServerThreadFunction, aStackSize, aHeapMinSize, aHeapMaxSize, aParams);
		++threadId;
		} while (err==KErrAlreadyExists);
	if (err!=KErrNone) return err;
	
	TRequestStatus rendezvous;
	server.Rendezvous(rendezvous);
	if (rendezvous == KRequestPending)
		{
		server.Resume();
		}
	User::WaitForRequest(rendezvous);
	err = rendezvous.Int();
	if (server.ExitType() != EExitPending && err >= 0) err = KErrDied;
	if (err==KErrNone)
		{
		err = Connect(aParams->iServer);
		}
	aServer = aParams->iServer;
	aServerThread = server;
	return err;
	}
开发者ID:cdaffara,项目名称:symbiandump-os1,代码行数:33,代码来源:client.cpp


示例2: RemoveLine

// ---------------------------------------------------------------------------
// CMmLineList::RemoveObject
// Marks a line object in array as not used
// ---------------------------------------------------------------------------
//
TInt CMmLineList::RemoveLine ( 
    const TName& aLineName )
    {
    TInt ret ( KErrGeneral );

    if ( iObjectContainer )
        {
        ret = KErrNone;
        if ( 0 == aLineName.CompareF( KMmTsyVoice1LineName ) )
            {
            iIsLineInUse[ ELine0Voice1 ] = EFalse;
            }
        else if ( 0 == aLineName.CompareF( KMmTsyVoice2LineName ) )
            {
            iIsLineInUse[ ELine1Voice2 ] = EFalse;
            }
        else if ( 0 == aLineName.CompareF( KMmTsyDataLineName ) )
            {
            iIsLineInUse[ ELine2Data ] = EFalse;
            }
        else if ( 0 == aLineName.CompareF( KMmTsyFaxLineName ) )
            {
            iIsLineInUse[ ELine3Fax ] = EFalse;
            }
        else
            {
            ret = KErrNotFound;
            }
        }
    return ret;
    }
开发者ID:cdaffara,项目名称:symbiandump-os1,代码行数:36,代码来源:cmmlinelist.cpp


示例3: GetResolverConfig

TInt CTS_MultiHomingStep::GetResolverConfig(const TInt aIndex, TName &aHostName, TInt& aProtocol,																				 
										TBool& aExpectSuccess, TBool& aExpectTimeout, TBool& aExpectNotReady, 
										TBool& aExplicitResolve, TConnDetails **aConnDetails)
/**
 * Gets resolver configuration from file, using defaults if necessary
 * @param aIndex The index for the socket configkey
 * @param aHostName The host to be resolved
 * @param aProtocol The protocol to be used
 * @param aExpectSuccess Flag indicating if name should be resolved ok
 * @param aExpectTimeout Flag indicating if name resolution should timeout
 * @param aConnDetails The connection for an explicit resolver
 * @return System wide error code
 */
	{
	TInt err=KErrNone;	
	TName resolverName;		// Create the Key for the config lookup
	resolverName = KResolver;
	resolverName.AppendNum(aIndex);
	
	TPtrC ptrBuf;
	err = GetStringFromConfig(resolverName, KDestName, ptrBuf);
	if (!err)
		{
		LogExtra((TText8*)__FILE__, __LINE__, ESevrWarn, KEConfigFile);
		iTestStepResult= EInconclusive;
		return KErrNotFound;
		}
	aHostName.Copy(ptrBuf.Ptr(), ptrBuf.Length());
		
	
	aExpectSuccess = ETrue;
	GetBoolFromConfig(resolverName, KExpectSuccess, aExpectSuccess);
	
	aExpectTimeout = EFalse;
	GetBoolFromConfig(resolverName, KExpectTimeout, aExpectTimeout);

	aExpectNotReady = EFalse;
    GetBoolFromConfig(resolverName, KExpectNoDnsServer, aExpectNotReady);

	aExplicitResolve = EFalse;
	GetBoolFromConfig(resolverName, KExplicitResolve, aExplicitResolve);
		

	err = GetStringFromConfig(resolverName, KProtocol, ptrBuf);
	if (err && (ptrBuf.Compare(KTcp)==0))
		aProtocol = KProtocolInetTcp;
	else
		aProtocol = KProtocolInetUdp;	
		
	
	err = GetStringFromConfig(resolverName, KConnName, ptrBuf);
	if (!err)
		{
		return KErrNotFound;
		}		

	*aConnDetails = iOwnerSuite->GetTConnection(ptrBuf);								

	return KErrNone;
	}
开发者ID:cdaffara,项目名称:symbiandump-os1,代码行数:60,代码来源:TS_MultiHomingStep.cpp


示例4: AddLineObject

// ---------------------------------------------------------------------------
// CMmLineList::AddLineObject
// Adds a TSY to the Line list
// ---------------------------------------------------------------------------
//
TInt CMmLineList::AddLineObject ( 
    CTelObject* aTsyObject, const TName& aLineName )
    {
    TInt ret ( KErrGeneral );
    
OstTraceDef0(OST_TRACE_CATEGORY_DEBUG, TRACE_INTERNALS, CMMLINELIST_ADDLINEOBJECT_1, "TSY: CMmLineList::AddLineObject");
    if ( iObjectContainer )
        {
OstTraceDef1(OST_TRACE_CATEGORY_DEBUG, TRACE_INTERNALS, CMMLINELIST_ADDLINEOBJECT_2, "TSY: CMmLineList::AddLineObject:iObjectContainer->Count()=%d", iObjectContainer->Count());

        
        TInt trapError( KErrNone );    

        if ( 0 == aLineName.CompareF( KMmTsyVoice1LineName ) )
            {
            iIsLineInUse[ ELine0Voice1 ] = ETrue;
            iObjectContainer->Delete( ELine0Voice1 );
            iObjectContainer->Compress();
            TRAP( trapError, iObjectContainer->InsertL( ELine0Voice1, 
                                                        aTsyObject ) );
            }
        else if ( 0 == aLineName.CompareF( KMmTsyVoice2LineName ) )
            {
            iIsLineInUse[ ELine1Voice2 ] = ETrue;
            iObjectContainer->Delete( ELine1Voice2 );
            iObjectContainer->Compress();
            TRAP( trapError, iObjectContainer->InsertL( ELine1Voice2, 
                                                        aTsyObject ) );
            }
        else if ( 0 == aLineName.CompareF( KMmTsyDataLineName ) )
            {
            iIsLineInUse[ ELine2Data ] = ETrue;
            iObjectContainer->Delete( ELine2Data );
            iObjectContainer->Compress();
            TRAP( trapError, iObjectContainer->InsertL( ELine2Data,
                                                        aTsyObject ) );
            }
        else if ( 0 == aLineName.CompareF( KMmTsyFaxLineName ) )
            {
            iIsLineInUse[ ELine3Fax ] = ETrue;
            iObjectContainer->Delete( ELine3Fax );
            iObjectContainer->Compress();
            TRAP( trapError, iObjectContainer->InsertL( ELine3Fax,
                                                        aTsyObject ) );
            }
        //Check the trap error
        if ( KErrNone != trapError )
            {
            //change return value to indicate out of memory error
            ret = KErrNoMemory;
            }
        else
            {
            //success return value
            ret = KErrNone;
            iInitialised = ETrue;
            }
        }
    return ret;
    }
开发者ID:cdaffara,项目名称:symbiandump-os1,代码行数:65,代码来源:cmmlinelist.cpp


示例5: index

// ---------------------------------------------------------------------------
// CMmCallList::RemoveCallsByLine
// Removes Call objects from Call list that has been opened 
// from the Line (which name is given as a input parameter).
// ---------------------------------------------------------------------------
//
void CMmCallList::RemoveCallsByLine(
    const TName* aLineName )
    {
    //if call list exists
    if ( iObjectContainer )
        {
        TInt callCount = iObjectContainer->Count();
        TInt index( 0 );
        //search through call list
        for ( TInt i = 0; i < callCount; i++ )
            {
            //get current call
            CMmCallTsy* mmCall = 
              reinterpret_cast<CMmCallTsy*>( iObjectContainer->At( index ) );

            //get the name of the line from which this call has been opened.
            //see class CMmLineTsy to see how the call object naming works.
            TName curLineName = mmCall->
                                    CallName().Left( aLineName->Length() );

            //if the name is the same as the line name given as input param.
            if ( curLineName.Compare( *aLineName ) == 0 )
                {
                //close this call
                mmCall->Close();
                index--;
                }
            index++;
            }
        }
    }
开发者ID:cdaffara,项目名称:symbiandump-os1,代码行数:37,代码来源:cmmcalllist.cpp


示例6: new

// -----------------------------------------------------------------------------
// TMSCallServer::StartThreadL
//
// -----------------------------------------------------------------------------
//
void TMSCallServer::StartThreadL(TMSCallServerStartParam& aStart)
    {
    TRACE_PRN_FN_ENT;

    CActiveScheduler* sched = new (ELeave) CActiveScheduler;
    CleanupStack::PushL(sched);

    CActiveScheduler::Install(sched);
    TMSCallServer* server = TMSCallServer::NewL(aStart.iTMSServer);
    CleanupStack::PushL(server);

    //Rename tmscall server name
    RThread tmscallServerThread;
    TThreadId threadId;
    TName name;
    name.Append(KTMSCallServerName);
    threadId = tmscallServerThread.Id();
    name.AppendNum(threadId.Id(), EHex);
    //We are ignoring the error code returned from User::RenameThread
    //as it is not important here, may be for profiling
    User::RenameThread(name);

    aStart.iTMSCallServerHandle = server->Server();
    // Sync with the client and enter the active scheduler
    RThread::Rendezvous(KErrNone);
    sched->Start();

    CleanupStack::PopAndDestroy(server); // server
    CleanupStack::PopAndDestroy(sched); // sched

    TRACE_PRN_FN_EXT;
    }
开发者ID:kuailexs,项目名称:symbiandump-mw2,代码行数:37,代码来源:tmscallsrvrstart.cpp


示例7: INFO_PRINTF1

enum TVerdict CTestIdna07::doTestStepL()
	{

	INFO_PRINTF1(_L(" Testing Punycode to IDN Conversion functionality   "));
	INFO_PRINTF1(_L("****************************************************"));
	
	SetTestStepResult(EFail); // By default start the test case with failure.	
	
	_LIT8(KPunyCodeName,"xn--rksmrgs-5wao1o.josefsson.org");
	TPunyCodeDndName punyCodeName;
	punyCodeName.Copy(KPunyCodeName());
	
	_LIT(KIDNName1,"räksmörgås.josefsson.org");
	
	TName myHostName ;
	TInt start =0;
	
	TInt err=punyCodeName.PunycodeToIdn(myHostName,start);
	if(err != KErrNone)
		{
		User::LeaveIfError(KErrNone); // just to suppress the LeaveScan warning
		INFO_PRINTF1(_L("Conversion of Punycode to IDN is NOT successful "));
		SetTestStepResult(EFail);
		return TestStepResult();
		}
	
	if( myHostName.Compare(KIDNName1()) == 0)
		{
		INFO_PRINTF1(_L(" Conversion of Punycode to IDN is successful"));
		SetTestStepResult(EPass);
		}
	
	return TestStepResult();
	}
开发者ID:cdaffara,项目名称:symbiandump-os2,代码行数:34,代码来源:te_unittestidna.cpp


示例8: TESTL

/**
*   Load network iformation (hosts names) from ini file.
*
*   @param aNetworkInfo ref. to the TNetworkInfo structure, which will be populated
*/
void   CTestStepLLMNR_Init::LoadNetworkConfigFromIniL(TNetworkInfo&  aNetworkInfo)
    {
    TName   tmpBuf;
    TInt    nRes;
    
    //-- get number of hosts which are supposed to be running
    //-- there should be at last 2 host names in the list
    TESTL(GetIntFromConfig(KNodesSection, _L("NumNodes"), nRes) && nRes >= KMinNodes);
    const TInt numNodes = nRes;  
    
    //-- get maximal number of trials of host hame resolution
    TESTL(GetIntFromConfig(KNodesSection, _L("ConnectTrials"), nRes) && nRes >= 1);
    const TInt maxTrials = nRes;  
    
    //-- populate NetworkInfo array with information from ini file.
    TNodeInfo nodeInfo;
    
    for(TInt i=0; i<numNodes; ++i)
        {
        //-- get host name from ini file
        tmpBuf.Format(_L("HostName%d"),i+1);
        if(!GetIniFileString(KNodesSection, tmpBuf, nodeInfo.iHostName))  
            continue;
        
        //-- put host info to the array
        nodeInfo.iCntTrials = maxTrials;
        aNetworkInfo.AppendNode(nodeInfo);
        }
    
    //-- check number of hosts to communicate with.
    TESTL(aNetworkInfo.NodesCount() >= KMinNodes);
    }
开发者ID:cdaffara,项目名称:symbiandump-os2,代码行数:37,代码来源:LlmnrInit.cpp


示例9: globalSettingsRecord

/**
Function to initialize the phone settings
@return TBool
*/
TBool CMBMSEngine::InitialisePhoneL()
	{
#ifdef SYMBIAN_NON_SEAMLESS_NETWORK_BEARER_MOBILITY
	CMDBSession* dbSession = CMDBSession::NewL(KCDVersion1_2);
#else
	CMDBSession* dbSession = CMDBSession::NewL(KCDVersion1_1);
#endif
    CleanupStack::PushL(dbSession);

	CMDBRecordSet<CCDGlobalSettingsRecord> globalSettingsRecord(KCDTIdGlobalSettingsRecord);
    TRAPD(err, globalSettingsRecord.LoadL(*dbSession));
    if(err != KErrNone)
      {
      User::Leave(KErrNotFound);
      }

    CCDModemBearerRecord *modemBearerRecord = static_cast<CCDModemBearerRecord*>(CCDRecordBase::RecordFactoryL(KCDTIdModemBearerRecord));
    CleanupStack::PushL(modemBearerRecord);

    modemBearerRecord->SetRecordId(((CCDGlobalSettingsRecord*)globalSettingsRecord.iRecords[0])->iModemForPhoneServicesAndSMS);
    TRAPD(err1,modemBearerRecord->LoadL(*dbSession));

    if(err1 != KErrNone)
      {
      User::Leave(KErrNotFound);
      }

    TName tsyName;
    tsyName = modemBearerRecord->iTsyName;
    //leave if not able to read Tsy name.
    if(tsyName.Length() == 0)
	  {
      User::Leave(KErrNotFound);
	  }

    CleanupStack::PopAndDestroy(modemBearerRecord);
    CleanupStack::PopAndDestroy(dbSession);

    User::LeaveIfError(iTelServer.Connect());
	User::LeaveIfError(iTelServer.LoadPhoneModule(tsyName));
	User::LeaveIfError(iTelServer.SetExtendedErrorGranularity(RTelServer::EErrorExtended));

	//Open telephony server
	GetPhoneInfoL(iTelServer,tsyName,iPhoneInfo);

	//Open phone
	User::LeaveIfError(iPhone.Open(iTelServer,iPhoneInfo.iName));
	//Get phone status
	User::LeaveIfError(iPhone.GetStatus(iPhoneStatus));

	SetActive();
	iPhoneState = EInitialising;

	TRequestStatus* status = &iStatus;
	User::RequestComplete(status, KErrNone);

	return ETrue;
	}
开发者ID:cdaffara,项目名称:symbiandump-os1,代码行数:62,代码来源:mbmsengine.cpp


示例10: SelectedL

void CTestList::SelectedL(TInt aIndex)
{
#if USE_PROCESS
    TThreadParams params;
    params.iIndex=aIndex;
    TName name;
    name.Format(_L("TimeTest-%x"),iCount++);
    params.iGroupId=Client()->iGroup->GroupWin()->Identifier();
    User::LeaveIfError(iTimeTest.Create(name,TimeThread,KDefaultStackSize*2,KHeapSize,KHeapSize,&params,EOwnerThread));
    TRequestStatus status;
    iTimeTest.Logon(status);
    __PROFILE_RESET(8);
    iTimeTest.Resume();
    User::WaitForRequest(status);
#else
    TThreadParams params;
    params.iIndex=aIndex;
    TimeThread(&params);
#endif
    TBuf<64> buf;
    TBuf<64> buf2;
    TBuf<64> buf3;
    CResultDialog *dialog=new(ELeave) CResultDialog(Client()->iGroup, iGc);
    dialog->ConstructLD();
#if USE_PROCESS
    if (status.Int()==KErrNone)
    {
#endif
#if !defined(__PROFILING__)
        buf=_L("Profiling information not available");
#else
        TProfile profile[6];
        __PROFILE_DISPLAY(6);
        for (TInt index=1; index<6; index++)
            AppendProfileNum(buf2,profile[index].iTime);
        for (TInt index2=1; index2<6; index2++)
            AppendProfileCount(buf3,profile[index2].iCount);
        buf.Format(_L("Time=%d.%2d"),profile[0].iTime/1000000,(profile[0].iTime%1000000)/10000);
#endif
        dialog->SetTitle(buf);
#if USE_PROCESS
    }
    else
    {
        dialog->SetTitle(_L("Error in test"));
        buf.Format(_L("Error=%d"),status.Int());
        buf2=iTimeTest.ExitCategory();
    }
#endif
    dialog->SetLine1(buf2);
    dialog->SetLine2(buf3);
    dialog->SetNumButtons(1);
    dialog->SetButtonText(0,_L("Okay"));
    if (dialog->Display()!=0)
        Panic(0);
}
开发者ID:kuailexs,项目名称:symbiandump-os1,代码行数:56,代码来源:TTIME.CPP


示例11: hashFunctionNameIfNeeded

TString TOutputGLSLBase::hashFunctionNameIfNeeded(const TName &mangledName)
{
    TString mangledStr = mangledName.getString();
    TString name = TFunction::unmangleName(mangledStr);
    if (mSymbolTable.findBuiltIn(mangledStr, mShaderVersion) != nullptr || name == "main")
        return translateTextureFunction(name);
    if (mangledName.isInternal())
        return name;
    else
        return hashName(name);
}
开发者ID:JasonJinCn,项目名称:gecko-dev,代码行数:11,代码来源:OutputGLSLBase.cpp


示例12: DecorateIfNeeded

TString DecorateIfNeeded(const TName &name)
{
    if (name.isInternal())
    {
        return name.getString();
    }
    else
    {
        return Decorate(name.getString());
    }
}
开发者ID:FahimArnob,项目名称:angle,代码行数:11,代码来源:UtilsHLSL.cpp


示例13: DecorateFunctionIfNeeded

TString DecorateFunctionIfNeeded(const TName &name)
{
    if (name.isInternal())
    {
        return TFunction::unmangleName(name.getString());
    }
    else
    {
        return Decorate(TFunction::unmangleName(name.getString()));
    }
}
开发者ID:FahimArnob,项目名称:angle,代码行数:11,代码来源:UtilsHLSL.cpp


示例14: serverUid

// -----------------------------------------------------------------------------
// MceServerStarter::CreateServerProcess
// -----------------------------------------------------------------------------
//
TInt MceServerStarter::CreateServerProcess (RSemaphore& aSemaphore)
	{
	const TUidType serverUid (KNullUid, KNullUid, KServerUid3);


#if ((defined (__WINS__) || defined(__WINSCW__)) && !defined (EKA2))

	RLibrary lib;
    RETURN_IF_ERROR (lib.Load(KMceServerFilename,serverUid))

    //  Get the WinsMain function
	TLibraryFunction functionWinsMain = lib.Lookup (1);

    //  Call it and cast the result to a thread function
	TThreadFunction serverThreadFunction = 
        reinterpret_cast<TThreadFunction> (functionWinsMain());

	TName threadName (KSipServerName);

	// Append a random number to make it unique
	threadName.AppendNum (Math::Random(), EHex);

	RThread server;
    TInt err = server.Create (threadName,
                              serverThreadFunction, // thread's main function
                              KDefaultStackSize,
                              NULL,
                              &lib,
                              NULL,
                              KServerMinHeapSize,
                              KServerMaxHeapSize,
                              EOwnerProcess );

	lib.Close ();	// if successful, server thread has handle to library now
    RETURN_IF_ERROR (err)

	server.SetPriority (EPriorityMore);

#else // HW build

	RProcess server;
	RETURN_IF_ERROR (server.Create( KMceServerName, KNullDesC, serverUid ) )

#endif


	server.Resume ();
	aSemaphore.Wait();
	TInt exitReason = server.ExitReason();
	server.Close ();

    return exitReason;
	}
开发者ID:kuailexs,项目名称:symbiandump-mw1,代码行数:57,代码来源:mceserverstarter.cpp


示例15: ContentionTestL

/**
@SYMTestCaseID          SYSLIB-STORE-CT-1191
@SYMTestCaseDesc	    Lock out of dictionary files test
@SYMTestPriority 	    High
@SYMTestActions  	    Attempt for opening of same dictionary file.Tests for file in use error
@SYMTestExpectedResults Test must not fail
@SYMREQ                 REQ0000
*/
void ContentionTestL()
	{
	test.Start(_L(" @SYMTestCaseID:SYSLIB-STORE-CT-1191 Contention tests "));
	
	TDriveUnit drive(static_cast<TUint>(RFs::GetSystemDrive()));	
	TParse testIniFile;
	testIniFile.Set(drive.Name(), &KTestIniFile, NULL);
	
	CDictionaryStore* dict=CDictionaryFileStore::OpenLC(TheFs,testIniFile.FullName(),KTestUid);
	TIniData data;
	data.SaveL(*dict);
	CleanupStack::PopAndDestroy(); // dict

	test.Next(_L("Lock-out test"));
	CDictionaryFileStore::OpenLC(TheFs,testIniFile.FullName(),KTestUid);
	TUint tick=User::TickCount();
	TRAPD(r,CDictionaryFileStore::OpenL(TheFs,testIniFile.FullName(),KTestUid));
	tick=User::TickCount()-tick;
	test (r==KErrInUse);
	test.Printf(_L("Lock-out discovered: %d ticks\r\n"),tick);
	CleanupStack::PopAndDestroy();

	test.Next(_L("Creating threads"));
	RThread threads[KNumThreads];
	TRequestStatus status[KNumThreads];
	TInt ii;
	for (ii=0;ii<KNumThreads;++ii)
		{
		TName name;
		name.Format(_L("Test_%d"),ii);
		test (threads[ii].Create(name,ThreadTest,KThreadStack,KThreadHeap,KThreadHeapMax,(TAny*)ii,EOwnerThread)==KErrNone);
		threads[ii].SetPriority(EPriorityLess);
		threads[ii].Logon(status[ii]);
		test (status[ii]==KRequestPending);
		}

	for (ii=0;ii<KNumThreads;++ii)
		threads[ii].Resume();

	test.Next(_L("Waiting for completion"));
	for (ii=0;ii<KNumThreads;++ii)
		User::WaitForAnyRequest();
	TInt success=0;
	for (ii=0;ii<KNumThreads;++ii)
		{
		test (status[ii]!=KRequestPending);
		if (status[ii].Int()==KErrNone)
			++success;
		}
	test.Printf(_L("Thread success: %d of %d\r\n"),success,KNumThreads);
	test.End();
	}
开发者ID:cdaffara,项目名称:symbiandump-os2,代码行数:60,代码来源:t_stordictfs.cpp


示例16: DecorateVariableIfNeeded

TString DecorateVariableIfNeeded(const TName &name)
{
    if (name.isInternal())
    {
        // The name should not have a prefix reserved for user-defined variables or functions.
        ASSERT(name.getString().compare(0, 2, "f_") != 0);
        ASSERT(name.getString().compare(0, 1, "_") != 0);
        return name.getString();
    }
    else
    {
        return Decorate(name.getString());
    }
}
开发者ID:luke-chang,项目名称:gecko-1,代码行数:14,代码来源:UtilsHLSL.cpp


示例17: TestRename

void TestRename()
	{
	TName name;

	test.Start(_L("Renaming the current process with User::RenameProcess"));
	name = RProcess().Name();
	name.SetLength(KTestProcessName().Length());
	test(name.CompareF(KTestProcessName)!=0);
	User::RenameProcess(KTestProcessName);
	name = RProcess().Name();
	name.SetLength(KTestProcessName().Length());
	test(name.CompareF(KTestProcessName)==0);


	test.End();
	}
开发者ID:kuailexs,项目名称:symbiandump-os1,代码行数:16,代码来源:t_sprocess.cpp


示例18: WaitForMsgComplete

/**
Wait for message completion by the helper process

@param  aProcessLog if ETrue, log messages from the helper process will be logged by TEF
@return             error code, result of the message processing.
*/
TInt CSyncMessageSender::WaitForMsgComplete(TBool aProcessLog/*=ETrue*/)
{
    if( !aProcessLog )
    {   //-- don't need to process messages from the helper process
        User::WaitForRequest(iMsgRqStat);
        return iMsgRqStat.Int();
    }

    //-- wait for message completion processing logs from the helper process
    TName logBuf;

    for(;;)
    {
        iLogMsgQueue.NotifyDataAvailable(iLogRqStat);
        User::WaitForRequest(iMsgRqStat, iLogRqStat);

        if(iLogRqStat.Int() == KRequestPending)
        {   //-- iMsgRqStat has been completed, the pessage has been processed
            //-- cancel waiting for the log messages.
            iLogMsgQueue.CancelDataAvailable();
            User::WaitForRequest(iLogRqStat);
            break;
        }
        else
        {   //-- log message has been posted to the queue, pull all log messages up and process them
            TIPLogMsg   logMsg;
            TInt        nRes;

            for(;;)
            {
                nRes = iLogMsgQueue.Receive(logMsg);
                if(nRes != KErrNone)
                    break;

                if(ipLogger)
                {   //-- logger is available, log the message.
                    logBuf.Copy(_L("\t~helper: "));
                    logBuf.Append(logMsg.iLogMsg);
                    ipLogger->Write(logBuf);
                }
            }//for(;;)
        }
    }//for(;;)


    return iMsgRqStat.Int();
}
开发者ID:kuailexs,项目名称:symbiandump-os1,代码行数:53,代码来源:EsockPlatSecTest.cpp


示例19: OpenEtelServerL

/**
@SYMTestCaseID BA-CTSY-SESMG-TGTN-0001
@SYMComponent  telephony_ctsy
@SYMTestCaseDesc Test support in CTSY for RTelServer::GetTsyName
@SYMTestPriority High
@SYMTestActions Invokes RTelServer::GetTsyName
@SYMTestExpectedResults Pass
@SYMTestType CT
*/
void CCTsySessionManagementFU::TestGetTsyName0001L()
	{

	OpenEtelServerL(EUseExtendedError);
	CleanupStack::PushL(TCleanupItem(Cleanup,this));

	TInt index(0);
	TName tsyName;
	
	_LIT(KTsyName, "PHONETSY");
	
	TInt ret = iTelServer.GetTsyName(index, tsyName);
	ASSERT_EQUALS(KErrNone, ret);
	ASSERT_EQUALS(0, tsyName.Compare(KTsyName));
	
	CleanupStack::PopAndDestroy(1, this);
	
	}
开发者ID:cdaffara,项目名称:symbiandump-os1,代码行数:27,代码来源:cctsysessionmanagementfu.cpp


示例20: DecorateUniform

TString DecorateUniform(const TName &name, const TType &type)
{
    if (type.getBasicType() == EbtSamplerExternalOES)
    {
        return "ex_" + name.getString();
    }

    return DecorateIfNeeded(name);
}
开发者ID:FahimArnob,项目名称:angle,代码行数:9,代码来源:UtilsHLSL.cpp



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


鲜花

握手

雷人

路过

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

请发表评论

全部评论

专题导读
上一篇:
C++ TNamed类代码示例发布时间:2022-05-31
下一篇:
C++ TMultiMap类代码示例发布时间:2022-05-31
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

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

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

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