X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FHYDROData%2FHYDROData_PriorityQueue.h;h=7983a1f783a0407a487d6f317dde205fbd5f92ab;hb=cde2ec476486fcd7c9b7b38ce814c648d73e7fd3;hp=3ca851b2791a4890935b0e5bc65f4f38439a364a;hpb=474c2cd65280d793f1c81ca528bc92e1cff988e6;p=modules%2Fhydro.git diff --git a/src/HYDROData/HYDROData_PriorityQueue.h b/src/HYDROData/HYDROData_PriorityQueue.h index 3ca851b2..7983a1f7 100644 --- a/src/HYDROData/HYDROData_PriorityQueue.h +++ b/src/HYDROData/HYDROData_PriorityQueue.h @@ -1,8 +1,4 @@ -// Copyright (C) 2007-2015 CEA/DEN, EDF R&D, OPEN CASCADE -// -// Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, -// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS -// +// Copyright (C) 2014-2015 EDF-R&D // This library is free software; you can redistribute it and/or // modify it under the terms of the GNU Lesser General Public // License as published by the Free Software Foundation; either @@ -24,7 +20,7 @@ #define HYDROData_PriorityQueue_HeaderFile #include -#include +#include #include class HYDROData_CalculationCase; @@ -37,10 +33,10 @@ enum HYDROData_PriorityType struct HYDROData_CustomRule { - Handle(HYDROData_Object) Object1; - HYDROData_PriorityType Priority; - Handle(HYDROData_Object) Object2; - HYDROData_Zone::MergeAltitudesType MergeType; + Handle(HYDROData_Entity) Object1; + HYDROData_PriorityType Priority; + Handle(HYDROData_Entity) Object2; + HYDROData_Zone::MergeType MergeType; }; typedef QList HYDROData_ListOfRules; @@ -48,22 +44,23 @@ typedef QList HYDROData_ListOfRules; class HYDROData_PriorityQueue { public: - HYDROData_PriorityQueue( HYDROData_CalculationCase* ); + HYDROData_PriorityQueue( HYDROData_CalculationCase* theCalcCase, + Standard_Integer aTag ); ~HYDROData_PriorityQueue(); - Handle_HYDROData_Object GetMostPriorityObject( const QStringList& theZoneObjects, - HYDROData_Zone::MergeAltitudesType& theMergeType ) const; + Handle_HYDROData_Entity GetMostPriorityObject( const QStringList& theZoneObjects, + HYDROData_Zone::MergeType& theMergeType ) const; - bool IsMorePriority( const Handle(HYDROData_Object)& theObj1, - const Handle(HYDROData_Object)& theObj2, - HYDROData_Zone::MergeAltitudesType& theMergeType ) const; + bool IsMorePriority( const Handle(HYDROData_Entity)& theObj1, + const Handle(HYDROData_Entity)& theObj2, + HYDROData_Zone::MergeType& theMergeType ) const; static void ClearRules( TDF_Label& theRulesLabel ); static void AddRule( TDF_Label& theRulesLabel, - const Handle(HYDROData_Object)& theObject1, + const Handle(HYDROData_Entity)& theObject1, HYDROData_PriorityType thePriority, - const Handle(HYDROData_Object)& theObject2, - HYDROData_Zone::MergeAltitudesType theMergeType ); + const Handle(HYDROData_Entity)& theObject2, + HYDROData_Zone::MergeType theMergeType ); static HYDROData_ListOfRules GetRules( const TDF_Label& theRulesLabel ); static QString DumpRules( const TDF_Label& theRulesLab ); static void DumpRulesToPython( const TDF_Label& theRulesLab, @@ -71,16 +68,16 @@ public: QStringList& theScript ); static bool GetRule( const TDF_Label& theRulesLab, int theIndex, - Handle(HYDROData_Object)& theObject1, + Handle(HYDROData_Entity)& theObject1, HYDROData_PriorityType& thePriority, - Handle(HYDROData_Object)& theObject2, - HYDROData_Zone::MergeAltitudesType& theMergeType ); + Handle(HYDROData_Entity)& theObject2, + HYDROData_Zone::MergeType& theMergeType ); private: - typedef QMap MapNameToObject; + typedef QMap MapNameToObject; - HYDROData_SequenceOfObjects myGeomObjects; ///< the ordered list of objects (default priority) - MapNameToObject myNames; ///< the map of name to object - HYDROData_ListOfRules myRules; ///< the list of rules + HYDROData_SequenceOfObjects myObjects; ///< the ordered list of objects (default priority) + MapNameToObject myNames; ///< the map of name to object + HYDROData_ListOfRules myRules; ///< the list of rules }; #endif