JODA  0.13.1 (59b41972)
JSON On-Demand Analysis
Public Types | Public Member Functions | Static Public Member Functions | Static Public Attributes
moodycamel::BlockingConcurrentQueue< T, Traits > Class Template Reference

#include <blockingconcurrentqueue.h>

Public Types

typedef ConcurrentQueue::producer_token_t producer_token_t
 
typedef ConcurrentQueue::consumer_token_t consumer_token_t
 
typedef ConcurrentQueue::index_t index_t
 
typedef ConcurrentQueue::size_t size_t
 
typedef std::make_signed< size_t >::type ssize_t
 

Public Member Functions

 BlockingConcurrentQueue (size_t capacity=6 *BLOCK_SIZE)
 
 BlockingConcurrentQueue (size_t minCapacity, size_t maxExplicitProducers, size_t maxImplicitProducers)
 
 BlockingConcurrentQueue (BlockingConcurrentQueue const &) MOODYCAMEL_DELETE_FUNCTION
 
BlockingConcurrentQueueoperator= (BlockingConcurrentQueue const &) MOODYCAMEL_DELETE_FUNCTION
 
 BlockingConcurrentQueue (BlockingConcurrentQueue &&other) MOODYCAMEL_NOEXCEPT
 
BlockingConcurrentQueueoperator= (BlockingConcurrentQueue &&other) MOODYCAMEL_NOEXCEPT
 
void swap (BlockingConcurrentQueue &other) MOODYCAMEL_NOEXCEPT
 
bool enqueue (T const &item)
 
bool enqueue (T &&item)
 
bool enqueue (producer_token_t const &token, T const &item)
 
bool enqueue (producer_token_t const &token, T &&item)
 
template<typename It >
bool enqueue_bulk (It itemFirst, size_t count)
 
template<typename It >
bool enqueue_bulk (producer_token_t const &token, It itemFirst, size_t count)
 
bool try_enqueue (T const &item)
 
bool try_enqueue (T &&item)
 
bool try_enqueue (producer_token_t const &token, T const &item)
 
bool try_enqueue (producer_token_t const &token, T &&item)
 
template<typename It >
bool try_enqueue_bulk (It itemFirst, size_t count)
 
template<typename It >
bool try_enqueue_bulk (producer_token_t const &token, It itemFirst, size_t count)
 
template<typename U >
bool try_dequeue (U &item)
 
template<typename U >
bool try_dequeue (consumer_token_t &token, U &item)
 
template<typename It >
size_t try_dequeue_bulk (It itemFirst, size_t max)
 
template<typename It >
size_t try_dequeue_bulk (consumer_token_t &token, It itemFirst, size_t max)
 
template<typename U >
void wait_dequeue (U &item)
 
template<typename U >
bool wait_dequeue_timed (U &item, std::int64_t timeout_usecs)
 
template<typename U , typename Rep , typename Period >
bool wait_dequeue_timed (U &item, std::chrono::duration< Rep, Period > const &timeout)
 
template<typename U >
void wait_dequeue (consumer_token_t &token, U &item)
 
template<typename U >
bool wait_dequeue_timed (consumer_token_t &token, U &item, std::int64_t timeout_usecs)
 
template<typename U , typename Rep , typename Period >
bool wait_dequeue_timed (consumer_token_t &token, U &item, std::chrono::duration< Rep, Period > const &timeout)
 
template<typename It >
size_t wait_dequeue_bulk (It itemFirst, size_t max)
 
template<typename It >
size_t wait_dequeue_bulk_timed (It itemFirst, size_t max, std::int64_t timeout_usecs)
 
template<typename It , typename Rep , typename Period >
size_t wait_dequeue_bulk_timed (It itemFirst, size_t max, std::chrono::duration< Rep, Period > const &timeout)
 
template<typename It >
size_t wait_dequeue_bulk (consumer_token_t &token, It itemFirst, size_t max)
 
template<typename It >
size_t wait_dequeue_bulk_timed (consumer_token_t &token, It itemFirst, size_t max, std::int64_t timeout_usecs)
 
template<typename It , typename Rep , typename Period >
size_t wait_dequeue_bulk_timed (consumer_token_t &token, It itemFirst, size_t max, std::chrono::duration< Rep, Period > const &timeout)
 
size_t size_approx () const
 

Static Public Member Functions

static bool is_lock_free ()
 

Static Public Attributes

static const size_t BLOCK_SIZE = ConcurrentQueue::BLOCK_SIZE
 
static const size_t EXPLICIT_BLOCK_EMPTY_COUNTER_THRESHOLD
 
static const size_t EXPLICIT_INITIAL_INDEX_SIZE
 
static const size_t IMPLICIT_INITIAL_INDEX_SIZE
 
static const size_t INITIAL_IMPLICIT_PRODUCER_HASH_SIZE
 
static const std::uint32_t EXPLICIT_CONSUMER_CONSUMPTION_QUOTA_BEFORE_ROTATE
 
static const size_t MAX_SUBQUEUE_SIZE = ConcurrentQueue::MAX_SUBQUEUE_SIZE
 

Member Typedef Documentation

◆ consumer_token_t

template<typename T , typename Traits = ConcurrentQueueDefaultTraits>
typedef ConcurrentQueue::consumer_token_t moodycamel::BlockingConcurrentQueue< T, Traits >::consumer_token_t

◆ index_t

template<typename T , typename Traits = ConcurrentQueueDefaultTraits>
typedef ConcurrentQueue::index_t moodycamel::BlockingConcurrentQueue< T, Traits >::index_t

◆ producer_token_t

template<typename T , typename Traits = ConcurrentQueueDefaultTraits>
typedef ConcurrentQueue::producer_token_t moodycamel::BlockingConcurrentQueue< T, Traits >::producer_token_t

◆ size_t

template<typename T , typename Traits = ConcurrentQueueDefaultTraits>
typedef ConcurrentQueue::size_t moodycamel::BlockingConcurrentQueue< T, Traits >::size_t

◆ ssize_t

template<typename T , typename Traits = ConcurrentQueueDefaultTraits>
typedef std::make_signed<size_t>::type moodycamel::BlockingConcurrentQueue< T, Traits >::ssize_t

Constructor & Destructor Documentation

◆ BlockingConcurrentQueue() [1/4]

template<typename T , typename Traits = ConcurrentQueueDefaultTraits>
moodycamel::BlockingConcurrentQueue< T, Traits >::BlockingConcurrentQueue ( size_t  capacity = 6 * BLOCK_SIZE)
inlineexplicit

◆ BlockingConcurrentQueue() [2/4]

template<typename T , typename Traits = ConcurrentQueueDefaultTraits>
moodycamel::BlockingConcurrentQueue< T, Traits >::BlockingConcurrentQueue ( size_t  minCapacity,
size_t  maxExplicitProducers,
size_t  maxImplicitProducers 
)
inline

◆ BlockingConcurrentQueue() [3/4]

template<typename T , typename Traits = ConcurrentQueueDefaultTraits>
moodycamel::BlockingConcurrentQueue< T, Traits >::BlockingConcurrentQueue ( BlockingConcurrentQueue< T, Traits > const &  )

◆ BlockingConcurrentQueue() [4/4]

template<typename T , typename Traits = ConcurrentQueueDefaultTraits>
moodycamel::BlockingConcurrentQueue< T, Traits >::BlockingConcurrentQueue ( BlockingConcurrentQueue< T, Traits > &&  other)
inline

Member Function Documentation

◆ enqueue() [1/4]

template<typename T , typename Traits = ConcurrentQueueDefaultTraits>
bool moodycamel::BlockingConcurrentQueue< T, Traits >::enqueue ( producer_token_t const &  token,
T &&  item 
)
inline
Here is the call graph for this function:

◆ enqueue() [2/4]

template<typename T , typename Traits = ConcurrentQueueDefaultTraits>
bool moodycamel::BlockingConcurrentQueue< T, Traits >::enqueue ( producer_token_t const &  token,
T const &  item 
)
inline
Here is the call graph for this function:

◆ enqueue() [3/4]

template<typename T , typename Traits = ConcurrentQueueDefaultTraits>
bool moodycamel::BlockingConcurrentQueue< T, Traits >::enqueue ( T &&  item)
inline
Here is the call graph for this function:

◆ enqueue() [4/4]

template<typename T , typename Traits = ConcurrentQueueDefaultTraits>
bool moodycamel::BlockingConcurrentQueue< T, Traits >::enqueue ( T const &  item)
inline
Here is the call graph for this function:

◆ enqueue_bulk() [1/2]

template<typename T , typename Traits = ConcurrentQueueDefaultTraits>
template<typename It >
bool moodycamel::BlockingConcurrentQueue< T, Traits >::enqueue_bulk ( It  itemFirst,
size_t  count 
)
inline
Here is the call graph for this function:

◆ enqueue_bulk() [2/2]

template<typename T , typename Traits = ConcurrentQueueDefaultTraits>
template<typename It >
bool moodycamel::BlockingConcurrentQueue< T, Traits >::enqueue_bulk ( producer_token_t const &  token,
It  itemFirst,
size_t  count 
)
inline
Here is the call graph for this function:

◆ is_lock_free()

template<typename T , typename Traits = ConcurrentQueueDefaultTraits>
static bool moodycamel::BlockingConcurrentQueue< T, Traits >::is_lock_free ( )
inlinestatic
Here is the call graph for this function:

◆ operator=() [1/2]

template<typename T , typename Traits = ConcurrentQueueDefaultTraits>
BlockingConcurrentQueue& moodycamel::BlockingConcurrentQueue< T, Traits >::operator= ( BlockingConcurrentQueue< T, Traits > &&  other)
inline

◆ operator=() [2/2]

template<typename T , typename Traits = ConcurrentQueueDefaultTraits>
BlockingConcurrentQueue& moodycamel::BlockingConcurrentQueue< T, Traits >::operator= ( BlockingConcurrentQueue< T, Traits > const &  )

◆ size_approx()

template<typename T , typename Traits = ConcurrentQueueDefaultTraits>
size_t moodycamel::BlockingConcurrentQueue< T, Traits >::size_approx ( ) const
inline

◆ swap()

template<typename T , typename Traits = ConcurrentQueueDefaultTraits>
void moodycamel::BlockingConcurrentQueue< T, Traits >::swap ( BlockingConcurrentQueue< T, Traits > &  other)
inline

◆ try_dequeue() [1/2]

template<typename T , typename Traits = ConcurrentQueueDefaultTraits>
template<typename U >
bool moodycamel::BlockingConcurrentQueue< T, Traits >::try_dequeue ( consumer_token_t token,
U &  item 
)
inline
Here is the call graph for this function:

◆ try_dequeue() [2/2]

template<typename T , typename Traits = ConcurrentQueueDefaultTraits>
template<typename U >
bool moodycamel::BlockingConcurrentQueue< T, Traits >::try_dequeue ( U &  item)
inline
Here is the call graph for this function:

◆ try_dequeue_bulk() [1/2]

template<typename T , typename Traits = ConcurrentQueueDefaultTraits>
template<typename It >
size_t moodycamel::BlockingConcurrentQueue< T, Traits >::try_dequeue_bulk ( consumer_token_t token,
It  itemFirst,
size_t  max 
)
inline

◆ try_dequeue_bulk() [2/2]

template<typename T , typename Traits = ConcurrentQueueDefaultTraits>
template<typename It >
size_t moodycamel::BlockingConcurrentQueue< T, Traits >::try_dequeue_bulk ( It  itemFirst,
size_t  max 
)
inline

◆ try_enqueue() [1/4]

template<typename T , typename Traits = ConcurrentQueueDefaultTraits>
bool moodycamel::BlockingConcurrentQueue< T, Traits >::try_enqueue ( producer_token_t const &  token,
T &&  item 
)
inline
Here is the call graph for this function:

◆ try_enqueue() [2/4]

template<typename T , typename Traits = ConcurrentQueueDefaultTraits>
bool moodycamel::BlockingConcurrentQueue< T, Traits >::try_enqueue ( producer_token_t const &  token,
T const &  item 
)
inline
Here is the call graph for this function:

◆ try_enqueue() [3/4]

template<typename T , typename Traits = ConcurrentQueueDefaultTraits>
bool moodycamel::BlockingConcurrentQueue< T, Traits >::try_enqueue ( T &&  item)
inline
Here is the call graph for this function:

◆ try_enqueue() [4/4]

template<typename T , typename Traits = ConcurrentQueueDefaultTraits>
bool moodycamel::BlockingConcurrentQueue< T, Traits >::try_enqueue ( T const &  item)
inline
Here is the call graph for this function:

◆ try_enqueue_bulk() [1/2]

template<typename T , typename Traits = ConcurrentQueueDefaultTraits>
template<typename It >
bool moodycamel::BlockingConcurrentQueue< T, Traits >::try_enqueue_bulk ( It  itemFirst,
size_t  count 
)
inline
Here is the call graph for this function:

◆ try_enqueue_bulk() [2/2]

template<typename T , typename Traits = ConcurrentQueueDefaultTraits>
template<typename It >
bool moodycamel::BlockingConcurrentQueue< T, Traits >::try_enqueue_bulk ( producer_token_t const &  token,
It  itemFirst,
size_t  count 
)
inline
Here is the call graph for this function:

◆ wait_dequeue() [1/2]

template<typename T , typename Traits = ConcurrentQueueDefaultTraits>
template<typename U >
void moodycamel::BlockingConcurrentQueue< T, Traits >::wait_dequeue ( consumer_token_t token,
U &  item 
)
inline
Here is the call graph for this function:

◆ wait_dequeue() [2/2]

template<typename T , typename Traits = ConcurrentQueueDefaultTraits>
template<typename U >
void moodycamel::BlockingConcurrentQueue< T, Traits >::wait_dequeue ( U &  item)
inline
Here is the call graph for this function:

◆ wait_dequeue_bulk() [1/2]

template<typename T , typename Traits = ConcurrentQueueDefaultTraits>
template<typename It >
size_t moodycamel::BlockingConcurrentQueue< T, Traits >::wait_dequeue_bulk ( consumer_token_t token,
It  itemFirst,
size_t  max 
)
inline

◆ wait_dequeue_bulk() [2/2]

template<typename T , typename Traits = ConcurrentQueueDefaultTraits>
template<typename It >
size_t moodycamel::BlockingConcurrentQueue< T, Traits >::wait_dequeue_bulk ( It  itemFirst,
size_t  max 
)
inline

◆ wait_dequeue_bulk_timed() [1/4]

template<typename T , typename Traits = ConcurrentQueueDefaultTraits>
template<typename It , typename Rep , typename Period >
size_t moodycamel::BlockingConcurrentQueue< T, Traits >::wait_dequeue_bulk_timed ( consumer_token_t token,
It  itemFirst,
size_t  max,
std::chrono::duration< Rep, Period > const &  timeout 
)
inline

◆ wait_dequeue_bulk_timed() [2/4]

template<typename T , typename Traits = ConcurrentQueueDefaultTraits>
template<typename It >
size_t moodycamel::BlockingConcurrentQueue< T, Traits >::wait_dequeue_bulk_timed ( consumer_token_t token,
It  itemFirst,
size_t  max,
std::int64_t  timeout_usecs 
)
inline

◆ wait_dequeue_bulk_timed() [3/4]

template<typename T , typename Traits = ConcurrentQueueDefaultTraits>
template<typename It , typename Rep , typename Period >
size_t moodycamel::BlockingConcurrentQueue< T, Traits >::wait_dequeue_bulk_timed ( It  itemFirst,
size_t  max,
std::chrono::duration< Rep, Period > const &  timeout 
)
inline

◆ wait_dequeue_bulk_timed() [4/4]

template<typename T , typename Traits = ConcurrentQueueDefaultTraits>
template<typename It >
size_t moodycamel::BlockingConcurrentQueue< T, Traits >::wait_dequeue_bulk_timed ( It  itemFirst,
size_t  max,
std::int64_t  timeout_usecs 
)
inline

◆ wait_dequeue_timed() [1/4]

template<typename T , typename Traits = ConcurrentQueueDefaultTraits>
template<typename U , typename Rep , typename Period >
bool moodycamel::BlockingConcurrentQueue< T, Traits >::wait_dequeue_timed ( consumer_token_t token,
U &  item,
std::chrono::duration< Rep, Period > const &  timeout 
)
inline
Here is the call graph for this function:

◆ wait_dequeue_timed() [2/4]

template<typename T , typename Traits = ConcurrentQueueDefaultTraits>
template<typename U >
bool moodycamel::BlockingConcurrentQueue< T, Traits >::wait_dequeue_timed ( consumer_token_t token,
U &  item,
std::int64_t  timeout_usecs 
)
inline
Here is the call graph for this function:

◆ wait_dequeue_timed() [3/4]

template<typename T , typename Traits = ConcurrentQueueDefaultTraits>
template<typename U , typename Rep , typename Period >
bool moodycamel::BlockingConcurrentQueue< T, Traits >::wait_dequeue_timed ( U &  item,
std::chrono::duration< Rep, Period > const &  timeout 
)
inline
Here is the call graph for this function:

◆ wait_dequeue_timed() [4/4]

template<typename T , typename Traits = ConcurrentQueueDefaultTraits>
template<typename U >
bool moodycamel::BlockingConcurrentQueue< T, Traits >::wait_dequeue_timed ( U &  item,
std::int64_t  timeout_usecs 
)
inline
Here is the call graph for this function:
Here is the caller graph for this function:

Field Documentation

◆ BLOCK_SIZE

template<typename T , typename Traits = ConcurrentQueueDefaultTraits>
const size_t moodycamel::BlockingConcurrentQueue< T, Traits >::BLOCK_SIZE = ConcurrentQueue::BLOCK_SIZE
static

◆ EXPLICIT_BLOCK_EMPTY_COUNTER_THRESHOLD

template<typename T , typename Traits = ConcurrentQueueDefaultTraits>
const size_t moodycamel::BlockingConcurrentQueue< T, Traits >::EXPLICIT_BLOCK_EMPTY_COUNTER_THRESHOLD
static
Initial value:
=
static const size_t EXPLICIT_BLOCK_EMPTY_COUNTER_THRESHOLD
Definition: concurrentqueue.h:811

◆ EXPLICIT_CONSUMER_CONSUMPTION_QUOTA_BEFORE_ROTATE

template<typename T , typename Traits = ConcurrentQueueDefaultTraits>
const std::uint32_t moodycamel::BlockingConcurrentQueue< T, Traits >::EXPLICIT_CONSUMER_CONSUMPTION_QUOTA_BEFORE_ROTATE
static
Initial value:
=
static const std::uint32_t EXPLICIT_CONSUMER_CONSUMPTION_QUOTA_BEFORE_ROTATE
Definition: concurrentqueue.h:819

◆ EXPLICIT_INITIAL_INDEX_SIZE

template<typename T , typename Traits = ConcurrentQueueDefaultTraits>
const size_t moodycamel::BlockingConcurrentQueue< T, Traits >::EXPLICIT_INITIAL_INDEX_SIZE
static
Initial value:
=
static const size_t EXPLICIT_INITIAL_INDEX_SIZE
Definition: concurrentqueue.h:813

◆ IMPLICIT_INITIAL_INDEX_SIZE

template<typename T , typename Traits = ConcurrentQueueDefaultTraits>
const size_t moodycamel::BlockingConcurrentQueue< T, Traits >::IMPLICIT_INITIAL_INDEX_SIZE
static
Initial value:
=
static const size_t IMPLICIT_INITIAL_INDEX_SIZE
Definition: concurrentqueue.h:815

◆ INITIAL_IMPLICIT_PRODUCER_HASH_SIZE

template<typename T , typename Traits = ConcurrentQueueDefaultTraits>
const size_t moodycamel::BlockingConcurrentQueue< T, Traits >::INITIAL_IMPLICIT_PRODUCER_HASH_SIZE
static
Initial value:
=
static const size_t INITIAL_IMPLICIT_PRODUCER_HASH_SIZE
Definition: concurrentqueue.h:817

◆ MAX_SUBQUEUE_SIZE

template<typename T , typename Traits = ConcurrentQueueDefaultTraits>
const size_t moodycamel::BlockingConcurrentQueue< T, Traits >::MAX_SUBQUEUE_SIZE = ConcurrentQueue::MAX_SUBQUEUE_SIZE
static

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