EgtExecutor :
- aggiunta funzione ExeGetNameInGroup, semplificata di conseguenza LuaGetNameInGroup - piccole migliorie a exe/lua GetInfoInGroup.
This commit is contained in:
+19
-1
@@ -219,12 +219,30 @@ ExeGetPrevName( int nId, const string& sName)
|
||||
return pGeomDB->GetPrevName( nId, sName) ;
|
||||
}
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
bool
|
||||
ExeGetNameInGroup( int nGroupId, const string& sName, INTVECTOR& vIds)
|
||||
{
|
||||
IGeomDB* pGeomDB = GetCurrGeomDB() ;
|
||||
VERIFY_GEOMDB( pGeomDB, false)
|
||||
if ( ! pGeomDB->ExistsObj( nGroupId))
|
||||
return false ;
|
||||
// recupero gli oggetti con il nome desiderato
|
||||
vIds.clear() ;
|
||||
int nId = pGeomDB->GetFirstNameInGroup( nGroupId, sName) ;
|
||||
while ( nId != GDB_ID_NULL) {
|
||||
vIds.push_back( nId) ;
|
||||
nId = pGeomDB->GetNextName( nId, sName) ;
|
||||
}
|
||||
return true ;
|
||||
}
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
bool
|
||||
ExeGetInfoInGroup( int nGroupId, const string& sKey, INTVECTOR& vIds)
|
||||
{
|
||||
IGeomDB* pGeomDB = GetCurrGeomDB() ;
|
||||
VERIFY_GEOMDB( pGeomDB, GDB_ID_NULL)
|
||||
VERIFY_GEOMDB( pGeomDB, false)
|
||||
if ( ! pGeomDB->ExistsObj( nGroupId))
|
||||
return false ;
|
||||
// recupero gli oggetti con l'info desiderata
|
||||
|
||||
Reference in New Issue
Block a user