SimpleScalingSpikingSynapse.cpp

Go to the documentation of this file.
00001 #include "SimpleScalingSpikingSynapse.h"
00002 
00003 const int SimpleScalingSpikingSynapse::exc = 1;
00004 const int SimpleScalingSpikingSynapse::inh = 2;
00005 const int SimpleScalingSpikingSynapse::currExc = 1;
00006 const int SimpleScalingSpikingSynapse::currInh = 2;
00007 const int SimpleScalingSpikingSynapse::condExc = 3;
00008 const int SimpleScalingSpikingSynapse::condInh = 4;
00009 
00010 SimpleScalingSpikingSynapse::SimpleScalingSpikingSynapse(int targetID, float W, float delay)
00011             : W(W), delay(delay), target_id(targetID)
00012 {}
00013 
00014 SimpleScalingSpikingSynapse::~SimpleScalingSpikingSynapse()
00015 {}      
00016 
00017 double SimpleScalingSpikingSynapse::getManagedDelay() const
00018 {
00019     return delay;
00020 }
00021 
00022 int SimpleScalingSpikingSynapse::spikeHit( spikeport_t port, SpikeEvent const& spike )
00023 {
00024     return target->spikeHit( port, SpikeEvent( spike, W ) );
00025 }
00026 
00027 int SimpleScalingSpikingSynapse::advance(AdvanceInfo const &ai)
00028 {
00029     return ADVANCEFLAG_DEACTIVATE;
00030 }
00031 
00032 SimObject * SimpleScalingSpikingSynapse::getChainedObject()
00033 {
00034     return target;
00035 }
00036 
00038 void SimpleScalingSpikingSynapse::outgoing(SimObject *receiver)
00039 {
00040     target = receiver->getInputTarget(target_id);
00041 }
00042 
00043 int SimpleScalingSpikingSynapse::nSpikeInputPorts() const
00044 {
00045     return 1;
00046 }
00047 
00048 int SimpleScalingSpikingSynapse::nSpikeOutputPorts() const
00049 {
00050     return 0;
00051 }
00052 
00053 int SimpleScalingSpikingSynapse::nAnalogInputPorts() const
00054 {
00055     return 0;
00056 }
00057 
00058 int SimpleScalingSpikingSynapse::nAnalogOutputPorts() const
00059 {
00060     return 0;
00061 }
00062 
00063 SimObject::PortType SimpleScalingSpikingSynapse::inputPortType(port_t i) const
00064 {
00065     if( i==0)
00066         return spiking;
00067     else
00068         return undefined;
00069 }

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