Brief description of class still missing. More...
#include <NormalizationParameters.h>
Public Types | |
enum | Type { None, SurfaceAttenuation, VolumeAttenuation, MaximumAmplitude, SpectrumEnergy } |
Public Member Functions | |
virtual void | collectKeywords (PARAMETERS_COLLECTKEYWORDS_ARGS) |
virtual int | keywordCount (PARAMETERS_KEYWORDCOUNT_ARGS) |
double | maximumFrequency () const |
double | minimumFrequency () const |
NormalizationParameters () | |
void | setRange (double min, double max) |
void | setType (Type t) |
void | setType (const QString &t) |
virtual bool | setValue (PARAMETERS_SETVALUE_ARGS) |
virtual QString | toString (PARAMETERS_TOSTRING_ARGS_DECL) const |
Type | type () const |
QString | typeString () const |
Brief description of class still missing.
Full description of class still missing
void GeopsyCore::NormalizationParameters::collectKeywords | ( | PARAMETERS_COLLECTKEYWORDS_ARGS | ) | [virtual] |
Reimplemented from QGpCoreTools::AbstractParameters.
References TRACE.
Referenced by ArrayCore::LinearFKParameters::collectKeywords().
{ TRACE; keywords.add(prefix+"NORMALIZATION TYPE", this, 0); keywords.add(prefix+"NORMALIZATION MINIMUM", this, 1); keywords.add(prefix+"NORMALIZATION MAXIMUM", this, 2); }
Reimplemented from QGpCoreTools::AbstractParameters.
{
return 3;
}
double GeopsyCore::NormalizationParameters::maximumFrequency | ( | ) | const [inline] |
Referenced by LinearFKActiveStationSignals::normalize(), and GeopsyGui::NormalizationParameterWidget::setParameters().
{return _maxF;}
double GeopsyCore::NormalizationParameters::minimumFrequency | ( | ) | const [inline] |
Referenced by LinearFKActiveStationSignals::normalize(), and GeopsyGui::NormalizationParameterWidget::setParameters().
{return _minF;}
void GeopsyCore::NormalizationParameters::setRange | ( | double | min, |
double | max | ||
) |
References TRACE.
Referenced by ToolLinearFKActived::getParameters(), GeopsyGui::NormalizationParameterWidget::getParameters(), and setType().
{ TRACE; if(min<max) { _minF=min; _maxF=max; } else { _minF=max; _maxF=min; } }
References setRange(), SpectrumEnergy, and TRACE.
Referenced by ToolLinearFKActived::getParameters(), GeopsyGui::NormalizationParameterWidget::getParameters(), and setValue().
{ TRACE; _type=t; if(_type==SpectrumEnergy && _minF>_maxF) { setRange(_maxF, _minF); } }
void GeopsyCore::NormalizationParameters::setType | ( | const QString & | t | ) |
References QGpCoreTools::endl(), MaximumAmplitude, None, setRange(), SpectrumEnergy, SurfaceAttenuation, QGpCoreTools::tr(), and VolumeAttenuation.
{ if(t.count()>3) { QString lt=t.toLower(); switch(lt[2].unicode()) { case 'x': if(lt=="maximumamplitude") { _type=MaximumAmplitude; return; } break; case 'n': if(lt=="none") { _type=None; return; } break; case 'r': if(lt=="surfaceattenuation") { _type=SurfaceAttenuation; return; } break; case 'e': if(lt=="spectrumenergy") { _type=SpectrumEnergy; if(_minF>_maxF) { setRange(_maxF, _minF); } } break; case 'l': if(lt=="volumeattenuation") { _type=VolumeAttenuation; return; } default: break; } App::stream() << tr("Unrecognized normalization type: %1").arg(t) << endl; } }
bool GeopsyCore::NormalizationParameters::setValue | ( | PARAMETERS_SETVALUE_ARGS | ) | [virtual] |
Reimplemented from QGpCoreTools::AbstractParameters.
QString GeopsyCore::NormalizationParameters::toString | ( | PARAMETERS_TOSTRING_ARGS_DECL | ) | const [virtual] |
Reimplemented from QGpCoreTools::AbstractParameters.
References QGpCoreTools::log(), TRACE, and typeString().
Referenced by ArrayCore::LinearFKParameters::toString().
{ TRACE; QString log; log+=prefix+"NORMALIZATION TYPE="+typeString()+"\n"; log+=prefix+"NORMALIZATION MINIMUM="+QString::number(_minF)+"\n"; log+=prefix+"NORMALIZATION MAXIMUM="+QString::number(_maxF)+"\n"; return log; }
Type GeopsyCore::NormalizationParameters::type | ( | ) | const [inline] |
Referenced by LinearFKActiveStationSignals::normalize(), ToolLinearFKActived::setParameters(), and GeopsyGui::NormalizationParameterWidget::setParameters().
{return _type;}
QString GeopsyCore::NormalizationParameters::typeString | ( | ) | const |
References MaximumAmplitude, None, SpectrumEnergy, SurfaceAttenuation, and VolumeAttenuation.
Referenced by toString().
{ switch(_type) { case None: break; case SurfaceAttenuation: return "SurfaceAttenuation"; case VolumeAttenuation: return "VolumeAttenuation"; case MaximumAmplitude: return "MaximumAmplitude"; case SpectrumEnergy: return "SpectrumEnergy"; } return "None"; }