NEST main@caf0ae8
 
Loading...
Searching...
No Matches
nest::ListRingBuffer Class Reference

#include <ring_buffer.h>

Public Member Functions

 ListRingBuffer ()
 
void append_value (const long offs, const double)
 Append a value to the ring buffer list.
 
std::list< double > & get_list (const long offs)
 
void clear ()
 Initialize the buffer with empty lists.
 
void resize ()
 Resize the buffer according to max_thread and max_delay.
 
size_t size () const
 Returns buffer size, for memory measurement.
 

Private Member Functions

size_t get_index_ (const long d) const
 Obtain buffer index.
 

Private Attributes

std::vector< std::list< double > > buffer_
 Buffered data.
 

Constructor & Destructor Documentation

◆ ListRingBuffer()

nest::ListRingBuffer::ListRingBuffer ( )

Member Function Documentation

◆ append_value()

void nest::ListRingBuffer::append_value ( const long  offs,
const double  v 
)
inline

Append a value to the ring buffer list.

Parameters
offsArrival time relative to beginning of slice.
doubleValue to append.

References buffer_, and get_index_().

Here is the call graph for this function:

◆ clear()

void nest::ListRingBuffer::clear ( )

Initialize the buffer with empty lists.

Also resizes the buffer if necessary.

References buffer_, and resize().

Here is the call graph for this function:

◆ get_index_()

size_t nest::ListRingBuffer::get_index_ ( const long  d) const
inlineprivate

Obtain buffer index.

Parameters
delaydelivery delay for event
Returns
index to buffer element into which event should be recorded.

References buffer_, nest::KernelManager::event_delivery_manager, nest::EventDeliveryManager::get_modulo(), and nest::kernel().

Referenced by append_value(), and get_list().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ get_list()

std::list< double > & nest::ListRingBuffer::get_list ( const long  offs)
inline

References buffer_, get_index_(), and nest::kernel().

Here is the call graph for this function:

◆ resize()

void nest::ListRingBuffer::resize ( )

Resize the buffer according to max_thread and max_delay.

New elements are filled with empty lists.

Note
resize() has no effect if the buffer has the correct size.

References buffer_, nest::KernelManager::connection_manager, nest::ConnectionManager::get_max_delay(), nest::ConnectionManager::get_min_delay(), nest::kernel(), and size().

Referenced by clear().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ size()

size_t nest::ListRingBuffer::size ( ) const
inline

Returns buffer size, for memory measurement.

References buffer_.

Referenced by resize().

Here is the caller graph for this function:

Member Data Documentation

◆ buffer_

std::vector< std::list< double > > nest::ListRingBuffer::buffer_
private

Buffered data.

Referenced by append_value(), clear(), get_index_(), get_list(), resize(), and size().


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