Class containing set of hypotheses. More...
#include <SMESHGUI_Hypotheses.h>
Public Member Functions | |
| HypothesesSet (const QString &) | |
| HypothesesSet (const QString &, const QStringList &, const QStringList &) | |
| QString | name () const |
| void | set (bool, const QStringList &) |
| int | count (bool) const |
| void | setIsCustom (bool) |
| bool | getIsCustom () const |
| int | maxDim () const |
| bool | isAlgo () const |
| void | init (bool) |
| bool | more () const |
| void | next () |
| QString | current () const |
Private Member Functions | |
| QStringList * | list (bool) const |
| QStringList * | list () const |
Private Attributes | |
| QString | myHypoSetName |
| QStringList | myHypoList |
| QStringList | myAlgoList |
| bool | myIsAlgo |
| bool | myIsCustom |
| int | myIndex |
Class containing set of hypotheses.
Actually it contains list of hypo types
Definition at line 195 of file SMESHGUI_Hypotheses.h.
| HypothesesSet::HypothesesSet | ( | const QString & | theSetName | ) |
Definition at line 697 of file SMESHGUI_Hypotheses.cxx.
: myHypoSetName( theSetName ), myIsAlgo( false ), myIsCustom( false ) { }
| HypothesesSet::HypothesesSet | ( | const QString & | theSetName, |
| const QStringList & | theHypoList, | ||
| const QStringList & | theAlgoList | ||
| ) |
Definition at line 704 of file SMESHGUI_Hypotheses.cxx.
: myHypoSetName( theSetName ), myHypoList( theHypoList ), myAlgoList( theAlgoList ), myIsAlgo( false ), myIsCustom( false ) { }
Definition at line 735 of file SMESHGUI_Hypotheses.cxx.
References list().
Referenced by SMESH.GetHypothesesSets().
{
return list(isAlgo)->count();
}
| QString HypothesesSet::current | ( | ) | const |
Definition at line 761 of file SMESHGUI_Hypotheses.cxx.
References list(), and myIndex.
Referenced by maxDim(), and SMESHGUI_MeshOp.processSet().
| bool HypothesesSet::getIsCustom | ( | ) | const |
Definition at line 771 of file SMESHGUI_Hypotheses.cxx.
References myIsCustom.
Referenced by SMESH.mangledHypoSetName().
{
return myIsCustom;
}
| void HypothesesSet::init | ( | bool | isAlgo | ) |
Definition at line 745 of file SMESHGUI_Hypotheses.cxx.
References isAlgo(), myIndex, and myIsAlgo.
Referenced by maxDim(), and SMESHGUI_MeshOp.onHypoSet().
| bool HypothesesSet::isAlgo | ( | ) | const |
Definition at line 740 of file SMESHGUI_Hypotheses.cxx.
References myIsAlgo.
Referenced by init(), maxDim(), and SMESHGUI_MeshOp.processSet().
{
return myIsAlgo;
}
| QStringList * HypothesesSet::list | ( | ) | const [private] |
| QStringList * HypothesesSet::list | ( | bool | is_algo | ) | const [private] |
Definition at line 715 of file SMESHGUI_Hypotheses.cxx.
References myAlgoList, and myHypoList.
{
return const_cast<QStringList*>( &( is_algo ? myAlgoList : myHypoList ) );
}
| int HypothesesSet::maxDim | ( | ) | const |
Definition at line 776 of file SMESHGUI_Hypotheses.cxx.
References current(), SMESH.GetHypothesisData(), init(), isAlgo(), more(), and next().
Referenced by SMESH.GetHypothesesSets(), and SMESH.mangledHypoSetName().
{
HypothesesSet * thisSet = (HypothesesSet*) this;
int dim = -1;
for ( int isAlgo = 0; isAlgo < 2; ++isAlgo )
{
thisSet->init( isAlgo );
while ( thisSet->next(), thisSet->more() )
if ( HypothesisData* hypData = SMESH::GetHypothesisData( thisSet->current() ))
for ( int i = 0; i < hypData->Dim.count(); ++i )
dim = qMax( dim, hypData->Dim[i] );
}
return dim;
}
| bool HypothesesSet::more | ( | ) | const |
Definition at line 751 of file SMESHGUI_Hypotheses.cxx.
References list(), and myIndex.
Referenced by maxDim(), and SMESHGUI_MeshOp.processSet().
| QString HypothesesSet::name | ( | ) | const |
Definition at line 725 of file SMESHGUI_Hypotheses.cxx.
References myHypoSetName.
Referenced by SMESH.GetHypothesesSet(), and SMESH.mangledHypoSetName().
{
return myHypoSetName;
}
| void HypothesesSet::next | ( | ) |
Definition at line 756 of file SMESHGUI_Hypotheses.cxx.
References myIndex.
Referenced by maxDim(), and SMESHGUI_MeshOp.processSet().
{
myIndex++;
}
| void HypothesesSet::set | ( | bool | isAlgo, |
| const QStringList & | lst | ||
| ) |
Definition at line 730 of file SMESHGUI_Hypotheses.cxx.
References list().
Referenced by SMESHGUI_XmlHandler.startElement().
{
*list(isAlgo) = lst;
}
| void HypothesesSet::setIsCustom | ( | bool | isCustom | ) |
Definition at line 766 of file SMESHGUI_Hypotheses.cxx.
References myIsCustom.
{
myIsCustom = isCustom;
}
QStringList HypothesesSet.myAlgoList [private] |
Definition at line 224 of file SMESHGUI_Hypotheses.h.
Referenced by list().
QStringList HypothesesSet.myHypoList [private] |
Definition at line 224 of file SMESHGUI_Hypotheses.h.
Referenced by list().
QString HypothesesSet.myHypoSetName [private] |
Definition at line 223 of file SMESHGUI_Hypotheses.h.
Referenced by name().
int HypothesesSet.myIndex [private] |
bool HypothesesSet.myIsAlgo [private] |
Definition at line 225 of file SMESHGUI_Hypotheses.h.
bool HypothesesSet.myIsCustom [private] |
Definition at line 225 of file SMESHGUI_Hypotheses.h.
Referenced by getIsCustom(), and setIsCustom().