Kinetica   C#   API  Version 7.2.3.1
Stripe< T > Class Template Reference

A stripe within a worker queue. More...

Public Member Functions

 Stripe (int capacity)
 
List< T >? Add (T record)
 Adds a record to the stripe. More...
 
List< List< T > > AddRange (IReadOnlyList< T > records)
 Adds multiple records to the stripe. More...
 
List< T >? Flush ()
 Flushes all records from the stripe, regardless of count. More...
 

Properties

int Count [get]
 Gets the current count of records in the stripe. More...
 

Detailed Description

A stripe within a worker queue.

Each stripe has its own lock to reduce contention.

Template Parameters
TThe record type.

Definition at line 11 of file StripedWorkerQueue.cs.

Constructor & Destructor Documentation

◆ Stripe()

Stripe< T >.Stripe ( int  capacity)
inline

Definition at line 17 of file StripedWorkerQueue.cs.

Member Function Documentation

◆ Add()

List<T>? Stripe< T >.Add ( record)
inline

Adds a record to the stripe.

Returns the batch if capacity is reached, null otherwise.

Definition at line 26 of file StripedWorkerQueue.cs.

◆ AddRange()

List<List<T> > Stripe< T >.AddRange ( IReadOnlyList< T >  records)
inline

Adds multiple records to the stripe.

Returns any complete batches.

Definition at line 44 of file StripedWorkerQueue.cs.

◆ Flush()

List<T>? Stripe< T >.Flush ( )
inline

Flushes all records from the stripe, regardless of count.

Definition at line 65 of file StripedWorkerQueue.cs.

Property Documentation

◆ Count

int Stripe< T >.Count
get

Gets the current count of records in the stripe.

Definition at line 82 of file StripedWorkerQueue.cs.


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