本文整理汇总了C++中CBaseEntityTA::GetID方法的典型用法代码示例。如果您正苦于以下问题:C++ CBaseEntityTA::GetID方法的具体用法?C++ CBaseEntityTA::GetID怎么用?C++ CBaseEntityTA::GetID使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类CBaseEntityTA
的用法示例。
在下文中一共展示了CBaseEntityTA::GetID方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: RepositionSubEntity
/******************************************************************************
Function Name : RepositionSubEntity
Input(s) : CBaseEntityTA* pouRefSubEntity
CBaseEntityTA* pouCurrSubEntity
Output : HRESULT - returns the New Entity ID
Functionality : Reposition pouRefSubEntity after pouCurrSubEntity
Member of : CTestCaseEntity
Friend of : -
Author(s) : Venkatanarayana Makam
Date Created : 06/04/2011
Modifications :
Codetag : CS021
******************************************************************************/
HRESULT CTestCaseEntity::RepositionSubEntity(CBaseEntityTA* pouRefSubEntity, CBaseEntityTA* pouCurrSubEntity)
{
//DESIGN:: First Take copy of Data and delete it from current position and add at required place
UINT unCount = (UINT)m_ouData.m_odTAEntityList.GetCount();
for(UINT i=0; i<unCount; i++)
{
POSITION pos = m_ouData.m_odTAEntityList.FindIndex(i);
CBaseEntityTA* pEntity = m_ouData.m_odTAEntityList.GetAt(pos);
if(pEntity->GetID() == pouRefSubEntity->GetID())
{
m_ouData.m_odTAEntityList.RemoveAt(pos);
break;
}
}
if(pouCurrSubEntity == NULL) //Insert At First Index;
{
m_ouData.m_odTAEntityList.AddHead(pouRefSubEntity);
}
else
{
for(UINT i=0; i<unCount; i++)
{
POSITION pos = m_ouData.m_odTAEntityList.FindIndex(i);
CBaseEntityTA* pEntity = m_ouData.m_odTAEntityList.GetAt(pos);
if(pEntity->GetID() == pouCurrSubEntity->GetID())
{
m_ouData.m_odTAEntityList.InsertAfter(pos, pouRefSubEntity);
break;
}
}
}
return pouRefSubEntity->GetID();
}
示例2: bParseTestSetup
/******************************************************************************
Function Name : bParseTestSetup
Input(s) : INT nIndex
Output : BOOL
Functionality : Loads The
Member of : CTSExecutorChildFrame
Friend of : -
Author(s) : Venkatanarayana Makam
Date Created : 07/04/2011
Modifications :
Code Tag :
******************************************************************************/
BOOL CTSExecutorChildFrame::bParseTestSetup(INT nIndex)
{
BOOL bResult = FALSE;
STestSetupInfo sTSInfo;
if( m_ouTSExecutor.GetTestSetupInfo(nIndex, sTSInfo) == S_OK)
{
HTREEITEM hTSItem = m_odTreeView->InsertTreeItem(m_hParentTreeItem, sTSInfo.m_omstrName, NULL, def_INDEX_TESTSETUPIMAGE,
def_INDEX_TESTSETUPIMAGE, sTSInfo.m_dwID);
m_odTreeView->GetTreeCtrl().SetCheck(hTSItem, sTSInfo.m_bEnable);
for(INT i = 0; i < sTSInfo.m_nTCCount; i++)
{
CBaseEntityTA* pouTCData;
CTestCaseData ouTCData;
if(m_ouTSExecutor.GetTestCaseInfo(sTSInfo.m_dwID, i, &pouTCData) == S_OK)
{
pouTCData->GetEntityData(TEST_CASE, &ouTCData);
HTREEITEM hTCItem = m_odTreeView->InsertTreeItem(hTSItem, ouTCData.m_omTitle, NULL, def_INDEX_TESTCASEIMAGE,
def_INDEX_TESTCASEIMAGE, pouTCData->GetID());
m_odTreeView->GetTreeCtrl().SetCheck(hTCItem, pouTCData->bGetEnableStatus());
}
}
bResult = TRUE;
}
return bResult;
}
示例3: DeleteSubEntry
/******************************************************************************
Function Name : DeleteSubEntry
Input(s) : CBaseEntityTA* pouSubEntryObj
Output : HRESULT
Functionality : Deletes a Subentry
Member of : CTestCaseEntity
Friend of : -
Author(s) : Venkatanarayana Makam
Date Created : 06/04/2011
Modifications :
Codetag : CS018
******************************************************************************/
HRESULT CTestCaseEntity::DeleteSubEntry(CBaseEntityTA* pouSubEntryObj)
{
HRESULT hResult = S_FALSE;
INT nCount = (INT)m_ouData.m_odTAEntityList.GetCount();
for(int i = 0; i < nCount; i++)
{
POSITION pos = m_ouData.m_odTAEntityList.FindIndex(i);
CBaseEntityTA *pEntity = m_ouData.m_odTAEntityList.GetAt(pos);
if(pEntity->GetID() == pouSubEntryObj->GetID())
{
m_ouData.m_odTAEntityList.RemoveAt(pos);
hResult = S_OK;
break;
}
}
return hResult;
}