//------------------------------------------------------------------------------ bool SolverSequenceCommand::IsParameterReadOnly(const std::string& label) const { return IsParameterReadOnly(GetParameterID(label)); }
//------------------------------------------------------------------------------ bool BulirschStoer::IsParameterReadOnly(const std::string &label) const { return IsParameterReadOnly(GetParameterID(label)); }
//------------------------------------------------------------------------------ bool FileInterface::IsParameterReadOnly(const std::string& label) const { return IsParameterReadOnly(GetParameterID(label)); }
//--------------------------------------------------------------------------- bool CalculatedPoint::IsParameterReadOnly(const std::string &label) const { return IsParameterReadOnly(GetParameterID(label)); }
//--------------------------------------------------------------------------- bool GroundStation::IsParameterReadOnly(const std::string & label) const { return IsParameterReadOnly(GetParameterID(label)); }
//------------------------------------------------------------------------------ bool Propagator::IsParameterReadOnly(const wxString &label) const { return IsParameterReadOnly(GetParameterID(label)); }
//------------------------------------------------------------------------------ bool BodyFixedPoint::SetStringParameter(const Integer id, const std::string &value) { if (IsParameterReadOnly(id)) return false; static bool firstTimeWarning = true; bool retval = false; std::string stateTypeList = "Cartesian, Spherical"; std::string horizonList = "Sphere, Ellipsoid"; std::string currentStateType = stateType; std::string currentHorizon = horizon; if (id == CENTRAL_BODY) { if (value != SolarSystem::EARTH_NAME) { std::string errmsg = "The value of \"" + value + "\" for field \"CentralBody\"" " on object \"" + instanceName + "\" is not an allowed value.\n" "The allowed values are: [ " + SolarSystem::EARTH_NAME + " ]. "; throw AssetException(errmsg); } if (theBody) theBody = NULL; cBodyName = value; retval = true; } else if (id == STATE_TYPE) { std::string v = value; if (v == "Geographical") // deprecated value { v = "Spherical"; // write one warning per GMAT session if (firstTimeWarning) { std::string msg = "The value of \"" + value + "\" for field \"StateType\"" " on object \"" + instanceName + "\" is not an allowed value.\n" "The allowed values are: [ " + stateTypeList + " ]. "; MessageInterface::ShowMessage("*** WARNING *** " + msg + "\n"); firstTimeWarning = false; } } if ((v == "Cartesian") || (v == "Spherical")) { stateType = v; if (v == "Cartesian") { locationLabels[0] = "X"; locationLabels[1] = "Y"; locationLabels[2] = "Z"; locationUnits[0] = "km"; locationUnits[1] = "km"; locationUnits[2] = "km"; } else { locationLabels[0] = "Latitude"; locationLabels[1] = "Longitude"; locationLabels[2] = "Altitude"; locationUnits[0] = "deg"; locationUnits[1] = "deg"; locationUnits[2] = "km"; } if (currentStateType != stateType) { Rvector3 locIn(location[0], location[1], location[2]); Rvector3 locOut = BodyFixedStateConverterUtil::Convert(locIn, currentStateType, horizon, stateType, horizon, flattening, meanEquatorialRadius); location[0] = locOut[0]; location[1] = locOut[1]; location[2] = locOut[2]; } retval = true; } else { std::string errmsg = "The value of \"" + value + "\" for field \"StateType\"" " on object \"" + instanceName + "\" is not an allowed value.\n" "The allowed values are: [ " + stateTypeList + " ]. "; throw AssetException(errmsg); } } else if (id == HORIZON_REFERENCE) { if ((value == "Sphere") || (value == "Ellipsoid")) { horizon = value; if (currentHorizon != horizon) { Rvector3 locIn(location[0], location[1], location[2]); Rvector3 locOut = BodyFixedStateConverterUtil::Convert(locIn, stateType, currentHorizon, stateType, horizon, flattening, meanEquatorialRadius); location[0] = locOut[0]; location[1] = locOut[1]; location[2] = locOut[2]; } retval = true; } else { std::string errmsg = "The value of \"" + value + "\" for field \"HorizonReference\"" " on object \"" + instanceName + "\" is not an allowed value.\n" "The allowed values are: [ " + horizonList + " ]. "; throw AssetException(errmsg); } } else retval = SpacePoint::SetStringParameter(id, value); return retval; }
//------------------------------------------------------------------------------ bool PredictorCorrector::IsParameterReadOnly(const std::string &label) const { return IsParameterReadOnly(GetParameterID(label)); }
//------------------------------------------------------------------------------ bool Antenna::IsParameterReadOnly(const std::string& label) const { return IsParameterReadOnly(GetParameterID(label)); }
//--------------------------------------------------------------------------- bool Solver::IsParameterReadOnly(const wxString &label) const { return IsParameterReadOnly(GetParameterID(label)); }