Intel(R) Threading Building Blocks Doxygen Documentation  version 4.2.3
tbb::flow::interface10::internal::function_input< Input, Output, Policy, A > Class Template Referenceabstract

Implements methods for a function node that takes a type Input as input and sends. More...

#include <flow_graph.h>

Inheritance diagram for tbb::flow::interface10::internal::function_input< Input, Output, Policy, A >:
Collaboration diagram for tbb::flow::interface10::internal::function_input< Input, Output, Policy, A >:

Public Types

typedef Input input_type
 
typedef Output output_type
 
typedef function_body< input_type, output_typefunction_body_type
 
typedef function_input< Input, Output, Policy, A > my_class
 
typedef function_input_base< Input, Policy, A, my_classbase_type
 
typedef function_input_queue< input_type, A > input_queue_type
 
- Public Types inherited from tbb::flow::interface10::internal::function_input_base< Input, Policy, A, function_input< Input, Output, Policy, A > >
typedef Input input_type
 The input type of this receiver. More...
 
typedef receiver< input_type >::predecessor_type predecessor_type
 
typedef predecessor_cache< input_type, null_mutexpredecessor_cache_type
 
typedef function_input_queue< input_type, A > input_queue_type
 
typedef A::template rebind< input_queue_type >::other queue_allocator_type
 
- Public Types inherited from tbb::flow::interface10::receiver< Input >
typedef Input input_type
 The input type of this receiver. More...
 
typedef internal::async_helpers< Input >::filtered_type filtered_type
 
- Public Types inherited from tbb::flow::interface10::internal::untyped_receiver
typedef untyped_sender predecessor_type
 The predecessor type for this node. More...
 

Public Member Functions

template<typename Body >
 function_input (graph &g, size_t max_concurrency,)
 
 function_input (const function_input &src)
 Copy constructor. More...
 
 ~function_input ()
 
template<typename Body >
Body copy_function_object ()
 
output_type apply_body_impl (const input_type &i)
 
taskapply_body_impl_bypass (const input_type &i)
 
- Public Member Functions inherited from tbb::flow::interface10::internal::function_input_base< Input, Policy, A, function_input< Input, Output, Policy, A > >
 __TBB_STATIC_ASSERT (!((internal::has_policy< queueing, Policy >::value) &&(internal::has_policy< rejecting, Policy >::value)), "queueing and rejecting policies can't be specified simultaneously")
 
 function_input_base (graph &g, __TBB_FLOW_GRAPH_PRIORITY_ARG1(size_t max_concurrency, node_priority_t priority))
 Constructor for function_input_base. More...
 
 function_input_base (const function_input_base &src)
 Copy constructor. More...
 
virtual ~function_input_base ()
 Destructor. More...
 
tasktry_put_task (const input_type &t) __TBB_override
 Put item to successor; return task to run the successor if possible. More...
 
bool register_predecessor (predecessor_type &src) __TBB_override
 Adds src to the list of cached predecessors. More...
 
bool remove_predecessor (predecessor_type &src) __TBB_override
 Removes src from the list of cached predecessors. More...
 
- Public Member Functions inherited from tbb::flow::interface10::receiver< Input >
bool try_put (const typename internal::async_helpers< Input >::filtered_type &t)
 Put an item to the receiver. More...
 
bool try_put (const typename internal::async_helpers< Input >::async_type &t)
 
- Public Member Functions inherited from tbb::flow::interface10::internal::untyped_receiver
virtual ~untyped_receiver ()
 Destructor. More...
 
template<typename X >
bool try_put (const X &t)
 Put an item to the receiver. More...
 

Protected Member Functions

void reset_function_input (reset_flags f)
 
virtual broadcast_cache< output_type > & successors ()=0
 
- Protected Member Functions inherited from tbb::flow::interface10::internal::function_input_base< Input, Policy, A, function_input< Input, Output, Policy, A > >
void reset_function_input_base (reset_flags f)
 
void reset_receiver (reset_flags f) __TBB_override
 put receiver back in initial state More...
 
graphgraph_reference () __TBB_override
 
tasktry_get_postponed_task (const input_type &i)
 
- Protected Member Functions inherited from tbb::flow::interface10::receiver< Input >
virtual tasktry_put_task_wrapper (const void *p, bool is_async) __TBB_override
 
- Protected Member Functions inherited from tbb::flow::interface10::internal::untyped_receiver
template<typename X >
tasktry_put_task (const X &t)
 
virtual bool is_continue_receiver ()
 

Protected Attributes

function_body_typemy_body
 
function_body_typemy_init_body
 
- Protected Attributes inherited from tbb::flow::interface10::internal::function_input_base< Input, Policy, A, function_input< Input, Output, Policy, A > >
graphmy_graph_ref
 
const size_t my_max_concurrency
 
size_t my_concurrency
 
input_queue_typemy_queue
 
predecessor_cache< input_type, null_mutexmy_predecessors
 

Detailed Description

template<typename Input, typename Output, typename Policy, typename A>
class tbb::flow::interface10::internal::function_input< Input, Output, Policy, A >

Implements methods for a function node that takes a type Input as input and sends.

Definition at line 425 of file flow_graph.h.

Member Typedef Documentation

◆ base_type

template<typename Input, typename Output, typename Policy, typename A>
typedef function_input_base<Input, Policy, A, my_class> tbb::flow::interface10::internal::function_input< Input, Output, Policy, A >::base_type

Definition at line 431 of file flow_graph.h.

◆ function_body_type

template<typename Input, typename Output, typename Policy, typename A>
typedef function_body<input_type, output_type> tbb::flow::interface10::internal::function_input< Input, Output, Policy, A >::function_body_type

Definition at line 429 of file flow_graph.h.

◆ input_queue_type

template<typename Input, typename Output, typename Policy, typename A>
typedef function_input_queue<input_type, A> tbb::flow::interface10::internal::function_input< Input, Output, Policy, A >::input_queue_type

Definition at line 432 of file flow_graph.h.

◆ input_type

template<typename Input, typename Output, typename Policy, typename A>
typedef Input tbb::flow::interface10::internal::function_input< Input, Output, Policy, A >::input_type

Definition at line 427 of file flow_graph.h.

◆ my_class

template<typename Input, typename Output, typename Policy, typename A>
typedef function_input<Input, Output, Policy,A> tbb::flow::interface10::internal::function_input< Input, Output, Policy, A >::my_class

Definition at line 430 of file flow_graph.h.

◆ output_type

template<typename Input, typename Output, typename Policy, typename A>
typedef Output tbb::flow::interface10::internal::function_input< Input, Output, Policy, A >::output_type

Definition at line 428 of file flow_graph.h.

Constructor & Destructor Documentation

◆ function_input() [1/2]

template<typename Input, typename Output, typename Policy, typename A>
template<typename Body >
tbb::flow::interface10::internal::function_input< Input, Output, Policy, A >::function_input ( graph g,
size_t  max_concurrency 
)
inline

Definition at line 436 of file flow_graph.h.

◆ function_input() [2/2]

template<typename Input, typename Output, typename Policy, typename A>
tbb::flow::interface10::internal::function_input< Input, Output, Policy, A >::function_input ( const function_input< Input, Output, Policy, A > &  src)
inline

Copy constructor.

Definition at line 445 of file flow_graph.h.

445  {
447  }
448 
449  bool try_put( const typename internal::async_helpers<T>::async_type& t ) {
bool try_put(const typename internal::async_helpers< Input >::filtered_type &t)
Put an item to the receiver.
Definition: flow_graph.h:445
bool try_put(const X &t)
Put an item to the receiver.
Definition: flow_graph.h:350

◆ ~function_input()

template<typename Input, typename Output, typename Policy, typename A>
tbb::flow::interface10::internal::function_input< Input, Output, Policy, A >::~function_input ( )
inline

Definition at line 451 of file flow_graph.h.

453  :
454  virtual task* try_put_task_wrapper( const void *p, bool is_async ) __TBB_override {
#define __TBB_override
Definition: tbb_stddef.h:244
void const char const char int ITT_FORMAT __itt_group_sync p
void const char const char int ITT_FORMAT __itt_group_sync x void const char ITT_FORMAT __itt_group_sync s void ITT_FORMAT __itt_group_sync p void ITT_FORMAT p void ITT_FORMAT p no args __itt_suppress_mode_t unsigned int void size_t ITT_FORMAT d void ITT_FORMAT p void ITT_FORMAT p __itt_model_site __itt_model_site_instance ITT_FORMAT p __itt_model_task * task
virtual task * try_put_task_wrapper(const void *p, bool is_async) __TBB_override
Definition: flow_graph.h:454

Member Function Documentation

◆ apply_body_impl()

template<typename Input, typename Output, typename Policy, typename A>
output_type tbb::flow::interface10::internal::function_input< Input, Output, Policy, A >::apply_body_impl ( const input_type i)
inline

Definition at line 462 of file flow_graph.h.

467  {
468 public:

◆ apply_body_impl_bypass()

template<typename Input, typename Output, typename Policy, typename A>
task* tbb::flow::interface10::internal::function_input< Input, Output, Policy, A >::apply_body_impl_bypass ( const input_type i)
inline

Definition at line 472 of file flow_graph.h.

475  {}
476 
477  // NOTE: Following part of PUBLIC section is partly copy-pasted in sender<T> under #if __TBB_PREVIEW_ASYNC_MSG
478 
480  virtual bool register_successor( successor_type &r ) = 0;
481 
483  virtual bool remove_successor( successor_type &r ) = 0;
484 
486  virtual bool try_get( T & ) { return false; }
487 
489  virtual bool try_reserve( T & ) { return false; }
490 
492  virtual bool try_release( ) { return false; }
493 
495  virtual bool try_consume( ) { return false; }
496 
497 #if TBB_DEPRECATED_FLOW_NODE_EXTRACTION
498  typedef typename internal::edge_container<successor_type> built_successors_type;
500  typedef typename built_successors_type::edge_list_type successor_list_type;
501  virtual built_successors_type &built_successors() = 0;
502  virtual void internal_add_built_successor( successor_type & ) = 0;
503  virtual void internal_delete_built_successor( successor_type & ) = 0;
504  virtual void copy_successors( successor_list_type &) = 0;
505  virtual size_t successor_count() = 0;
506 #endif /* TBB_DEPRECATED_FLOW_NODE_EXTRACTION */
507 }; // class sender<T>
508 

◆ copy_function_object()

template<typename Input, typename Output, typename Policy, typename A>
template<typename Body >
Body tbb::flow::interface10::internal::function_input< Input, Output, Policy, A >::copy_function_object ( )
inline

Definition at line 457 of file flow_graph.h.

467  {

◆ reset_function_input()

template<typename Input, typename Output, typename Policy, typename A>
void tbb::flow::interface10::internal::function_input< Input, Output, Policy, A >::reset_function_input ( reset_flags  f)
inlineprotected

Definition at line 512 of file flow_graph.h.

Referenced by tbb::flow::interface10::function_node< Input, Output, Policy, Allocator >::reset_node().

Here is the caller graph for this function:

◆ successors()

template<typename Input, typename Output, typename Policy, typename A>
virtual broadcast_cache<output_type >& tbb::flow::interface10::internal::function_input< Input, Output, Policy, A >::successors ( )
protectedpure virtual

Member Data Documentation

◆ my_body

template<typename Input, typename Output, typename Policy, typename A>
function_body_type* tbb::flow::interface10::internal::function_input< Input, Output, Policy, A >::my_body
protected

Definition at line 521 of file flow_graph.h.

◆ my_init_body

template<typename Input, typename Output, typename Policy, typename A>
function_body_type* tbb::flow::interface10::internal::function_input< Input, Output, Policy, A >::my_init_body
protected

Definition at line 522 of file flow_graph.h.


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

Copyright © 2005-2019 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.