LibreOffice Module sc (master) 1
Public Member Functions | Private Types | Private Member Functions | Private Attributes | List of all members
ScRecursionHelper Class Reference

#include <recursionhelper.hxx>

Collaboration diagram for ScRecursionHelper:
[legend]

Public Member Functions

 ScRecursionHelper ()
 
sal_uInt16 GetRecursionCount () const
 
void IncRecursionCount ()
 
void DecRecursionCount ()
 
sal_uInt16 GetDepComputeLevel () const
 
void IncDepComputeLevel ()
 
void DecDepComputeLevel ()
 
bool IsInRecursionReturn () const
 A pure recursion return, no iteration. More...
 
void SetInRecursionReturn (bool b)
 
bool IsDoingRecursion () const
 
void SetDoingRecursion (bool b)
 
void Insert (ScFormulaCell *p, bool bOldRunning, const ScFormulaResult &rRes)
 
bool IsInIterationReturn () const
 
void SetInIterationReturn (bool b)
 
bool IsDoingIteration () const
 
sal_uInt16 GetIteration () const
 
bool & GetConvergingReference ()
 
void StartIteration ()
 
void ResumeIteration ()
 
void IncIteration ()
 
void EndIteration ()
 
const ScFormulaRecursionList::iterator & GetLastIterationStart () const
 
ScFormulaRecursionList::iterator GetIterationStart ()
 
ScFormulaRecursionList::iterator GetIterationEnd ()
 
bool IsInReturn () const
 Any return, recursion or iteration, iteration is always coupled with recursion. More...
 
const ScFormulaRecursionListGetList () const
 
ScFormulaRecursionListGetList ()
 
ScRecursionInIterationStackGetRecursionInIterationStack ()
 
void Clear ()
 
bool PushFormulaGroup (ScFormulaCell *pCell)
 Detects a simple cycle involving formula-groups and singleton formula-cells. More...
 
void PopFormulaGroup ()
 
bool AnyCycleMemberInDependencyEvalMode (const ScFormulaCell *pCell)
 
bool AnyParentFGInCycle ()
 
void SetFormulaGroupDepEvalMode (bool bSet)
 
void AbortDependencyComputation ()
 
bool IsAbortingDependencyComputation () const
 
void AddTemporaryGroupCell (ScFormulaCell *cell)
 
void CleanTemporaryGroupCells ()
 
void SetFormulaGroupSet (o3tl::sorted_vector< ScFormulaCellGroup * > *pSet)
 
bool HasFormulaGroupSet () const
 
bool CheckFGIndependence (ScFormulaCellGroup *pFG)
 
void SetGroupsIndependent (bool bSet)
 
bool AreGroupsIndependent ()
 

Private Types

typedef ::std::stack< ScFormulaCell * > ScRecursionInIterationStack
 

Private Member Functions

void Init ()
 
void ResetIteration ()
 

Private Attributes

ScFormulaRecursionList aRecursionFormulas
 
ScFormulaRecursionList::iterator aInsertPos
 
ScFormulaRecursionList::iterator aLastIterationStart
 
ScRecursionInIterationStack aRecursionInIterationStack
 
std::vector< ScFormulaCell * > aFGList
 
std::vector< bool > aInDependencyEvalMode
 
sal_uInt16 nRecursionCount
 
sal_uInt16 nIteration
 
sal_uInt16 nDependencyComputationLevel
 
bool bInRecursionReturn
 
bool bDoingRecursion
 
bool bInIterationReturn
 
bool bConverging
 
bool bGroupsIndependent
 
bool bAbortingDependencyComputation
 
std::vector< ScFormulaCell * > aTemporaryGroupCells
 
o3tl::sorted_vector< ScFormulaCellGroup * > * pFGSet
 

Detailed Description

Definition at line 45 of file recursionhelper.hxx.

Member Typedef Documentation

◆ ScRecursionInIterationStack

Definition at line 47 of file recursionhelper.hxx.

Constructor & Destructor Documentation

◆ ScRecursionHelper()

ScRecursionHelper::ScRecursionHelper ( )

Definition at line 31 of file recursionhelper.cxx.

References bGroupsIndependent, Init(), and pFGSet.

Member Function Documentation

◆ AbortDependencyComputation()

void ScRecursionHelper::AbortDependencyComputation ( )

◆ AddTemporaryGroupCell()

void ScRecursionHelper::AddTemporaryGroupCell ( ScFormulaCell cell)

Definition at line 216 of file recursionhelper.cxx.

References aTemporaryGroupCells.

◆ AnyCycleMemberInDependencyEvalMode()

bool ScRecursionHelper::AnyCycleMemberInDependencyEvalMode ( const ScFormulaCell pCell)

◆ AnyParentFGInCycle()

bool ScRecursionHelper::AnyParentFGInCycle ( )

Definition at line 178 of file recursionhelper.cxx.

References aFGList.

Referenced by ScFormulaCell::Interpret().

◆ AreGroupsIndependent()

bool ScRecursionHelper::AreGroupsIndependent ( )
inline

◆ CheckFGIndependence()

bool ScRecursionHelper::CheckFGIndependence ( ScFormulaCellGroup pFG)

◆ CleanTemporaryGroupCells()

void ScRecursionHelper::CleanTemporaryGroupCells ( )

Definition at line 221 of file recursionhelper.cxx.

References aTemporaryGroupCells, and GetRecursionCount().

◆ Clear()

void ScRecursionHelper::Clear ( )

Definition at line 95 of file recursionhelper.cxx.

References aRecursionFormulas, aRecursionInIterationStack, and Init().

Referenced by ScFormulaCell::Interpret().

◆ DecDepComputeLevel()

void ScRecursionHelper::DecDepComputeLevel ( )

◆ DecRecursionCount()

void ScRecursionHelper::DecRecursionCount ( )
inline

Definition at line 77 of file recursionhelper.hxx.

References nRecursionCount.

◆ EndIteration()

void ScRecursionHelper::EndIteration ( )

◆ GetConvergingReference()

bool & ScRecursionHelper::GetConvergingReference ( )
inline

Definition at line 94 of file recursionhelper.hxx.

References bConverging.

Referenced by ScFormulaCell::Interpret().

◆ GetDepComputeLevel()

sal_uInt16 ScRecursionHelper::GetDepComputeLevel ( ) const
inline

Definition at line 78 of file recursionhelper.hxx.

References nDependencyComputationLevel.

Referenced by ScFormulaCell::Interpret().

◆ GetIteration()

sal_uInt16 ScRecursionHelper::GetIteration ( ) const
inline

Definition at line 93 of file recursionhelper.hxx.

References nIteration.

Referenced by ScFormulaCell::Interpret(), and ScFormulaCell::InterpretTail().

◆ GetIterationEnd()

ScFormulaRecursionList::iterator ScRecursionHelper::GetIterationEnd ( )

Definition at line 90 of file recursionhelper.cxx.

References aRecursionFormulas.

Referenced by EndIteration(), Init(), ScFormulaCell::Interpret(), and ResetIteration().

◆ GetIterationStart()

ScFormulaRecursionList::iterator ScRecursionHelper::GetIterationStart ( )

◆ GetLastIterationStart()

const ScFormulaRecursionList::iterator & ScRecursionHelper::GetLastIterationStart ( ) const
inline

Definition at line 100 of file recursionhelper.hxx.

References aLastIterationStart.

Referenced by ScFormulaCell::Interpret().

◆ GetList() [1/2]

ScFormulaRecursionList & ScRecursionHelper::GetList ( )
inline

Definition at line 107 of file recursionhelper.hxx.

References aRecursionFormulas.

◆ GetList() [2/2]

const ScFormulaRecursionList & ScRecursionHelper::GetList ( ) const
inline

Definition at line 106 of file recursionhelper.hxx.

References aRecursionFormulas.

Referenced by ScFormulaCell::Interpret().

◆ GetRecursionCount()

sal_uInt16 ScRecursionHelper::GetRecursionCount ( ) const
inline

Definition at line 75 of file recursionhelper.hxx.

References nRecursionCount.

Referenced by CleanTemporaryGroupCells(), and ScFormulaCell::Interpret().

◆ GetRecursionInIterationStack()

ScRecursionInIterationStack & ScRecursionHelper::GetRecursionInIterationStack ( )
inline

Definition at line 108 of file recursionhelper.hxx.

References aRecursionInIterationStack.

Referenced by ScFormulaCell::Interpret().

◆ HasFormulaGroupSet()

bool ScRecursionHelper::HasFormulaGroupSet ( ) const
inline

◆ IncDepComputeLevel()

void ScRecursionHelper::IncDepComputeLevel ( )

◆ IncIteration()

void ScRecursionHelper::IncIteration ( )

Definition at line 74 of file recursionhelper.cxx.

References nIteration.

Referenced by ScFormulaCell::Interpret().

◆ IncRecursionCount()

void ScRecursionHelper::IncRecursionCount ( )
inline

Definition at line 76 of file recursionhelper.hxx.

References nRecursionCount.

◆ Init()

void ScRecursionHelper::Init ( void  )
private

◆ Insert()

void ScRecursionHelper::Insert ( ScFormulaCell p,
bool  bOldRunning,
const ScFormulaResult rRes 
)

Definition at line 46 of file recursionhelper.cxx.

References aInsertPos, aRecursionFormulas, and p.

Referenced by ScFormulaCell::Interpret().

◆ IsAbortingDependencyComputation()

bool ScRecursionHelper::IsAbortingDependencyComputation ( ) const
inline

◆ IsDoingIteration()

bool ScRecursionHelper::IsDoingIteration ( ) const
inline

Definition at line 92 of file recursionhelper.hxx.

References nIteration.

Referenced by ScFormulaCell::Interpret().

◆ IsDoingRecursion()

bool ScRecursionHelper::IsDoingRecursion ( ) const
inline

Definition at line 85 of file recursionhelper.hxx.

References bDoingRecursion.

Referenced by ScFormulaCell::Interpret().

◆ IsInIterationReturn()

bool ScRecursionHelper::IsInIterationReturn ( ) const
inline

Definition at line 90 of file recursionhelper.hxx.

References bInIterationReturn.

Referenced by ScFormulaCell::Interpret().

◆ IsInRecursionReturn()

bool ScRecursionHelper::IsInRecursionReturn ( ) const
inline

A pure recursion return, no iteration.

Definition at line 82 of file recursionhelper.hxx.

References bInIterationReturn, and bInRecursionReturn.

Referenced by ScFormulaCell::CheckComputeDependencies(), and ScFormulaCell::Interpret().

◆ IsInReturn()

bool ScRecursionHelper::IsInReturn ( ) const
inline

Any return, recursion or iteration, iteration is always coupled with recursion.

Definition at line 105 of file recursionhelper.hxx.

References bInRecursionReturn.

Referenced by ScFormulaCell::Interpret(), and ScFormulaCell::InterpretTail().

◆ PopFormulaGroup()

void ScRecursionHelper::PopFormulaGroup ( )

◆ PushFormulaGroup()

bool ScRecursionHelper::PushFormulaGroup ( ScFormulaCell pCell)

Detects a simple cycle involving formula-groups and singleton formula-cells.

Definition at line 114 of file recursionhelper.cxx.

References aFGList, aInDependencyEvalMode, ScFormulaCell::GetSeenInPath(), and ScFormulaCell::SetSeenInPath().

Referenced by ScFormulaGroupCycleCheckGuard::ScFormulaGroupCycleCheckGuard().

◆ ResetIteration()

void ScRecursionHelper::ResetIteration ( )
private

Definition at line 24 of file recursionhelper.cxx.

References aLastIterationStart, bConverging, GetIterationEnd(), and nIteration.

Referenced by EndIteration(), and Init().

◆ ResumeIteration()

void ScRecursionHelper::ResumeIteration ( )

◆ SetDoingRecursion()

void ScRecursionHelper::SetDoingRecursion ( bool  b)
inline

Definition at line 86 of file recursionhelper.hxx.

References bDoingRecursion.

Referenced by ScFormulaCell::Interpret().

◆ SetFormulaGroupDepEvalMode()

void ScRecursionHelper::SetFormulaGroupDepEvalMode ( bool  bSet)

◆ SetFormulaGroupSet()

void ScRecursionHelper::SetFormulaGroupSet ( o3tl::sorted_vector< ScFormulaCellGroup * > *  pSet)
inline

◆ SetGroupsIndependent()

void ScRecursionHelper::SetGroupsIndependent ( bool  bSet)
inline

◆ SetInIterationReturn()

void ScRecursionHelper::SetInIterationReturn ( bool  b)

◆ SetInRecursionReturn()

void ScRecursionHelper::SetInRecursionReturn ( bool  b)

◆ StartIteration()

void ScRecursionHelper::StartIteration ( )

Member Data Documentation

◆ aFGList

std::vector< ScFormulaCell* > ScRecursionHelper::aFGList
private

◆ aInDependencyEvalMode

std::vector< bool > ScRecursionHelper::aInDependencyEvalMode
private

◆ aInsertPos

ScFormulaRecursionList::iterator ScRecursionHelper::aInsertPos
private

Definition at line 49 of file recursionhelper.hxx.

Referenced by Init(), Insert(), and SetInRecursionReturn().

◆ aLastIterationStart

ScFormulaRecursionList::iterator ScRecursionHelper::aLastIterationStart
private

◆ aRecursionFormulas

ScFormulaRecursionList ScRecursionHelper::aRecursionFormulas
private

◆ aRecursionInIterationStack

ScRecursionInIterationStack ScRecursionHelper::aRecursionInIterationStack
private

Definition at line 51 of file recursionhelper.hxx.

Referenced by Clear(), and GetRecursionInIterationStack().

◆ aTemporaryGroupCells

std::vector< ScFormulaCell* > ScRecursionHelper::aTemporaryGroupCells
private

Definition at line 66 of file recursionhelper.hxx.

Referenced by AddTemporaryGroupCell(), and CleanTemporaryGroupCells().

◆ bAbortingDependencyComputation

bool ScRecursionHelper::bAbortingDependencyComputation
private

◆ bConverging

bool ScRecursionHelper::bConverging
private

Definition at line 63 of file recursionhelper.hxx.

Referenced by GetConvergingReference(), ResetIteration(), and StartIteration().

◆ bDoingRecursion

bool ScRecursionHelper::bDoingRecursion
private

Definition at line 61 of file recursionhelper.hxx.

Referenced by Init(), IsDoingRecursion(), and SetDoingRecursion().

◆ bGroupsIndependent

bool ScRecursionHelper::bGroupsIndependent
private

◆ bInIterationReturn

bool ScRecursionHelper::bInIterationReturn
private

◆ bInRecursionReturn

bool ScRecursionHelper::bInRecursionReturn
private

Definition at line 60 of file recursionhelper.hxx.

Referenced by Init(), IsInRecursionReturn(), IsInReturn(), and SetInRecursionReturn().

◆ nDependencyComputationLevel

sal_uInt16 ScRecursionHelper::nDependencyComputationLevel
private

◆ nIteration

sal_uInt16 ScRecursionHelper::nIteration
private

◆ nRecursionCount

sal_uInt16 ScRecursionHelper::nRecursionCount
private

Definition at line 56 of file recursionhelper.hxx.

Referenced by DecRecursionCount(), GetRecursionCount(), IncRecursionCount(), and Init().

◆ pFGSet

o3tl::sorted_vector< ScFormulaCellGroup* >* ScRecursionHelper::pFGSet
private

The documentation for this class was generated from the following files: