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

C++ GetBoolFromConfig函数代码示例

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

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



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

示例1: GetBoolFromConfig

/**
 Function : ModifyDefaultSearchSortOptions
 Description : Modifies the default values of TMsvSearchSortQuery object
 @return : none
 */
void CT_MsgCreatePerfSearchSortQuery::ModifyDefaultSearchSortOptions()
	{
	// Set the wildcard cahracter option to be enabled or not
	TBool wildcardSearch = EFalse;
	GetBoolFromConfig(ConfigSection(), KWildcardSearch, wildcardSearch);	
	iSharedDataCommon.iSearchSortQuery->SetWildCardSearch(wildcardSearch);

	// Set the whole word option to be enabled or not
	TBool wholeWordOption = EFalse;
	GetBoolFromConfig(ConfigSection(), KWholeWordOption, wholeWordOption);	
	iSharedDataCommon.iSearchSortQuery->SetWholeWord(wholeWordOption);

	// Set the option for case sensitve/insensitive search option
	TBool caseSensitiveFlag = EFalse;
	GetBoolFromConfig(ConfigSection(), KCaseSensitive, caseSensitiveFlag);
	iSharedDataCommon.iSearchSortQuery->SetCaseSensitiveOption(caseSensitiveFlag);

	// Set the preferred result type flag, default value is TMsvId 
	TBool resInTMsvEntry = EFalse;
	TMsvSearchSortResultType resultType = EMsvResultAsTMsvId;
	GetBoolFromConfig(ConfigSection(), KResultAsTMsvEntry, resInTMsvEntry);	
	if(resInTMsvEntry)
		{
		resultType = EMsvResultAsTMsvEntry;
		}
	iSharedDataCommon.iSearchSortQuery->SetResultType(resultType);
	
	// Set the subfolder search flag
	TBool subfolderFlag = EFalse;
	GetBoolFromConfig(ConfigSection(), KSubFolderSearch, subfolderFlag);	
	if(subfolderFlag)
		{
		iSharedDataCommon.iSearchSortQuery->SetSubFolderSearch(subfolderFlag);
		}
	}
开发者ID:cdaffara,项目名称:symbiandump-mw2,代码行数:40,代码来源:t_createperfsearchsortquery.cpp


示例2: GetStringFromConfig

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


示例3: GetBoolFromConfig

void COomTestStep::ReadTestConfigurationL()
	{
	// Read OOM Test Flag
	GetBoolFromConfig(ConfigSection(), KConfigOOMTest, iOOMTest);
	// Read OOM Server Test Flag
	GetBoolFromConfig(ConfigSection(), KConfigOOMServerTest, iOOMServerTest);
	}
开发者ID:cdaffara,项目名称:symbiandump-mw1,代码行数:7,代码来源:oomteststep.cpp


示例4: INFO_PRINTF1

TVerdict CWriteBoolStep::doTestStepL()
/**
 * @return - TVerdict code
 * Override of base class pure virtual
 * Our implementation only gets called if the base class doTestStepPreambleL() did
 * not leave. That being the case, the current test result value will be EPass.
 */
	{
	INFO_PRINTF1(_L("This step tests WriteBoolToConfig function."));
	SetTestStepResult(EFail);
	
	TBool originalValue;
	TBool TheBool;
	TBool ret = EFalse;
	
	if(!GetBoolFromConfig(ConfigSection(),KTe_RegStepTestSuiteBool, originalValue))
		{
		// Leave if there's any error.
		User::Leave(KErrNotFound);
		}
	
	INFO_PRINTF2(_L("The ORIGINAL Bool is %d"), originalValue); // Block end
	TheBool = ETrue;
	if (WriteBoolToConfig(ConfigSection(),KTe_RegStepTestSuiteBool,TheBool))
		{
		if (GetBoolFromConfig(ConfigSection(),KTe_RegStepTestSuiteBool, TheBool) && TheBool)
			{
			INFO_PRINTF2(_L("The CHANGED Bool is %d"), TheBool);
			ret = ETrue;
			}
		}
	
	TheBool = EFalse;
	if (WriteBoolToConfig(ConfigSection(),KTe_RegStepTestSuiteBool,TheBool))
		{
		if (GetBoolFromConfig(ConfigSection(),KTe_RegStepTestSuiteBool, TheBool) && !TheBool)
			{
			INFO_PRINTF2(_L("The CHANGED Bool is %d"), TheBool);
			}
		}
	else
		{
		ret = EFalse;
		}
	
	if (!WriteBoolToConfig(ConfigSection(),KTe_RegStepTestSuiteBool,originalValue))
		{
		ret = EFalse;
		}
	
	if (ret)
		{
		SetTestStepResult(EPass);
		}

	return TestStepResult();
	}
开发者ID:cdaffara,项目名称:symbiandump-os2,代码行数:57,代码来源:writeboolstep.cpp


示例5: GetIntFromConfig

void CEtelMMLbsTestStepBase::ValidateMCRefTimeParams()
{
	TInt expectedGpsWeek ;
	GetIntFromConfig(ConfigSection(), _L("expectedGpsWeek"), expectedGpsWeek );

	TInt expectedGpsTowOneMsce ;
	GetIntFromConfig(ConfigSection(), _L("expectedGpsTowOneMsce"), expectedGpsTowOneMsce );

	TBool expectedReftimeRequest;
	GetBoolFromConfig(ConfigSection(), _L("expectedReftimeRequest"), expectedReftimeRequest);

	TInt expectedRefTimeLsPart  ;
	GetIntFromConfig(ConfigSection(), _L("expectedRefTimeLsPart"), expectedRefTimeLsPart  );

	TInt expectedRefTimeMsPart  ;
	GetIntFromConfig(ConfigSection(), _L("expectedRefTimeMsPart"), expectedRefTimeMsPart  );

	TInt expectedRefTimeSfn  ;
	GetIntFromConfig(ConfigSection(), _L("expectedRefTimeSfn"), expectedRefTimeSfn  );

	TBool expectedAcqAsstRequest;
	GetBoolFromConfig(ConfigSection(), _L("expectedAcqAsstRequest"), expectedAcqAsstRequest);

	TBool expectedIntegrityRequest;
	GetBoolFromConfig(ConfigSection(), _L("expectedIntegrityRequest"), expectedIntegrityRequest);

	TInt expectedAcqAsstTime ;
	GetIntFromConfig(ConfigSection(), _L("expectedAcqAsstTime"), expectedAcqAsstTime );

	TInt expectedModePrimaryCode ;
	GetIntFromConfig(ConfigSection(), _L("expectedModePrimaryCode"), expectedModePrimaryCode );

	TInt expectedModeCellId ;
	GetIntFromConfig(ConfigSection(), _L("expectedModeCellId"), expectedModeCellId );

	TBool expectedModeStatusRequest;
	GetBoolFromConfig(ConfigSection(), _L("expectedModeStatusRequest"), expectedModeStatusRequest);

	//Reference Time Data populated and status is false
	TEST(iMeasurementControl.iMeasurementCommand.iSetup.iUePosGpsAssistanceData.iReferencTime.iGpsWeek == expectedGpsWeek);		
	TEST(iMeasurementControl.iMeasurementCommand.iSetup.iUePosGpsAssistanceData.iReferencTime.iGpsTowOneMsec == expectedGpsTowOneMsce );
	TEST(iMeasurementControl.iMeasurementCommand.iSetup.iUePosGpsAssistanceData.iGpsAddlDataStatus.iReferenceTimeRequest == expectedReftimeRequest);	
		
	//	Acquisition Assistance Data populated and status is false
	TEST(iMeasurementControl.iMeasurementCommand.iSetup.iUePosGpsAssistanceData.iReferencTime.iUtranGpsRefTime.iLsPart == expectedRefTimeLsPart);
	TEST(iMeasurementControl.iMeasurementCommand.iSetup.iUePosGpsAssistanceData.iReferencTime.iUtranGpsRefTime.iMsPart == expectedRefTimeMsPart);
	TEST(iMeasurementControl.iMeasurementCommand.iSetup.iUePosGpsAssistanceData.iReferencTime.iUtranGpsRefTime.iSfn == expectedRefTimeSfn);
	TEST(iMeasurementControl.iMeasurementCommand.iSetup.iUePosGpsAssistanceData.iGpsAddlDataStatus.iAcquisitionAssistanceReq == expectedAcqAsstRequest);
	
	TEST(iMeasurementControl.iMeasurementCommand.iSetup.iUePosGpsAssistanceData.iGpsAddlDataStatus.iRealTimeIntegrityRequest == expectedIntegrityRequest);
	TEST(iMeasurementControl.iMeasurementCommand.iSetup.iUePosGpsAssistanceData.iAcquisitionAssistance.iGpsReferenceTime == expectedAcqAsstTime	);
	TEST(iMeasurementControl.iMeasurementCommand.iSetup.iUePosGpsAssistanceData.iAcquisitionAssistance.iUtranGpsReferenceTime.iPrimaryScramblingCode == expectedModePrimaryCode);
	TEST(iMeasurementControl.iMeasurementCommand.iSetup.iUePosGpsAssistanceData.iAcquisitionAssistance.iUtranGpsReferenceTime.iCellParametersID == expectedModeCellId);
	TEST(iMeasurementControl.iMeasurementCommand.iSetup.iUePosGpsAssistanceData.iReferencTime.iUtranGpsRefTime.iModeSpecificInfoStatus == expectedModeStatusRequest);
	TEST(iMeasurementControl.iMeasurementCommand.iSetup.iUePosGpsAssistanceData.iReferencTime.iUtranGpsRefTime.iModeSpecificInfo.iPrimaryScramblingCode == expectedModeCellId);
}
开发者ID:cdaffara,项目名称:symbiandump-os1,代码行数:56,代码来源:TE_EtelMMLbsStepBase.cpp


示例6: INFO_PRINTF1

/**
 Function : doTestStepL
 Description : Get the count of message entries satisfying serach-sort criteria and get the entries.
 @return : TVerdict - Test step result
 */
TVerdict CT_MsgSearchSortByQueryObject::doTestStepL()
	{
	INFO_PRINTF1(_L("Test Step : SearchSortByQueryObject"));
	
	// Read query marking option
	TBool markQuery = EFalse;
	GetBoolFromConfig(ConfigSection(), KMarkQuery, markQuery);
	markQuery ? INFO_PRINTF1(_L("Query is marked")) : INFO_PRINTF1(_L("Query is to not marked"));

	// Read the iteration limit for getting the results
	TInt iteratorLimit = 0;
	GetIntFromConfig(ConfigSection(), KIteratorLimit, iteratorLimit);

	// Execute the search/sort request
	iSharedDataCommon.iSearchSortOperation = CMsvSearchSortOperation::NewL(*iSharedDataCommon.iSession);
	CT_MsgActive& active=Active();
	TRAPD(err, iSharedDataCommon.iSearchSortOperation->RequestL(iSharedDataCommon.iSearchSortQuery, markQuery, active.iStatus, iteratorLimit));
	if(err == KErrNone)
		{
		active.Activate();
		CActiveScheduler::Start();
		
		//Check Search/Sort operation for errors
		TInt error = active.Result();
		if (error != KErrNone)
			{
			ERR_PRINTF2(_L("Search/Sort request failed with %d error"), error);
			SetTestStepError(error);
			}
		else
			{
			// Get the query ID for the above search/sort request
			TInt quryId = iSharedDataCommon.iSearchSortOperation->GetQueryIdL();
			TBool isRepetitionRequired = EFalse;
			GetBoolFromConfig(ConfigSection(), KIsRepetitionRequired, isRepetitionRequired);
			// Save the query ID to INI file
			isRepetitionRequired ? WriteIntToConfig(ConfigSection(), KRepeatedQueryID, quryId):WriteIntToConfig(ConfigSection(), KLastQueryID, quryId);

			TBool resInTMsvEntry = EFalse;
			GetBoolFromConfig(ConfigSection(), KResultAsTMsvEntry, resInTMsvEntry);	
			TMsvSearchSortResultType resultType = EMsvResultAsTMsvId;
			if(resInTMsvEntry)
				{
				resultType = EMsvResultAsTMsvEntry;
				}
			RetriveSearchSortResultL(iteratorLimit, resultType);
			}
		}
	else
		{
		SetTestStepError(err);	
		}
	return TestStepResult();
	}
开发者ID:cdaffara,项目名称:symbiandump-mw2,代码行数:59,代码来源:t_searchsortbyqueryobject.cpp


示例7: _LIT

/**
* New contact entries are added in the database. The newly added contacts can have fields that meet the sort order
* of some existing views, With the addition of such contact fields, the existing views needs resorting. The newly added
* fields may also meet the filter criteria of some existing views. This is useful while testing filtered views
* The new added contacts can have fields with some predefined string content, this is useful in case of Find Views and Sub Views.
*/
void CTestContactViewCRUDOperationsStep::AddContactEntriesL()
	{
	_LIT(KViewSortOrder, "SortOrder");
	TPtrC viewSortOrderString;
	GetStringFromConfig(ConfigSection(), KViewSortOrder, viewSortOrderString);

	RContactViewSortOrder sortOrder = ViewUtilityReference().ConvertStringToSortOrderL(viewSortOrderString);
	CleanupClosePushL(sortOrder);

	_LIT(KNumOfContactsToBeAdded, "NumOfContactsToBeAdded");
	TInt numOfContactsToBeAdded;
	GetIntFromConfig(ConfigSection(), KNumOfContactsToBeAdded, numOfContactsToBeAdded);


	for(TInt i = 0; i < numOfContactsToBeAdded; ++i)
		{
		CContactCard* contactCard = CContactCard::NewL();
		CleanupStack::PushL(contactCard);
		AddContactFieldL(*contactCard, sortOrder);

		TBool filterBasedFields;
		_LIT(KFilterBasedFields, "FilterBasedFields");
		GetBoolFromConfig(ConfigSection(), KFilterBasedFields, filterBasedFields);
		if(filterBasedFields)
			{
			AddFieldsSpecificToFilterL(*contactCard);
			}

		TBool contactsWithDesiredString;
		_LIT(KContactsWithDesiredString, "ContactsWithDesiredString");
		GetBoolFromConfig(ConfigSection(), KContactsWithDesiredString, contactsWithDesiredString);
		if(contactsWithDesiredString)
			{
			AddMatchingStringToContactL(*contactCard);
			}


		TContactItemId contactId = DatabaseReference().AddNewContactL(*contactCard);

		TPtrC addContactToGroup;
		_LIT(KAddContactToGroup, "grouplist");
		GetStringFromConfig(ConfigSection(), KAddContactToGroup, addContactToGroup);
		if(addContactToGroup != KNullDesC)
			{
			IterateThroAllGroupSectionsAndUpdateContactL(addContactToGroup, *contactCard);
			}

		CleanupStack::PopAndDestroy();// contactCard
		DatabaseReference().CloseContactL(contactId);
		}
	CleanupStack::PopAndDestroy(); // sortOrder
	}
开发者ID:Esclapion,项目名称:qt-mobility,代码行数:58,代码来源:testcontactviewcrudoperationsstep.cpp


示例8: GetStringFromConfig

// Gets the input from ini file
void CTestContactsPBAPExport::GetInputFromIni()
	{
	iSetOOM = EFalse;
	GetStringFromConfig(ConfigSection(), KStandard, iStandard);
	GetStringFromConfig(ConfigSection(), KExportTo, iExportTo);
	GetStringFromConfig(ConfigSection(), KFilter, iFilter);
	// For OOM testing
	GetBoolFromConfig(ConfigSection(), KSetOOM, iSetOOM);
	GetBoolFromConfig(ConfigSection(), KDamageDb, iDamageDb);
	GetBoolFromConfig(ConfigSection(), KInvalidFileSystem, iInvalidFileSystem);
	GetBoolFromConfig(ConfigSection(), KFilterBitsFutureUse, iFilterBitsFutureUse);
	GetBoolFromConfig(ConfigSection(), KSetFilterOnlyFutureUse, iSetFilterOnlyFutureUse);
	}
开发者ID:Esclapion,项目名称:qt-mobility,代码行数:14,代码来源:testcontactspbapexport.cpp


示例9: GetBoolFromConfig

void CEtelMMLbsTestStepBase::ValidateMCParams()
	{

	TBool isVelocityRequested;
	GetBoolFromConfig(ConfigSection(), _L("velocityRequested"), isVelocityRequested);

	TInt expectedGpsTow ;
	GetIntFromConfig(ConfigSection(), _L("expectedGpsTow"), expectedGpsTow );

	TBool expectedCorrectionRequest;
	GetBoolFromConfig(ConfigSection(), _L("expectedCorrectionRequest"), expectedCorrectionRequest);

	TInt expectedGpsAlmanac ;
	GetIntFromConfig(ConfigSection(), _L("expectedGpsAlmanac"), expectedGpsAlmanac );

	TBool expectedGpsAlmanacRequest;
	GetBoolFromConfig(ConfigSection(), _L("expectedGpsAlmanacRequest"), expectedGpsAlmanacRequest);

	TInt expectedBadSatList ;
	GetIntFromConfig(ConfigSection(), _L("expectedBadSatList"), expectedBadSatList );

	TInt expectedHorAccuracy ;
	GetIntFromConfig(ConfigSection(), _L("expectedHorAccuracy"), expectedHorAccuracy );

	TInt expectedVertAccuracy ;
	GetIntFromConfig(ConfigSection(), _L("expectedVertAccuracy"), expectedVertAccuracy );

	TBool expectedAddlAsstDataRequest;
	GetBoolFromConfig(ConfigSection(), _L("expectedAddlAsstDataRequest"), expectedAddlAsstDataRequest);

	TEST(iMeasurementControl.iVelocityRequested == isVelocityRequested);
	TEST(iMeasurementControl.iMeasReportTransferMode == DMMTSY_PHONE_LCS_MC_RPTTRANSFERMODE);

	//DGPS corrections data populated and status is false		
	TEST(iMeasurementControl.iMeasurementCommand.iSetup.iUePosGpsAssistanceData.iDgpsCorrections.iGpsTow == expectedGpsTow);	
	TEST(iMeasurementControl.iMeasurementCommand.iSetup.iUePosGpsAssistanceData.iGpsAddlDataStatus.iDgpsCorrectionsRequest == expectedCorrectionRequest);	
			
	//Almanac data populated and status is false
	TEST(iMeasurementControl.iMeasurementCommand.iSetup.iUePosGpsAssistanceData.iAlmanac.iWnA == expectedGpsAlmanac);
	TEST(iMeasurementControl.iMeasurementCommand.iSetup.iUePosGpsAssistanceData.iGpsAddlDataStatus.iAlmanacRequest	== expectedGpsAlmanacRequest);
	
	//RealTime integrity data populated and status is false
	TEST(iMeasurementControl.iMeasurementCommand.iSetup.iUePosGpsAssistanceData.iBadSatList[0] == expectedBadSatList);
	TEST(iMeasurementControl.iMeasurementCommand.iSetup.iUePosReportingQuantity.iHorzAccuracy == expectedHorAccuracy);
	TEST(iMeasurementControl.iMeasurementCommand.iSetup.iUePosReportingQuantity.iVertAccuracy == expectedVertAccuracy);
	//Additional Assistance Data is not required
	TEST(iMeasurementControl.iMeasurementCommand.iSetup.iUePosReportingQuantity.iAddlAssistanceDataReq == expectedAddlAsstDataRequest);
	}
开发者ID:cdaffara,项目名称:symbiandump-os1,代码行数:48,代码来源:TE_EtelMMLbsStepBase.cpp


示例10: SetTestStepResult

/**
Implementation of CTestStep base class virtual
It is used for doing all initialisation common to derived classes in here.
Make it being able to leave if there are any errors here as there's no point in
trying to run a test step if anything fails.
The leave will be picked up by the framework.

@return - TVerdict
*/
TVerdict CTe_graphicsperformanceSuiteStepBase::doTestStepPreambleL()
	{
	SetTestStepResult(EPass);
	
	// Create and install Active Scheduler in case tests require active objects
	iScheduler = new(ELeave) CActiveScheduler;
	CActiveScheduler::Install(iScheduler);
	
	FbsStartup();
	TESTNOERRORL(RFbsSession::Connect());
	HAL::Get(HALData::ECPUSpeed,iCPUSpeed); 
	INFO_PRINTF2(_L("CPUSpeed: %i	kHz"),iCPUSpeed);
	
	// get input for tests from .ini file
	TEST(GetIntFromConfig(_L("Profiling"), _L("DoProfiling"), iDoProfiling));
	TEST(GetBoolFromConfig(_L("SanityCheck"), _L("Bitmaps"), iShowBitmaps));
	
	if (iDoProfiling>0)	
		{
		__INITPROFILER	
		}
			
	iProfiler = CTProfiler::NewL(*this);
	__UHEAP_MARK;	
	return TestStepResult();
	}
开发者ID:cdaffara,项目名称:symbiandump-os1,代码行数:35,代码来源:te_graphicsperformanceSuiteStepBase.cpp


示例11: INFO_PRINTF1

TVerdict CCTestLtsySmsControlReceiveSmsCase1Step::doTestStepL()
/**
 * @return - TVerdict code
 * Override of base class pure virtual
 * Our implementation only gets called if the base class doTestStepPreambleL() did
 * not leave. That being the case, the current test result value will be EPass.
 */
	{
	  if (TestStepResult()==EPass)
		{

		//  ************** Delete the Block, the block start ****************
		INFO_PRINTF1(_L("Please modify me. I am in CCTestLtsySmsControlReceiveSmsCase1Step::doTestStepL() in the file CTestLtsySmsControlReceiveSmsCase1Step.cpp"));  //Block start
		TPtrC TheString;
		TBool TheBool;
		TInt TheInt;
		if(!GetStringFromConfig(ConfigSection(),KTe_integration_stltsySuiteString, TheString) ||
			!GetBoolFromConfig(ConfigSection(),KTe_integration_stltsySuiteBool,TheBool) ||
			!GetIntFromConfig(ConfigSection(),KTe_integration_stltsySuiteInt,TheInt)
			)
			{
			// Leave if there's any error.
			User::Leave(KErrNotFound);
			}
		else
			{
			INFO_PRINTF4(_L("The test step is %S, The Bool is %d, The int-value is %d"), &TheString, TheBool,TheInt); // Block end
			}

		//  **************   Block end ****************

		SetTestStepResult(EPass);
		}
	  return TestStepResult();
	}
开发者ID:cdaffara,项目名称:symbiandump-os1,代码行数:35,代码来源:testltsysmscontrolreceivesmscase1step.cpp


示例12: while

TInt CC32RunThreadStep::ReadIniTotalSemaphoreCount()
/**
 * @return - TInt code
 * Override of base class virtual
 * Finds semaphore count from the ini file.
 */
	{
	TInt  semaphoreCount = 0;
	TInt  count		     = 0;
	TBool findField      = ETrue;
	TBool semStatus;
		
	while(findField)
		{
		//parse thread details from ini files
		iSection.Copy(KThreadSection);
		iSection.AppendNum(count++);
		
		findField = GetBoolFromConfig(iSection, KSemaphore, semStatus);
		if(findField)
		   {
	   	   if(semStatus)
	   	 	   {
	   	 	   //increment if semaphore field is set to True.
	   	 	   semaphoreCount++;
	   	 	   }
	   	   }
	    else
	       {
	       findField = EFalse;
	       }
	    }

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


示例13: INFO_PRINTF1

/**
This is to test the find fuctionality to get the list type of a specific given uri
and check that returned list type is corrrect if it is positive and non-capability test.
It reads values from INI file and gets the list type of a specific uri from DB.
@internalTechnology 
@test
@param		None
@return		EPass or EFail indicating the success or failure of the test step
*/
TVerdict CTestUriListTypeStep::doTestStepL()
	{
	__UHEAP_MARK;
	INFO_PRINTF1(_L("\n"));
	// Get necessary information from INI file

	TPtrC uri;
	TInt serviceType;
	TInt expListType;
	TInt expRetCode;
	TBool isCapabilityTest;
	
	if(!GetStringFromConfig(ConfigSection(), 	KIniUri, uri) ||
	   !GetIntFromConfig(ConfigSection(), 	KIniServiceType, serviceType) ||
	   !GetIntFromConfig(ConfigSection(), 	KIniExpectedListType, expListType) ||
	   !GetIntFromConfig(ConfigSection(), KIniExpectedRetCode, expRetCode) ||
	   !GetBoolFromConfig(ConfigSection(), KIniIsCapabilityTest, isCapabilityTest) 
	  )
		{
		ERR_PRINTF6(_L("Problem in reading values from ini.			\
						\nExpected fields are: \n%S\n%S\n%S\n%S\n%S\n"
					  ),&KIniUri, &KIniServiceType, &KIniExpectedRetCode, &KIniExpectedListType, &isCapabilityTest
				   );
		SetTestStepResult(EFail);
		}
开发者ID:kuailexs,项目名称:symbiandump-mw2,代码行数:34,代码来源:testurilisttypestep.cpp


示例14: GetBoolFromConfig

TVerdict CTSmallWindowsTest::doTestStepPreambleL()
	{
	CTe_graphicsperformanceSuiteStepBase::doTestStepPreambleL();
	iScreenSize = CTWindow::GetDisplaySizeInPixels();	
	TBool preload = EFalse;
	GetBoolFromConfig(_L("FlowTests"), _L("Preload"), preload);

	TPtrC fileNameList;
	TEST(GetStringFromConfig(_L("FlowTests"), _L("Files"), fileNameList));
	ExtractListL(fileNameList, iFileNames);

	ComputeSmallWindows();

	TPoint initialPosition(0, 0);
	RArray<TPoint> initialPositions;
    RArray<pTWindowCreatorFunction> windowCreatorFunctions;
    CleanupClosePushL(initialPositions);
    CleanupClosePushL(windowCreatorFunctions);
	for (TInt i = 0; i < iWindowsAcross; i++)
		{
		initialPosition.iY = 0;
		for (TInt j = 0; j < iWindowsAcross; j++)
			{
			windowCreatorFunctions.AppendL(CTSmallWindowRaster::NewL);
			initialPositions.AppendL(initialPosition);
			initialPosition.iY += iWindowSize.iHeight;
			}
		initialPosition.iX += iWindowSize.iWidth;
		}

	iFlowWindowsController = CTFlowWindowsController::NewL(preload, iFileNames, iWindowSize, windowCreatorFunctions, initialPositions, ETrue);
    CleanupStack::PopAndDestroy(2, &initialPositions);
	return TestStepResult();
	}
开发者ID:cdaffara,项目名称:symbiandump-os1,代码行数:34,代码来源:tsmallwindowstest.cpp


示例15: GetIntFromConfig

TVerdict CLbsConnectDisconnectNotificationTest::doTestStepPreambleL()
/**
 * @return - TVerdict code
 * Override of base class virtual
 */
	{
	__UHEAP_MARK;
	
	// Get the delay
	GetIntFromConfig(ConfigSection(), KDelay, iDelay);
	// Assistance data provider
	TInt provider;
	GetIntFromConfig(ConfigSection(), KProvider, provider);
	iProvider = TUid::Uid(provider);
	// Step mode?
	TBool stepMode = EFalse;
	GetBoolFromConfig(ConfigSection(), KStepMode, stepMode);

	iState = EStart;
	iTest = new (ELeave) CAOTest(this, iDelay, stepMode);  // Stopped in postamble
	iGateway = new (ELeave) CAOGateway(this); // Stopped during test

	SetTestStepResult(EPass);
	return TestStepResult();
	}
开发者ID:kuailexs,项目名称:symbiandump-os1,代码行数:25,代码来源:LbsConnectDisconnectNotificationTest.cpp


示例16: INFO_PRINTF1

/**
@SYMTestCaseID			PIM-APP-ENGINES-CALINTERIMAPI-CIT-0005-HP
@SYMTestType			CIT
@SYMTestPriority		Medium
@SYMPREQ				1098
@SYMFssID				3.2.1 005
@SYMTestCaseDesc		delete the opened file
@SYMTestActions			deletes the opened file
@SYMTestExpectedResults	Aganda file is and deleted
*/
void CTestCalInterimApiSuiteStepBase::DeleteCalenderFileL()
	{
	INFO_PRINTF1(_L("Deleting calender file"));

	TRAPD(err, iSession->DeleteCalFileL(iCalenderFileName));
	if( err == KErrNone )
		{
		TBool reCreateCalFile = ETrue;
	    if (!GetBoolFromConfig(ConfigSection(), KReCreateCalFile, reCreateCalFile))
	        {
	    	reCreateCalFile = ETrue;
	        }

	    if (reCreateCalFile)
	        {
	    	INFO_PRINTF1(_L("Trying to create the file after deletion"));
		    TRAPD(err, iSession->CreateCalFileL(iCalenderFileName));
		    if( err != KErrNone )
			    {
			    ERR_PRINTF2(KErrInDeleteCalFileL, err);
			    SetTestStepResult(EFail);
			    }
	        }
		}
	else
		{
		ERR_PRINTF2(KErrDeletingCalenderFile, err);
		SetTestStepResult(EFail);
		}
	}
开发者ID:cdaffara,项目名称:symbiandump-ossapps,代码行数:40,代码来源:TestCalInterimApiSuiteStepBase.cpp


示例17: GetPartOfBufferL

/** Gets the specified part of the unicode based on the requirement from the user
@param	aBuffer Pointer to CHtmlToCrtConvBuffer
@param	aPartOfUnicode Contains the return value of GetPartOfBufferL()
@test
*/
void CTestHtmlToCrtConverterBufferStep::GetPartOfConvertedBufferL(CHtmlToCrtConvBuffer* aBuffer, TDes& aPartOfBuffer)
	{
	GetBoolFromConfig(ConfigSection(), KGetPartOfBuffer, iGetPartOfBuffer);
	if ( iGetPartOfBuffer == EFalse )
		{
		return;
		}
		
	GetIntFromConfig(ConfigSection(), KStartPosition, iStartPosition);
	GetIntFromConfig(ConfigSection(), KEndPosition, iEndPosition);
	TPtrC	partOfBufferUnicode;
	if ( iEndPosition == 0 )
		{
		// Gets the part of the buffer from the start position till the end
		aBuffer->GetToEndOfBufferL(partOfBufferUnicode, iStartPosition);
		aPartOfBuffer.Copy(partOfBufferUnicode);	
		}
	else if ( (iStartPosition != 0) && (iEndPosition != 0) )
		{
		// Get the specified part of the buffer returned from CHtmlToCrtConverterBuffer
		aBuffer->GetPartOfBufferL(partOfBufferUnicode, iStartPosition, iEndPosition);
		aPartOfBuffer.Copy(partOfBufferUnicode);
		}
	else if ( iEndPosition != 0 )
		{
		TBuf8<KMaxLengthString>	partOfBufferUnicode;
		// Get the sample of text from the file and returns it in the partOfBufferUnicode
		aBuffer->GetSampleOfTextFromFileL(partOfBufferUnicode, iEndPosition, 0);
		aPartOfBuffer.Copy(partOfBufferUnicode);
		}

	}
开发者ID:cdaffara,项目名称:symbiandump-mw1,代码行数:37,代码来源:TestHtmlToCrtConverterBufferStep.cpp


示例18: INFO_PRINTF1

/** Calls CFbsFont::HasCharacter() */
void CT_DataFbsFont::DoCmdHasCharacter(const TDesC& aSection)
	{
	INFO_PRINTF1(_L("Calls CFbsFont::HasCharacter()"));

	// get character code from parameters
	TInt	charCode = 0;
	if(!GetIntFromConfig(aSection, KCharCode(), charCode))
		{
		ERR_PRINTF2(_L("No %S"), &KCharCode());
		SetBlockResult(EFail);
		}
	else
		{
		// call HasCharacter()
		TBool	actual = iFbsFont->HasCharacter(charCode);

		TBool	expected;
		if(GetBoolFromConfig(aSection, KExpectedBool(), expected))
			{
		// check that the value is as expected
			if (actual != expected)
				{
				ERR_PRINTF3(_L("The value is not as expected! expected: %d, actual: %d"), expected, actual);
				SetBlockResult(EFail);
				}
			}
		}
	}
开发者ID:fedor4ever,项目名称:default,代码行数:29,代码来源:T_DataFbsFont.cpp


示例19: DoCmd_iParRightToLeft

void CT_DataDrawTextExtendedParam::DoCmd_iParRightToLeft(const TDesC& aSection)
	{
	if ( !GetBoolFromConfig(aSection, KFldValue(), iDrawTextExtendedParam->iParRightToLeft) )
		{
		INFO_PRINTF2(_L("iParRightToLeft=%d"), iDrawTextExtendedParam->iParRightToLeft);
		}
	}
开发者ID:fedor4ever,项目名称:default,代码行数:7,代码来源:T_DataDrawTextExtendedParam.cpp


示例20: doTestStepPreambleL

enum TVerdict CTS_Delay::doTestStepPreambleL(void)
/**
 * Implements OOM testing in each test
 */
	{
	if (!(GetBoolFromConfig(KDelay,KOomTest,iIsOOMTest)))
		iIsOOMTest=EFalse;
	return EPass;
	}
开发者ID:cdaffara,项目名称:symbiandump-os1,代码行数:9,代码来源:TS_Delay.cpp



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


鲜花

握手

雷人

路过

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

请发表评论

全部评论

专题导读
上一篇:
C++ GetBorder函数代码示例发布时间:2022-05-30
下一篇:
C++ GetBool函数代码示例发布时间: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