Main Page | Namespace List | Alphabetical List | Class List | Directories | File List | Class Members | File Members

NeuronTaskHolder Class Reference

#include <NeuronTaskHolder.h>

List of all members.

Public Member Functions

 NeuronTaskHolder (int thisTaskID, unsigned int maxNumberOfNeurons)
 ~NeuronTaskHolder ()
void addReceivingTask (int)
void removeReceivingTask (int)
bool sendFiringNeuronMessages ()

Public Attributes

int thisTaskID
vector< unsigned int > firingNeuronVector

Private Member Functions

 NeuronTaskHolder (const NeuronTaskHolder &)
NeuronTaskHolder operator= (const NeuronTaskHolder &)

Private Attributes

int * destinationTaskIDs
int numberOfTasks


Detailed Description

Stores the current firing pattern of the neuron group and sends it to any tasks that want to monitor the firing neurons rather than the spikes.

Definition at line 37 of file NeuronTaskHolder.h.


Constructor & Destructor Documentation

NeuronTaskHolder::NeuronTaskHolder int  myTID,
unsigned int  maxNumberOfNeurons
 

Constructor.

Definition at line 37 of file NeuronTaskHolder.cpp.

References firingNeuronVector, numberOfTasks, and thisTaskID.

NeuronTaskHolder::~NeuronTaskHolder  ) 
 

Destructor.

Definition at line 50 of file NeuronTaskHolder.cpp.

References destinationTaskIDs, and numberOfTasks.

NeuronTaskHolder::NeuronTaskHolder const NeuronTaskHolder  )  [private]
 

Declare copy constructor private so it cannot be used inadvertently.


Member Function Documentation

void NeuronTaskHolder::addReceivingTask int  newTaskID  ) 
 

Adds a receiving task to the task array. Done in this clunky way because the broadcast message function in pvm needs an integer array, not a vector, as one of its arguments.

Definition at line 67 of file NeuronTaskHolder.cpp.

References destinationTaskIDs, and numberOfTasks.

Referenced by SpikeStreamSimulation::addReceivingTask_Neurons().

NeuronTaskHolder NeuronTaskHolder::operator= const NeuronTaskHolder  )  [private]
 

Declare assignment private so it cannot be used.

void NeuronTaskHolder::removeReceivingTask int  taskID  ) 
 

Removes a receiving task from the task holder.

Definition at line 89 of file NeuronTaskHolder.cpp.

References destinationTaskIDs, and numberOfTasks.

Referenced by SpikeStreamSimulation::removeReceivingTask_Neurons().

bool NeuronTaskHolder::sendFiringNeuronMessages  ) 
 

Sends the list of firing neurons to the receiving tasks.

Definition at line 122 of file NeuronTaskHolder.cpp.

References destinationTaskIDs, firingNeuronVector, SimulationClock::getTimeStep(), numberOfTasks, SpikeStreamSimulation::simulationClock, and thisTaskID.

Referenced by SpikeStreamSimulation::sendSpikeMessages().


Member Data Documentation

int* NeuronTaskHolder::destinationTaskIDs [private]
 

Task IDs of the tasks that will be sent the firing neuron lists held in this task holder. Stored as an integer array to make it simpler to send using pvm_mcast. A vector of task ids would have to be converted.

Definition at line 60 of file NeuronTaskHolder.h.

Referenced by addReceivingTask(), removeReceivingTask(), sendFiringNeuronMessages(), and ~NeuronTaskHolder().

vector<unsigned int> NeuronTaskHolder::firingNeuronVector
 

Vector holding the list of currently firing neurons.

Definition at line 52 of file NeuronTaskHolder.h.

Referenced by Neuron::fireNeuron(), SpikeStreamSimulation::loadSimulationData(), NeuronTaskHolder(), and sendFiringNeuronMessages().

int NeuronTaskHolder::numberOfTasks [private]
 

Size of the destinationTaskIDs array.

Definition at line 63 of file NeuronTaskHolder.h.

Referenced by addReceivingTask(), NeuronTaskHolder(), removeReceivingTask(), sendFiringNeuronMessages(), and ~NeuronTaskHolder().

int NeuronTaskHolder::thisTaskID
 

Keep a record of this task here for error messages.

Definition at line 49 of file NeuronTaskHolder.h.

Referenced by NeuronTaskHolder(), and sendFiringNeuronMessages().


The documentation for this class was generated from the following files:
Generated on Mon Sep 3 22:24:34 2007 for SpikeStream Simulation by  doxygen 1.4.4