12 #include "ModulateNeuronPropSynapse.h"
19 #include "ClassFactory.h"
54 if(strType ==
"REGULAR")
56 else if(strType ==
"PACEMAKER")
58 else if(strType ==
"TONIC")
60 else if(strType ==
"RANDOM")
62 else if(strType ==
"BISTABLE")
68 THROW_PARAM_ERROR(Nl_Err_lInvalidNeuronType, Nl_Err_strInvalidNeuronType,
"NeuronType", strType);
73 catch(CStdErrorInfo oError)
75 if(lpNeuron)
delete lpNeuron;
81 if(lpNeuron)
delete lpNeuron;
82 THROW_ERROR(Std_Err_lUnspecifiedError, Std_Err_strUnspecifiedError);
102 if(strType ==
"REGULAR")
104 else if(strType ==
"COMPOUND")
106 else if(strType ==
"GATED")
108 else if(strType ==
"MODULATED")
110 else if(strType ==
"MODULATENEURONPROP")
116 THROW_PARAM_ERROR(Nl_Err_lInvalidSynapseType, Nl_Err_strInvalidSynapseType,
"SynapseType", strType);
121 catch(CStdErrorInfo oError)
123 if(lpSynapse)
delete lpSynapse;
129 if(lpSynapse)
delete lpSynapse;
130 THROW_ERROR(Std_Err_lUnspecifiedError, Std_Err_strUnspecifiedError);
143 DataColumn *lpColumn=NULL;
155 THROW_PARAM_ERROR(Al_Err_lInvalidDataColumnType, Al_Err_strInvalidDataColumnType,
"DataColumnType", strType);
160 catch(CStdErrorInfo oError)
162 if(lpColumn)
delete lpColumn;
168 if(lpColumn)
delete lpColumn;
169 THROW_ERROR(Std_Err_lUnspecifiedError, Std_Err_strUnspecifiedError);
190 if(strType ==
"CURRENT")
192 else if(strType ==
"VOLTAGECLAMP")
198 THROW_PARAM_ERROR(Nl_Err_lInvalidExternalStimulusType, Nl_Err_strInvalidExternalStimulusType,
"ExternalStimulusType", strType);
203 catch(CStdErrorInfo oError)
205 if(lpStimulus)
delete lpStimulus;
211 if(lpStimulus)
delete lpStimulus;
212 THROW_ERROR(Std_Err_lUnspecifiedError, Std_Err_strUnspecifiedError);
225 NeuralModule *lpModule=NULL;
231 if(strType ==
"FIRINGRATESIMMODULE")
237 THROW_PARAM_ERROR(Al_Err_lInvalidNeuralModuleType, Al_Err_strInvalidNeuralModuleType,
"NeuralModule", strType);
242 catch(CStdErrorInfo oError)
244 if(lpModule)
delete lpModule;
250 if(lpModule)
delete lpModule;
251 THROW_ERROR(Std_Err_lUnspecifiedError, Std_Err_strUnspecifiedError);
261 CStdSerialize *ClassFactory::CreateObject(std::string strClassType, std::string strObjectType,
bool bThrowError)
267 if(strClassType ==
"DATACOLUMN")
269 else if(strClassType ==
"EXTERNALSTIMULUS")
271 else if(strClassType ==
"NEURON")
273 else if(strClassType ==
"SYNAPSE")
275 else if(strClassType ==
"NEURALMODULE")
281 THROW_PARAM_ERROR(Std_Err_lInvalidClassType, Std_Err_strInvalidClassType,
"ClassType", strClassType);
Firing rate neural module.
Declares the gated synapse class.
Random firing rate neuron.
ClassFactory()
Default constructor.
Gated firing rate synapse.
Declares the random neuron class.
Bistable firing rate neuron.
Declares the bistable neuron class.
Modulated firing rate synapse.
virtual Neuron * CreateNeuron(std::string strType, bool bThrowError=true)
Creates a neuron.
virtual ExternalStimulus * CreateExternalStimulus(std::string strType, bool bThrowError=true)
Creates an external stimulus.
std::string Std_Trim(std::string strVal)
Trims a string.
virtual Synapse * CreateSynapse(std::string strType, bool bThrowError=true)
Creates a synapse.
Declares the modulated synapse class.
Firing Rate Neuron model.
virtual DataColumn * CreateDataColumn(std::string strType, bool bThrowError=true)
Creates a data column.
Current stimulus for neural items.
Declares the synapse class.
virtual ~ClassFactory()
Destructor.
Declares the firing rate module class.
Declares the pacemaker neuron class.
Firing rate synapse model for modulating neuron properties.
Declares the tonic neuron class.
Contains the classes for a firing rate neural model.
Firing rate synapse model.
std::string Std_ToUpper(std::string strVal)
Converts a string to upper case.
Tonic firing rate neuron.
virtual NeuralModule * CreateNeuralModule(std::string strType, bool bThrowError=true)
Creates a neural module.