SplitStrategyCommon Class Reference

This common base class provides code that is useful for writing pivot split strategies. More...

Inheritance diagram for SplitStrategyCommon:

## Public Member Functions

virtual void | getPivot (Term &pivot, Slice &slice) const
| Sets pivot to the pivot of a pivot split on slice.
virtual void | getPivot (Term &pivot, Slice &slice, const TermGrader &grader) const
| Sets pivot to the pivot of a pivot split on slice.
virtual size_t | getLabelSplitVariable (const Slice &slice) const
| Returns the variable to perform a label split on.
virtual bool | isPivotSplit () const
| If returns true, only call getPivot.
virtual bool | isLabelSplit () const
| If returns true, only call getLabelSplitVariable.
Public Member Functions inherited from SplitStrategy
virtual | ~SplitStrategy ()
virtual const char * | getName () const =0
| Returns the name of the strategy.

## Protected Member Functions

Exponent | getMedianPositiveExponentOf (Slice &slice, size_t var) const
size_t | getBestVar (const Slice &slice) const
Protected Member Functions inherited from SplitStrategy
| SplitStrategy ()
| SplitStrategy (const SplitStrategy &)
SplitStrategy & | operator= (const SplitStrategy &)
bool | operator== (const SplitStrategy &)

## Protected Attributes

Term | coVariableForGetBestVar

## Additional Inherited Members

Static Public Member Functions inherited from SplitStrategy
static unique_ptr< SplitStrategy > | createStrategy (const string &prefix)
| Returns the strategy whose name has the given prefix.

## Detailed Description

This common base class provides code that is useful for writing pivot split strategies.

Definition at line 37 of file SplitStrategy.cpp.

## Member Function Documentation

## getBestVar()

size_t SplitStrategyCommon::getBestVar | ( | const Slice & | slice | ) | const

inline protected

Definition at line 78 of file SplitStrategy.cpp.

## getLabelSplitVariable()

virtual size_t SplitStrategyCommon::getLabelSplitVariable | ( | const Slice & | slice | ) | const

inline virtual

Returns the variable to perform a label split on.

This method must only be called if isLabelSplit() returns true.

Implements SplitStrategy.

Reimplemented in MaxLabelSplit, MinLabelSplit, and VarLabelSplit.

Definition at line 48 of file SplitStrategy.cpp.

## getMedianPositiveExponentOf()

Exponent SplitStrategyCommon::getMedianPositiveExponentOf | ( | Slice & | slice,
|  | size_t | var ) const

inline protected

Definition at line 63 of file SplitStrategy.cpp.

## getPivot() [1/2]

virtual void SplitStrategyCommon::getPivot | ( | Term & | pivot,
|  | Slice & | slice ) const

inline virtual

Sets pivot to the pivot of a pivot split on slice.

The slice is not changed mathematically, but e.g. the generators may be permuted.

This method must only be called if isPivotSplit() returns true.

Implements SplitStrategy.

Reimplemented in DegreeSplit, GcdSplit, IndependencePivotSplit, MaximumSplit, MedianSplit, MinGenSplit, and MinimumSplit.

Definition at line 39 of file SplitStrategy.cpp.

## getPivot() [2/2]

virtual void SplitStrategyCommon::getPivot | ( | Term & | pivot,
|  | Slice & | slice,
|  | const TermGrader & | grader ) const

inline virtual

Sets pivot to the pivot of a pivot split on slice.

Some pivot selection strategies make use of a grading. The slice is not changed mathematically, but e.g. the generators may be permuted.

This method must only be called if isPivotSplit() returns true.

Implements SplitStrategy.

Reimplemented in DegreeSplit.

Definition at line 44 of file SplitStrategy.cpp.

## isLabelSplit()

virtual bool SplitStrategyCommon::isLabelSplit | ( |  | ) | const

inline virtual

If returns true, only call getLabelSplitVariable.

Implements SplitStrategy.

Reimplemented in LabelSplit.

Definition at line 58 of file SplitStrategy.cpp.

## isPivotSplit()

virtual bool SplitStrategyCommon::isPivotSplit | ( |  | ) | const

inline virtual

If returns true, only call getPivot.

Implements SplitStrategy.

Reimplemented in PivotSplit.

Definition at line 54 of file SplitStrategy.cpp.

## Member Data Documentation

## coVariableForGetBestVar

Term SplitStrategyCommon::coVariableForGetBestVar

mutable protected

Definition at line 77 of file SplitStrategy.cpp.

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

- src/SplitStrategy.cpp