tbb::interface6::internal::filter_node Class Referenceabstract

Abstract base class that represents a node in a parse tree underlying a filter_t. More...

`#include <pipeline.h>`

Inheritance diagram for tbb::interface6::internal::filter_node:
Collaboration diagram for tbb::interface6::internal::filter_node:

## Public Member Functions

virtual void | add_to (pipeline &)=0
| Add concrete_filter to pipeline. More...
void | add_ref ()
| Increment reference count. More...
void | remove_ref ()
| Decrement reference count and delete if it becomes zero. More...
virtual | ~filter_node ()

## Protected Member Functions

| filter_node ()

## Private Attributes

tbb::atomic< intptr_t > | ref_count

## Additional Inherited Members

Private Member Functions inherited from tbb::internal::no_copy
| no_copy (const no_copy &)=delete
| no_copy ()=default

## Detailed Description

Abstract base class that represents a node in a parse tree underlying a filter_t.

These nodes are always heap-allocated and can be shared by filter_t objects.

Definition at line 528 of file pipeline.h.

## Constructor & Destructor Documentation

## filter_node()

tbb::interface6::internal::filter_node::filter_node | ( |  | ) |

inline protected

Definition at line 532 of file pipeline.h.

{
ref_count = 0;
#ifdef __TBB_TEST_FILTER_NODE_COUNT
++(__TBB_TEST_FILTER_NODE_COUNT);
#endif
}
tbb::interface6::internal::filter_node::ref_count
tbb::atomic< intptr_t > ref_count
Definition: pipeline.h:530

References ref_count.

## ~filter_node()

virtual tbb::interface6::internal::filter_node::~filter_node | ( |  | ) |

inline virtual

Definition at line 549 of file pipeline.h.

{
#ifdef __TBB_TEST_FILTER_NODE_COUNT
--(__TBB_TEST_FILTER_NODE_COUNT);
#endif
}

## Member Function Documentation

## add_ref()

void tbb::interface6::internal::filter_node::add_ref | ( |  | ) |

inline

Increment reference count.

Definition at line 542 of file pipeline.h.

{ ++ref_count; }

References ref_count.

Referenced by tbb::interface6::internal::filter_node_join::filter_node_join(), tbb::interface6::filter_t< T, U >::filter_t(), and tbb::interface6::filter_t< T, U >::operator=().

Here is the caller graph for this function:

## add_to()

virtual void tbb::interface6::internal::filter_node::add_to | ( | pipeline & |  | ) |

pure virtual

Add concrete_filter to pipeline.

Implemented in tbb::interface6::internal::filter_node_join, and tbb::interface6::internal::filter_node_leaf< T, U, Body >.

Referenced by tbb::interface6::internal::filter_node_join::add_to(), and tbb::interface6::internal::pipeline_proxy::pipeline_proxy().

Here is the caller graph for this function:

## remove_ref()

void tbb::interface6::internal::filter_node::remove_ref | ( |  | ) |

inline

Decrement reference count and delete if it becomes zero.

Definition at line 544 of file pipeline.h.

{
__TBB_ASSERT(ref_count>0,"ref_count underflow");
if( --ref_count==0 )
delete this;
}
__TBB_ASSERT
#define __TBB_ASSERT(predicate, comment)
No-op version of __TBB_ASSERT.
Definition: tbb_stddef.h:165

References __TBB_ASSERT, and ref_count.

Referenced by tbb::interface6::filter_t< T, U >::clear(), tbb::interface6::filter_t< T, U >::operator=(), tbb::interface6::internal::filter_node_join::~filter_node_join(), and tbb::interface6::filter_t< T, U >::~filter_t().

Here is the caller graph for this function:

## Member Data Documentation

## ref_count

tbb::atomic<intptr_t> tbb::interface6::internal::filter_node::ref_count

private

Count must be atomic because it is hidden state for user, but might be shared by threads.

Definition at line 530 of file pipeline.h.

Referenced by add_ref(), filter_node(), and remove_ref().

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

- pipeline.h

Copyright © 2005-2020 Intel Corporation. All Rights Reserved.

Intel, Pentium, Intel Xeon, Itanium, Intel XScale and VTune are registered trademarks or trademarks of Intel Corporation or its subsidiaries in the United States and other countries.

* Other names and brands may be claimed as the property of others.