Web Analytics Made Easy - Statcounter
Skip to content

Class SBCFunctorPredicateOr0#

ClassList > SBCFunctorPredicateOr0

This class describes a predicate that is true if at least one of two predicates istrue __More...

  • #include <SBCFunctorPredicateOr.hpp>

Inherits the following classes: SBCFunctorPredicate0

Public Functions#

Type Name
SBCFunctorPredicateOr0 (const SBCFunctorPredicate0 * firstPredicate, const SBCFunctorPredicate0 * secondPredicate)
Builds the functor predicate. The input functors are cloned internally.
virtual SBCFunctorPredicateOr0 * clone () override const
Clones the functor.
virtual bool operator() () override
Performs the predicate's operations and returns the result.
virtual bool operator() () override const
Performs the predicate's operations and returns the result.
virtual ~SBCFunctorPredicateOr0 ()
Destructor.

Detailed Description#

See also: SBCFunctorPredicateOrOr0

Public Functions Documentation#

function SBCFunctorPredicateOr0#

Builds the functor predicate. The input functors are cloned internally.

SBCFunctorPredicateOr0::SBCFunctorPredicateOr0 (
    const SBCFunctorPredicate0 * firstPredicate,
    const SBCFunctorPredicate0 * secondPredicate
) 

Constructs an SBCFunctorPredicateOr0 from two predicate functors.

The provided predicates are cloned internally. The resulting predicate evaluates to true if either of the cloned predicates evaluates to true.

Parameters:

  • firstPredicate Pointer to the first predicate functor to be cloned.
  • secondPredicate Pointer to the second predicate functor to be cloned.

function clone#

Clones the functor.

virtual SBCFunctorPredicateOr0 * SBCFunctorPredicateOr0::clone () override const

Creates a copy of this predicate.

The returned predicate is a new instance with its own clones of the underlying predicate functors.

Returns:

A pointer to a newly allocated SBCFunctorPredicateOr0 that is a copy of this object.

Implements SBCFunctor::clone


function operator()#

Performs the predicate's operations and returns the result.

virtual bool SBCFunctorPredicateOr0::operator() () override

Evaluates the predicate.

Returns true if either of the two underlying predicates evaluates to true.

Returns:

The result of the logical OR of the two predicate evaluations.


function operator()#

Performs the predicate's operations and returns the result.

virtual bool SBCFunctorPredicateOr0::operator() () override const

Evaluates the predicate (const overload).

Returns true if either of the two underlying predicates evaluates to true.

Returns:

The result of the logical OR of the two predicate evaluations.


function ~SBCFunctorPredicateOr0#

Destructor.

virtual SBCFunctorPredicateOr0::~SBCFunctorPredicateOr0 () 

Destructor for SBCFunctorPredicateOr0.

Releases any resources held by the predicate, including the cloned predicate objects.