コード例 #1
0
 private bool LoadTemplate(string templateName)
 {
     if (_template == null || templateName != TemplateName)
     {
         var templateType = Utils.GetType("WaveletStudio.SignalGeneration." + templateName);
         if (templateType == null)
         {
             return(false);
         }
         _template = (CommonSignalBase)Activator.CreateInstance(templateType);
     }
     _template.Amplitude        = Amplitude;
     _template.Frequency        = Frequency;
     _template.Phase            = Phase;
     _template.Offset           = Offset;
     _template.Start            = Start;
     _template.Finish           = Finish;
     _template.SamplingRate     = SamplingRate;
     _template.IgnoreLastSample = IgnoreLastSample;
     return(true);
 }
コード例 #2
0
 private bool LoadTemplate(string templateName)
 {
     if (_template == null || templateName != TemplateName)
     {
         var templateType = Utils.GetType("WaveletStudio.SignalGeneration." + templateName);
         if (templateType == null)
         {
             return false;
         }
         _template = (CommonSignalBase)Activator.CreateInstance(templateType);
     }
     _template.Amplitude = Amplitude;
     _template.Frequency = Frequency;
     _template.Phase = Phase;
     _template.Offset = Offset;
     _template.Start = Start;
     _template.Finish = Finish;
     _template.SamplingRate = SamplingRate;
     _template.IgnoreLastSample = IgnoreLastSample;
     return true;
 }