MPIInputSpikeBuffer< T > Class Template Reference

Buffer class which holds the received serialized spike data from some other node via MPI. More...

#include <MPIInputSpikeBuffer.h>

Collaboration diagram for MPIInputSpikeBuffer< T >:

Collaboration graph
[legend]

List of all members.

Public Types

typedef
MPIInputSpikeBufferIterator< T > 
const_iterator
 The iterator type for the mpi input buffer.
typedef MPIInputSpikeBufferElement value_type
 The type of the "virtual" values stored in the buffer, that are accessed through the iterator.
typedef T coding_element_type
 Type of the elements in the serialized raw spike data.

Public Member Functions

 MPIInputSpikeBuffer ()
 Constructor.
virtual ~MPIInputSpikeBuffer ()
void initialize (T *buffer)
const_iterator begin ()
 Provides an iterator pointing at the first MPIInputSpikeBufferElement.
const_iterator end ()
 Provides an iterator pointing at the last MPIInputSpikeBufferElement.
T * getBuffer ()
 Get the buffer in a serialized raw form.
intgetLength ()
bool isLastReceivedBuffer ()
 Checks if this is the last received buffer from the node associated with the buffer.
void setHasNewContent (bool indicator)
bool hasNewContent ()

Public Attributes

guard_value
 guard/marker value used to separate segments in the serialized spike data.

Protected Attributes

bool contentIndicator
T * _buffer
 Pointer to the serialized data received through MPI.
int len
 Length of the serialized data in _buffer.

Friends

class MPIInputSpikeBufferIterator< T >
class MPIInputSpikeBufferVector< T >


Detailed Description

template<typename T = unsigned short>
class MPIInputSpikeBuffer< T >

Buffer class which holds the received serialized spike data from some other node via MPI.

It is used by MPIAlltoAllCommunicator to store the received data from other nodes, and by the DistributedIncomingSpikeScheduler which iterates through the spikes and schedules them to the appropriate propagated spike buffers.

To access iteratively the individual spikes, an iterator-like interface MPIInputSpikeBufferIterator is provided.

See also:
MPIAllToAllCommunicator, DistributedIncomingSpikeScheduler, MPIInputSpikeBufferIterator

Definition at line 102 of file MPIInputSpikeBuffer.h.


Member Typedef Documentation

template<typename T = unsigned short>
typedef MPIInputSpikeBufferIterator<T> MPIInputSpikeBuffer< T >::const_iterator

The iterator type for the mpi input buffer.

Definition at line 106 of file MPIInputSpikeBuffer.h.

template<typename T = unsigned short>
typedef MPIInputSpikeBufferElement MPIInputSpikeBuffer< T >::value_type

The type of the "virtual" values stored in the buffer, that are accessed through the iterator.

Definition at line 109 of file MPIInputSpikeBuffer.h.

template<typename T = unsigned short>
typedef T MPIInputSpikeBuffer< T >::coding_element_type

Type of the elements in the serialized raw spike data.

Can be short int or long int

Definition at line 116 of file MPIInputSpikeBuffer.h.


Constructor & Destructor Documentation

template<typename T>
MPIInputSpikeBuffer< T >::MPIInputSpikeBuffer (  )  [inline]

template<typename T>
MPIInputSpikeBuffer< T >::~MPIInputSpikeBuffer (  )  [inline, virtual]

Definition at line 301 of file MPIInputSpikeBuffer.h.


Member Function Documentation

template<typename T = unsigned short>
void MPIInputSpikeBuffer< T >::initialize ( T *  buffer  )  [inline]

template<typename T>
MPIInputSpikeBuffer< T >::const_iterator MPIInputSpikeBuffer< T >::begin (  )  [inline]

template<typename T>
MPIInputSpikeBuffer< T >::const_iterator MPIInputSpikeBuffer< T >::end (  )  [inline]

template<typename T>
T * MPIInputSpikeBuffer< T >::getBuffer (  )  [inline]

Get the buffer in a serialized raw form.

Definition at line 334 of file MPIInputSpikeBuffer.h.

References MPIInputSpikeBuffer< T >::_buffer.

template<typename T>
int & MPIInputSpikeBuffer< T >::getLength (  )  [inline]

Definition at line 340 of file MPIInputSpikeBuffer.h.

References MPIInputSpikeBuffer< T >::len.

template<typename T>
bool MPIInputSpikeBuffer< T >::isLastReceivedBuffer (  )  [inline]

Checks if this is the last received buffer from the node associated with the buffer.

Used to detect whether the all-to-all exchange iterations are over or there are more steps to be performed.

Definition at line 346 of file MPIInputSpikeBuffer.h.

References MPIInputSpikeBuffer< T >::_buffer.

Referenced by MPIInputBuffer::hasNextBufferSlice().

template<typename T = unsigned short>
void MPIInputSpikeBuffer< T >::setHasNewContent ( bool  indicator  )  [inline]

template<typename T = unsigned short>
bool MPIInputSpikeBuffer< T >::hasNewContent (  )  [inline]

Definition at line 161 of file MPIInputSpikeBuffer.h.

References MPIInputSpikeBuffer< T >::contentIndicator.


Friends And Related Function Documentation

template<typename T = unsigned short>
friend class MPIInputSpikeBufferIterator< T > [friend]

Definition at line 175 of file MPIInputSpikeBuffer.h.

template<typename T = unsigned short>
friend class MPIInputSpikeBufferVector< T > [friend]

Definition at line 176 of file MPIInputSpikeBuffer.h.


Member Data Documentation

template<typename T = unsigned short>
T MPIInputSpikeBuffer< T >::guard_value

guard/marker value used to separate segments in the serialized spike data.

Definition at line 119 of file MPIInputSpikeBuffer.h.

Referenced by MPIInputSpikeBuffer< T >::MPIInputSpikeBuffer().

template<typename T = unsigned short>
bool MPIInputSpikeBuffer< T >::contentIndicator [protected]

template<typename T = unsigned short>
T* MPIInputSpikeBuffer< T >::_buffer [protected]

template<typename T = unsigned short>
int MPIInputSpikeBuffer< T >::len [protected]


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

Generated on Wed Jul 9 16:34:51 2008 for PCSIM by  doxygen 1.5.5