EgtExecutor :
- correzione a ExeDuploCount e ExeDuploList per aggiunta verifica esistenza dei duplo.
This commit is contained in:
+11
-1
@@ -724,7 +724,12 @@ ExeDuploCount( int nSouId, int& nCount)
|
||||
// Recupero info del sorgente
|
||||
INTVECTOR vnRef ;
|
||||
pGeomDB->GetInfo( nSouId, GDB_SI_DUPLIST, vnRef) ;
|
||||
nCount = int( vnRef.size()) ;
|
||||
// Conto i reali duplo
|
||||
nCount = 0 ;
|
||||
for ( int i = 0 ; i < int( vnRef.size()) ; ++ i) {
|
||||
if ( ExeIsDuplo( vnRef[i]))
|
||||
++ nCount ;
|
||||
}
|
||||
return true ;
|
||||
}
|
||||
|
||||
@@ -739,6 +744,11 @@ ExeDuploList( int nSouId, INTVECTOR& vnRef)
|
||||
return false ;
|
||||
// Recupero info del sorgente
|
||||
pGeomDB->GetInfo( nSouId, GDB_SI_DUPLIST, vnRef) ;
|
||||
// Elimino duplo non più esistenti
|
||||
for ( int i = int( vnRef.size()) - 1 ; i >= 0 ; -- i) {
|
||||
if ( ! ExeIsDuplo( vnRef[i]))
|
||||
vnRef.erase( vnRef.begin() + i) ;
|
||||
}
|
||||
return true ;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user