MSG(MYDEBUG,"GetFamiliesByEntity(...)");
TEntity2FamilySet anEntity2FamilySet;
- typedef map<TInt,PFamilyInfo> TId2Family;
+ typedef std::map<TInt,PFamilyInfo> TId2Family;
TId2Family anId2Family;
TFamilyInfoSet::const_iterator anIter = theFamilyInfoSet.begin();
for(; anIter != theFamilyInfoSet.end(); anIter++){
if(!anId2Family.empty()){
typedef std::map<TInt,TInt> TFamilyID2Size;
- typedef map<EEntiteMaillage,TFamilyID2Size> TEntity2FamilyID;
+ typedef std::map<EEntiteMaillage,TFamilyID2Size> TEntity2FamilyID;
TEntity2FamilyID anEntity2FamilyID;
if(!theEntity2TGeom2ElemInfo.empty()){
TErr* theErr,
EModeSwitch theMode)
{
- INITMSG(MYDEBUG,"GetKey2Gauss - theMode = "<<theMode<<endl);
+ INITMSG(MYDEBUG,"GetKey2Gauss - theMode = "<<theMode<<std::endl);
TKey2Gauss aKey2Gauss;
TInt aNbGauss = theWrapper->GetNbGauss(theErr);
for(TInt anId = 1; anId <= aNbGauss; anId++){
INITMSG(MYDEBUG,
"- aGeom = "<<aGeom<<
"; aName = '"<<aName<<"'"<<
- endl);
+ std::endl);
#endif
}
TErr* theErr,
EModeProfil theMode)
{
- INITMSG(MYDEBUG,"GetMKey2Profile - theMode = "<<theMode<<endl);
+ INITMSG(MYDEBUG,"GetMKey2Profile - theMode = "<<theMode<<std::endl);
TKey2Profile aKey2Profile;
TInt aNbProfiles = theWrapper->GetNbProfiles(theErr);
for(TInt anId = 1; anId <= aNbProfiles; anId++){
INITMSG(MYDEBUG,
"- aName = '"<<aName<<"'"<<
" : "<<
- endl);
- TInt aNbElem = anInfo->myElemNum.size();
+ std::endl);
+ TInt aNbElem = anInfo->GetSize();
for(TInt iElem = 0; iElem < aNbElem; iElem++){
ADDMSG(MYVALUEDEBUG,anInfo->GetElemNum(iElem)<<", ");
}
- ADDMSG(MYVALUEDEBUG,endl);
+ ADDMSG(MYVALUEDEBUG, std::endl);
#endif
}
return TMKey2Profile(theMode,aKey2Profile);
}
+ //---------------------------------------------------------------
+ EEntiteMaillage
+ GetEntityByFamilyId(PGrilleInfo& theInfo,TInt theId){
+ TElemNum::iterator aNodeFamIter = (theInfo->myFamNumNode).begin();
+ for(;aNodeFamIter != (theInfo->myFamNumNode).end(); aNodeFamIter++){
+ if(theId == *aNodeFamIter)
+ return eNOEUD;
+ }
+ TElemNum::iterator aCellFamIter = (theInfo->myFamNum).begin();
+ for(;aCellFamIter != (theInfo->myFamNum).end(); aCellFamIter++){
+ if(theId == *aCellFamIter)
+ return eMAILLE;
+ }
+ EXCEPTION(std::runtime_error, "GetEntityByFamilyId - fails");
+ return EEntiteMaillage(-1);
+ }
+
+ TFamilyID2NbCells
+ GetFamilyID2NbCells(PGrilleInfo& theInfo){
+ TFamilyID2NbCells aFamily2NbCells;
+ TInt aNbNodes = theInfo->myFamNumNode.size();
+ TInt aNbCells = theInfo->myFamNum.size();
+ for(TInt i=0; i<aNbNodes; i++) aFamily2NbCells[theInfo->GetFamNumNode(i)] = 0;
+ for(TInt i=0; i<aNbCells; i++) aFamily2NbCells[theInfo->GetFamNum(i)] = 0;
+ for(TInt i=0; i<aNbNodes; i++) aFamily2NbCells[theInfo->GetFamNumNode(i)] += 1;
+ for(TInt i=0; i<aNbCells; i++) aFamily2NbCells[theInfo->GetFamNum(i)] += 1;
+ return aFamily2NbCells;
+ }
}