U operator()( tbb::flow_control& control ) const {
     AssertLive();
     if( --input_counter < 0 ) {
         control.stop();
     }
     return U();  // default constructed
 }
Example #2
0
 void operator()( tbb::flow_control& control ) const {
     AssertLive();
     if( --input_counter < 0 ) {
         control.stop();
     }
     else
         ++non_pointer_specialized_calls;
 }
Example #3
0
 U operator()( tbb::flow_control& control ) const {
     AssertLive();
     if( --input_counter < 0 ) {
         control.stop();
     }
     else  // only count successful reads
         ++non_pointer_specialized_calls;
     return U();  // default constructed
 }
Example #4
0
static Pair read_( tbb::flow_control& flow )
{
    if( queue.empty() || is_shutdown || !callback->good() || !std::cout.good() || !running )
    {
        flow.stop();
        return Pair();
    }
    Pair p;
    queue.pop( p );
    return p;
}
Example #5
0
 int
 operator()(tbb::flow_control& control ) const {
     AssertLive();
     int oldval = --input_counter;
     if( oldval < 0 ) {
         control.stop();
     }
     else
         ++non_pointer_specialized_calls;
     return oldval+1;
 }
 void operator()( tbb::flow_control& control ) {
     if( --counter < 0 ) {
         control.stop();
     }
 }
 U operator()( tbb::flow_control& control ) {
     if( --counter < 0 ) {
         control.stop();
     }
     return U();
 }
 void operator()( tbb::flow_control& control ) const {
     AssertLive();
     if( --input_counter < 0 ) {
         control.stop();
     }
 }