From b7f03c8d20f65902ea3074e53f7c273d4ca56436 Mon Sep 17 00:00:00 2001 From: Austin Sanders Date: Mon, 23 Sep 2024 11:32:37 -0600 Subject: [PATCH 1/4] Update std::tostring, stoi, stod to IString functions --- isis/src/apollo/apps/apollo2isis/main.cpp | 20 +- .../apollo/apps/apollofindrx/apollofindrx.cpp | 38 +- isis/src/apollo/apps/apollopaninit/main.cpp | 26 +- .../apollo/apps/apolloremrx/apolloremrx.cpp | 6 +- .../apollo/apps/apollowarp/WarpTransform.cpp | 6 +- isis/src/apollo/apps/apollowarp/main.cpp | 12 +- .../ApolloPanoramicCamera.cpp | 2 +- isis/src/base/apps/appjit/main.cpp | 2 +- isis/src/base/apps/ascii2isis/main.cpp | 2 +- isis/src/base/apps/autoregtemplate/main.cpp | 42 +- isis/src/base/apps/bit2bit/main.cpp | 32 +- isis/src/base/apps/cam2cam/cam2cam.cpp | 2 +- isis/src/base/apps/cam2map/cam2map.cpp | 44 +- isis/src/base/apps/caminfo/CamTools.cpp | 12 +- isis/src/base/apps/caminfo/CamTools.h | 2 +- isis/src/base/apps/camrange/camrange.cpp | 34 +- isis/src/base/apps/camstats/camstats.cpp | 2 +- isis/src/base/apps/center/main.cpp | 8 +- .../src/base/apps/ckwriter/CkSpiceSegment.cpp | 8 +- isis/src/base/apps/crop/crop.cpp | 20 +- isis/src/base/apps/cropspecial/main.cpp | 16 +- isis/src/base/apps/csminit/csminit.cpp | 2 +- isis/src/base/apps/cubeavg/main.cpp | 10 +- isis/src/base/apps/cubediff/main.cpp | 38 +- isis/src/base/apps/cubefunc/main.cpp | 2 +- isis/src/base/apps/cubenorm/main.cpp | 32 +- isis/src/base/apps/ddd2isis/main.cpp | 12 +- isis/src/base/apps/demprep/demprep.cpp | 12 +- isis/src/base/apps/errors/main.cpp | 2 +- isis/src/base/apps/fillgap/fillgap.cpp | 2 +- .../base/apps/findgaps/FindGapsFunctor.cpp | 22 +- .../findimageoverlaps/findimageoverlaps.cpp | 2 +- isis/src/base/apps/findrx/main.cpp | 24 +- .../base/apps/footprintinit/footprintinit.cpp | 4 +- isis/src/base/apps/footprintmerge/main.cpp | 4 +- .../src/base/apps/framestitch/framestitch.cpp | 4 +- isis/src/base/apps/isis2fits/main.cpp | 4 +- isis/src/base/apps/isis2pds/isis2pds.cpp | 28 +- isis/src/base/apps/isis2raw/main.cpp | 14 +- isis/src/base/apps/isis2std/isis2std.cpp | 4 +- .../base/apps/isisimport/CassiniImportUtils.h | 18 +- isis/src/base/apps/isisimport/isisimport.cpp | 16 +- .../apps/isisminer/StereoPairStrategy.cpp | 4 +- isis/src/base/apps/kernfilter/main.cpp | 2 +- isis/src/base/apps/lineeq/main.cpp | 4 +- isis/src/base/apps/makeflat/main.cpp | 18 +- isis/src/base/apps/map2map/main.cpp | 16 +- isis/src/base/apps/map2map/map2map.cpp | 28 +- isis/src/base/apps/mapgrid/main.cpp | 8 +- isis/src/base/apps/maplab/main.cpp | 8 +- isis/src/base/apps/mapmos/mapmos.cpp | 8 +- isis/src/base/apps/mappt/mappt.cpp | 24 +- isis/src/base/apps/mapsize/main.cpp | 16 +- isis/src/base/apps/maptemplate/main.cpp | 40 +- isis/src/base/apps/mask/main.cpp | 4 +- isis/src/base/apps/mosrange/mosrange.cpp | 64 +- isis/src/base/apps/mvstats/main.cpp | 4 +- isis/src/base/apps/nocam2map/nocam2map.cpp | 46 +- isis/src/base/apps/noisefilter/main.cpp | 10 +- isis/src/base/apps/noproj/noproj.cpp | 40 +- .../base/apps/overlapstats/overlapstats.cpp | 40 +- isis/src/base/apps/pad/main.cpp | 16 +- isis/src/base/apps/percent/main.cpp | 4 +- isis/src/base/apps/phoempglobal/main.cpp | 12 +- isis/src/base/apps/phoemplocal/main.cpp | 18 +- isis/src/base/apps/phohillier/Hillier.cpp | 32 +- isis/src/base/apps/phohillier/Hillier.h | 4 +- isis/src/base/apps/photemplate/main.cpp | 4 +- isis/src/base/apps/photomet/main.cpp | 2 +- isis/src/base/apps/pixel2map/main.cpp | 52 +- isis/src/base/apps/pvldiff/main.cpp | 2 +- isis/src/base/apps/remrx/main.cpp | 22 +- isis/src/base/apps/ringscam2map/main.cpp | 44 +- isis/src/base/apps/ringsmappt/main.cpp | 18 +- .../apps/ringspt/CameraRingsPointInfo.cpp | 96 +-- isis/src/base/apps/shadow/ShadowFunctor.cpp | 28 +- isis/src/base/apps/shadowtau/main.cpp | 28 +- isis/src/base/apps/skymap/main.cpp | 42 +- isis/src/base/apps/skypt/skypt.cpp | 12 +- isis/src/base/apps/skyrange/main.cpp | 22 +- isis/src/base/apps/slpmap/main.cpp | 2 +- isis/src/base/apps/smtk/main.cpp | 20 +- isis/src/base/apps/spechighpass/main.cpp | 4 +- isis/src/base/apps/specpix/main.cpp | 12 +- isis/src/base/apps/spiceinit/spiceinit.cpp | 8 +- .../src/base/apps/spiceserver/spiceserver.cpp | 12 +- .../src/base/apps/spkwriter/SpkKernelWriter.h | 2 +- isis/src/base/apps/stats/stats.cpp | 38 +- isis/src/base/apps/trackextract/main.cpp | 2 +- isis/src/base/objs/AlbedoAtm/AlbedoAtm.cpp | 6 +- isis/src/base/objs/AlphaCube/AlphaCube.cpp | 32 +- .../src/base/objs/Application/Application.cpp | 2 +- isis/src/base/objs/AutoReg/AutoReg.cpp | 48 +- isis/src/base/objs/CSVReader/CSVReader.cpp | 2 +- isis/src/base/objs/CSVReader/unitTest.cpp | 2 +- isis/src/base/objs/Camera/Camera.cpp | 28 +- isis/src/base/objs/Camera/unitTest.cpp | 8 +- .../objs/CameraPointInfo/CameraPointInfo.cpp | 146 ++-- .../base/objs/CameraPointInfo/unitTest.cpp | 8 +- .../CameraStatistics/CameraStatistics.cpp | 6 +- .../base/objs/CameraStatistics/unitTest.cpp | 2 +- isis/src/base/objs/Cube/Cube.cpp | 36 +- isis/src/base/objs/Cube/CubeBsqHandler.cpp | 8 +- isis/src/base/objs/Cube/CubeTileHandler.cpp | 12 +- .../base/objs/CubeAttribute/CubeAttribute.h | 2 +- .../objs/CubeDataThread/CubeDataThread.cpp | 4 +- .../src/base/objs/CubeStretch/CubeStretch.cpp | 4 +- isis/src/base/objs/DemShape/unitTest.cpp | 2 +- .../src/base/objs/EllipsoidShape/unitTest.cpp | 2 +- isis/src/base/objs/Enlarge/Enlarge.cpp | 20 +- .../base/objs/Equalization/Equalization.cpp | 28 +- .../EquatorialCylindricalShape/unitTest.cpp | 2 +- .../objs/Equirectangular/Equirectangular.cpp | 6 +- .../base/objs/Equirectangular/unitTest.cpp | 24 +- .../objs/ExportPdsTable/ExportPdsTable.cpp | 14 +- .../src/base/objs/ExportPdsTable/unitTest.cpp | 10 +- isis/src/base/objs/FitsToJson/FitsToJson.cpp | 6 +- .../GridPolygonSeeder/GridPolygonSeeder.cpp | 10 +- .../base/objs/GridPolygonSeeder/unitTest.cpp | 22 +- isis/src/base/objs/GroundGrid/GroundGrid.cpp | 8 +- isis/src/base/objs/Gruen/Gruen.cpp | 28 +- isis/src/base/objs/Gruen/Gruen.h | 4 +- isis/src/base/objs/Gruen/unitTest.cpp | 16 +- isis/src/base/objs/Hapke/unitTest.cpp | 60 +- isis/src/base/objs/Hillshade/Hillshade.cpp | 2 +- .../src/base/objs/IdealCamera/IdealCamera.cpp | 2 +- .../base/objs/ImageExporter/ImageExporter.cpp | 2 +- .../objs/ImportPdsTable/ImportPdsTable.cpp | 20 +- .../objs/InfixToPostfix/InfixToPostfix.cpp | 2 +- .../LambertAzimuthalEqualArea.cpp | 4 +- .../LambertAzimuthalEqualArea/unitTest.cpp | 6 +- .../LambertConformal/LambertConformal.cpp | 4 +- isis/src/base/objs/Latitude/Latitude.cpp | 28 +- .../LimitPolygonSeeder/LimitPolygonSeeder.cpp | 8 +- .../objs/LunarAzimuthalEqualArea/unitTest.cpp | 18 +- .../LunarLambertEmpirical.cpp | 8 +- .../objs/LunarLambertEmpirical/unitTest.cpp | 6 +- isis/src/base/objs/Mercator/Mercator.cpp | 4 +- .../MinnaertEmpirical/MinnaertEmpirical.cpp | 6 +- .../base/objs/MinnaertEmpirical/unitTest.cpp | 6 +- isis/src/base/objs/Mollweide/Mollweide.cpp | 2 +- isis/src/base/objs/Mollweide/unitTest.cpp | 16 +- .../MultivariateStatistics.cpp | 16 +- .../NaifDskPlateModel/NaifDskPlateModel.cpp | 2 +- .../ObliqueCylindrical/ObliqueCylindrical.cpp | 24 +- .../base/objs/ObliqueCylindrical/unitTest.cpp | 18 +- .../ObservationNumber/ObservationNumber.cpp | 2 +- .../OriginalXmlLabel/OriginalXmlLabel.cpp | 2 +- .../base/objs/Orthographic/Orthographic.cpp | 4 +- .../OverlapStatistics/OverlapStatistics.cpp | 38 +- isis/src/base/objs/Pipeline/Pipeline.cpp | 4 +- isis/src/base/objs/Planar/Planar.cpp | 8 +- isis/src/base/objs/PlaneShape/unitTest.cpp | 2 +- .../PointPerspective/PointPerspective.cpp | 4 +- .../base/objs/PointPerspective/unitTest.cpp | 40 +- .../PolarStereographic/PolarStereographic.cpp | 6 +- .../base/objs/PolarStereographic/unitTest.cpp | 20 +- .../base/objs/PolygonSeeder/PolygonSeeder.cpp | 8 +- .../PrincipalComponentAnalysis.cpp | 4 +- .../ProcessExportPds/ProcessExportPds.cpp | 200 ++--- .../ProcessImportFits/ProcessImportFits.cpp | 48 +- .../ProcessImportPds/ProcessImportPds.cpp | 50 +- .../ProcessMapMosaic/ProcessMapMosaic.cpp | 36 +- .../base/objs/ProcessMapMosaic/unitTest.cpp | 8 +- .../base/objs/ProcessMosaic/ProcessMosaic.cpp | 10 +- isis/src/base/objs/Projection/Projection.cpp | 4 +- isis/src/base/objs/Projection/unitTest.cpp | 24 +- .../ProjectionFactory/ProjectionFactory.cpp | 32 +- .../base/objs/ProjectionFactory/unitTest.cpp | 124 +-- .../RadarSlantRangeMap/RadarSlantRangeMap.cpp | 8 +- isis/src/base/objs/Reduce/Reduce.cpp | 20 +- .../ReseauDistortionMap.cpp | 8 +- .../objs/RingCylindrical/RingCylindrical.cpp | 8 +- isis/src/base/objs/Robinson/Robinson.cpp | 2 +- .../base/objs/SerialNumber/SerialNumber.cpp | 2 +- isis/src/base/objs/SessionLog/unitTest.cpp | 6 +- .../ShapeModelFactory/ShapeModelFactory.cpp | 4 +- .../base/objs/ShapeModelFactory/unitTest.cpp | 8 +- .../SimpleCylindrical/SimpleCylindrical.cpp | 2 +- .../base/objs/SimpleCylindrical/unitTest.cpp | 16 +- isis/src/base/objs/Sinusoidal/Sinusoidal.cpp | 2 +- isis/src/base/objs/Sinusoidal/unitTest.cpp | 16 +- isis/src/base/objs/Spice/Spice.cpp | 14 +- isis/src/base/objs/Spice/unitTest.cpp | 4 +- .../base/objs/SpicePosition/SpicePosition.cpp | 12 +- isis/src/base/objs/SpicePosition/unitTest.cpp | 6 +- .../base/objs/SpiceRotation/SpiceRotation.cpp | 60 +- isis/src/base/objs/Statistics/Statistics.cpp | 44 +- isis/src/base/objs/Stretch/Stretch.cpp | 6 +- .../StripPolygonSeeder/StripPolygonSeeder.cpp | 8 +- .../base/objs/StripPolygonSeeder/unitTest.cpp | 16 +- isis/src/base/objs/SubArea/SubArea.cpp | 18 +- isis/src/base/objs/SubArea/unitTest.cpp | 220 +++--- .../src/base/objs/TProjection/TProjection.cpp | 34 +- isis/src/base/objs/Target/Target.cpp | 20 +- isis/src/base/objs/Target/unitTest.cpp | 10 +- .../base/objs/TiffImporter/TiffImporter.cpp | 20 +- .../TransverseMercator/TransverseMercator.cpp | 6 +- .../base/objs/TransverseMercator/unitTest.cpp | 40 +- .../UpturnedEllipsoidTransverseAzimuthal.cpp | 14 +- .../unitTest.cpp | 2 +- .../base/objs/UserInterface/UserInterface.cpp | 2 +- .../XmlToPvlTranslationManager.cpp | 2 +- isis/src/cassini/apps/ciss2isis/ciss2isis.cpp | 16 +- isis/src/cassini/apps/cisscal/DarkCurrent.cpp | 2 +- isis/src/cassini/apps/cisscal/main.cpp | 28 +- isis/src/cassini/apps/vims2isis/main.cpp | 14 +- isis/src/cassini/apps/vimscal/main.cpp | 14 +- .../cassini/objs/CissLabels/CissLabels.cpp | 2 +- .../cassini/objs/VimsCamera/VimsGroundMap.cpp | 6 +- .../cassini/objs/VimsCamera/VimsSkyMap.cpp | 6 +- .../apps/chan1m32isis/chan1m32isis.cpp | 16 +- isis/src/clementine/apps/clem2isis/main.cpp | 4 +- isis/src/clementine/apps/clemnircal/main.cpp | 20 +- .../src/clementine/apps/clemuvviscal/main.cpp | 34 +- isis/src/clipper/apps/eis2isis/eis2isis.cpp | 16 +- isis/src/clipper/apps/jitterfit/jitterfit.cpp | 8 +- .../ClipperNacRollingShutterCamera.cpp | 4 +- .../ClipperPushBroomCamera.cpp | 2 +- isis/src/control/apps/autoseed/autoseed.cpp | 12 +- isis/src/control/apps/cnet2dem/main.cpp | 2 +- isis/src/control/apps/cnetcheck/cnetcheck.cpp | 16 +- .../apps/cnetcombinept/cnetcombinept.cpp | 18 +- isis/src/control/apps/cnetdiff/cnetdiff.cpp | 2 +- isis/src/control/apps/cnetedit/cnetedit.cpp | 6 +- .../control/apps/cnetextract/cnetextract.cpp | 34 +- isis/src/control/apps/cnetnewradii/main.cpp | 8 +- .../apps/cnetref/CnetRefByEmission.cpp | 18 +- .../apps/cnetref/CnetRefByIncidence.cpp | 18 +- .../apps/cnetref/CnetRefByResolution.cpp | 20 +- isis/src/control/apps/coreg/main.cpp | 16 +- isis/src/control/apps/deltack/main.cpp | 30 +- .../control/apps/findfeatures/ImageSource.cpp | 2 +- .../control/apps/findfeatures/MatchMaker.cpp | 26 +- .../apps/findfeatures/MatcherAlgorithms.cpp | 2 +- .../apps/findfeatures/findfeatures.cpp | 12 +- isis/src/control/apps/fplanemap/main.cpp | 16 +- isis/src/control/apps/mat2cnet/main.cpp | 2 +- isis/src/control/apps/pointreg/pointreg.cpp | 12 +- isis/src/control/apps/seedgrid/main.cpp | 16 +- isis/src/control/apps/sumspice/SumFinder.cpp | 2 +- isis/src/control/apps/warp/WarpTransform.cpp | 6 +- .../objs/BundleAdjust/BundleAdjust.cpp | 34 +- .../objs/BundleResults/BundleResults.cpp | 2 +- .../BundleObservationSolveSettings.cpp | 4 +- .../ControlMeasureLogData.cpp | 6 +- .../objs/ControlMeasureLogData/unitTest.cpp | 2 +- isis/src/control/objs/ControlNet/unitTest.cpp | 8 +- .../objs/ControlNetDiff/ControlNetDiff.cpp | 10 +- .../ControlNetFilter/ControlNetFilter.cpp | 12 +- .../objs/ControlNetFilter/unitTest.cpp | 34 +- .../ControlNetStatistics.cpp | 72 +- .../ControlNetValidMeasure.cpp | 90 +-- .../objs/ControlNetValidMeasure/unitTest.cpp | 148 ++-- .../ControlNetVersioner.cpp | 110 +-- .../ControlNetVersioner/ControlPointV0001.cpp | 102 +-- .../ControlNetVersioner/ControlPointV0002.cpp | 38 +- .../ControlNetVersioner/ControlPointV0003.cpp | 28 +- .../objs/ControlPoint/ControlPoint.cpp | 4 +- .../ControlPointList/ControlPointList.cpp | 6 +- .../InterestOperator/InterestOperator.cpp | 46 +- .../objs/InterestOperator/unitTest.cpp | 22 +- isis/src/core/src/Blob.cpp | 8 +- isis/src/core/src/FileName.cpp | 6 +- isis/src/core/src/IException.cpp | 2 +- isis/src/core/src/Preference.cpp | 2 +- isis/src/core/src/PvlKeyword.cpp | 16 +- isis/src/core/src/Table.cpp | 6 +- isis/src/core/src/TableField.cpp | 22 +- isis/src/core/tests/PvlKeywordTests.cpp | 18 + .../src/dawn/apps/dawnfc2isis/dawnfc2isis.cpp | 8 +- .../dawn/objs/DawnFcCamera/DawnFcCamera.cpp | 2 +- .../dawn/objs/DawnVirCamera/DawnVirCamera.cpp | 20 +- isis/src/dev/apps/camcoeffs/main.cpp | 24 +- isis/src/dev/apps/camtest/main.cpp | 14 +- isis/src/galileo/apps/gllnims2isis/main.cpp | 10 +- isis/src/galileo/apps/gllssi2isis/main.cpp | 4 +- isis/src/galileo/apps/gllssical/gllssical.cpp | 62 +- .../apps/amica2isis/AmicaImportFits.cpp | 12 +- isis/src/hayabusa/apps/amica2isis/main.cpp | 2 +- isis/src/hayabusa/apps/amicacal/main.cpp | 28 +- .../apps/nirs2isis/NirsImportFits.cpp | 12 +- isis/src/hayabusa/apps/nirs2isis/main.cpp | 6 +- .../apps/hyb2onc2isis/hyb2onc2isis.cpp | 2 +- isis/src/hayabusa2/apps/hyb2onccal/main.cpp | 10 +- isis/src/juno/apps/junocam2isis/main.cpp | 14 +- isis/src/juno/objs/JunoCamera/unitTest.cpp | 2 +- .../apps/kaguyami2isis/kaguyami2isis.cpp | 2 +- isis/src/kaguya/apps/kaguyasp2ascii/main.cpp | 50 +- isis/src/kaguya/apps/kaguyasp2isis/main.cpp | 40 +- .../src/kaguya/apps/mimap2isis/mimap2isis.cpp | 4 +- isis/src/lo/apps/lo2isis/lo2isis.cpp | 2 +- isis/src/lo/apps/lopdsgen/main.cpp | 4 +- .../LoCameraFiducialMap.cpp | 8 +- isis/src/lro/apps/lromakeflat/main.cpp | 6 +- isis/src/lro/apps/lronac2isis/lronac2isis.cpp | 6 +- isis/src/lro/apps/lronac2pds/lronac2pds.cpp | 36 +- isis/src/lro/apps/lronaccal/lronaccal.cpp | 20 +- isis/src/lro/apps/lronacpho/LROCEmpirical.cpp | 26 +- isis/src/lro/apps/lrowac2isis/lrowac2isis.cpp | 20 +- isis/src/lro/apps/lrowac2pds/lrowac2pds.cpp | 20 +- isis/src/lro/apps/lrowaccal/lrowaccal.cpp | 14 +- isis/src/lro/apps/lrowacpho/Exponential.cpp | 24 +- .../lro/apps/lrowacpho/HapkeExponential.cpp | 24 +- isis/src/lro/apps/lrowacpho/Hillier.cpp | 30 +- isis/src/lro/apps/lrowacphomap/HapkeLRO.cpp | 18 +- isis/src/lro/apps/lrowacphomap/HapkeLROC.cpp | 18 +- isis/src/lro/apps/mrf2isis/main.cpp | 6 +- .../LroWideAngleCamera/LroWideAngleCamera.cpp | 16 +- isis/src/mariner/apps/mar10cal/main.cpp | 2 +- isis/src/mer/apps/mical/MiCalibration.cpp | 4 +- isis/src/mer/apps/mical/main.cpp | 18 +- isis/src/messenger/apps/mdis2isis/main.cpp | 12 +- isis/src/messenger/apps/mdis2pds/main.cpp | 14 +- isis/src/messenger/apps/mdiscal/main.cpp | 24 +- isis/src/messenger/apps/mdisddr/main.cpp | 2 +- isis/src/mgs/apps/moc2isis/main.cpp | 20 +- isis/src/mgs/apps/moccal/moccal.cpp | 18 +- isis/src/mgs/apps/mocnoise50/main.cpp | 10 +- isis/src/mro/apps/crism2isis/crism2isis.cpp | 6 +- isis/src/mro/apps/ctxcal/ctxcal.cpp | 2 +- isis/src/mro/apps/hi2isis/hi2isis.cpp | 84 +- isis/src/mro/apps/hicalproc/main.cpp | 6 +- isis/src/mro/apps/hiccdstitch/main.cpp | 12 +- isis/src/mro/apps/hicolormos/hicolormos.cpp | 14 +- isis/src/mro/apps/hicrop/hicrop.cpp | 10 +- isis/src/mro/apps/hicubenorm/hicubenorm.cpp | 42 +- isis/src/mro/apps/hideal2pds/main.cpp | 38 +- isis/src/mro/apps/hidtmgen/hidtmgen.cpp | 26 +- isis/src/mro/apps/hifringe/main.cpp | 32 +- isis/src/mro/apps/hifurrows/main.cpp | 2 +- isis/src/mro/apps/hijitreg/main.cpp | 6 +- isis/src/mro/apps/himos/himos.cpp | 14 +- isis/src/mro/apps/hinoise/main.cpp | 4 +- isis/src/mro/apps/hirdrgen/main.cpp | 28 +- isis/src/mro/apps/histat/main.cpp | 24 +- isis/src/mro/apps/histitch/main.cpp | 16 +- isis/src/mro/apps/marci2isis/marci2isis.cpp | 18 +- isis/src/mro/apps/marcical/marcical.cpp | 16 +- isis/src/mro/apps/marciflip/marciflip.cpp | 2 +- isis/src/mro/apps/mroctx2isis/main.cpp | 10 +- isis/src/mro/apps/pds2hideal/main.cpp | 18 +- isis/src/near/apps/msi2isis/msi2isis.cpp | 4 +- .../apps/leisa2isis/leisa2isis.cpp | 2 +- .../newhorizons/apps/mvic2isis/mvic2isis.cpp | 2 +- .../NewHorizonsLeisaCamera.cpp | 2 +- .../NewHorizonsMvicFrameCamera.cpp | 2 +- isis/src/odyssey/apps/thm2isis/thm2isis.cpp | 10 +- isis/src/odyssey/apps/thmnoseam/main.cpp | 2 +- isis/src/odyssey/apps/thmvisflat/main.cpp | 4 +- isis/src/odyssey/apps/thmvistrim/main.cpp | 2 +- .../objs/ThemisIrCamera/ThemisIrCamera.cpp | 2 +- .../objs/ThemisVisCamera/ThemisVisCamera.cpp | 2 +- .../apps/tagcams2isis/tagcams2isis.cpp | 4 +- .../qisis/objs/CubeViewport/CubeViewport.cpp | 34 +- .../objs/Directory/ExportImagesWorkOrder.cpp | 2 +- isis/src/qisis/objs/FileTool/FileTool.cpp | 20 +- .../ImageFileListWidget.cpp | 6 +- .../objs/MosaicSceneWidget/MosaicAreaTool.cpp | 2 +- .../MosaicControlNetTool.cpp | 12 +- .../objs/MosaicSceneWidget/MosaicFindTool.cpp | 2 +- .../objs/MosaicSceneWidget/MosaicGridTool.cpp | 48 +- .../MosaicSceneWidget/MosaicSceneWidget.cpp | 16 +- .../objs/ScatterPlotTool/ScatterPlotData.cpp | 8 +- isis/src/qisis/objs/Shape/Shape.cpp | 12 +- .../SpectralPlotTool/SpectralPlotTool.cpp | 2 +- .../SpectralPlotTool/SpectralPlotWindow.cpp | 8 +- .../qisis/objs/StretchTool/StretchTool.cpp | 6 +- isis/src/rosetta/apps/rososiris2isis/main.cpp | 14 +- isis/src/rosetta/apps/rosvirtis2isis/main.cpp | 10 +- .../RosettaVirtisCamera.cpp | 20 +- .../socetlinescankeywords.cpp | 4 +- .../system/apps/isisdataeval/isisdataeval.cpp | 32 +- .../system/apps/kerneldbgen/kerneldbgen.cpp | 14 +- .../apps/prtloganalyzer/ProgramAnalyzer.cpp | 22 +- .../apps/tgocassis2isis/tgocassis2isis.cpp | 6 +- .../tgo/apps/tgocassismos/tgocassismos.cpp | 14 +- .../apps/tgocassisstitch/tgocassisstitch.cpp | 8 +- .../tgocassisunstitch/tgocassisunstitch.cpp | 20 +- .../objs/TgoCassisCamera/TgoCassisCamera.cpp | 4 +- .../src/tgo/objs/TgoCassisCamera/unitTest.cpp | 2 +- isis/src/viking/apps/vik2isis/main.cpp | 8 +- isis/src/viking/apps/vikcal/main.cpp | 28 +- isis/src/viking/apps/vikcal/vikcal.cpp | 28 +- isis/src/voyager/apps/voy2isis/main.cpp | 8 +- isis/src/voyager/apps/voycal/main.cpp | 16 +- isis/src/voyager/apps/voyramp/main.cpp | 6 +- isis/tests/CameraFixtures.cpp | 12 +- isis/tests/CubeFixtures.cpp | 8 +- isis/tests/FunctionalTestsApollofindrx.cpp | 18 +- isis/tests/FunctionalTestsApolloremrx.cpp | 18 +- isis/tests/FunctionalTestsCaminfo.cpp | 4 +- isis/tests/FunctionalTestsCampt.cpp | 36 +- isis/tests/FunctionalTestsChan1m32isis.cpp | 56 +- isis/tests/FunctionalTestsFootprintinit.cpp | 4 +- isis/tests/FunctionalTestsFrameStitch.cpp | 6 +- isis/tests/FunctionalTestsHicubenorm.cpp | 8 +- isis/tests/FunctionalTestsHimos.cpp | 14 +- isis/tests/FunctionalTestsIsisImport.cpp | 6 +- isis/tests/FunctionalTestsIsisImportLo.cpp | 38 +- isis/tests/FunctionalTestsJitterfit.cpp | 12 +- isis/tests/FunctionalTestsLeisa2isis.cpp | 48 +- isis/tests/FunctionalTestsLo2isis.cpp | 38 +- isis/tests/FunctionalTestsLorri2isis.cpp | 8 +- isis/tests/FunctionalTestsLrowac2isis.cpp | 48 +- isis/tests/FunctionalTestsMimap2isis.cpp | 718 +++++++++--------- isis/tests/FunctionalTestsPds2isis.cpp | 154 ++-- isis/tests/FunctionalTestsPhocube.cpp | 12 +- isis/tests/FunctionalTestsSumspice.cpp | 4 +- isis/tests/TestUtilities.cpp | 8 +- 410 files changed, 3998 insertions(+), 3980 deletions(-) diff --git a/isis/src/apollo/apps/apollo2isis/main.cpp b/isis/src/apollo/apps/apollo2isis/main.cpp index 586cfd7d03..744983832c 100644 --- a/isis/src/apollo/apps/apollo2isis/main.cpp +++ b/isis/src/apollo/apps/apollo2isis/main.cpp @@ -239,9 +239,9 @@ void TranslateApolloLabels (IString filename, Cube *opack) { PvlGroup error("ERROR"); error.addComment("The decrypted code is invalid."); for (int i=0; i<4; i++) { - PvlKeyword keyword("Column"+toString(i+1)); + PvlKeyword keyword("Column"+Isis::toString(i+1)); for (int j=0; j<32; j++) { - keyword += toString((int)code[i][j]); + keyword += Isis::toString((int)code[i][j]); } error.addKeyword(keyword); codeGroup += keyword; @@ -250,17 +250,17 @@ void TranslateApolloLabels (IString filename, Cube *opack) { } else { codeGroup += PvlKeyword("StartTime", FrameTime().toStdString()); - codeGroup += PvlKeyword("SpacecraftAltitude", toString(Altitude()),"meters"); + codeGroup += PvlKeyword("SpacecraftAltitude", Isis::toString(Altitude()),"meters"); if (apollo->IsMetric()){ - codeGroup += PvlKeyword("ExposureDuration", toString(ShutterInterval()), "milliseconds"); + codeGroup += PvlKeyword("ExposureDuration", Isis::toString(ShutterInterval()), "milliseconds"); codeGroup += PvlKeyword("ForwardMotionCompensation", FMC().toStdString()); } for (int i=0; i<4; i++) { - PvlKeyword keyword("Column"+ toString(i+1)); + PvlKeyword keyword("Column"+ Isis::toString(i+1)); for (int j=0; j<32; j++) { - keyword += toString((int)code[i][j]); + keyword += Isis::toString((int)code[i][j]); } codeGroup += keyword; } @@ -284,17 +284,17 @@ void TranslateApolloLabels (IString filename, Cube *opack) { // Update reseau locations based on refined code location for (int i=0; i<(reseaus->findKeyword("Type")).size(); i++) { - double x = IString::ToDouble(reseaus->findKeyword("Sample")[i]) + sampleTranslation + 2278, - y = IString::ToDouble(reseaus->findKeyword("Line")[i]) + lineTranslation - 20231; + double x = Isis::toDouble(reseaus->findKeyword("Sample")[i]) + sampleTranslation + 2278, + y = Isis::toDouble(reseaus->findKeyword("Line")[i]) + lineTranslation - 20231; if (apollo->IsApollo17()) { x += 50; y += 20; } - reseaus->findKeyword("Sample")[i] = toString( + reseaus->findKeyword("Sample")[i] = Isis::toString( cos(rotation)*(x-sampleTranslation) - sin(rotation)*(y-lineTranslation) + sampleTranslation); - reseaus->findKeyword("Line")[i] = toString( + reseaus->findKeyword("Line")[i] = Isis::toString( sin(rotation)*(x-sampleTranslation) + cos(rotation)*(y-lineTranslation) + lineTranslation); } inst += PvlKeyword("StartTime", utcTime.toStdString()); diff --git a/isis/src/apollo/apps/apollofindrx/apollofindrx.cpp b/isis/src/apollo/apps/apollofindrx/apollofindrx.cpp index 214ab57742..0f3a4b9c8d 100644 --- a/isis/src/apollo/apps/apollofindrx/apollofindrx.cpp +++ b/isis/src/apollo/apps/apollofindrx/apollofindrx.cpp @@ -66,20 +66,20 @@ namespace Isis { int nres = reseaus["Line"].size(); if (nres != reseaus["Sample"].size()) { std::string msg = "Sample size incorrect [Sample size " + - toString(reseaus["Sample"].size()) + " != " + " Line size " + - toString(reseaus["Line"].size()) + "]"; + Isis::toString(reseaus["Sample"].size()) + " != " + " Line size " + + Isis::toString(reseaus["Line"].size()) + "]"; throw IException(IException::Unknown, msg, _FILEINFO_); } if (nres != reseaus["Type"].size()) { std::string msg = "Type size incorrect [Type size " + - toString(reseaus["Type"].size()) + " != " + " Line size " + - toString(reseaus["Line"].size()) + "]"; + Isis::toString(reseaus["Type"].size()) + " != " + " Line size " + + Isis::toString(reseaus["Line"].size()) + "]"; throw IException(IException::Unknown, msg, _FILEINFO_); } if (nres != reseaus["Valid"].size()) { std::string msg = "Valid size incorrect [Valid size " + - toString(reseaus["Valid"].size()) + " != " + " Line size " + - toString(reseaus["Line"].size()) + "]"; + Isis::toString(reseaus["Valid"].size()) + " != " + " Line size " + + Isis::toString(reseaus["Line"].size()) + "]"; throw IException(IException::Unknown, msg, _FILEINFO_); } @@ -106,8 +106,8 @@ namespace Isis { int validReseaus = 0; // for (int res=0; res 0 && reseaus["Valid"][res-1] == "1") dy = currentLine - patternSize/2 - dl + bestLine-1 - IString::ToDouble(reseaus["Line"][res]); - if (res/dim > 0 && reseaus["Valid"][res - dim] == "1") dx = currentSample - patternSize/2 - ds + bestSample-1 - IString::ToDouble(reseaus["Sample"][res]); - double horizontalShift = currentSample - patternSize/2 - ds + bestSample-1 - IString::ToDouble(reseaus["Sample"][res]) - dx, - verticalShift = currentLine - patternSize/2 - dl + bestLine-1 - IString::ToDouble(reseaus["Line"][res]) - dy; + if (res%dim > 0 && reseaus["Valid"][res-1] == "1") dy = currentLine - patternSize/2 - dl + bestLine-1 - Isis::toDouble(reseaus["Line"][res]); + if (res/dim > 0 && reseaus["Valid"][res - dim] == "1") dx = currentSample - patternSize/2 - ds + bestSample-1 - Isis::toDouble(reseaus["Sample"][res]); + double horizontalShift = currentSample - patternSize/2 - ds + bestSample-1 - Isis::toDouble(reseaus["Sample"][res]) - dx, + verticalShift = currentLine - patternSize/2 - dl + bestLine-1 - Isis::toDouble(reseaus["Line"][res]) - dy; for (int i=res; i xy; xy.push_back(res%(int)sqrt(nres)); xy.push_back(res/(int)sqrt(nres)); - sampFunc.AddKnown(xy, IString::ToDouble(reseaus["Sample"][res])); - lineFunc.AddKnown(xy, IString::ToDouble(reseaus["Line"][res])); + sampFunc.AddKnown(xy, Isis::toDouble(reseaus["Sample"][res])); + lineFunc.AddKnown(xy, Isis::toDouble(reseaus["Line"][res])); ds = (int)(MIN_DISP+ abs(dx) + abs(horizontalShift)); dl = (int)(MIN_DISP + abs(dy) + abs(verticalShift)); @@ -150,12 +150,12 @@ namespace Isis { // for invalid reseaus, refine the estimated locations for (int res=0; res xy; xy.push_back(res%(int)sqrt(nres)); xy.push_back(res/(int)sqrt(nres)); - reseaus["Sample"][res] = toString(sampFunc.Evaluate(xy)); - reseaus["Line"][res] = toString(lineFunc.Evaluate(xy)); + reseaus["Sample"][res] = Isis::toString(sampFunc.Evaluate(xy)); + reseaus["Line"][res] = Isis::toString(lineFunc.Evaluate(xy)); } } diff --git a/isis/src/apollo/apps/apollopaninit/main.cpp b/isis/src/apollo/apps/apollopaninit/main.cpp index 8a885ebd2d..866c6d40ec 100644 --- a/isis/src/apollo/apps/apollopaninit/main.cpp +++ b/isis/src/apollo/apps/apollopaninit/main.cpp @@ -181,7 +181,7 @@ void IsisMain() { keyword.setName("LineExposureDuration"); //converted led to msec/mm--negative sign to account for the anti-parallel time and line axes - keyword.setValue(toString(-led),"sec/mm"); + keyword.setValue(Isis::toString(-led),"sec/mm"); inst_pvlG.addKeyword(keyword); panCube.putGroup(inst_pvlG); @@ -191,7 +191,7 @@ void IsisMain() { kernels_pvlG.clear(); keyword.setName("NaifFrameCode"); - keyword.setValue(toString(insCode)); + keyword.setValue(Isis::toString(insCode)); kernels_pvlG.addKeyword(keyword); keyword.setName("LeapSecond"); @@ -404,7 +404,7 @@ void IsisMain() { recordPos[2] = posJ20[2]; recordPos[3] = temp; //temp = et (right now anyway) tablePos += recordPos; - tablePos.Label() += PvlKeyword("SpkTableStartTime",toString(temp)); + tablePos.Label() += PvlKeyword("SpkTableStartTime",Isis::toString(temp)); //now the other node temp = 0.515*(time1-time0); //3% extension posSel[0] = pos0[0] + temp*vel[0]; //selenocentric coordinate calculation @@ -424,7 +424,7 @@ void IsisMain() { recordPos[2] = posJ20[2]; recordPos[3] = temp; //temp = et (right now anyway) tablePos += recordPos; - tablePos.Label() += PvlKeyword("SpkTableEndTime",toString(temp)); + tablePos.Label() += PvlKeyword("SpkTableEndTime",Isis::toString(temp)); tablePos.Label() += PvlKeyword("CacheType","Linear"); tablePos.Label() += PvlKeyword("Description","Created by apollopaninit"); panCube.write(tablePos); //now attach it to the table @@ -547,18 +547,18 @@ void IsisMain() { recordRot[4] = Q[i][4]; tableRot += recordRot; } - tableRot.Label() += PvlKeyword("CkTableStartTime", toString(Q[0][4])); - tableRot.Label() += PvlKeyword("CkTableEndTime", toString(Q[NODES-1][4])); + tableRot.Label() += PvlKeyword("CkTableStartTime", Isis::toString(Q[0][4])); + tableRot.Label() += PvlKeyword("CkTableEndTime", Isis::toString(Q[NODES-1][4])); tableRot.Label() += PvlKeyword("Description", "Created by appollopan2isis"); keyword.setName("TimeDependentFrames"); - keyword.setValue(toString(scFrameCode)); + keyword.setValue(Isis::toString(scFrameCode)); keyword.addValue("1"); tableRot.Label() += keyword; keyword.setName("ConstantFrames"); - keyword.setValue(toString(insCode)); - keyword.addValue(toString(scFrameCode)); + keyword.setValue(Isis::toString(insCode)); + keyword.addValue(Isis::toString(scFrameCode)); tableRot.Label() += keyword; keyword.setName("ConstantRotation"); @@ -777,10 +777,10 @@ void IsisMain() { ApolloPanoramicCamera* cam = (ApolloPanoramicCamera*)(panCube.camera()); //log the residual report from interior orientation PvlGroup residualStats("InteriorOrientationStats"); - residualStats += PvlKeyword("FiducialsFound", toString(tableFid.Records())); - residualStats += PvlKeyword("ResidualMax", toString(cam->intOriResidualMax()),"pixels"); - residualStats += PvlKeyword("ResidualMean", toString(cam->intOriResidualMean()),"pixels"); - residualStats += PvlKeyword("ResidualStdev", toString(cam->intOriResidualStdev()),"pixels"); + residualStats += PvlKeyword("FiducialsFound", Isis::toString(tableFid.Records())); + residualStats += PvlKeyword("ResidualMax", Isis::toString(cam->intOriResidualMax()),"pixels"); + residualStats += PvlKeyword("ResidualMean", Isis::toString(cam->intOriResidualMean()),"pixels"); + residualStats += PvlKeyword("ResidualStdev", Isis::toString(cam->intOriResidualStdev()),"pixels"); Application::Log( residualStats ); diff --git a/isis/src/apollo/apps/apolloremrx/apolloremrx.cpp b/isis/src/apollo/apps/apolloremrx/apolloremrx.cpp index dd4d0f82eb..676385f8ab 100644 --- a/isis/src/apollo/apps/apolloremrx/apolloremrx.cpp +++ b/isis/src/apollo/apps/apolloremrx/apolloremrx.cpp @@ -99,9 +99,9 @@ namespace Isis { Brick brick(dim,dim,1,cube.pixelType()); int width = ui.GetInteger("WIDTH"); for (int res=0; resKnowns(); i++) { - PvlKeyword p("POINT"+toString(i+1)); - p += toString(p_lsqInputLine->Residual(i)); - p += toString(p_lsqInputSamp->Residual(i)); + PvlKeyword p("POINT"+Isis::toString(i+1)); + p += Isis::toString(p_lsqInputLine->Residual(i)); + p += Isis::toString(p_lsqInputSamp->Residual(i)); errs += p; } return errs; diff --git a/isis/src/apollo/apps/apollowarp/main.cpp b/isis/src/apollo/apps/apollowarp/main.cpp index 71962ea865..a30859b0ea 100644 --- a/isis/src/apollo/apps/apollowarp/main.cpp +++ b/isis/src/apollo/apps/apollowarp/main.cpp @@ -43,14 +43,14 @@ void IsisMain() { vector inputLine,inputSample,outputLine,outputSample; // Setup the parameters for the transform for (int i=0; i 100.0)) { std::string msg = "Invalid value for [PVALIDPERCENT] entered [" - + toString(percent) + "]. Must be greater than 0.0 and less than or equal to 100.0 (Default = 50.0)"; + + Isis::toString(percent) + "]. Must be greater than 0.0 and less than or equal to 100.0 (Default = 50.0)"; throw IException(IException::User, msg, _FILEINFO_); } - patternChip += PvlKeyword("ValidPercent", toString(percent)); + patternChip += PvlKeyword("ValidPercent", Isis::toString(percent)); } // Set up the search chip group PvlGroup searchChip("SearchChip"); - searchChip += PvlKeyword("Samples", toString(ssamp)); - searchChip += PvlKeyword("Lines", toString(sline)); + searchChip += PvlKeyword("Samples", Isis::toString(ssamp)); + searchChip += PvlKeyword("Lines", Isis::toString(sline)); if(ui.WasEntered("SMIN")) { - searchChip += PvlKeyword("ValidMinimum", toString(ui.GetInteger("SMIN"))); + searchChip += PvlKeyword("ValidMinimum", Isis::toString(ui.GetInteger("SMIN"))); } if(ui.WasEntered("SMAX")) { - searchChip += PvlKeyword("ValidMaximum", toString(ui.GetInteger("SMAX"))); + searchChip += PvlKeyword("ValidMaximum", Isis::toString(ui.GetInteger("SMAX"))); } if(ui.WasEntered("SSUBCHIPVALIDPERCENT")) { double percent = ui.GetDouble("SSUBCHIPVALIDPERCENT"); if((percent <= 0.0) || (percent > 100.0)) { std::string msg = "Invalid value for [SSUBCHIPVALIDPERCENT] entered [" - + toString(percent) + "]. Must be greater than 0.0 and less than or equal to 100.0 (Default = 50.0)"; + + Isis::toString(percent) + "]. Must be greater than 0.0 and less than or equal to 100.0 (Default = 50.0)"; throw IException(IException::User, msg, _FILEINFO_); } - searchChip += PvlKeyword("SubchipValidPercent", toString(percent)); + searchChip += PvlKeyword("SubchipValidPercent", Isis::toString(percent)); } // Add groups to the autoreg object @@ -152,21 +152,21 @@ void IsisMain() { PvlGroup surfaceModel("SurfaceModel"); double distanceTol = ui.GetDouble("DISTANCETOLERANCE"); - surfaceModel += PvlKeyword("DistanceTolerance", toString(distanceTol)); + surfaceModel += PvlKeyword("DistanceTolerance", Isis::toString(distanceTol)); if(distanceTol <= 0.0) { std::string msg = "Invalid value for [DISTANCETOLERANCE] entered [" - + toString(distanceTol) + "]. Must be greater than 0.0 (Default = 1.5)"; + + Isis::toString(distanceTol) + "]. Must be greater than 0.0 (Default = 1.5)"; throw IException(IException::User, msg, _FILEINFO_); } int winSize = ui.GetInteger("WINDOWSIZE"); - surfaceModel += PvlKeyword("WindowSize", toString(winSize)); + surfaceModel += PvlKeyword("WindowSize", Isis::toString(winSize)); // Make sure the window size is odd if(winSize % 2 == 0) { std::string msg = "Invalid value for [WINDOWSIZE] entered [" - + toString(winSize) + "]. Must be an odd number (Default = 5)"; + + Isis::toString(winSize) + "]. Must be an odd number (Default = 5)"; throw IException(IException::User, msg, _FILEINFO_); } autoreg.addGroup(surfaceModel); diff --git a/isis/src/base/apps/bit2bit/main.cpp b/isis/src/base/apps/bit2bit/main.cpp index ed0a81cca8..4d5c0ac4ec 100644 --- a/isis/src/base/apps/bit2bit/main.cpp +++ b/isis/src/base/apps/bit2bit/main.cpp @@ -99,16 +99,16 @@ void IsisMain(){ //!Write bit2bit summary to print.prt logfile PvlGroup results("bit2bit_Results"); - results += PvlKeyword ("INPUT_LRS",toString(iLrs)); - results += PvlKeyword ("INPUT_HRS",toString(iHrs)); - results += PvlKeyword ("INPUT_NULL",toString(iNull)); - results += PvlKeyword ("INPUT_INVALID_PERCENT",toString(invalid_pi)); - results += PvlKeyword ("OUTPUT_MIN",toString(validMin)); - results += PvlKeyword ("OUTPUT_MAX",toString(validMax)); - results += PvlKeyword ("OUTPUT_LRS",toString(oLrs)); - results += PvlKeyword ("OUTPUT_HRS",toString(oHrs)); - results += PvlKeyword ("OUTPUT_NULL",toString(oNull)); - results += PvlKeyword ("OUTPUT_INVALID_PERCENT",toString(invalid_po)); + results += PvlKeyword ("INPUT_LRS",Isis::toString(iLrs)); + results += PvlKeyword ("INPUT_HRS",Isis::toString(iHrs)); + results += PvlKeyword ("INPUT_NULL",Isis::toString(iNull)); + results += PvlKeyword ("INPUT_INVALID_PERCENT",Isis::toString(invalid_pi)); + results += PvlKeyword ("OUTPUT_MIN",Isis::toString(validMin)); + results += PvlKeyword ("OUTPUT_MAX",Isis::toString(validMax)); + results += PvlKeyword ("OUTPUT_LRS",Isis::toString(oLrs)); + results += PvlKeyword ("OUTPUT_HRS",Isis::toString(oHrs)); + results += PvlKeyword ("OUTPUT_NULL",Isis::toString(oNull)); + results += PvlKeyword ("OUTPUT_INVALID_PERCENT",Isis::toString(invalid_po)); Application::Log(results); delete histptr; @@ -135,12 +135,12 @@ void IsisMain(){ //!Write bit2bit summary to print.prt logfile PvlGroup results("bit2bit_Results"); - results += PvlKeyword ("INPUT_LRS",toString(iLrs)); - results += PvlKeyword ("INPUT_HRS",toString(iHrs)); - results += PvlKeyword ("INPUT_NULL",toString(iNull)); - results += PvlKeyword ("INPUT_INVALID_PERCENT",toString(invalid_pi)); - results += PvlKeyword ("OUTPUT_MIN",toString(validMin)); - results += PvlKeyword ("OUTPUT_MAX",toString(validMax)); + results += PvlKeyword ("INPUT_LRS",Isis::toString(iLrs)); + results += PvlKeyword ("INPUT_HRS",Isis::toString(iHrs)); + results += PvlKeyword ("INPUT_NULL",Isis::toString(iNull)); + results += PvlKeyword ("INPUT_INVALID_PERCENT",Isis::toString(invalid_pi)); + results += PvlKeyword ("OUTPUT_MIN",Isis::toString(validMin)); + results += PvlKeyword ("OUTPUT_MAX",Isis::toString(validMax)); Application::Log(results); delete histptr; diff --git a/isis/src/base/apps/cam2cam/cam2cam.cpp b/isis/src/base/apps/cam2cam/cam2cam.cpp index 566fd5cd72..4ae30e0b93 100644 --- a/isis/src/base/apps/cam2cam/cam2cam.cpp +++ b/isis/src/base/apps/cam2cam/cam2cam.cpp @@ -70,7 +70,7 @@ namespace Isis { // Set the reference band we want to match PvlGroup instgrp = mcube->group("Instrument"); if (!outcam->IsBandIndependent()) { - PvlKeyword rBand("ReferenceBand", toString(referenceBand)); + PvlKeyword rBand("ReferenceBand", Isis::toString(referenceBand)); rBand.addComment("# All bands are aligned to reference band"); instgrp += rBand; mcube->putGroup(instgrp); diff --git a/isis/src/base/apps/cam2map/cam2map.cpp b/isis/src/base/apps/cam2map/cam2map.cpp index 77e6217a99..87e27c737c 100644 --- a/isis/src/base/apps/cam2map/cam2map.cpp +++ b/isis/src/base/apps/cam2map/cam2map.cpp @@ -66,10 +66,10 @@ namespace Isis { // Make the target info match the user mapfile double minlat, maxlat, minlon, maxlon; incam->GroundRange(minlat, maxlat, minlon, maxlon, userMap); - camGrp.addKeyword(PvlKeyword("MinimumLatitude", toString(minlat)), Pvl::Replace); - camGrp.addKeyword(PvlKeyword("MaximumLatitude", toString(maxlat)), Pvl::Replace); - camGrp.addKeyword(PvlKeyword("MinimumLongitude", toString(minlon)), Pvl::Replace); - camGrp.addKeyword(PvlKeyword("MaximumLongitude", toString(maxlon)), Pvl::Replace); + camGrp.addKeyword(PvlKeyword("MinimumLatitude", Isis::toString(minlat)), Pvl::Replace); + camGrp.addKeyword(PvlKeyword("MaximumLatitude", Isis::toString(maxlat)), Pvl::Replace); + camGrp.addKeyword(PvlKeyword("MinimumLongitude", Isis::toString(minlon)), Pvl::Replace); + camGrp.addKeyword(PvlKeyword("MaximumLongitude", Isis::toString(maxlon)), Pvl::Replace); // We want to delete the keywords we just added if the user wants the range @@ -119,22 +119,22 @@ namespace Isis { // If the user decided to enter a ground range then override if ( ui.WasEntered("MINLON") ) { userGrp.addKeyword(PvlKeyword("MinimumLongitude", - toString(ui.GetDouble("MINLON"))), Pvl::Replace); + Isis::toString(ui.GetDouble("MINLON"))), Pvl::Replace); } if ( ui.WasEntered("MAXLON") ) { userGrp.addKeyword(PvlKeyword("MaximumLongitude", - toString(ui.GetDouble("MAXLON"))), Pvl::Replace); + Isis::toString(ui.GetDouble("MAXLON"))), Pvl::Replace); } if ( ui.WasEntered("MINLAT") ) { userGrp.addKeyword(PvlKeyword("MinimumLatitude", - toString(ui.GetDouble("MINLAT"))), Pvl::Replace); + Isis::toString(ui.GetDouble("MINLAT"))), Pvl::Replace); } if ( ui.WasEntered("MAXLAT") ) { userGrp.addKeyword(PvlKeyword("MaximumLatitude", - toString(ui.GetDouble("MAXLAT"))), Pvl::Replace); + Isis::toString(ui.GetDouble("MAXLAT"))), Pvl::Replace); } // If they want the res. from the mapfile, delete it from the camera so @@ -164,7 +164,7 @@ namespace Isis { if (ui.WasEntered("PIXRES")) { if (ui.GetString("PIXRES") == "MPP") { userGrp.addKeyword(PvlKeyword("PixelResolution", - toString(ui.GetDouble("RESOLUTION"))), + Isis::toString(ui.GetDouble("RESOLUTION"))), Pvl::Replace); if (userGrp.hasKeyword("Scale")) { userGrp.deleteKeyword("Scale"); @@ -172,7 +172,7 @@ namespace Isis { } else if (ui.GetString("PIXRES") == "PPD") { userGrp.addKeyword(PvlKeyword("Scale", - toString(ui.GetDouble("RESOLUTION"))), + Isis::toString(ui.GetDouble("RESOLUTION"))), Pvl::Replace); if (userGrp.hasKeyword("PixelResolution")) { userGrp.deleteKeyword("PixelResolution"); @@ -205,16 +205,16 @@ namespace Isis { double minlat, maxlat, minlon, maxlon; incam->GroundRange(minlat, maxlat, minlon, maxlon, userMap); if (!ui.WasEntered("MINLAT")) { - userGrp.addKeyword(PvlKeyword("MinimumLatitude", toString(minlat)), Pvl::Replace); + userGrp.addKeyword(PvlKeyword("MinimumLatitude", Isis::toString(minlat)), Pvl::Replace); } if (!ui.WasEntered("MAXLAT")) { - userGrp.addKeyword(PvlKeyword("MaximumLatitude", toString(maxlat)), Pvl::Replace); + userGrp.addKeyword(PvlKeyword("MaximumLatitude", Isis::toString(maxlat)), Pvl::Replace); } if (!ui.WasEntered("MINLON")) { - userGrp.addKeyword(PvlKeyword("MinimumLongitude", toString(minlon)), Pvl::Replace); + userGrp.addKeyword(PvlKeyword("MinimumLongitude", Isis::toString(minlon)), Pvl::Replace); } if (!ui.WasEntered("MAXLON")) { - userGrp.addKeyword(PvlKeyword("MaximumLongitude", toString(maxlon)), Pvl::Replace); + userGrp.addKeyword(PvlKeyword("MaximumLongitude", Isis::toString(maxlon)), Pvl::Replace); } } @@ -294,14 +294,14 @@ namespace Isis { // Create an alpha cube group for the output cube if (!ocube->hasGroup("AlphaCube")) { PvlGroup alpha("AlphaCube"); - alpha += PvlKeyword("AlphaSamples", toString(icube->sampleCount())); - alpha += PvlKeyword("AlphaLines", toString(icube->lineCount())); - alpha += PvlKeyword("AlphaStartingSample", toString(0.5)); - alpha += PvlKeyword("AlphaStartingLine", toString(0.5)); - alpha += PvlKeyword("AlphaEndingSample", toString(icube->sampleCount() + 0.5)); - alpha += PvlKeyword("AlphaEndingLine", toString(icube->lineCount() + 0.5)); - alpha += PvlKeyword("BetaSamples", toString(icube->sampleCount())); - alpha += PvlKeyword("BetaLines", toString(icube->lineCount())); + alpha += PvlKeyword("AlphaSamples", Isis::toString(icube->sampleCount())); + alpha += PvlKeyword("AlphaLines", Isis::toString(icube->lineCount())); + alpha += PvlKeyword("AlphaStartingSample", Isis::toString(0.5)); + alpha += PvlKeyword("AlphaStartingLine", Isis::toString(0.5)); + alpha += PvlKeyword("AlphaEndingSample", Isis::toString(icube->sampleCount() + 0.5)); + alpha += PvlKeyword("AlphaEndingLine", Isis::toString(icube->lineCount() + 0.5)); + alpha += PvlKeyword("BetaSamples", Isis::toString(icube->sampleCount())); + alpha += PvlKeyword("BetaLines", Isis::toString(icube->lineCount())); ocube->putGroup(alpha); } diff --git a/isis/src/base/apps/caminfo/CamTools.cpp b/isis/src/base/apps/caminfo/CamTools.cpp index 2e19a0093e..8aef561ea1 100644 --- a/isis/src/base/apps/caminfo/CamTools.cpp +++ b/isis/src/base/apps/caminfo/CamTools.cpp @@ -368,9 +368,9 @@ namespace Isis { GProperties g = getGeometrySummary(); //geometry keywords for band output - pband += PvlKeyword("BandsUsed", toString(size())); - pband += PvlKeyword("ReferenceBand", toString(g.band)); - pband += PvlKeyword("OriginalBand", toString(g.realBand)); + pband += PvlKeyword("BandsUsed", Isis::toString(size())); + pband += PvlKeyword("ReferenceBand", Isis::toString(g.band)); + pband += PvlKeyword("OriginalBand", Isis::toString(g.realBand)); pband += PvlKeyword("Target", g.target.toStdString()); @@ -600,7 +600,7 @@ namespace Isis { } } - mapping += PvlKeyword("CenterLongitude", toString(clon)); + mapping += PvlKeyword("CenterLongitude", Isis::toString(clon)); TProjection *sinu = (TProjection *) ProjectionFactory::Create(sinuMap, true); geos::geom::MultiPolygon *sPoly = PolygonTools::LatLonToXY(*poly, sinu); @@ -647,8 +647,8 @@ namespace Isis { pband += ValidateKey("SurfaceArea", _summary.surfaceArea, "km^2"); pband += ValidateKey("GlobalCoverage", globalCoverage, "percent"); if(_combined != 0) { - pband += PvlKeyword("SampleIncrement", toString(_sampleInc)); - pband += PvlKeyword("LineIncrement", toString(_lineInc)); + pband += PvlKeyword("SampleIncrement", Isis::toString(_sampleInc)); + pband += PvlKeyword("LineIncrement", Isis::toString(_lineInc)); if(_combined->getGeometryTypeId() != geos::geom::GEOS_MULTIPOLYGON) { geos::geom::MultiPolygon *geom = makeMultiPolygon(_combined); pband += PvlKeyword("GisFootprint", geom->toString()); diff --git a/isis/src/base/apps/caminfo/CamTools.h b/isis/src/base/apps/caminfo/CamTools.h index 548d0db6d4..0e76f9ff49 100644 --- a/isis/src/base/apps/caminfo/CamTools.h +++ b/isis/src/base/apps/caminfo/CamTools.h @@ -56,7 +56,7 @@ namespace Isis { return (PvlKeyword(keyname.toStdString(), "NULL")); } else { - return (PvlKeyword(keyname.toStdString(), toString(value), unit.toStdString())); + return (PvlKeyword(keyname.toStdString(), Isis::toString(value), unit.toStdString())); } } diff --git a/isis/src/base/apps/camrange/camrange.cpp b/isis/src/base/apps/camrange/camrange.cpp index 6f1508769b..2093ea0024 100644 --- a/isis/src/base/apps/camrange/camrange.cpp +++ b/isis/src/base/apps/camrange/camrange.cpp @@ -35,16 +35,16 @@ namespace Isis { PvlGroup target("Target"); target += PvlKeyword("From", ui.GetCubeName("FROM").toStdString()); target += PvlKeyword("TargetName", camTarget->name().toStdString()); - target += PvlKeyword("RadiusA", toString(radii[0].meters()), "meters"); - target += PvlKeyword("RadiusB", toString(radii[1].meters()), "meters"); - target += PvlKeyword("RadiusC", toString(radii[2].meters()), "meters"); + target += PvlKeyword("RadiusA", Isis::toString(radii[0].meters()), "meters"); + target += PvlKeyword("RadiusB", Isis::toString(radii[1].meters()), "meters"); + target += PvlKeyword("RadiusC", Isis::toString(radii[2].meters()), "meters"); // Get resolution PvlGroup res("PixelResolution"); double lowres = cam->LowestImageResolution(); double hires = cam->HighestImageResolution(); - res += PvlKeyword("Lowest", toString(lowres), "meters"); - res += PvlKeyword("Highest", toString(hires), "meters"); + res += PvlKeyword("Lowest", Isis::toString(lowres), "meters"); + res += PvlKeyword("Highest", Isis::toString(hires), "meters"); // Get the universal ground range PvlGroup ugr("UniversalGroundRange"); @@ -53,10 +53,10 @@ namespace Isis { ugr += PvlKeyword("LatitudeType", "Planetocentric"); ugr += PvlKeyword("LongitudeDirection", "PositiveEast"); ugr += PvlKeyword("LongitudeDomain", "360"); - ugr += PvlKeyword("MinimumLatitude", toString(minlat)); - ugr += PvlKeyword("MaximumLatitude", toString(maxlat)); - ugr += PvlKeyword("MinimumLongitude", toString(minlon)); - ugr += PvlKeyword("MaximumLongitude", toString(maxlon)); + ugr += PvlKeyword("MinimumLatitude", Isis::toString(minlat)); + ugr += PvlKeyword("MaximumLatitude", Isis::toString(maxlat)); + ugr += PvlKeyword("MinimumLongitude", Isis::toString(minlon)); + ugr += PvlKeyword("MaximumLongitude", Isis::toString(maxlon)); // Get the ographic latitude range mapgrp.addKeyword(PvlKeyword("LatitudeType", "Planetographic"), @@ -64,8 +64,8 @@ namespace Isis { cam->GroundRange(minlat, maxlat, minlon, maxlon, mapping); PvlGroup ogr("LatitudeRange"); ogr += PvlKeyword("LatitudeType", "Planetographic"); - ogr += PvlKeyword("MinimumLatitude", toString(minlat)); - ogr += PvlKeyword("MaximumLatitude", toString(maxlat)); + ogr += PvlKeyword("MinimumLatitude", Isis::toString(minlat)); + ogr += PvlKeyword("MaximumLatitude", Isis::toString(maxlat)); // Get positive west longitude coordinates in 360 domain mapgrp.addKeyword(PvlKeyword("LongitudeDirection", "PositiveWest"), @@ -74,8 +74,8 @@ namespace Isis { PvlGroup pos360("PositiveWest360"); pos360 += PvlKeyword("LongitudeDirection", "PositiveWest"); pos360 += PvlKeyword("LongitudeDomain", "360"); - pos360 += PvlKeyword("MinimumLongitude", toString(minlon)); - pos360 += PvlKeyword("MaximumLongitude", toString(maxlon)); + pos360 += PvlKeyword("MinimumLongitude", Isis::toString(minlon)); + pos360 += PvlKeyword("MaximumLongitude", Isis::toString(maxlon)); // Get positive east longitude coordinates in 180 domain mapgrp.addKeyword(PvlKeyword("LongitudeDirection", "PositiveEast"), @@ -86,8 +86,8 @@ namespace Isis { PvlGroup pos180("PositiveEast180"); pos180 += PvlKeyword("LongitudeDirection", "PositiveEast"); pos180 += PvlKeyword("LongitudeDomain", "180"); - pos180 += PvlKeyword("MinimumLongitude", toString(minlon)); - pos180 += PvlKeyword("MaximumLongitude", toString(maxlon)); + pos180 += PvlKeyword("MinimumLongitude", Isis::toString(minlon)); + pos180 += PvlKeyword("MaximumLongitude", Isis::toString(maxlon)); // Get positive west longitude coordinates in 180 domain mapgrp.addKeyword(PvlKeyword("LongitudeDirection", "PositiveWest"), @@ -96,8 +96,8 @@ namespace Isis { PvlGroup neg180("PositiveWest180"); neg180 += PvlKeyword("LongitudeDirection", "PositiveWest"); neg180 += PvlKeyword("LongitudeDomain", "180"); - neg180 += PvlKeyword("MinimumLongitude", toString(minlon)); - neg180 += PvlKeyword("MaximumLongitude", toString(maxlon)); + neg180 += PvlKeyword("MinimumLongitude", Isis::toString(minlon)); + neg180 += PvlKeyword("MaximumLongitude", Isis::toString(maxlon)); Application::AppendAndLog(target, log); Application::AppendAndLog(res, log); diff --git a/isis/src/base/apps/camstats/camstats.cpp b/isis/src/base/apps/camstats/camstats.cpp index a4fe2102ad..3fbff65ac9 100644 --- a/isis/src/base/apps/camstats/camstats.cpp +++ b/isis/src/base/apps/camstats/camstats.cpp @@ -195,7 +195,7 @@ namespace Isis { record[entry] = group.name(); entry++; for (int j = 0; j < group.keywords(); j++) { - record[entry] = IString::ToDouble(group[j][0]); + record[entry] = Isis::toDouble(group[j][0]); entry++; } table += record; diff --git a/isis/src/base/apps/center/main.cpp b/isis/src/base/apps/center/main.cpp index a4cd9eec6f..6afd9dede5 100644 --- a/isis/src/base/apps/center/main.cpp +++ b/isis/src/base/apps/center/main.cpp @@ -52,10 +52,10 @@ void IsisMain() { if (sumall.ValidPixels() > 0) { csamp = sumX / sumall.Sum(); cline = sumY / sumall.Sum(); - results += PvlKeyword("CentroidLine", toString(cline)); - results += PvlKeyword("CentroidSample", toString(csamp)); - results += PvlKeyword("LineOffset", toString(lMiddle - cline)); - results += PvlKeyword("SampleOffset", toString(sMiddle - csamp)); + results += PvlKeyword("CentroidLine", Isis::toString(cline)); + results += PvlKeyword("CentroidSample", Isis::toString(csamp)); + results += PvlKeyword("LineOffset", Isis::toString(lMiddle - cline)); + results += PvlKeyword("SampleOffset", Isis::toString(sMiddle - csamp)); } else { PvlKeyword badl = PvlKeyword("CentroidLine", "Null"); diff --git a/isis/src/base/apps/ckwriter/CkSpiceSegment.cpp b/isis/src/base/apps/ckwriter/CkSpiceSegment.cpp index 40f756e54a..3486a57d47 100644 --- a/isis/src/base/apps/ckwriter/CkSpiceSegment.cpp +++ b/isis/src/base/apps/ckwriter/CkSpiceSegment.cpp @@ -360,7 +360,7 @@ bool CkSpiceSegment::getTimeDependentFrameIds(Table &table, int &toId, int &from if ( table.Label().hasKeyword("TimeDependentFrames") ) { PvlKeyword labelTimeFrames = table.Label()["TimeDependentFrames"]; for (int i=0; i widths; widths.resize(icube->bandCount()); for(int i = 0; i < pvlCenter.size(); i++) { - centers[i] = IString::ToDouble(pvlCenter[i]); + centers[i] = Isis::toDouble(pvlCenter[i]); if(hasWidth) - widths[i] = IString::ToDouble((*pvlWidth)[i]); + widths[i] = Isis::toDouble((*pvlWidth)[i]); else widths[i] = 0.0; } @@ -145,14 +145,14 @@ void compute(vector centers, vector widths, small = (double)centers[i] - (double)widths[i] / 2.0; } } - pvlCenter.setValue(toString((large - small) / 2 + small), centerUnit.toStdString()); + pvlCenter.setValue(Isis::toString((large - small) / 2 + small), centerUnit.toStdString()); if(hasWidth) { PvlKeyword &pvlWidth = pvlg.findKeyword("Width"); - pvlWidth.setValue(toString(large - small), pvlWidth.unit()); + pvlWidth.setValue(Isis::toString(large - small), pvlWidth.unit()); } else { PvlKeyword pvlWidth = PvlKeyword("Width"); - pvlWidth.setValue(toString(large - small), centerUnit.toStdString()); + pvlWidth.setValue(Isis::toString(large - small), centerUnit.toStdString()); pvlg.addKeyword(pvlWidth); } diff --git a/isis/src/base/apps/cubediff/main.cpp b/isis/src/base/apps/cubediff/main.cpp index c6c4f8782b..b1939100ea 100644 --- a/isis/src/base/apps/cubediff/main.cpp +++ b/isis/src/base/apps/cubediff/main.cpp @@ -85,9 +85,9 @@ void IsisMain() { } else { results += PvlKeyword("Compare", "Different"); - results += PvlKeyword("Sample", toString(sample)); - results += PvlKeyword("Line", toString(line)); - results += PvlKeyword("Band", toString(band)); + results += PvlKeyword("Sample", Isis::toString(sample)); + results += PvlKeyword("Line", Isis::toString(line)); + results += PvlKeyword("Band", Isis::toString(band)); if(stats.TotalPixels() < 1) { results += PvlKeyword("AverageDifference", "0"); results += PvlKeyword("StandardDeviation", "0"); @@ -96,21 +96,21 @@ void IsisMain() { results += PvlKeyword("MaximumDifference", "0"); } else { - results += PvlKeyword("AverageDifference", toString(stats.Average())); - results += PvlKeyword("StandardDeviation", toString(stats.StandardDeviation())); - results += PvlKeyword("Variance", toString(stats.Variance())); - results += PvlKeyword("MinimumDifference", toString(stats.Minimum())); - results += PvlKeyword("MaximumDifference", toString(stats.Maximum())); - results += PvlKeyword("MaxDifferenceSample", toString(gMaxDiffSample)); - results += PvlKeyword("MaxDifferenceLine", toString(gMaxDiffLine)); - results += PvlKeyword("MaxDifferenceBand", toString(gMaxDiffBand)); + results += PvlKeyword("AverageDifference", Isis::toString(stats.Average())); + results += PvlKeyword("StandardDeviation", Isis::toString(stats.StandardDeviation())); + results += PvlKeyword("Variance", Isis::toString(stats.Variance())); + results += PvlKeyword("MinimumDifference", Isis::toString(stats.Minimum())); + results += PvlKeyword("MaximumDifference", Isis::toString(stats.Maximum())); + results += PvlKeyword("MaxDifferenceSample", Isis::toString(gMaxDiffSample)); + results += PvlKeyword("MaxDifferenceLine", Isis::toString(gMaxDiffLine)); + results += PvlKeyword("MaxDifferenceBand", Isis::toString(gMaxDiffBand)); } - results += PvlKeyword("ValidPixelDifferences", toString(stats.TotalPixels())); - results += PvlKeyword("SpecialPixelDifferences", toString(spCount)); - results += PvlKeyword("SigFigAccuracy", toString(sigFigAccuracy)); - results += PvlKeyword("SigFigMaxDifferenceSample", toString(sigFigSample)); - results += PvlKeyword("SigFigMaxDifferenceLine", toString(sigFigLine)); - results += PvlKeyword("SigFigMaxDifferenceBand", toString(sigFigBand)); + results += PvlKeyword("ValidPixelDifferences", Isis::toString(stats.TotalPixels())); + results += PvlKeyword("SpecialPixelDifferences", Isis::toString(spCount)); + results += PvlKeyword("SigFigAccuracy", Isis::toString(sigFigAccuracy)); + results += PvlKeyword("SigFigMaxDifferenceSample", Isis::toString(sigFigSample)); + results += PvlKeyword("SigFigMaxDifferenceLine", Isis::toString(sigFigLine)); + results += PvlKeyword("SigFigMaxDifferenceBand", Isis::toString(sigFigBand)); } Application::Log(results); @@ -278,7 +278,7 @@ void diffTable(std::ofstream &target, int precision) { for(unsigned int i = 0; i < samps.size(); i++) { Column currCol; //Prepare and add the first file's column - currCol.SetName(QString::fromStdString("File1_" + toString(samps[i]))); + currCol.SetName(QString::fromStdString("File1_" + Isis::toString(samps[i]))); if((int)(colWidth + precision + 1) < (int)currCol.Name().length()) { currCol.SetWidth(currCol.Name().length() + 1); } @@ -290,7 +290,7 @@ void diffTable(std::ofstream &target, int precision) { cols.push_back(currCol); //Prepare and add the second file's column - currCol.SetName(QString::fromStdString("File2_" + toString(samps[i]))); + currCol.SetName(QString::fromStdString("File2_" + Isis::toString(samps[i]))); cols.push_back(currCol); } diff --git a/isis/src/base/apps/cubefunc/main.cpp b/isis/src/base/apps/cubefunc/main.cpp index 739ef9d50f..f0c47887c4 100644 --- a/isis/src/base/apps/cubefunc/main.cpp +++ b/isis/src/base/apps/cubefunc/main.cpp @@ -75,7 +75,7 @@ void IsisMain() { PvlGroup results("Results"); std::string message = "Invalid input pixels converted to Isis NULL values"; results += PvlKeyword("Error", message); - results += PvlKeyword("Count", toString(bad)); + results += PvlKeyword("Count", Isis::toString(bad)); Application::Log(results); } p.EndProcess(); diff --git a/isis/src/base/apps/cubenorm/main.cpp b/isis/src/base/apps/cubenorm/main.cpp index c8c9a182a9..7ee0468215 100644 --- a/isis/src/base/apps/cubenorm/main.cpp +++ b/isis/src/base/apps/cubenorm/main.cpp @@ -219,15 +219,15 @@ void getStats(Buffer &in) { void pvlOut(const QString &StatFile) { PvlGroup results("Results"); for(unsigned int i = 0; i < st.size(); i++) { - results += PvlKeyword("Band", toString(band[i])); - results += PvlKeyword("RowCol", toString(element[i])); - results += PvlKeyword("ValidPixels", toString(st[i].ValidPixels())); + results += PvlKeyword("Band", Isis::toString(band[i])); + results += PvlKeyword("RowCol", Isis::toString(element[i])); + results += PvlKeyword("ValidPixels", Isis::toString(st[i].ValidPixels())); if(st[i].ValidPixels() > 0) { - results += PvlKeyword("Mean", toString(st[i].Average())); - results += PvlKeyword("Median", toString(median[i])); - results += PvlKeyword("Std", toString(st[i].StandardDeviation())); - results += PvlKeyword("Minimum", toString(st[i].Minimum())); - results += PvlKeyword("Maximum", toString(st[i].Maximum())); + results += PvlKeyword("Mean", Isis::toString(st[i].Average())); + results += PvlKeyword("Median", Isis::toString(median[i])); + results += PvlKeyword("Std", Isis::toString(st[i].StandardDeviation())); + results += PvlKeyword("Minimum", Isis::toString(st[i].Minimum())); + results += PvlKeyword("Maximum", Isis::toString(st[i].Maximum())); } else { results += PvlKeyword("Mean", "0.0"); @@ -304,21 +304,21 @@ void PVLIn(const Isis::FileName &filename) { while(itr != results.end()) { StaticStats newStat; - band.push_back(IString::ToInteger((*itr)[0])); + band.push_back(Isis::toInt((*itr)[0])); itr++; - element.push_back(IString::ToInteger((*itr)[0])); + element.push_back(Isis::toInt((*itr)[0])); itr++; - newStat.setValidPixels(IString::ToInteger((*itr)[0])); + newStat.setValidPixels(Isis::toInt((*itr)[0])); itr++; - newStat.setMean(IString::ToDouble((*itr)[0])); + newStat.setMean(Isis::toDouble((*itr)[0])); itr++; - median.push_back(IString::ToDouble((*itr)[0])); + median.push_back(Isis::toDouble((*itr)[0])); itr++; - newStat.setStandardDeviation(IString::ToDouble((*itr)[0])); + newStat.setStandardDeviation(Isis::toDouble((*itr)[0])); itr++; - newStat.setMinimum(IString::ToDouble((*itr)[0])); + newStat.setMinimum(Isis::toDouble((*itr)[0])); itr++; - newStat.setMaximum(IString::ToDouble((*itr)[0])); + newStat.setMaximum(Isis::toDouble((*itr)[0])); itr++; st.push_back(newStat); diff --git a/isis/src/base/apps/ddd2isis/main.cpp b/isis/src/base/apps/ddd2isis/main.cpp index 82a8443350..1ec43e992b 100644 --- a/isis/src/base/apps/ddd2isis/main.cpp +++ b/isis/src/base/apps/ddd2isis/main.cpp @@ -140,14 +140,14 @@ void IsisMain() { fin.close(); PvlGroup results("FileInfo"); - results += PvlKeyword( "NumberOfLines", toString(nLines) ); - results += PvlKeyword( "NumberOfBytesPerLine", toString(nBytes) ); - results += PvlKeyword( "BitType", toString(bitType) ); + results += PvlKeyword( "NumberOfLines", Isis::toString(nLines) ); + results += PvlKeyword( "NumberOfBytesPerLine", Isis::toString(nBytes) ); + results += PvlKeyword( "BitType", Isis::toString(bitType) ); int nSamples = nBytes / (totalBandBits / 8); - results += PvlKeyword( "NumberOfSamples", toString(nSamples) ); + results += PvlKeyword( "NumberOfSamples", Isis::toString(nSamples) ); int nBands = (totalBandBits / 8) / dataTypeBytes; - results += PvlKeyword( "NumberOfBands", toString(nBands) ); - results += PvlKeyword( "LabelBytes", toString(nOffset) ); + results += PvlKeyword( "NumberOfBands", Isis::toString(nBands) ); + results += PvlKeyword( "LabelBytes", Isis::toString(nOffset) ); Application::Log(results); ProcessImport p; diff --git a/isis/src/base/apps/demprep/demprep.cpp b/isis/src/base/apps/demprep/demprep.cpp index f3ed99d268..eac956fde6 100644 --- a/isis/src/base/apps/demprep/demprep.cpp +++ b/isis/src/base/apps/demprep/demprep.cpp @@ -66,8 +66,8 @@ namespace Isis{ p.StartProcess(GetStats); PvlGroup demRange("Results"); - demRange += PvlKeyword("MinimumRadius", toString(inCubeStats.Minimum()), "meters"); - demRange += PvlKeyword("MaximumRadius", toString(inCubeStats.Maximum()), "meters"); + demRange += PvlKeyword("MinimumRadius", Isis::toString(inCubeStats.Minimum()), "meters"); + demRange += PvlKeyword("MaximumRadius", Isis::toString(inCubeStats.Maximum()), "meters"); Application::Log(demRange); // Store min/max radii values in new ShapeModelStatistics table @@ -237,12 +237,12 @@ namespace Isis{ double upperLeftCorner = mapgrp["UpperLeftCornerX"]; upperLeftCorner -= leftPad * proj->Resolution(); - mapgrp.addKeyword(PvlKeyword("UpperLeftCornerX", toString(upperLeftCorner), "meters"), + mapgrp.addKeyword(PvlKeyword("UpperLeftCornerX", Isis::toString(upperLeftCorner), "meters"), Pvl::Replace); upperLeftCorner = mapgrp["UpperLeftCornerY"]; upperLeftCorner += topPad * proj->Resolution(); - mapgrp.addKeyword(PvlKeyword("UpperLeftCornerY", toString(upperLeftCorner), "meters"), + mapgrp.addKeyword(PvlKeyword("UpperLeftCornerY", Isis::toString(upperLeftCorner), "meters"), Pvl::Replace); @@ -264,8 +264,8 @@ namespace Isis{ ocube->putGroup(mapgrp); PvlGroup demRange("Results"); - demRange += PvlKeyword("MinimumRadius", toString(outCubeStats.Minimum()), "meters"); - demRange += PvlKeyword("MaximumRadius", toString(outCubeStats.Maximum()), "meters"); + demRange += PvlKeyword("MinimumRadius", Isis::toString(outCubeStats.Minimum()), "meters"); + demRange += PvlKeyword("MaximumRadius", Isis::toString(outCubeStats.Maximum()), "meters"); Application::Log(demRange); // Store min/max radii values in new ShapeModelStatistics table diff --git a/isis/src/base/apps/errors/main.cpp b/isis/src/base/apps/errors/main.cpp index 764a3d5f8a..0d80d88f50 100644 --- a/isis/src/base/apps/errors/main.cpp +++ b/isis/src/base/apps/errors/main.cpp @@ -29,7 +29,7 @@ void IsisMain() { numErrors++; } } - PvlKeyword errors("TotalErrors", toString(numErrors)); + PvlKeyword errors("TotalErrors", Isis::toString(numErrors)); output.addKeyword(errors); // write output to file if(!append) { diff --git a/isis/src/base/apps/fillgap/fillgap.cpp b/isis/src/base/apps/fillgap/fillgap.cpp index 5757c6be76..c03346c801 100644 --- a/isis/src/base/apps/fillgap/fillgap.cpp +++ b/isis/src/base/apps/fillgap/fillgap.cpp @@ -78,7 +78,7 @@ namespace Isis { if(numSpecPixKept > 0) { PvlGroup mLog("Messages"); mLog += PvlKeyword("Warning", - "Unable to fill " + toString(numSpecPixKept) + " special pixels."); + "Unable to fill " + Isis::toString(numSpecPixKept) + " special pixels."); Application::AppendAndLog(mLog, log); } return; diff --git a/isis/src/base/apps/findgaps/FindGapsFunctor.cpp b/isis/src/base/apps/findgaps/FindGapsFunctor.cpp index 088e15b41b..c050325208 100644 --- a/isis/src/base/apps/findgaps/FindGapsFunctor.cpp +++ b/isis/src/base/apps/findgaps/FindGapsFunctor.cpp @@ -151,18 +151,18 @@ namespace Isis { if( !(*m_inGap) ) { *m_inGap = true; - m_gap->addKeyword(PvlKeyword("NewGapInBand", toString(in.Band()))); - m_gap->addKeyword(PvlKeyword("StartLine", toString(in.Line()))); + m_gap->addKeyword(PvlKeyword("NewGapInBand", Isis::toString(in.Band()))); + m_gap->addKeyword(PvlKeyword("StartLine", Isis::toString(in.Line()))); if(correlation == Isis::Null) { correlation = 0.0; } - m_gap->addKeyword(PvlKeyword("Correlation", toString(correlation))); + m_gap->addKeyword(PvlKeyword("Correlation", Isis::toString(correlation))); } if (in.Line() == m_lineCount) { - m_gap->addKeyword(PvlKeyword("LastGapLine", toString(in.Line()))); - m_gap->addKeyword(PvlKeyword("ToEndOfBand", toString(m_lineCount))); + m_gap->addKeyword(PvlKeyword("LastGapLine", Isis::toString(in.Line()))); + m_gap->addKeyword(PvlKeyword("ToEndOfBand", Isis::toString(m_lineCount))); addGapToGroup(); } @@ -174,7 +174,7 @@ namespace Isis { * correlate. Or this line is the last line and it is in the gap. */ - m_gap->addKeyword(PvlKeyword("LastGapLine", toString(in.Line() - 2))); + m_gap->addKeyword(PvlKeyword("LastGapLine", Isis::toString(in.Line() - 2))); addGapToGroup(); } @@ -195,9 +195,9 @@ namespace Isis { for (int i = 0; i < m_gaps->groups(); i++) { - int gapBand = IString::ToInteger((*m_gaps).group(i).findKeyword(" NewGapInBand")[0]); - int gapStart = IString::ToInteger((*m_gaps).group(i).findKeyword("StartLine")[0]); - int gapEnd = IString::ToInteger((*m_gaps).group(i).findKeyword("LastGapLine")[0]); + int gapBand = Isis::toInt((*m_gaps).group(i).findKeyword(" NewGapInBand")[0]); + int gapStart = Isis::toInt((*m_gaps).group(i).findKeyword("StartLine")[0]); + int gapEnd = Isis::toInt((*m_gaps).group(i).findKeyword("LastGapLine")[0]); if ( (in.Line() >= gapStart - m_bufferSizeBeforeGap) && (in.Line() <= gapEnd + m_bufferSizeAfterGap) && @@ -239,8 +239,8 @@ namespace Isis { * In case the gap is a flase positive. The end of the gap will end up being the line * before the start of the gap. */ - if (IString::ToInteger(m_gap->findKeyword("StartLine")[0]) < - IString::ToInteger(m_gap->findKeyword("LastGapLine")[0])) { + if (Isis::toInt(m_gap->findKeyword("StartLine")[0]) < + Isis::toInt(m_gap->findKeyword("LastGapLine")[0])) { m_gaps->addGroup(*m_gap); } diff --git a/isis/src/base/apps/findimageoverlaps/findimageoverlaps.cpp b/isis/src/base/apps/findimageoverlaps/findimageoverlaps.cpp index 9d5c16e983..97d3c746cf 100644 --- a/isis/src/base/apps/findimageoverlaps/findimageoverlaps.cpp +++ b/isis/src/base/apps/findimageoverlaps/findimageoverlaps.cpp @@ -84,7 +84,7 @@ namespace Isis { } PvlGroup results("Results"); - results += PvlKeyword("ErrorCount", toString((BigInt)overlaps.Errors().size())); + results += PvlKeyword("ErrorCount", Isis::toString((BigInt)overlaps.Errors().size())); Application::Log(results); } diff --git a/isis/src/base/apps/findrx/main.cpp b/isis/src/base/apps/findrx/main.cpp index 3fd1194093..b8e3212756 100644 --- a/isis/src/base/apps/findrx/main.cpp +++ b/isis/src/base/apps/findrx/main.cpp @@ -35,20 +35,20 @@ void IsisMain() { int nres = reseaus["Line"].size(); if (nres != reseaus["Sample"].size()) { std::string msg = "Sample size incorrect [Sample size " + - toString(reseaus["Sample"].size()) + " != " + " Line size " + - toString(reseaus["Line"].size()) + "]"; + Isis::toString(reseaus["Sample"].size()) + " != " + " Line size " + + Isis::toString(reseaus["Line"].size()) + "]"; throw IException(IException::Unknown, msg, _FILEINFO_); } if (nres != reseaus["Type"].size()) { std::string msg = "Type size incorrect [Type size " + - toString(reseaus["Type"].size()) + " != " + " Line size " + - toString(reseaus["Line"].size()) + "]"; + Isis::toString(reseaus["Type"].size()) + " != " + " Line size " + + Isis::toString(reseaus["Line"].size()) + "]"; throw IException(IException::Unknown, msg, _FILEINFO_); } if (nres != reseaus["Valid"].size()) { std::string msg = "Valid size incorrect [Valid size " + - toString(reseaus["Valid"].size()) + " != " + " Line size " + - toString(reseaus["Line"].size()) + "]"; + Isis::toString(reseaus["Valid"].size()) + " != " + " Line size " + + Isis::toString(reseaus["Line"].size()) + "]"; throw IException(IException::Unknown, msg, _FILEINFO_); } @@ -77,10 +77,10 @@ void IsisMain() { // And the loop... for (int res = 0; res < nres; ++res) { // Output chips - ar->SearchChip()->TackCube(IString::ToDouble(reseaus["Sample"][res]), IString::ToDouble(reseaus["Line"][res])); + ar->SearchChip()->TackCube(Isis::toDouble(reseaus["Sample"][res]), Isis::toDouble(reseaus["Line"][res])); ar->SearchChip()->Load(*cube); ar->PatternChip()->Load(pattern, 0, 1.0, res + 1); - int type = IString::ToInteger(reseaus["Type"][res]); + int type = Isis::toInt(reseaus["Type"][res]); // If the reseaus is in the center (type 5) use full percent value if (type == 5) { ar->SetPatternValidPercent(patternValidPercent); @@ -100,8 +100,8 @@ void IsisMain() { ar->Register(); if (ar->Success()) { - reseaus["Sample"][res] = toString(ar->CubeSample()); - reseaus["Line"][res] = toString(ar->CubeLine()); + reseaus["Sample"][res] = Isis::toString(ar->CubeSample()); + reseaus["Line"][res] = Isis::toString(ar->CubeLine()); reseaus["Valid"][res] = "1"; } else { @@ -110,8 +110,8 @@ void IsisMain() { // And if the reseaus are to be marked...mark em if (white != NULL) { - double line = IString::ToDouble(reseaus["Line"][res]); - double sample = IString::ToDouble(reseaus["Sample"][res]); + double line = Isis::toDouble(reseaus["Line"][res]); + double sample = Isis::toDouble(reseaus["Sample"][res]); white->SetBasePosition(int(sample), int(line), 1); cube->write(*white); } diff --git a/isis/src/base/apps/footprintinit/footprintinit.cpp b/isis/src/base/apps/footprintinit/footprintinit.cpp index 6af7e762bc..04614d05ff 100644 --- a/isis/src/base/apps/footprintinit/footprintinit.cpp +++ b/isis/src/base/apps/footprintinit/footprintinit.cpp @@ -142,8 +142,8 @@ namespace Isis { if (precision) { PvlGroup results("Results"); - results.addKeyword(PvlKeyword("SINC", toString(sinc))); - results.addKeyword(PvlKeyword("LINC", toString(linc))); + results.addKeyword(PvlKeyword("SINC", Isis::toString(sinc))); + results.addKeyword(PvlKeyword("LINC", Isis::toString(linc))); Application::AppendAndLog(results, log); } diff --git a/isis/src/base/apps/footprintmerge/main.cpp b/isis/src/base/apps/footprintmerge/main.cpp index ec2e1afeb2..6275da6097 100644 --- a/isis/src/base/apps/footprintmerge/main.cpp +++ b/isis/src/base/apps/footprintmerge/main.cpp @@ -129,7 +129,7 @@ void IsisMain() { // Brief if(mode == "BRIEF") { PvlGroup results("Results"); - results += PvlKeyword("NumberOfIslands", toString((int)islandPolys.size())); + results += PvlKeyword("NumberOfIslands", Isis::toString((int)islandPolys.size())); Application::Log(results); } else if(mode == "FULL") { @@ -139,7 +139,7 @@ void IsisMain() { int numFiles = islands[p].size(); QString isle = "FootprintIsland_" + QString::number((int)p + 1); PvlGroup island(isle.toStdString()); - island += PvlKeyword("NumberFiles", toString(numFiles)); + island += PvlKeyword("NumberFiles", Isis::toString(numFiles)); PvlKeyword files("Files"); for(int f = 0; f < numFiles; f++) { files.addValue(islands[p][f].toStdString()); diff --git a/isis/src/base/apps/framestitch/framestitch.cpp b/isis/src/base/apps/framestitch/framestitch.cpp index 6b4cfc84a3..981fced0bb 100644 --- a/isis/src/base/apps/framestitch/framestitch.cpp +++ b/isis/src/base/apps/framestitch/framestitch.cpp @@ -234,13 +234,13 @@ namespace Isis { if (!outInst.hasKeyword("DataFlipped")) { outInst.addKeyword(PvlKeyword("DataFlipped")); } - outInst["DataFlipped"].setValue(toString(!inputFlipped)); + outInst["DataFlipped"].setValue(Isis::toString(!inputFlipped)); } // Record numLinesOverlap if (!outInst.hasKeyword("NumLinesOverlap")) outInst.addKeyword(PvlKeyword("NumLinesOverlap")); - outInst["numLinesOverlap"].setValue(toString(numLinesOverlap)); + outInst["numLinesOverlap"].setValue(Isis::toString(numLinesOverlap)); process.EndProcess(); diff --git a/isis/src/base/apps/isis2fits/main.cpp b/isis/src/base/apps/isis2fits/main.cpp index be6baff3f9..54004ec429 100644 --- a/isis/src/base/apps/isis2fits/main.cpp +++ b/isis/src/base/apps/isis2fits/main.cpp @@ -57,8 +57,8 @@ void IsisMain() { // determine core base and multiplier, set up the stretch PvlGroup pix = icube->label()->findObject("IsisCube").findObject("Core").findGroup("Pixels"); - double scale = IString::ToDouble(pix["Multiplier"][0]); - double base = IString::ToDouble(pix["Base"][0]); + double scale = Isis::toDouble(pix["Multiplier"][0]); + double base = Isis::toDouble(pix["Base"][0]); if (ui.GetString("STRETCH") != "NONE" && bitpix != "-32") { if (ui.GetString("STRETCH") == "LINEAR") { diff --git a/isis/src/base/apps/isis2pds/isis2pds.cpp b/isis/src/base/apps/isis2pds/isis2pds.cpp index 673d003639..3146e1c0cb 100644 --- a/isis/src/base/apps/isis2pds/isis2pds.cpp +++ b/isis/src/base/apps/isis2pds/isis2pds.cpp @@ -113,13 +113,13 @@ namespace Isis{ //Records what it did to the print.prt file PvlGroup results("DNs Used"); - results += PvlKeyword("Null", toString(p.OutputNull())); - results += PvlKeyword("LRS", toString(p.OutputLrs())); - results += PvlKeyword("LIS", toString(p.OutputLis())); - results += PvlKeyword("HIS", toString(p.OutputHis())); - results += PvlKeyword("HRS", toString(p.OutputHrs())); - results += PvlKeyword("ValidMin", toString(min)); - results += PvlKeyword("ValidMax", toString(max)); + results += PvlKeyword("Null", Isis::toString(p.OutputNull())); + results += PvlKeyword("LRS", Isis::toString(p.OutputLrs())); + results += PvlKeyword("LIS", Isis::toString(p.OutputLis())); + results += PvlKeyword("HIS", Isis::toString(p.OutputHis())); + results += PvlKeyword("HRS", Isis::toString(p.OutputHrs())); + results += PvlKeyword("ValidMin", Isis::toString(min)); + results += PvlKeyword("ValidMax", Isis::toString(max)); Application::Log(results); } else { @@ -187,13 +187,13 @@ namespace Isis{ // Records what it did to the print.prt file PvlGroup results("DNs Used"); - results += PvlKeyword("Null", toString(process.OutputNull())); - results += PvlKeyword("LRS", toString(process.OutputLrs())); - results += PvlKeyword("LIS", toString(process.OutputLis())); - results += PvlKeyword("HIS", toString(process.OutputHis())); - results += PvlKeyword("HRS", toString(process.OutputHrs())); - results += PvlKeyword("ValidMin", toString(min)); - results += PvlKeyword("ValidMax", toString(max)); + results += PvlKeyword("Null", Isis::toString(process.OutputNull())); + results += PvlKeyword("LRS", Isis::toString(process.OutputLrs())); + results += PvlKeyword("LIS", Isis::toString(process.OutputLis())); + results += PvlKeyword("HIS", Isis::toString(process.OutputHis())); + results += PvlKeyword("HRS", Isis::toString(process.OutputHrs())); + results += PvlKeyword("ValidMin", Isis::toString(min)); + results += PvlKeyword("ValidMax", Isis::toString(max)); Application::Log(results); process.StandardPds4Label(); diff --git a/isis/src/base/apps/isis2raw/main.cpp b/isis/src/base/apps/isis2raw/main.cpp index 6c8e664687..c27e5e6d98 100644 --- a/isis/src/base/apps/isis2raw/main.cpp +++ b/isis/src/base/apps/isis2raw/main.cpp @@ -105,13 +105,13 @@ void IsisMain() { // Records what output values were used, then sends it to the print.prt file // as well as the terminal. PvlGroup results("DNs Used"); - results += PvlKeyword("Null", toString(p.OutputNull())); - results += PvlKeyword("LRS", toString(p.OutputLrs())); - results += PvlKeyword("LIS", toString(p.OutputLis())); - results += PvlKeyword("HIS", toString(p.OutputHis())); - results += PvlKeyword("HRS", toString(p.OutputHrs())); - results += PvlKeyword("ValidMin", toString(min)); - results += PvlKeyword("ValidMax", toString(max)); + results += PvlKeyword("Null", Isis::toString(p.OutputNull())); + results += PvlKeyword("LRS", Isis::toString(p.OutputLrs())); + results += PvlKeyword("LIS", Isis::toString(p.OutputLis())); + results += PvlKeyword("HIS", Isis::toString(p.OutputHis())); + results += PvlKeyword("HRS", Isis::toString(p.OutputHrs())); + results += PvlKeyword("ValidMin", Isis::toString(min)); + results += PvlKeyword("ValidMax", Isis::toString(max)); Application::Log(results); return; diff --git a/isis/src/base/apps/isis2std/isis2std.cpp b/isis/src/base/apps/isis2std/isis2std.cpp index 00a03c9e01..098eda7076 100644 --- a/isis/src/base/apps/isis2std/isis2std.cpp +++ b/isis/src/base/apps/isis2std/isis2std.cpp @@ -138,8 +138,8 @@ namespace Isis { void addResults(PvlGroup &results, ImageExporter *exporter, QString channel, int index) { - results += PvlKeyword(channel.toStdString() + "InputMinimum", toString(exporter->inputMinimum(index))); - results += PvlKeyword(channel.toStdString() + "InputMaximum", toString(exporter->inputMaximum(index))); + results += PvlKeyword(channel.toStdString() + "InputMinimum", Isis::toString(exporter->inputMinimum(index))); + results += PvlKeyword(channel.toStdString() + "InputMaximum", Isis::toString(exporter->inputMaximum(index))); } } \ No newline at end of file diff --git a/isis/src/base/apps/isisimport/CassiniImportUtils.h b/isis/src/base/apps/isisimport/CassiniImportUtils.h index ead035673c..0483227888 100644 --- a/isis/src/base/apps/isisimport/CassiniImportUtils.h +++ b/isis/src/base/apps/isisimport/CassiniImportUtils.h @@ -40,8 +40,8 @@ namespace Isis { CassiniIssFixDnFunctor(PvlKeyword &stretchPairs, QString dataConversionType, int validMax) { m_stretch = Stretch(); for (size_t i = 0; i < (size_t)stretchPairs.size(); i+=2) { - m_stretch.AddPair(IString::ToDouble(stretchPairs[i]), - IString::ToDouble(stretchPairs[i + 1])); + m_stretch.AddPair(Isis::toDouble(stretchPairs[i]), + Isis::toDouble(stretchPairs[i + 1])); } m_validMax = validMax; m_dataConversionType = dataConversionType; @@ -76,7 +76,7 @@ namespace Isis { void cassiniIssFixDnPostProcess(QString ioFile, PvlObject postProcessObj) { PvlKeyword stretchPairsKeyword = postProcessObj["stretchPairs"]; QString dataConversionType = QString::fromStdString(postProcessObj["DataConversionType"]); - int validMax = IString::ToInteger(postProcessObj["ValidMaximum"]); + int validMax = Isis::toInt(postProcessObj["ValidMaximum"]); CassiniIssFixDnFunctor cassiniIssFixDnFunctor(stretchPairsKeyword, dataConversionType, validMax); ProcessByLine postProcess; @@ -102,12 +102,12 @@ namespace Isis { double flightSoftware = 0.0; if (translation["flightSoftwareVersionId"] != std::string("Unknown")) { - flightSoftware = IString::ToDouble(translation["flightSoftwareVersionId"]); + flightSoftware = Isis::toDouble(translation["flightSoftwareVersionId"]); } PvlKeyword stretchPairsKeyword = translation["stretchPairs"]; QString dataConversionType = QString::fromStdString(translation["DataConversionType"]); - int validMax = IString::ToInteger(translation["ValidMaximum"]); + int validMax = Isis::toInt(translation["ValidMaximum"]); CassiniIssFixDnFunctor cassiniIssFixDnFunctor(stretchPairsKeyword, dataConversionType, validMax); TableField overclockPixels("OverclockPixels", TableField::Double, 3); @@ -193,8 +193,8 @@ namespace Isis { PvlKeyword stretchPairs = translation["stretchPairs"]; Stretch stretch; for (size_t i = 0; i < (size_t)stretchPairs.size(); i+=2) { - stretch.AddPair(IString::ToDouble(stretchPairs[i]), - IString::ToDouble(stretchPairs[i + 1])); + stretch.AddPair(Isis::toDouble(stretchPairs[i]), + Isis::toDouble(stretchPairs[i + 1])); } PvlGroup &inst = outputLabel->findGroup("Instrument", Pvl::Traverse); QString dataConversionType = QString::fromStdString(translation["DataConversionType"]); @@ -208,7 +208,7 @@ namespace Isis { } else { double biasStripMean = inst.findKeyword("BiasStripMean"); - inst.findKeyword("BiasStripMean").setValue(toString(stretch.Map(biasStripMean))); + inst.findKeyword("BiasStripMean").setValue(Isis::toString(stretch.Map(biasStripMean))); inst.findKeyword("BiasStripMean").addComment("BiasStripMean value converted back to 12 bit."); importer->Progress()->SetText("Image was converted using 12-to-8 bit table. \nConverting prefix pixels back to 12 bit and saving line prefix data..."); } @@ -217,7 +217,7 @@ namespace Isis { int vicarLabelBytes = translation.findKeyword("VicarLabelBytes"); int roo = *(header + 50 + vicarLabelBytes) / 32 % 2; //**** THIS MAY NEED TO BE CHANGED, // SEE BOTTOM OF THIS FILE FOR IN DEPTH COMMENTS ON READOUTORDER - inst.addKeyword(PvlKeyword("ReadoutOrder", toString(roo))); + inst.addKeyword(PvlKeyword("ReadoutOrder", Isis::toString(roo))); }; } diff --git a/isis/src/base/apps/isisimport/isisimport.cpp b/isis/src/base/apps/isisimport/isisimport.cpp index 8da6d3e614..55229d26a4 100644 --- a/isis/src/base/apps/isisimport/isisimport.cpp +++ b/isis/src/base/apps/isisimport/isisimport.cpp @@ -386,9 +386,9 @@ namespace Isis { // Set everything needed by ProcessImport PvlGroup dimensions = newLabel.findObject("IsisCube").findObject("Core").findGroup("Dimensions"); - int ns = IString::ToInteger(dimensions["Samples"]); - int nl = IString::ToInteger(dimensions["Lines"]); - int nb = IString::ToInteger(dimensions["Bands"]); + int ns = Isis::toInt(dimensions["Samples"]); + int nl = Isis::toInt(dimensions["Lines"]); + int nb = Isis::toInt(dimensions["Bands"]); importer.SetDimensions(ns, nl, nb); PvlGroup pixels = newLabel.findObject("IsisCube").findObject("Core").findGroup("Pixels"); @@ -417,7 +417,7 @@ namespace Isis { if (dataFilePointer.size() == 1) { try { - offset = IString::ToInteger(dataFilePointer) - 1; + offset = Isis::toInt(dataFilePointer) - 1; units = QString::fromStdString(dataFilePointer.unit()); } catch(IException &e) { @@ -428,7 +428,7 @@ namespace Isis { } } else if (dataFilePointer.size() == 2) { - offset = IString::ToInteger(dataFilePointer[1]) - 1; + offset = Isis::toInt(dataFilePointer[1]) - 1; units = QString::fromStdString(dataFilePointer.unit(1)); } else { @@ -445,7 +445,7 @@ namespace Isis { } else { if (translation.hasKeyword("DataFileRecordBytes")) { - recSize = IString::ToInteger(translation["DataFileRecordBytes"]); + recSize = Isis::toInt(translation["DataFileRecordBytes"]); } } importer.SetFileHeaderBytes(offset * recSize); @@ -471,14 +471,14 @@ namespace Isis { // Processing unique to mroctx if (translation.hasKeyword("DataPrefixBytes")) { importer.SetDataPrefixBytes(translation["DataPrefixBytes"]); - if (IString::ToInteger(translation["DataPrefixBytes"]) > 0) { + if (Isis::toInt(translation["DataPrefixBytes"]) > 0) { importer.SaveDataPrefix(); } } if (translation.hasKeyword("DataSuffixBytes")) { importer.SetDataSuffixBytes(translation["DataSuffixBytes"]); - if (IString::ToInteger(translation["DataSuffixBytes"]) > 0) { + if (Isis::toInt(translation["DataSuffixBytes"]) > 0) { importer.SaveDataSuffix(); } } diff --git a/isis/src/base/apps/isisminer/StereoPairStrategy.cpp b/isis/src/base/apps/isisminer/StereoPairStrategy.cpp index 0b1063a337..b19f0997ad 100644 --- a/isis/src/base/apps/isisminer/StereoPairStrategy.cpp +++ b/isis/src/base/apps/isisminer/StereoPairStrategy.cpp @@ -411,12 +411,12 @@ namespace Isis { QVector threshold; try { for ( nval = 0 ; nval < key.size() ; nval++ ) { - threshold.push_back(IString::ToDouble(key[nval])); + threshold.push_back(Isis::toDouble(key[nval])); } } catch (IException &ie) { // Traps float conversion errors - std::string mess = "Error converting value [" + toString(nval+1) + + std::string mess = "Error converting value [" + Isis::toString(nval+1) + "] in keyword [" + key.name() + "] to double."; throw IException(ie, IException::User, mess, _FILEINFO_); } diff --git a/isis/src/base/apps/kernfilter/main.cpp b/isis/src/base/apps/kernfilter/main.cpp index 7a5e5c069b..98552b4a0f 100644 --- a/isis/src/base/apps/kernfilter/main.cpp +++ b/isis/src/base/apps/kernfilter/main.cpp @@ -56,7 +56,7 @@ void IsisMain() { // Iterate through the input kernel's data values to fill the coefs array for(int i = 0 ; i < kern["data"].size() ; i ++) { - coefs.push_back(IString::ToDouble(kern["data"][i])); + coefs.push_back(Isis::toDouble(kern["data"][i])); } // Weight for multiplication of resultant immidately before completion diff --git a/isis/src/base/apps/lineeq/main.cpp b/isis/src/base/apps/lineeq/main.cpp index 2d657601a1..dee63ef2c9 100644 --- a/isis/src/base/apps/lineeq/main.cpp +++ b/isis/src/base/apps/lineeq/main.cpp @@ -45,8 +45,8 @@ void IsisMain() { } PvlGroup data("lineeq"); - data += PvlKeyword("BoxcarSize", toString(boxcarSize), "lines"); - data += PvlKeyword("OutputCsv", toString((int)ui.GetBoolean("AVERAGES"))); + data += PvlKeyword("BoxcarSize", Isis::toString(boxcarSize), "lines"); + data += PvlKeyword("OutputCsv", Isis::toString((int)ui.GetBoolean("AVERAGES"))); TextFile *csvOutput = NULL; if(ui.GetBoolean("AVERAGES")) { diff --git a/isis/src/base/apps/makeflat/main.cpp b/isis/src/base/apps/makeflat/main.cpp index 6df419bd79..d765bb558e 100644 --- a/isis/src/base/apps/makeflat/main.cpp +++ b/isis/src/base/apps/makeflat/main.cpp @@ -398,13 +398,13 @@ void IsisMain() { PvlObject currFile("Exclusions"); currFile += PvlKeyword("FileName", inList[currImage].toString()); - currFile += PvlKeyword("Tolerance", toString(maxStdev)); + currFile += PvlKeyword("Tolerance", Isis::toString(maxStdev)); if(cameraType == LineScan) { - currFile += PvlKeyword("FrameLines", toString(numFrameLines)); + currFile += PvlKeyword("FrameLines", Isis::toString(numFrameLines)); } else if(cameraType == PushFrame) { - currFile += PvlKeyword("FrameletLines", toString(numFrameLines)); + currFile += PvlKeyword("FrameletLines", Isis::toString(numFrameLines)); } excludedDetails.push_back(currFile); @@ -665,11 +665,11 @@ void CreateTemporaryData(Buffer &in) { // Record the exclusion PvlGroup currExclusion("ExcludedLines"); - currExclusion += PvlKeyword("FrameStartLine", toString(in.Line())); - currExclusion += PvlKeyword("ValidPixels", toString(inputFrameStats.ValidPixels())); + currExclusion += PvlKeyword("FrameStartLine", Isis::toString(in.Line())); + currExclusion += PvlKeyword("ValidPixels", Isis::toString(inputFrameStats.ValidPixels())); if(!IsSpecial(inputFrameStats.StandardDeviation())) - currExclusion += PvlKeyword("StandardDeviation", toString(inputFrameStats.StandardDeviation())); + currExclusion += PvlKeyword("StandardDeviation", Isis::toString(inputFrameStats.StandardDeviation())); else currExclusion += PvlKeyword("StandardDeviation", "N/A"); @@ -713,12 +713,12 @@ void CreateTemporaryData(Buffer &in) { if(excluded && ((in.Line() - 1) % numFrameLines == 0)) { PvlGroup currExclusion("ExcludedFramelet"); - currExclusion += PvlKeyword("FrameletStartLine", toString(in.Line())); - currExclusion += PvlKeyword("FrameletNumber", toString((in.Line() - 1) / numFrameLines)); + currExclusion += PvlKeyword("FrameletStartLine", Isis::toString(in.Line())); + currExclusion += PvlKeyword("FrameletNumber", Isis::toString((in.Line() - 1) / numFrameLines)); if(!IsSpecial(stdev)) { currExclusion += PvlKeyword("StandardDeviation", - toString(stdev)); + Isis::toString(stdev)); } else { currExclusion += PvlKeyword("StandardDeviation", diff --git a/isis/src/base/apps/map2map/main.cpp b/isis/src/base/apps/map2map/main.cpp index ba1918bdc9..90d0042b7c 100644 --- a/isis/src/base/apps/map2map/main.cpp +++ b/isis/src/base/apps/map2map/main.cpp @@ -88,12 +88,12 @@ if((QString::fromStdString(userMapping["LongitudeDirection"])).compare(QString:: } if(QString::fromStdString(userMapping["LongitudeDirection"]) == "PositiveEast") { - fromMapping["MaximumLongitude"] = toString(TProjection::ToPositiveEast(minLon, domain)); - fromMapping["MinimumLongitude"] = toString(TProjection::ToPositiveEast(maxLon, domain)); + fromMapping["MaximumLongitude"] = Isis::toString(TProjection::ToPositiveEast(minLon, domain)); + fromMapping["MinimumLongitude"] = Isis::toString(TProjection::ToPositiveEast(maxLon, domain)); } else if(QString::fromStdString(userMapping["LongitudeDirection"]) == "PositiveWest") { - fromMapping["MaximumLongitude"] = toString(TProjection::ToPositiveWest(minLon, domain)); - fromMapping["MinimumLongitude"] = toString(TProjection::ToPositiveWest(maxLon, domain)); + fromMapping["MaximumLongitude"] = Isis::toString(TProjection::ToPositiveWest(minLon, domain)); + fromMapping["MinimumLongitude"] = Isis::toString(TProjection::ToPositiveWest(maxLon, domain)); } } } @@ -102,21 +102,21 @@ if((QString::fromStdString(userMapping["LongitudeDirection"])).compare(QString:: if(userMapping.hasKeyword("LatitudeType")) { // user set a new domain? if((QString::fromStdString(userMapping["LatitudeType"])).compare(QString::fromStdString(fromMapping["LatitudeType"])) != 0) { // new lat type different? if((QString::fromStdString(userMapping["LatitudeType"])).compare("Planetographic") == 0) { - fromMapping["MinimumLatitude"] = toString(TProjection::ToPlanetographic( + fromMapping["MinimumLatitude"] = Isis::toString(TProjection::ToPlanetographic( (double)fromMapping["MinimumLatitude"], (double)fromMapping["EquatorialRadius"], (double)fromMapping["PolarRadius"])); - fromMapping["MaximumLatitude"] = toString(TProjection::ToPlanetographic( + fromMapping["MaximumLatitude"] = Isis::toString(TProjection::ToPlanetographic( (double)fromMapping["MaximumLatitude"], (double)fromMapping["EquatorialRadius"], (double)fromMapping["PolarRadius"])); } else { - fromMapping["MinimumLatitude"] = toString(TProjection::ToPlanetocentric( + fromMapping["MinimumLatitude"] = Isis::toString(TProjection::ToPlanetocentric( (double)fromMapping["MinimumLatitude"], (double)fromMapping["EquatorialRadius"], (double)fromMapping["PolarRadius"])); - fromMapping["MaximumLatitude"] = toString(TProjection::ToPlanetocentric( + fromMapping["MaximumLatitude"] = Isis::toString(TProjection::ToPlanetocentric( (double)fromMapping["MaximumLatitude"], (double)fromMapping["EquatorialRadius"], (double)fromMapping["PolarRadius"])); diff --git a/isis/src/base/apps/map2map/map2map.cpp b/isis/src/base/apps/map2map/map2map.cpp index 5ed705464a..bee3a85680 100644 --- a/isis/src/base/apps/map2map/map2map.cpp +++ b/isis/src/base/apps/map2map/map2map.cpp @@ -57,19 +57,19 @@ namespace Isis { // Deal with user overrides entered in the GUI. Do this by changing the user's mapping group, which // will then overlay anything in the output mapping group. if(ui.WasEntered("MINLAT") && !ui.GetBoolean("MATCHMAP")) { - userMappingGrp.addKeyword(PvlKeyword("MinimumLatitude", toString(ui.GetDouble("MINLAT"))), Pvl::Replace); + userMappingGrp.addKeyword(PvlKeyword("MinimumLatitude", Isis::toString(ui.GetDouble("MINLAT"))), Pvl::Replace); } if(ui.WasEntered("MAXLAT") && !ui.GetBoolean("MATCHMAP")) { - userMappingGrp.addKeyword(PvlKeyword("MaximumLatitude", toString(ui.GetDouble("MAXLAT"))), Pvl::Replace); + userMappingGrp.addKeyword(PvlKeyword("MaximumLatitude", Isis::toString(ui.GetDouble("MAXLAT"))), Pvl::Replace); } if(ui.WasEntered("MINLON") && !ui.GetBoolean("MATCHMAP")) { - userMappingGrp.addKeyword(PvlKeyword("MinimumLongitude", toString(ui.GetDouble("MINLON"))), Pvl::Replace); + userMappingGrp.addKeyword(PvlKeyword("MinimumLongitude", Isis::toString(ui.GetDouble("MINLON"))), Pvl::Replace); } if(ui.WasEntered("MAXLON") && !ui.GetBoolean("MATCHMAP")) { - userMappingGrp.addKeyword(PvlKeyword("MaximumLongitude", toString(ui.GetDouble("MAXLON"))), Pvl::Replace); + userMappingGrp.addKeyword(PvlKeyword("MaximumLongitude", Isis::toString(ui.GetDouble("MAXLON"))), Pvl::Replace); } /** @@ -92,8 +92,8 @@ namespace Isis { double minLon = outMappingGrp["MinimumLongitude"]; double maxLon = outMappingGrp["MaximumLongitude"]; - outMappingGrp["MaximumLongitude"] = toString(minLon); - outMappingGrp["MinimumLongitude"] = toString(maxLon); + outMappingGrp["MaximumLongitude"] = Isis::toString(minLon); + outMappingGrp["MinimumLongitude"] = Isis::toString(maxLon); } if(ui.GetString("PIXRES").compare("FROM") == 0 && !ui.GetBoolean("MATCHMAP")) { @@ -151,7 +151,7 @@ namespace Isis { userMappingGrp.deleteKeyword("PixelResolution"); } - outMappingGrp.addKeyword(PvlKeyword("PixelResolution", toString(ui.GetDouble("RESOLUTION")), "meters/pixel"), Pvl::Replace); + outMappingGrp.addKeyword(PvlKeyword("PixelResolution", Isis::toString(ui.GetDouble("RESOLUTION")), "meters/pixel"), Pvl::Replace); } else if(ui.GetString("PIXRES").compare("PPD") == 0) { // Resolution specified - delete all and add to outMappingGrp @@ -179,7 +179,7 @@ namespace Isis { userMappingGrp.deleteKeyword("PixelResolution"); } - outMappingGrp.addKeyword(PvlKeyword("Scale", toString(ui.GetDouble("RESOLUTION")), "pixels/degree"), Pvl::Replace); + outMappingGrp.addKeyword(PvlKeyword("Scale", Isis::toString(ui.GetDouble("RESOLUTION")), "pixels/degree"), Pvl::Replace); } // Rotation will NOT Propagate @@ -217,12 +217,12 @@ namespace Isis { if(!userMappingGrp.hasKeyword(longitudes[index].name())) { // use the from domain because that's where our values are coming from if(((std::string)userMappingGrp["LongitudeDirection"]).compare("PositiveEast") == 0) { - outMappingGrp[longitudes[index].name()] = toString( + outMappingGrp[longitudes[index].name()] = Isis::toString( TProjection::ToPositiveEast(outMappingGrp[longitudes[index].name()], outMappingGrp["LongitudeDomain"])); } else { - outMappingGrp[longitudes[index].name()] = toString( + outMappingGrp[longitudes[index].name()] = Isis::toString( TProjection::ToPositiveWest(outMappingGrp[longitudes[index].name()], outMappingGrp["LongitudeDomain"])); } @@ -238,11 +238,11 @@ namespace Isis { for(int index = 0; index < longitudes.keywords(); index ++) { if(!userMappingGrp.hasKeyword(longitudes[index].name())) { if((int)userMappingGrp["LongitudeDomain"] == 180) { - outMappingGrp[longitudes[index].name()] = toString( + outMappingGrp[longitudes[index].name()] = Isis::toString( TProjection::To180Domain(outMappingGrp[longitudes[index].name()])); } else { - outMappingGrp[longitudes[index].name()] = toString( + outMappingGrp[longitudes[index].name()] = Isis::toString( TProjection::To360Domain(outMappingGrp[longitudes[index].name()])); } } @@ -259,13 +259,13 @@ namespace Isis { for(int index = 0; index < latitudes.keywords(); index ++) { if(!userMappingGrp.hasKeyword(latitudes[index].name())) { if(((std::string)userMappingGrp["LatitudeType"]).compare("Planetographic") == 0) { - outMappingGrp[latitudes[index].name()] = toString(TProjection::ToPlanetographic( + outMappingGrp[latitudes[index].name()] = Isis::toString(TProjection::ToPlanetographic( (double)fromMappingGrp[latitudes[index].name()], (double)fromMappingGrp["EquatorialRadius"], (double)fromMappingGrp["PolarRadius"])); } else { - outMappingGrp[latitudes[index].name()] = toString(TProjection::ToPlanetocentric( + outMappingGrp[latitudes[index].name()] = Isis::toString(TProjection::ToPlanetocentric( (double)fromMappingGrp[latitudes[index].name()], (double)fromMappingGrp["EquatorialRadius"], (double)fromMappingGrp["PolarRadius"])); diff --git a/isis/src/base/apps/mapgrid/main.cpp b/isis/src/base/apps/mapgrid/main.cpp index 79c329268a..4b138d91a5 100644 --- a/isis/src/base/apps/mapgrid/main.cpp +++ b/isis/src/base/apps/mapgrid/main.cpp @@ -52,10 +52,10 @@ void IsisMain() { mapping.deleteKeyword("MaximumLongitude"); } - mapping += PvlKeyword("MinimumLatitude", toString(latStart)); - mapping += PvlKeyword("MaximumLatitude", toString(latEnd)); - mapping += PvlKeyword("MinimumLongitude", toString(lonStart)); - mapping += PvlKeyword("MaximumLongitude", toString(lonEnd)); + mapping += PvlKeyword("MinimumLatitude", Isis::toString(latStart)); + mapping += PvlKeyword("MaximumLatitude", Isis::toString(latEnd)); + mapping += PvlKeyword("MinimumLongitude", Isis::toString(lonStart)); + mapping += PvlKeyword("MaximumLongitude", Isis::toString(lonEnd)); TProjection *proj; try { diff --git a/isis/src/base/apps/maplab/main.cpp b/isis/src/base/apps/maplab/main.cpp index 5fb1831128..67c4698aac 100644 --- a/isis/src/base/apps/maplab/main.cpp +++ b/isis/src/base/apps/maplab/main.cpp @@ -90,14 +90,14 @@ void IsisMain() { y = y + res * (line - 0.5); //add origen values to Mapping Group - mapGrp.addKeyword(PvlKeyword("UpperLeftCornerX", toString(x), "meters"), Pvl::Replace); - mapGrp.addKeyword(PvlKeyword("UpperLeftCornerY", toString(y), "meters"), Pvl::Replace); + mapGrp.addKeyword(PvlKeyword("UpperLeftCornerX", Isis::toString(x), "meters"), Pvl::Replace); + mapGrp.addKeyword(PvlKeyword("UpperLeftCornerY", Isis::toString(y), "meters"), Pvl::Replace); if(!mapGrp.hasKeyword("PixelResolution")) { - mapGrp.addKeyword(PvlKeyword("PixelResolution", toString(res), "meters")); + mapGrp.addKeyword(PvlKeyword("PixelResolution", Isis::toString(res), "meters")); } if(!mapGrp.hasKeyword("Scale")) { - mapGrp.addKeyword(PvlKeyword("Scale", toString(scale), "pixels/degree")); + mapGrp.addKeyword(PvlKeyword("Scale", Isis::toString(scale), "pixels/degree")); } diff --git a/isis/src/base/apps/mapmos/mapmos.cpp b/isis/src/base/apps/mapmos/mapmos.cpp index 6d1fb33b39..73975bef29 100644 --- a/isis/src/base/apps/mapmos/mapmos.cpp +++ b/isis/src/base/apps/mapmos/mapmos.cpp @@ -62,19 +62,19 @@ namespace Isis { inCube->close(); if ( ui.WasEntered("MINLAT") ) { - mapGroup.addKeyword(PvlKeyword( "MinimumLatitude", toString( ui.GetDouble("MINLAT") ) ), + mapGroup.addKeyword(PvlKeyword( "MinimumLatitude", Isis::toString( ui.GetDouble("MINLAT") ) ), Pvl::Replace); } if ( ui.WasEntered("MAXLAT") ) { - mapGroup.addKeyword(PvlKeyword( "MaximumLatitude", toString( ui.GetDouble("MAXLAT") ) ), + mapGroup.addKeyword(PvlKeyword( "MaximumLatitude", Isis::toString( ui.GetDouble("MAXLAT") ) ), Pvl::Replace); } if ( ui.WasEntered("MINLON") ) { - mapGroup.addKeyword(PvlKeyword( "MinimumLongitude", toString( ui.GetDouble("MINLON") ) ), + mapGroup.addKeyword(PvlKeyword( "MinimumLongitude", Isis::toString( ui.GetDouble("MINLON") ) ), Pvl::Replace); } if ( ui.WasEntered("MAXLON") ) { - mapGroup.addKeyword(PvlKeyword( "MaximumLongitude", toString( ui.GetDouble("MAXLON") ) ), + mapGroup.addKeyword(PvlKeyword( "MaximumLongitude", Isis::toString( ui.GetDouble("MAXLON") ) ), Pvl::Replace); } //check to make sure they're all there. If not, throw error, need to enter all. diff --git a/isis/src/base/apps/mappt/mappt.cpp b/isis/src/base/apps/mappt/mappt.cpp index a8b185140e..8a3859354a 100644 --- a/isis/src/base/apps/mappt/mappt.cpp +++ b/isis/src/base/apps/mappt/mappt.cpp @@ -141,7 +141,7 @@ PvlGroup getProjPointInfo(Cube *icube, QPair point, UserInterfac // Make sure we have a valid latitude value if(fabs(lat) > 90.0) { std::string msg = "Invalid value for LATITUDE [" - + toString(lat) + "] outside range of "; + + Isis::toString(lat) + "] outside range of "; msg += "[-90,90]"; throw IException(IException::User, msg, _FILEINFO_); } @@ -255,36 +255,36 @@ PvlGroup getProjPointInfo(Cube *icube, QPair point, UserInterfac if(proj->IsGood()) { results += PvlKeyword("Filename", FileName(icube->fileName().toStdString()).expanded()); - results += PvlKeyword("Sample", toString(proj->WorldX())); - results += PvlKeyword("Line", toString(proj->WorldY())); - results += PvlKeyword("Band", toString(icube->physicalBand(1))); + results += PvlKeyword("Sample", Isis::toString(proj->WorldX())); + results += PvlKeyword("Line", Isis::toString(proj->WorldY())); + results += PvlKeyword("Band", Isis::toString(icube->physicalBand(1))); results += PvlKeyword("FilterName", filterName.toStdString()); results += PvlKeyword("PixelValue", PixelToString(b[0])); - results += PvlKeyword("X", toString(proj->XCoord())); - results += PvlKeyword("Y", toString(proj->YCoord())); + results += PvlKeyword("X", Isis::toString(proj->XCoord())); + results += PvlKeyword("Y", Isis::toString(proj->YCoord())); // Put together all the keywords for different coordinate systems. PvlKeyword centLat = - PvlKeyword("PlanetocentricLatitude", toString(proj->UniversalLatitude())); + PvlKeyword("PlanetocentricLatitude", Isis::toString(proj->UniversalLatitude())); PvlKeyword graphLat = PvlKeyword("PlanetographicLatitude", - toString(proj->ToPlanetographic(proj->UniversalLatitude()))); + Isis::toString(proj->ToPlanetographic(proj->UniversalLatitude()))); PvlKeyword pE360 = - PvlKeyword("PositiveEast360Longitude", toString(proj->UniversalLongitude())); + PvlKeyword("PositiveEast360Longitude", Isis::toString(proj->UniversalLongitude())); PvlKeyword pW360 = PvlKeyword("PositiveWest360Longitude", - toString(proj->ToPositiveWest(proj->UniversalLongitude(), 360))); + Isis::toString(proj->ToPositiveWest(proj->UniversalLongitude(), 360))); PvlKeyword pE180 = PvlKeyword("PositiveEast180Longitude", - toString(proj->To180Domain(proj->UniversalLongitude()))); + Isis::toString(proj->To180Domain(proj->UniversalLongitude()))); PvlKeyword pW180 = PvlKeyword("PositiveWest180Longitude", - toString(proj->To180Domain(proj->ToPositiveEast( + Isis::toString(proj->To180Domain(proj->ToPositiveEast( proj->UniversalLongitude(), 360)))); diff --git a/isis/src/base/apps/mapsize/main.cpp b/isis/src/base/apps/mapsize/main.cpp index e539b4b8aa..9324b31f75 100644 --- a/isis/src/base/apps/mapsize/main.cpp +++ b/isis/src/base/apps/mapsize/main.cpp @@ -45,14 +45,14 @@ void IsisMain() { // Create a label and log it PvlGroup results("Results"); results += PvlKeyword("Map", ui.GetFileName("MAP").toStdString()); - results += PvlKeyword("Scale", toString(scale)); - results += PvlKeyword("Width", toString(width), "inches"); - results += PvlKeyword("Height", toString(height), "inches"); - results += PvlKeyword("Samples", toString(samples)); - results += PvlKeyword("Lines", toString(lines)); - results += PvlKeyword("RealSize", toString(((Isis::BigInt)lines * samples * 4) / 1024.0), "KB"); - results += PvlKeyword("SignedWordSize", toString(((Isis::BigInt)lines * samples * 2) / 1024.0), "KB"); - results += PvlKeyword("UnsignedByteSize", toString(((Isis::BigInt)lines * samples) / 1024.0), "KB"); + results += PvlKeyword("Scale", Isis::toString(scale)); + results += PvlKeyword("Width", Isis::toString(width), "inches"); + results += PvlKeyword("Height", Isis::toString(height), "inches"); + results += PvlKeyword("Samples", Isis::toString(samples)); + results += PvlKeyword("Lines", Isis::toString(lines)); + results += PvlKeyword("RealSize", Isis::toString(((Isis::BigInt)lines * samples * 4) / 1024.0), "KB"); + results += PvlKeyword("SignedWordSize", Isis::toString(((Isis::BigInt)lines * samples * 2) / 1024.0), "KB"); + results += PvlKeyword("UnsignedByteSize", Isis::toString(((Isis::BigInt)lines * samples) / 1024.0), "KB"); Application::Log(results); // Write the output file if requested diff --git a/isis/src/base/apps/maptemplate/main.cpp b/isis/src/base/apps/maptemplate/main.cpp index 5916bd21a1..43d625164f 100644 --- a/isis/src/base/apps/maptemplate/main.cpp +++ b/isis/src/base/apps/maptemplate/main.cpp @@ -391,39 +391,39 @@ void addProject(PvlGroup &mapping) { mapping += PvlKeyword("ProjectionName", projLUT[projName].toStdString()); if(ui.WasEntered("CLON")) { double clonOut = ui.GetDouble("CLON"); - mapping += PvlKeyword("CenterLongitude", toString(clonOut)); + mapping += PvlKeyword("CenterLongitude", Isis::toString(clonOut)); } if(ui.WasEntered("CLAT")) { double clatOut = ui.GetDouble("CLAT"); - mapping += PvlKeyword("CenterLatitude", toString(clatOut)); + mapping += PvlKeyword("CenterLatitude", Isis::toString(clatOut)); } if(ui.WasEntered("SCALEFACTOR")) { double scaleFactorOut = ui.GetDouble("SCALEFACTOR"); - mapping += PvlKeyword("ScaleFactor", toString(scaleFactorOut)); + mapping += PvlKeyword("ScaleFactor", Isis::toString(scaleFactorOut)); } if(ui.WasEntered("PAR1")) { double par1 = ui.GetDouble("PAR1"); - mapping += PvlKeyword("FirstStandardParallel", toString(par1)); + mapping += PvlKeyword("FirstStandardParallel", Isis::toString(par1)); } if(ui.WasEntered("PAR2")) { double par2 = ui.GetDouble("PAR2"); - mapping += PvlKeyword("SecondStandardParallel", toString(par2)); + mapping += PvlKeyword("SecondStandardParallel", Isis::toString(par2)); } if(ui.WasEntered("PLAT")) { double plat = ui.GetDouble("PLAT"); - mapping += PvlKeyword("PoleLatitude", toString(plat)); + mapping += PvlKeyword("PoleLatitude", Isis::toString(plat)); } if(ui.WasEntered("PLON")) { double plon = ui.GetDouble("PLON"); - mapping += PvlKeyword("PoleLongitude", toString(plon)); + mapping += PvlKeyword("PoleLongitude", Isis::toString(plon)); } if(ui.WasEntered("PROT")) { double prot = ui.GetDouble("PROT"); - mapping += PvlKeyword("PoleRotation", toString(prot)); + mapping += PvlKeyword("PoleRotation", Isis::toString(prot)); } if(ui.WasEntered("DIST")) { double dist = ui.GetDouble("DIST"); - mapping += PvlKeyword("Distance", toString(dist)); + mapping += PvlKeyword("Distance", Isis::toString(dist)); } } @@ -511,13 +511,13 @@ void addRange(PvlGroup &mapping) { // Use the values that have been entered in the GUI if(ui.GetString("RNGOPT") == "USER") { double minLat = ui.GetDouble("MINLAT"); - mapping += PvlKeyword("MinimumLatitude", toString(minLat)); + mapping += PvlKeyword("MinimumLatitude", Isis::toString(minLat)); double maxLat = ui.GetDouble("MAXLAT"); - mapping += PvlKeyword("MaximumLatitude", toString(maxLat)); + mapping += PvlKeyword("MaximumLatitude", Isis::toString(maxLat)); double minLon = ui.GetDouble("MINLON"); - mapping += PvlKeyword("MinimumLongitude", toString(minLon)); + mapping += PvlKeyword("MinimumLongitude", Isis::toString(minLon)); double maxLon = ui.GetDouble("MAXLON"); - mapping += PvlKeyword("MaximumLongitude", toString(maxLon)); + mapping += PvlKeyword("MaximumLongitude", Isis::toString(maxLon)); } else if(ui.GetString("RNGOPT") == "CALC") { // calculate range values using function calcRange and fromlist @@ -527,10 +527,10 @@ void addRange(PvlGroup &mapping) { double maxLon; // Call calcRange to calculate min and max ground range values calcRange(minLat, maxLat, minLon, maxLon); - mapping += PvlKeyword("MinimumLatitude", toString(minLat)); - mapping += PvlKeyword("MaximumLatitude", toString(maxLat)); - mapping += PvlKeyword("MinimumLongitude", toString(minLon)); - mapping += PvlKeyword("MaximumLongitude", toString(maxLon)); + mapping += PvlKeyword("MinimumLatitude", Isis::toString(minLat)); + mapping += PvlKeyword("MaximumLatitude", Isis::toString(maxLat)); + mapping += PvlKeyword("MinimumLongitude", Isis::toString(minLon)); + mapping += PvlKeyword("MaximumLongitude", Isis::toString(maxLon)); } } @@ -540,16 +540,16 @@ void addResolution(PvlGroup &mapping) { UserInterface &ui = Application::GetUserInterface(); if(ui.GetString("RESOPT") == "PPD") { double res = ui.GetDouble("RESOLUTION"); - mapping += PvlKeyword("Scale", toString(res), "pixels/degree"); + mapping += PvlKeyword("Scale", Isis::toString(res), "pixels/degree"); } else if(ui.GetString("RESOPT") == "MPP") { double res = ui.GetDouble("RESOLUTION"); - mapping += PvlKeyword("PixelResolution", toString(res), "meters/pixel"); + mapping += PvlKeyword("PixelResolution", Isis::toString(res), "meters/pixel"); } else if(ui.GetString("RESOPT") == "CALC") { // run the function to calculate the resolution double Res = calcResolution(); - mapping += PvlKeyword("PixelResolution", toString(Res), "meters/pixel"); + mapping += PvlKeyword("PixelResolution", Isis::toString(Res), "meters/pixel"); } } diff --git a/isis/src/base/apps/mask/main.cpp b/isis/src/base/apps/mask/main.cpp index 322a63aeed..8f62767973 100644 --- a/isis/src/base/apps/mask/main.cpp +++ b/isis/src/base/apps/mask/main.cpp @@ -74,10 +74,10 @@ void IsisMain() { PvlGroup results("Results"); if(g_masked == true) { - results += PvlKeyword("PixelsMasked", toString(g_pixelsMasked)); + results += PvlKeyword("PixelsMasked", Isis::toString(g_pixelsMasked)); } else { - PvlKeyword pm("PixelsMasked", toString(g_pixelsMasked)); + PvlKeyword pm("PixelsMasked", Isis::toString(g_pixelsMasked)); pm.addComment( "No pixels were masked for this image"); results += pm; } diff --git a/isis/src/base/apps/mosrange/mosrange.cpp b/isis/src/base/apps/mosrange/mosrange.cpp index 1c497e4ebf..34838bd38e 100644 --- a/isis/src/base/apps/mosrange/mosrange.cpp +++ b/isis/src/base/apps/mosrange/mosrange.cpp @@ -143,8 +143,8 @@ namespace Isis { PvlObject fmap("File"); fmap += PvlKeyword("Name", cubeFileList[i].toString()); - fmap += PvlKeyword("Lines", toString(lines)); - fmap += PvlKeyword("Samples", toString(samples)); + fmap += PvlKeyword("Lines", Isis::toString(lines)); + fmap += PvlKeyword("Samples", Isis::toString(samples)); Camera *cam = cube.camera(); Pvl mapping; @@ -182,20 +182,20 @@ namespace Isis { double pixres = (lowres + hires) / 2.0; double scale = Scale(pixres, poleRad, eqRad); - mapgrp.addKeyword(PvlKeyword("PixelResolution", toString(pixres)), Pvl::Replace); - mapgrp.addKeyword(PvlKeyword("Scale", toString(scale), "pixels/degree"), Pvl::Replace); - mapgrp += PvlKeyword("MinPixelResolution", toString(lowres), "meters/pixel"); - mapgrp += PvlKeyword("MaxPixelResolution", toString(hires), "meters/pixel"); - mapgrp += PvlKeyword("MinObliquePixelResolution", toString(lowObliqueRes), "meters/pixel"); - mapgrp += PvlKeyword("MaxObliquePixelResolution", toString(hiObliqueRes), "meters/pixel"); + mapgrp.addKeyword(PvlKeyword("PixelResolution", Isis::toString(pixres)), Pvl::Replace); + mapgrp.addKeyword(PvlKeyword("Scale", Isis::toString(scale), "pixels/degree"), Pvl::Replace); + mapgrp += PvlKeyword("MinPixelResolution", Isis::toString(lowres), "meters/pixel"); + mapgrp += PvlKeyword("MaxPixelResolution", Isis::toString(hires), "meters/pixel"); + mapgrp += PvlKeyword("MinObliquePixelResolution", Isis::toString(lowObliqueRes), "meters/pixel"); + mapgrp += PvlKeyword("MaxObliquePixelResolution", Isis::toString(hiObliqueRes), "meters/pixel"); // Get the universal ground range double minlat, maxlat, minlon, maxlon; cam->GroundRange(minlat, maxlat, minlon, maxlon, mapping); - mapgrp.addKeyword(PvlKeyword("MinimumLatitude", toString(minlat)), Pvl::Replace); - mapgrp.addKeyword(PvlKeyword("MaximumLatitude", toString(maxlat)), Pvl::Replace); - mapgrp.addKeyword(PvlKeyword("MinimumLongitude", toString(minlon)), Pvl::Replace); - mapgrp.addKeyword(PvlKeyword("MaximumLongitude", toString(maxlon)), Pvl::Replace); + mapgrp.addKeyword(PvlKeyword("MinimumLatitude", Isis::toString(minlat)), Pvl::Replace); + mapgrp.addKeyword(PvlKeyword("MaximumLatitude", Isis::toString(maxlat)), Pvl::Replace); + mapgrp.addKeyword(PvlKeyword("MinimumLongitude", Isis::toString(minlon)), Pvl::Replace); + mapgrp.addKeyword(PvlKeyword("MaximumLongitude", Isis::toString(maxlon)), Pvl::Replace); fmap.addGroup(mapgrp); fileset.addObject(fmap); @@ -263,38 +263,38 @@ namespace Isis { mapping += PvlKeyword("ProjectionName", projection.toStdString()); mapping += PvlKeyword("TargetName", target.toStdString()); - mapping += PvlKeyword("EquatorialRadius", toString(eqRad), "meters"); - mapping += PvlKeyword("PolarRadius", toString(poleRad), "meters"); + mapping += PvlKeyword("EquatorialRadius", Isis::toString(eqRad), "meters"); + mapping += PvlKeyword("PolarRadius", Isis::toString(poleRad), "meters"); mapping += PvlKeyword("LatitudeType", lattype.toStdString()); mapping += PvlKeyword("LongitudeDirection", londir.toStdString()); mapping += PvlKeyword("LongitudeDomain", londom.toStdString()); - mapping += PvlKeyword("PixelResolution", toString(SetRound(avgPixRes, digits)), "meters/pixel"); - mapping += PvlKeyword("Scale", toString(SetRound(scale, digits)), "pixels/degree"); - mapping += PvlKeyword("MinPixelResolution", toString(scaleStat.Minimum()), "meters/pixel"); - mapping += PvlKeyword("MaxPixelResolution", toString(scaleStat.Maximum()), "meters/pixel"); - mapping += PvlKeyword("MinObliquePixelResolution", toString(obliqueScaleStat.Minimum()), + mapping += PvlKeyword("PixelResolution", Isis::toString(SetRound(avgPixRes, digits)), "meters/pixel"); + mapping += PvlKeyword("Scale", Isis::toString(SetRound(scale, digits)), "pixels/degree"); + mapping += PvlKeyword("MinPixelResolution", Isis::toString(scaleStat.Minimum()), "meters/pixel"); + mapping += PvlKeyword("MaxPixelResolution", Isis::toString(scaleStat.Maximum()), "meters/pixel"); + mapping += PvlKeyword("MinObliquePixelResolution", Isis::toString(obliqueScaleStat.Minimum()), "meters/pixel"); - mapping += PvlKeyword("MaxObliquePixelResolution", toString(obliqueScaleStat.Maximum()), + mapping += PvlKeyword("MaxObliquePixelResolution", Isis::toString(obliqueScaleStat.Maximum()), "meters/pixel"); - mapping += PvlKeyword("CenterLongitude", toString(SetRound(avgLon, digits))); - mapping += PvlKeyword("CenterLatitude", toString(SetRound(avgLat, digits))); - mapping += PvlKeyword("MinimumLatitude", toString(std::max(SetFloor(latitudeStat.Minimum(), + mapping += PvlKeyword("CenterLongitude", Isis::toString(SetRound(avgLon, digits))); + mapping += PvlKeyword("CenterLatitude", Isis::toString(SetRound(avgLat, digits))); + mapping += PvlKeyword("MinimumLatitude", Isis::toString(std::max(SetFloor(latitudeStat.Minimum(), digits), -90.0))); - mapping += PvlKeyword("MaximumLatitude", toString(std::min(SetCeil(latitudeStat.Maximum(), + mapping += PvlKeyword("MaximumLatitude", Isis::toString(std::min(SetCeil(latitudeStat.Maximum(), digits), 90.0))); - mapping += PvlKeyword("MinimumLongitude", toString(std::max(SetFloor(longitudeStat.Minimum(), + mapping += PvlKeyword("MinimumLongitude", Isis::toString(std::max(SetFloor(longitudeStat.Minimum(), digits), -180.0))); - mapping += PvlKeyword("MaximumLongitude", toString(std::min(SetCeil(longitudeStat.Maximum(), + mapping += PvlKeyword("MaximumLongitude", Isis::toString(std::min(SetCeil(longitudeStat.Maximum(), digits), 360.0))); - PvlKeyword clat("PreciseCenterLongitude", toString(avgLon)); + PvlKeyword clat("PreciseCenterLongitude", Isis::toString(avgLon)); clat.addComment("Actual Parameters without precision applied"); mapping += clat; - mapping += PvlKeyword("PreciseCenterLatitude", toString(avgLat)); - mapping += PvlKeyword("PreciseMinimumLatitude", toString(latitudeStat.Minimum())); - mapping += PvlKeyword("PreciseMaximumLatitude", toString(latitudeStat.Maximum())); - mapping += PvlKeyword("PreciseMinimumLongitude", toString(longitudeStat.Minimum())); - mapping += PvlKeyword("PreciseMaximumLongitude", toString(longitudeStat.Maximum())); + mapping += PvlKeyword("PreciseCenterLatitude", Isis::toString(avgLat)); + mapping += PvlKeyword("PreciseMinimumLatitude", Isis::toString(latitudeStat.Minimum())); + mapping += PvlKeyword("PreciseMaximumLatitude", Isis::toString(latitudeStat.Maximum())); + mapping += PvlKeyword("PreciseMinimumLongitude", Isis::toString(longitudeStat.Minimum())); + mapping += PvlKeyword("PreciseMaximumLongitude", Isis::toString(longitudeStat.Maximum())); Application::Log(mapping); diff --git a/isis/src/base/apps/mvstats/main.cpp b/isis/src/base/apps/mvstats/main.cpp index 0404632576..667a771e6a 100644 --- a/isis/src/base/apps/mvstats/main.cpp +++ b/isis/src/base/apps/mvstats/main.cpp @@ -64,8 +64,8 @@ void IsisMain() { //Set CubeAttributeInputs to tell the ProcessByLine which //bands to compare - CubeAttributeInput band_a("d+" + toString(icube->physicalBand(i))); - CubeAttributeInput band_b("d+" + toString(icube->physicalBand(j))); + CubeAttributeInput band_a("d+" + Isis::toString(icube->physicalBand(i))); + CubeAttributeInput band_b("d+" + Isis::toString(icube->physicalBand(j))); //Set Input files and process, to accumulate the statistics p.SetInputCube(file, band_a); diff --git a/isis/src/base/apps/nocam2map/nocam2map.cpp b/isis/src/base/apps/nocam2map/nocam2map.cpp index c3fe7052d0..948466ca7b 100644 --- a/isis/src/base/apps/nocam2map/nocam2map.cpp +++ b/isis/src/base/apps/nocam2map/nocam2map.cpp @@ -175,16 +175,16 @@ namespace Isis { //Records the error to the log PvlGroup error("Error"); - error += PvlKeyword("Degree", toString(degree)); - error += PvlKeyword("NumberOfPoints", toString((int)sampResiduals.size())); - error += PvlKeyword("SampleMinimumError", toString(sampErr.Minimum())); - error += PvlKeyword("SampleAverageError", toString(sampErr.Average())); - error += PvlKeyword("SampleMaximumError", toString(sampErr.Maximum())); - error += PvlKeyword("SampleStdDeviationError", toString(sampErr.StandardDeviation())); - error += PvlKeyword("LineMinimumError", toString(lineErr.Minimum())); - error += PvlKeyword("LineAverageError", toString(lineErr.Average())); - error += PvlKeyword("LineMaximumError", toString(lineErr.Maximum())); - error += PvlKeyword("LineStdDeviationError", toString(lineErr.StandardDeviation())); + error += PvlKeyword("Degree", Isis::toString(degree)); + error += PvlKeyword("NumberOfPoints", Isis::toString((int)sampResiduals.size())); + error += PvlKeyword("SampleMinimumError", Isis::toString(sampErr.Minimum())); + error += PvlKeyword("SampleAverageError", Isis::toString(sampErr.Average())); + error += PvlKeyword("SampleMaximumError", Isis::toString(sampErr.Maximum())); + error += PvlKeyword("SampleStdDeviationError", Isis::toString(sampErr.StandardDeviation())); + error += PvlKeyword("LineMinimumError", Isis::toString(lineErr.Minimum())); + error += PvlKeyword("LineAverageError", Isis::toString(lineErr.Average())); + error += PvlKeyword("LineMaximumError", Isis::toString(lineErr.Maximum())); + error += PvlKeyword("LineStdDeviationError", Isis::toString(lineErr.StandardDeviation())); Application::Log(error); @@ -226,8 +226,8 @@ namespace Isis { PvlKeyword polRadius; //If the user entered the equatorial and polar radii if (ui.WasEntered("EQURADIUS") && ui.WasEntered("POLRADIUS")) { - equRadius = PvlKeyword("EquatorialRadius", toString(ui.GetDouble("EQURADIUS"))); - polRadius = PvlKeyword("PolarRadius", toString(ui.GetDouble("POLRADIUS"))); + equRadius = PvlKeyword("EquatorialRadius", Isis::toString(ui.GetDouble("EQURADIUS"))); + polRadius = PvlKeyword("PolarRadius", Isis::toString(ui.GetDouble("POLRADIUS"))); } //Else read them from the pck else { @@ -319,31 +319,31 @@ namespace Isis { maxLon = temp; } - mapGrp.addKeyword(PvlKeyword("MinimumLatitude", toString(minLat)), Pvl::Replace); - mapGrp.addKeyword(PvlKeyword("MaximumLatitude", toString(maxLat)), Pvl::Replace); - mapGrp.addKeyword(PvlKeyword("MinimumLongitude", toString(minLon)), Pvl::Replace); - mapGrp.addKeyword(PvlKeyword("MaximumLongitude", toString(maxLon)), Pvl::Replace); + mapGrp.addKeyword(PvlKeyword("MinimumLatitude", Isis::toString(minLat)), Pvl::Replace); + mapGrp.addKeyword(PvlKeyword("MaximumLatitude", Isis::toString(maxLat)), Pvl::Replace); + mapGrp.addKeyword(PvlKeyword("MinimumLongitude", Isis::toString(minLon)), Pvl::Replace); + mapGrp.addKeyword(PvlKeyword("MaximumLongitude", Isis::toString(maxLon)), Pvl::Replace); } //If the user decided to enter a ground range then override if (ui.WasEntered("MINLAT")) { mapGrp.addKeyword(PvlKeyword("MinimumLatitude", - toString(ui.GetDouble("MINLAT"))), Pvl::Replace); + Isis::toString(ui.GetDouble("MINLAT"))), Pvl::Replace); } if (ui.WasEntered("MAXLAT")) { mapGrp.addKeyword(PvlKeyword("MaximumLatitude", - toString(ui.GetDouble("MAXLAT"))), Pvl::Replace); + Isis::toString(ui.GetDouble("MAXLAT"))), Pvl::Replace); } if (ui.WasEntered("MINLON")) { mapGrp.addKeyword(PvlKeyword("MinimumLongitude", - toString(ui.GetDouble("MINLON"))), Pvl::Replace); + Isis::toString(ui.GetDouble("MINLON"))), Pvl::Replace); } if (ui.WasEntered("MAXLON")) { mapGrp.addKeyword(PvlKeyword("MaximumLongitude", - toString(ui.GetDouble("MAXLON"))), Pvl::Replace); + Isis::toString(ui.GetDouble("MAXLON"))), Pvl::Replace); } //If the pixel resolution is to be computed, compute the pixels/degree from the input @@ -378,7 +378,7 @@ namespace Isis { //Add the scale in pixels/degree to the mapping group mapGrp.addKeyword(PvlKeyword("Scale", - toString(pixels / angle), "pixels/degree"), + Isis::toString(pixels / angle), "pixels/degree"), Pvl::Replace); if (mapGrp.hasKeyword("PixelResolution")) { mapGrp.deleteKeyword("PixelResolution"); @@ -389,7 +389,7 @@ namespace Isis { // If the user decided to enter a resolution then override if (ui.GetString("PIXRES") == "MPP") { mapGrp.addKeyword(PvlKeyword("PixelResolution", - toString(ui.GetDouble("RESOLUTION")), "meters/pixel"), + Isis::toString(ui.GetDouble("RESOLUTION")), "meters/pixel"), Pvl::Replace); if (mapGrp.hasKeyword("Scale")) { mapGrp.deleteKeyword("Scale"); @@ -397,7 +397,7 @@ namespace Isis { } else if (ui.GetString("PIXRES") == "PPD") { mapGrp.addKeyword(PvlKeyword("Scale", - toString(ui.GetDouble("RESOLUTION")), "pixels/degree"), + Isis::toString(ui.GetDouble("RESOLUTION")), "pixels/degree"), Pvl::Replace); if (mapGrp.hasKeyword("PixelResolution")) { mapGrp.deleteKeyword("PixelResolution"); diff --git a/isis/src/base/apps/noisefilter/main.cpp b/isis/src/base/apps/noisefilter/main.cpp index bd722e41d4..4602bfbbc8 100644 --- a/isis/src/base/apps/noisefilter/main.cpp +++ b/isis/src/base/apps/noisefilter/main.cpp @@ -63,15 +63,15 @@ void IsisMain() { // Generate a results group and log it PvlGroup results("Results"); - results += PvlKeyword("DarkPixelsReplaced", toString(darkPixelsReplaced)); - results += PvlKeyword("BrightPixelsReplaced", toString(brightPixelsReplaced)); - results += PvlKeyword("SpecialPixelsReplaced", toString(specialPixelsReplaced)); + results += PvlKeyword("DarkPixelsReplaced", Isis::toString(darkPixelsReplaced)); + results += PvlKeyword("BrightPixelsReplaced", Isis::toString(brightPixelsReplaced)); + results += PvlKeyword("SpecialPixelsReplaced", Isis::toString(specialPixelsReplaced)); int pixelsReplaced = darkPixelsReplaced + brightPixelsReplaced + specialPixelsReplaced; - results += PvlKeyword("TotalPixelsReplaced", toString(pixelsReplaced)); + results += PvlKeyword("TotalPixelsReplaced", Isis::toString(pixelsReplaced)); double pct = ((double)pixelsReplaced / ((double)icube->sampleCount() * (double)icube->lineCount())) * 100.; pct = (int)(pct * 10.0) / 10.0; - results += PvlKeyword("PercentChanged", toString(pct)); + results += PvlKeyword("PercentChanged", Isis::toString(pct)); Application::Log(results); p.EndProcess(); } diff --git a/isis/src/base/apps/noproj/noproj.cpp b/isis/src/base/apps/noproj/noproj.cpp index 293537e488..e101a64de4 100644 --- a/isis/src/base/apps/noproj/noproj.cpp +++ b/isis/src/base/apps/noproj/noproj.cpp @@ -234,11 +234,11 @@ namespace Isis { inst.addKeyword(key); key.setName("SampleDetectors"); - key.setValue(toString(detectorSamples)); + key.setValue(Isis::toString(detectorSamples)); inst.addKeyword(key); key.setName("LineDetectors"); - key.setValue(toString(detectorLines)); + key.setValue(Isis::toString(detectorLines)); inst.addKeyword(key); key.setName("InstrumentType"); @@ -287,24 +287,24 @@ namespace Isis { } if (naifKeywordsObject) { - naifKeywordsObject->addKeyword(PvlKeyword("IDEAL_FOCAL_LENGTH", toString(incam->FocalLength())), + naifKeywordsObject->addKeyword(PvlKeyword("IDEAL_FOCAL_LENGTH", Isis::toString(incam->FocalLength())), Pvl::Replace); } else { - inst.addKeyword(PvlKeyword("FocalLength", toString(incam->FocalLength()), "millimeters")); + inst.addKeyword(PvlKeyword("FocalLength", Isis::toString(incam->FocalLength()), "millimeters")); } double newPixelPitch = incam->PixelPitch() * summingMode; if (naifKeywordsObject) { - naifKeywordsObject->addKeyword(PvlKeyword("IDEAL_PIXEL_PITCH", toString(newPixelPitch)), + naifKeywordsObject->addKeyword(PvlKeyword("IDEAL_PIXEL_PITCH", Isis::toString(newPixelPitch)), Pvl::Replace); } else { - inst.addKeyword(PvlKeyword("PixelPitch", toString(newPixelPitch), "millimeters")); + inst.addKeyword(PvlKeyword("PixelPitch", Isis::toString(newPixelPitch), "millimeters")); } key.setName("EphemerisTime"); - key.setValue(toString(et), "seconds"); + key.setValue(Isis::toString(et), "seconds"); inst.addKeyword(key); key.setName("StartTime"); @@ -318,16 +318,16 @@ namespace Isis { } key.setName("FocalPlaneXDependency"); - key.setValue(toString((int)incam->FocalPlaneMap()->FocalPlaneXDependency())); + key.setValue(Isis::toString((int)incam->FocalPlaneMap()->FocalPlaneXDependency())); inst.addKeyword(key); int xDependency = incam->FocalPlaneMap()->FocalPlaneXDependency(); double newInstrumentTransX = incam->FocalPlaneMap()->SignMostSigX(); - inst.addKeyword(PvlKeyword("TransX", toString(newInstrumentTransX))); + inst.addKeyword(PvlKeyword("TransX", Isis::toString(newInstrumentTransX))); double newInstrumentTransY = incam->FocalPlaneMap()->SignMostSigY(); - inst.addKeyword(PvlKeyword("TransY", toString(newInstrumentTransY))); + inst.addKeyword(PvlKeyword("TransY", Isis::toString(newInstrumentTransY))); storeSpice(&inst, naifKeywordsObject, "TransX0", "IDEAL_TRANSX", transx, newPixelPitch * newInstrumentTransX, (xDependency == CameraFocalPlaneMap::Sample)); @@ -349,7 +349,7 @@ namespace Isis { if(instType == "LINESCAN") { key.setName("ExposureDuration"); - key.setValue(toString(incam->DetectorMap()->LineRate() * 1000.), "milliseconds"); + key.setValue(Isis::toString(incam->DetectorMap()->LineRate() * 1000.), "milliseconds"); inst.addKeyword(key); } @@ -367,9 +367,9 @@ namespace Isis { QString matchLbl = matchCubeFileNoExt + ".lbl"; label.read(matchLbl.toStdString()); PvlGroup &dims = label.findGroup("Dimensions", Pvl::Traverse); - dims["Lines"] = toString(numberLines); - dims["Samples"] = toString(detectorSamples); - dims["Bands"] = toString(numberBands); + dims["Lines"] = Isis::toString(numberLines); + dims["Samples"] = Isis::toString(detectorSamples); + dims["Bands"] = Isis::toString(numberBands); label.write(matchLbl.toStdString()); // And run cam2cam to apply the transformation @@ -413,19 +413,19 @@ namespace Isis { QString oldName, QString spiceName, double constantCoeff, double multiplierCoeff, bool putMultiplierInX) { if(constantCoeff != 0 && !naifKeywordsObject && instrumentGroup) { - instrumentGroup->addKeyword(PvlKeyword(oldName.toStdString(), toString(constantCoeff))); + instrumentGroup->addKeyword(PvlKeyword(oldName.toStdString(), Isis::toString(constantCoeff))); } else if (naifKeywordsObject) { PvlKeyword spiceKeyword(spiceName.toStdString()); - spiceKeyword += toString(constantCoeff); + spiceKeyword += Isis::toString(constantCoeff); if (putMultiplierInX) { - spiceKeyword += toString(multiplierCoeff); - spiceKeyword += toString(0.0); + spiceKeyword += Isis::toString(multiplierCoeff); + spiceKeyword += Isis::toString(0.0); } else { - spiceKeyword += toString(0.0); - spiceKeyword += toString(multiplierCoeff); + spiceKeyword += Isis::toString(0.0); + spiceKeyword += Isis::toString(multiplierCoeff); } naifKeywordsObject->addKeyword(spiceKeyword, Pvl::Replace); diff --git a/isis/src/base/apps/overlapstats/overlapstats.cpp b/isis/src/base/apps/overlapstats/overlapstats.cpp index cf415b4ec2..6e21889d8d 100644 --- a/isis/src/base/apps/overlapstats/overlapstats.cpp +++ b/isis/src/base/apps/overlapstats/overlapstats.cpp @@ -218,25 +218,25 @@ namespace Isis { //Create and Log the BRIEF description PvlGroup brief("Results"); - brief += PvlKeyword("ThicknessMinimum", toString(thickness.Minimum())); - brief += PvlKeyword("ThicknessMaximum", toString(thickness.Maximum())); - brief += PvlKeyword("ThicknessAverage", toString(thickness.Average())); - brief += PvlKeyword("ThicknessStandardDeviation", toString(thickness.StandardDeviation())); - brief += PvlKeyword("ThicknessVariance", toString(thickness.Variance())); - - brief += PvlKeyword("AreaMinimum", toString(area.Minimum())); - brief += PvlKeyword("AreaMaximum", toString(area.Maximum())); - brief += PvlKeyword("AreaAverage", toString(area.Average())); - brief += PvlKeyword("AreaStandardDeviation", toString(area.StandardDeviation())); - brief += PvlKeyword("AreaVariance", toString(area.Variance())); - - brief += PvlKeyword("ImageStackMinimum", toString(sncount.Minimum())); - brief += PvlKeyword("ImageStackMaximum", toString(sncount.Maximum())); - brief += PvlKeyword("ImageStackAverage", toString(sncount.Average())); - brief += PvlKeyword("ImageStackStandardDeviation", toString(sncount.StandardDeviation())); - brief += PvlKeyword("ImageStackVariance", toString(sncount.Variance())); - - brief += PvlKeyword("PolygonCount", toString(overlaps.Size())); + brief += PvlKeyword("ThicknessMinimum", Isis::toString(thickness.Minimum())); + brief += PvlKeyword("ThicknessMaximum", Isis::toString(thickness.Maximum())); + brief += PvlKeyword("ThicknessAverage", Isis::toString(thickness.Average())); + brief += PvlKeyword("ThicknessStandardDeviation", Isis::toString(thickness.StandardDeviation())); + brief += PvlKeyword("ThicknessVariance", Isis::toString(thickness.Variance())); + + brief += PvlKeyword("AreaMinimum", Isis::toString(area.Minimum())); + brief += PvlKeyword("AreaMaximum", Isis::toString(area.Maximum())); + brief += PvlKeyword("AreaAverage", Isis::toString(area.Average())); + brief += PvlKeyword("AreaStandardDeviation", Isis::toString(area.StandardDeviation())); + brief += PvlKeyword("AreaVariance", Isis::toString(area.Variance())); + + brief += PvlKeyword("ImageStackMinimum", Isis::toString(sncount.Minimum())); + brief += PvlKeyword("ImageStackMaximum", Isis::toString(sncount.Maximum())); + brief += PvlKeyword("ImageStackAverage", Isis::toString(sncount.Average())); + brief += PvlKeyword("ImageStackStandardDeviation", Isis::toString(sncount.StandardDeviation())); + brief += PvlKeyword("ImageStackVariance", Isis::toString(sncount.Variance())); + + brief += PvlKeyword("PolygonCount", Isis::toString(overlaps.Size())); // Add non-overlapping cubes to the output if (!nooverlap.empty()) { @@ -259,7 +259,7 @@ namespace Isis { //Log error num in print.prt if there were errors if (errorNum > 0) { PvlGroup grp("OverlapStats"); - PvlKeyword key("ErrorNumber", toString(errorNum)); + PvlKeyword key("ErrorNumber", Isis::toString(errorNum)); grp.addKeyword(key); Application::AppendAndLog(grp, log); } diff --git a/isis/src/base/apps/pad/main.cpp b/isis/src/base/apps/pad/main.cpp index 3ffd41eea6..025a37d331 100644 --- a/isis/src/base/apps/pad/main.cpp +++ b/isis/src/base/apps/pad/main.cpp @@ -49,14 +49,14 @@ void IsisMain() { // Construct a label with the results PvlGroup results("Results"); - results += PvlKeyword("InputLines", toString(inl)); - results += PvlKeyword("InputSamples", toString(ins)); - results += PvlKeyword("LeftPad", toString(leftPad)); - results += PvlKeyword("RightPad", toString(rightPad)); - results += PvlKeyword("TopPad", toString(topPad)); - results += PvlKeyword("BottomPad", toString(bottomPad)); - results += PvlKeyword("OutputLines", toString(nl)); - results += PvlKeyword("OutputSamples", toString(ns)); + results += PvlKeyword("InputLines", Isis::toString(inl)); + results += PvlKeyword("InputSamples", Isis::toString(ins)); + results += PvlKeyword("LeftPad", Isis::toString(leftPad)); + results += PvlKeyword("RightPad", Isis::toString(rightPad)); + results += PvlKeyword("TopPad", Isis::toString(topPad)); + results += PvlKeyword("BottomPad", Isis::toString(bottomPad)); + results += PvlKeyword("OutputLines", Isis::toString(nl)); + results += PvlKeyword("OutputSamples", Isis::toString(ns)); // Update the Mapping, Instrument, and AlphaCube groups in the // output cube label diff --git a/isis/src/base/apps/percent/main.cpp b/isis/src/base/apps/percent/main.cpp index 8c907ea958..c77ee98835 100644 --- a/isis/src/base/apps/percent/main.cpp +++ b/isis/src/base/apps/percent/main.cpp @@ -34,8 +34,8 @@ void IsisMain() { // Obtain the Histogram and the value at the percentage Histogram *hist = icube->histogram(); double value = hist->Percent(percentage); - kwPercent += toString(percentage); - kwValue += toString(value); + kwPercent += Isis::toString(percentage); + kwValue += Isis::toString(value); } results += kwPercent; results += kwValue; diff --git a/isis/src/base/apps/phoempglobal/main.cpp b/isis/src/base/apps/phoempglobal/main.cpp index 407347f82c..9c982d4a2e 100644 --- a/isis/src/base/apps/phoempglobal/main.cpp +++ b/isis/src/base/apps/phoempglobal/main.cpp @@ -247,16 +247,16 @@ void IsisMain() { if (!iord) { // Fit with no additive offset: output multiplier normalized to // zero phase, which is the desired phase curve B, and unnormalized - phaseAngle.addValue(toString(lFitParams.phase)); - limbValue.addValue(toString(rmsmin)); - phaseCurve.addValue(toString(c1/c1_0)); + phaseAngle.addValue(Isis::toString(lFitParams.phase)); + limbValue.addValue(Isis::toString(rmsmin)); + phaseCurve.addValue(Isis::toString(c1/c1_0)); } else { // Fit with additive offset: normalizing would make no sense, just // output additive offset and multiplier from fit - phaseAngle.addValue(toString(lFitParams.phase)); - limbValue.addValue(toString(rmsmin)); - phaseCurve.addValue(toString(c1)); + phaseAngle.addValue(Isis::toString(lFitParams.phase)); + limbValue.addValue(Isis::toString(rmsmin)); + phaseCurve.addValue(Isis::toString(c1)); } } diff --git a/isis/src/base/apps/phoemplocal/main.cpp b/isis/src/base/apps/phoemplocal/main.cpp index aef6c22608..8e97450554 100644 --- a/isis/src/base/apps/phoemplocal/main.cpp +++ b/isis/src/base/apps/phoemplocal/main.cpp @@ -293,10 +293,10 @@ void IsisMain() { os << "BEST_FIT_MULTIPLIER = " << lFitParams.c1 << endl; os << "RMS_ERROR_OF_FIT = " << parmin << endl; PvlGroup fitParams("Results"); - fitParams += PvlKeyword("PhaseAngle", toString(datum.m_phase), "degrees"); - fitParams += PvlKeyword("LimbDarkeningParameter", toString(xb)); - fitParams += PvlKeyword("BestFitMultiplier", toString(lFitParams.c1)); - fitParams += PvlKeyword("RMSErrorOfFit", toString(parmin)); + fitParams += PvlKeyword("PhaseAngle", Isis::toString(datum.m_phase), "degrees"); + fitParams += PvlKeyword("LimbDarkeningParameter", Isis::toString(xb)); + fitParams += PvlKeyword("BestFitMultiplier", Isis::toString(lFitParams.c1)); + fitParams += PvlKeyword("RMSErrorOfFit", Isis::toString(parmin)); Application::Log(fitParams); } else { @@ -305,11 +305,11 @@ void IsisMain() { os << "BEST_FIT_MULTIPLIER = " << lFitParams.c1 << endl; os << "RMS_ERROR_OF_FIT = " << parmin << endl; PvlGroup fitParams("Results"); - fitParams += PvlKeyword("PhaseAngle", toString(datum.m_phase), "degrees"); - fitParams += PvlKeyword("LimbDarkeningParameter", toString(xb)); - fitParams += PvlKeyword("BestFitAdditiveTerm", toString(lFitParams.c0)); - fitParams += PvlKeyword("BestFitMultiplier", toString(lFitParams.c1)); - fitParams += PvlKeyword("RMSErrorOfFit", toString(parmin)); + fitParams += PvlKeyword("PhaseAngle", Isis::toString(datum.m_phase), "degrees"); + fitParams += PvlKeyword("LimbDarkeningParameter", Isis::toString(xb)); + fitParams += PvlKeyword("BestFitAdditiveTerm", Isis::toString(lFitParams.c0)); + fitParams += PvlKeyword("BestFitMultiplier", Isis::toString(lFitParams.c1)); + fitParams += PvlKeyword("RMSErrorOfFit", Isis::toString(parmin)); Application::Log(fitParams); } diff --git a/isis/src/base/apps/phohillier/Hillier.cpp b/isis/src/base/apps/phohillier/Hillier.cpp index 612af76dc3..6502f10d9c 100644 --- a/isis/src/base/apps/phohillier/Hillier.cpp +++ b/isis/src/base/apps/phohillier/Hillier.cpp @@ -107,7 +107,7 @@ namespace Isis { double Hillier::photometry(double i, double e, double g, int band) const { // Test for valid band if((band <= 0) || (band > (int) _bandpho.size())) { - std::string mess = "Provided band " + toString(band) + " out of range."; + std::string mess = "Provided band " + Isis::toString(band) + " out of range."; throw IException(IException::Programmer, mess, _FILEINFO_); } double ph = photometry(_bandpho[band-1], i, e, g); @@ -170,9 +170,9 @@ namespace Isis { */ void Hillier::Report(PvlContainer &pvl) { pvl += PvlKeyword("Algorithm", "Hillier"); - pvl += PvlKeyword("IncRef", toString(_iRef), "degrees"); - pvl += PvlKeyword("EmaRef", toString(_eRef), "degrees"); - pvl += PvlKeyword("PhaRef", toString(_gRef), "degrees"); + pvl += PvlKeyword("IncRef", Isis::toString(_iRef), "degrees"); + pvl += PvlKeyword("EmaRef", Isis::toString(_eRef), "degrees"); + pvl += PvlKeyword("PhaRef", Isis::toString(_gRef), "degrees"); PvlKeyword units("HillierUnits"); PvlKeyword phostd("PhotometricStandard"); PvlKeyword bbc("BandBinCenter"); @@ -188,17 +188,17 @@ namespace Isis { for(unsigned int i = 0 ; i < _bandpho.size() ; i++) { Parameters &p = _bandpho[i]; units.addValue(p.units.toStdString()); - phostd.addValue(toString(p.phoStd)); - bbc.addValue(toString(p.wavelength)); - bbct.addValue(toString(p.tolerance)); - bbn.addValue(toString(p.band)); - b0.addValue(toString(p.b0)); - b1.addValue(toString(p.b1)); - a0.addValue(toString(p.a0)); - a1.addValue(toString(p.a1)); - a2.addValue(toString(p.a2)); - a3.addValue(toString(p.a3)); - a4.addValue(toString(p.a4)); + phostd.addValue(Isis::toString(p.phoStd)); + bbc.addValue(Isis::toString(p.wavelength)); + bbct.addValue(Isis::toString(p.tolerance)); + bbn.addValue(Isis::toString(p.band)); + b0.addValue(Isis::toString(p.b0)); + b1.addValue(Isis::toString(p.b1)); + a0.addValue(Isis::toString(p.a0)); + a1.addValue(Isis::toString(p.a1)); + a2.addValue(Isis::toString(p.a2)); + a3.addValue(Isis::toString(p.a3)); + a4.addValue(Isis::toString(p.a4)); } pvl += units; pvl += phostd; @@ -335,7 +335,7 @@ namespace Isis { PvlKeyword center = label->findGroup("BandBin", Pvl::Traverse)["Center"]; std::string errs(""); for(int i = 0; i < cube.bandCount() ; i++) { - Parameters parms = findParameters(IString::ToDouble(center[i])); + Parameters parms = findParameters(Isis::toDouble(center[i])); if(parms.IsValid()) { parms.band = i + 1; _camera->SetBand(i + 1); diff --git a/isis/src/base/apps/phohillier/Hillier.h b/isis/src/base/apps/phohillier/Hillier.h index fba9deca3a..354d884387 100644 --- a/isis/src/base/apps/phohillier/Hillier.h +++ b/isis/src/base/apps/phohillier/Hillier.h @@ -146,13 +146,13 @@ namespace Isis { return qValue; } else if constexpr (std::is_same_v) { try { - return IString::ToInteger(iValue); + return Isis::toInt(iValue); } catch (...) { return defval; } } else if constexpr (std::is_same_v) { try { - return IString::ToDouble(iValue); + return Isis::toDouble(iValue); } catch (...) { return defval; } diff --git a/isis/src/base/apps/photemplate/main.cpp b/isis/src/base/apps/photemplate/main.cpp index e832ab97ef..41c15f83a0 100644 --- a/isis/src/base/apps/photemplate/main.cpp +++ b/isis/src/base/apps/photemplate/main.cpp @@ -56,11 +56,11 @@ void OutputKeyValue(PvlKeyword & key, QString val){ key.clear(); int found = val.indexOf(","); while(found != -1) { - key += toString((val.mid(0, found)).toDouble()); + key += Isis::toString((val.mid(0, found)).toDouble()); val = val.mid(found+1); found = val.indexOf(","); } - key += toString((val).toDouble()); + key += Isis::toString((val).toDouble()); } // Helper function to load the input pvl file into the GUI diff --git a/isis/src/base/apps/photomet/main.cpp b/isis/src/base/apps/photomet/main.cpp index b6b65443f2..bd6bd399c2 100644 --- a/isis/src/base/apps/photomet/main.cpp +++ b/isis/src/base/apps/photomet/main.cpp @@ -1836,7 +1836,7 @@ void IsisMain() { double wl; if(pvlg.hasKeyword("Center")) { PvlKeyword &wavelength = pvlg.findKeyword("Center"); - wl = IString::ToDouble(wavelength[0]); + wl = Isis::toDouble(wavelength[0]); } else { wl = 1.0; diff --git a/isis/src/base/apps/pixel2map/main.cpp b/isis/src/base/apps/pixel2map/main.cpp index 21b1ade416..abaa8822ea 100755 --- a/isis/src/base/apps/pixel2map/main.cpp +++ b/isis/src/base/apps/pixel2map/main.cpp @@ -136,10 +136,10 @@ void IsisMain() { g_incam = NULL; } //end for list.size - camGrp.addKeyword(PvlKeyword("MinimumLatitude", toString(minlat)), Pvl::Replace); - camGrp.addKeyword(PvlKeyword("MaximumLatitude", toString(maxlat)), Pvl::Replace); - camGrp.addKeyword(PvlKeyword("MinimumLongitude", toString(minlon)), Pvl::Replace); - camGrp.addKeyword(PvlKeyword("MaximumLongitude", toString(maxlon)), Pvl::Replace); + camGrp.addKeyword(PvlKeyword("MinimumLatitude", Isis::toString(minlat)), Pvl::Replace); + camGrp.addKeyword(PvlKeyword("MaximumLatitude", Isis::toString(maxlat)), Pvl::Replace); + camGrp.addKeyword(PvlKeyword("MinimumLongitude", Isis::toString(minlon)), Pvl::Replace); + camGrp.addKeyword(PvlKeyword("MaximumLongitude", Isis::toString(maxlon)), Pvl::Replace); // We want to delete the keywords we just added if the user wants the range @@ -172,22 +172,22 @@ void IsisMain() { // If the user decided to enter a ground range then override if (ui.WasEntered("MINLON")) { userGrp.addKeyword(PvlKeyword("MinimumLongitude", - toString(ui.GetDouble("MINLON"))), Pvl::Replace); + Isis::toString(ui.GetDouble("MINLON"))), Pvl::Replace); } if (ui.WasEntered("MAXLON")) { userGrp.addKeyword(PvlKeyword("MaximumLongitude", - toString(ui.GetDouble("MAXLON"))), Pvl::Replace); + Isis::toString(ui.GetDouble("MAXLON"))), Pvl::Replace); } if (ui.WasEntered("MINLAT")) { userGrp.addKeyword(PvlKeyword("MinimumLatitude", - toString(ui.GetDouble("MINLAT"))), Pvl::Replace); + Isis::toString(ui.GetDouble("MINLAT"))), Pvl::Replace); } if (ui.WasEntered("MAXLAT")) { userGrp.addKeyword(PvlKeyword("MaximumLatitude", - toString(ui.GetDouble("MAXLAT"))), Pvl::Replace); + Isis::toString(ui.GetDouble("MAXLAT"))), Pvl::Replace); } // If they want the res. from the mapfile, delete it from the camera so @@ -216,7 +216,7 @@ void IsisMain() { // If the user decided to enter a resolution then override if (ui.GetString("PIXRES") == "MPP") { userGrp.addKeyword(PvlKeyword("PixelResolution", - toString(ui.GetDouble("RESOLUTION"))), + Isis::toString(ui.GetDouble("RESOLUTION"))), Pvl::Replace); if (userGrp.hasKeyword("Scale")) { userGrp.deleteKeyword("Scale"); @@ -224,7 +224,7 @@ void IsisMain() { } else if (ui.GetString("PIXRES") == "PPD") { userGrp.addKeyword(PvlKeyword("Scale", - toString(ui.GetDouble("RESOLUTION"))), + Isis::toString(ui.GetDouble("RESOLUTION"))), Pvl::Replace); if (userGrp.hasKeyword("PixelResolution")) { userGrp.deleteKeyword("PixelResolution"); @@ -247,22 +247,22 @@ void IsisMain() { if (g_incam->IntersectsLongitudeDomain(userMap)) { if (ui.GetString("LONSEAM") == "AUTO") { if ((int) userGrp["LongitudeDomain"] == 360) { - userGrp.addKeyword(PvlKeyword("LongitudeDomain", toString(180)), + userGrp.addKeyword(PvlKeyword("LongitudeDomain", Isis::toString(180)), Pvl::Replace); if (g_incam->IntersectsLongitudeDomain(userMap)) { // Its looks like a global image so switch back to the // users preference - userGrp.addKeyword(PvlKeyword("LongitudeDomain", toString(360)), + userGrp.addKeyword(PvlKeyword("LongitudeDomain", Isis::toString(360)), Pvl::Replace); } } else { - userGrp.addKeyword(PvlKeyword("LongitudeDomain", toString(360)), + userGrp.addKeyword(PvlKeyword("LongitudeDomain", Isis::toString(360)), Pvl::Replace); if (g_incam->IntersectsLongitudeDomain(userMap)) { // Its looks like a global image so switch back to the // users preference - userGrp.addKeyword(PvlKeyword("LongitudeDomain", toString(180)), + userGrp.addKeyword(PvlKeyword("LongitudeDomain", Isis::toString(180)), Pvl::Replace); } } @@ -270,16 +270,16 @@ void IsisMain() { double minlat, maxlat, minlon, maxlon; g_incam->GroundRange(minlat, maxlat, minlon, maxlon, userMap); if (!ui.WasEntered("MINLAT")) { - userGrp.addKeyword(PvlKeyword("MinimumLatitude", toString(minlat)), Pvl::Replace); + userGrp.addKeyword(PvlKeyword("MinimumLatitude", Isis::toString(minlat)), Pvl::Replace); } if (!ui.WasEntered("MAXLAT")) { - userGrp.addKeyword(PvlKeyword("MaximumLatitude", toString(maxlat)), Pvl::Replace); + userGrp.addKeyword(PvlKeyword("MaximumLatitude", Isis::toString(maxlat)), Pvl::Replace); } if (!ui.WasEntered("MINLON")) { - userGrp.addKeyword(PvlKeyword("MinimumLongitude", toString(minlon)), Pvl::Replace); + userGrp.addKeyword(PvlKeyword("MinimumLongitude", Isis::toString(minlon)), Pvl::Replace); } if (!ui.WasEntered("MAXLON")) { - userGrp.addKeyword(PvlKeyword("MaximumLongitude", toString(maxlon)), Pvl::Replace); + userGrp.addKeyword(PvlKeyword("MaximumLongitude", Isis::toString(maxlon)), Pvl::Replace); } } @@ -303,14 +303,14 @@ void IsisMain() { Cube parent(list[0].toString()); if (!parent.hasGroup("AlphaCube")) { PvlGroup alpha("AlphaCube"); - alpha += PvlKeyword("AlphaSamples", toString(parent.sampleCount())); - alpha += PvlKeyword("AlphaLines", toString(parent.lineCount())); - alpha += PvlKeyword("AlphaStartingSample", toString(0.5)); - alpha += PvlKeyword("AlphaStartingLine", toString(0.5)); - alpha += PvlKeyword("AlphaEndingSample", toString(parent.sampleCount() + 0.5)); - alpha += PvlKeyword("AlphaEndingLine", toString(parent.lineCount() + 0.5)); - alpha += PvlKeyword("BetaSamples", toString(parent.sampleCount())); - alpha += PvlKeyword("BetaLines", toString(parent.lineCount())); + alpha += PvlKeyword("AlphaSamples", Isis::toString(parent.sampleCount())); + alpha += PvlKeyword("AlphaLines", Isis::toString(parent.lineCount())); + alpha += PvlKeyword("AlphaStartingSample", Isis::toString(0.5)); + alpha += PvlKeyword("AlphaStartingLine", Isis::toString(0.5)); + alpha += PvlKeyword("AlphaEndingSample", Isis::toString(parent.sampleCount() + 0.5)); + alpha += PvlKeyword("AlphaEndingLine", Isis::toString(parent.lineCount() + 0.5)); + alpha += PvlKeyword("BetaSamples", Isis::toString(parent.sampleCount())); + alpha += PvlKeyword("BetaLines", Isis::toString(parent.lineCount())); pvl.addGroup(alpha); } } diff --git a/isis/src/base/apps/pvldiff/main.cpp b/isis/src/base/apps/pvldiff/main.cpp index ce48ae15ab..87fb3b3eff 100644 --- a/isis/src/base/apps/pvldiff/main.cpp +++ b/isis/src/base/apps/pvldiff/main.cpp @@ -153,7 +153,7 @@ void compareKeywords(PvlKeyword &pvl1, PvlKeyword &pvl2) { double difference = abs(val1.toDouble() - val2.toDouble()); if ( tolerances.hasKeyword(pvl1.name()) ) { - tolerance = IString::ToDouble( + tolerance = Isis::toDouble( (tolerances[pvl1.name()].size() == 1) ? tolerances[pvl1.name()][0] : tolerances[pvl1.name()][i]); } diff --git a/isis/src/base/apps/remrx/main.cpp b/isis/src/base/apps/remrx/main.cpp index 366adc9594..6bcc8454de 100644 --- a/isis/src/base/apps/remrx/main.cpp +++ b/isis/src/base/apps/remrx/main.cpp @@ -73,9 +73,9 @@ void IsisMain() { Brick brick(sdim, ldim, 1, cube.pixelType()); for(int res = 0; res < numres; res++) { - if((resvalid == 0 || IString::ToInteger(valid[res]) == 1) && IString::ToInteger(type[res]) != 0) { - int baseSamp = (int)(IString::ToDouble(samps[res]) + 0.5) - (sdim / 2); - int baseLine = (int)(IString::ToDouble(lines[res]) + 0.5) - (ldim / 2); + if((resvalid == 0 || Isis::toInt(valid[res]) == 1) && Isis::toInt(type[res]) != 0) { + int baseSamp = (int)(Isis::toDouble(samps[res]) + 0.5) - (sdim / 2); + int baseLine = (int)(Isis::toDouble(lines[res]) + 0.5) - (ldim / 2); brick.SetBasePosition(baseSamp, baseLine, 1); cube.read(brick); if(action == "NULL") { @@ -99,7 +99,7 @@ void IsisMain() { double sdev = stats.StandardDeviation(); // Top Edge Reseau - if(IString::ToInteger(type[res]) == 2) { + if(Isis::toInt(type[res]) == 2) { int l1 = 0; int l2 = ldim - 1; for(int s = 0; s < sdim; s++) { @@ -107,7 +107,7 @@ void IsisMain() { } } // Left Edge Reseau - else if(IString::ToInteger(type[res]) == 4) { + else if(Isis::toInt(type[res]) == 4) { int s1 = 0; int s2 = sdim - 1; for(int l = 0; l < ldim; l++) { @@ -115,7 +115,7 @@ void IsisMain() { } } // Right Edge Reseau - else if(IString::ToInteger(type[res]) == 6) { + else if(Isis::toInt(type[res]) == 6) { int s1 = 0; int s2 = sdim - 1; for(int l = 0; l < ldim; l++) { @@ -123,7 +123,7 @@ void IsisMain() { } } // Bottom Edge Reseau - else if(IString::ToInteger(type[res]) == 8) { + else if(Isis::toInt(type[res]) == 8) { int l1 = 0; int l2 = ldim - 1; for(int s = 0; s < sdim; s++) { @@ -159,14 +159,14 @@ void IsisMain() { for(int l = 0; l < ldim; l++) { int c = l * sdim; //count // Top Edge Reseau - if(IString::ToInteger(type[res]) == 2 && l < (ldim / 2)) continue; + if(Isis::toInt(type[res]) == 2 && l < (ldim / 2)) continue; // Bottom Edge Reseau - if(IString::ToInteger(type[res]) == 8 && l > (ldim / 2 + 1)) continue; + if(Isis::toInt(type[res]) == 8 && l > (ldim / 2 + 1)) continue; for(int s = 0; s < sdim; s++, c++) { // Left Edge Reseau - if(IString::ToInteger(type[res]) == 4 && s < (sdim / 2)) continue; + if(Isis::toInt(type[res]) == 4 && s < (sdim / 2)) continue; // Right Edge Reseau - if(IString::ToInteger(type[res]) == 6 && s > (sdim / 2 + 1)) continue; + if(Isis::toInt(type[res]) == 6 && s > (sdim / 2 + 1)) continue; double sum = 0.0; int gline1 = 0; int gline2 = ldim - 1; diff --git a/isis/src/base/apps/ringscam2map/main.cpp b/isis/src/base/apps/ringscam2map/main.cpp index eb1637ef4c..31c6160753 100644 --- a/isis/src/base/apps/ringscam2map/main.cpp +++ b/isis/src/base/apps/ringscam2map/main.cpp @@ -67,10 +67,10 @@ void IsisMain() { // Make the target info match the user mapfile double minrad, maxrad, minaz, maxaz; incam->ringRange(minrad, maxrad, minaz, maxaz, userMap); - camGrp.addKeyword(PvlKeyword("MinimumRingRadius", toString(minrad)), Pvl::Replace); - camGrp.addKeyword(PvlKeyword("MaximumRingRadius", toString(maxrad)), Pvl::Replace); - camGrp.addKeyword(PvlKeyword("MinimumRingLongitude", toString(minaz)), Pvl::Replace); - camGrp.addKeyword(PvlKeyword("MaximumRingLongitude", toString(maxaz)), Pvl::Replace); + camGrp.addKeyword(PvlKeyword("MinimumRingRadius", Isis::toString(minrad)), Pvl::Replace); + camGrp.addKeyword(PvlKeyword("MaximumRingRadius", Isis::toString(maxrad)), Pvl::Replace); + camGrp.addKeyword(PvlKeyword("MinimumRingLongitude", Isis::toString(minaz)), Pvl::Replace); + camGrp.addKeyword(PvlKeyword("MaximumRingLongitude", Isis::toString(maxaz)), Pvl::Replace); // We want to delete the keywords we just added if the user wants the range // out of the mapfile, otherwise they will replace any keywords not in the @@ -101,22 +101,22 @@ void IsisMain() { // If the user decided to enter a ground range then override if(ui.WasEntered("MINRINGLON")) { userGrp.addKeyword(PvlKeyword("MinimumRingLongitude", - toString(ui.GetDouble("MINRINGLON"))), Pvl::Replace); + Isis::toString(ui.GetDouble("MINRINGLON"))), Pvl::Replace); } if(ui.WasEntered("MAXRINGLON")) { userGrp.addKeyword(PvlKeyword("MaximumRingLongitude", - toString(ui.GetDouble("MAXRINGLON"))), Pvl::Replace); + Isis::toString(ui.GetDouble("MAXRINGLON"))), Pvl::Replace); } if(ui.WasEntered("MINRINGRAD")) { userGrp.addKeyword(PvlKeyword("MinimumRingRadius", - toString(ui.GetDouble("MINRINGRAD"))), Pvl::Replace); + Isis::toString(ui.GetDouble("MINRINGRAD"))), Pvl::Replace); } if(ui.WasEntered("MAXRINGRAD")) { userGrp.addKeyword(PvlKeyword("MaximumRingRadius", - toString(ui.GetDouble("MAXRINGRAD"))), Pvl::Replace); + Isis::toString(ui.GetDouble("MAXRINGRAD"))), Pvl::Replace); } // If they want the res. from the mapfile, delete it from the camera so @@ -146,7 +146,7 @@ void IsisMain() { if (!ui.GetBoolean("MATCHMAP")) { if(ui.GetString("PIXRES") == "MPP") { userGrp.addKeyword(PvlKeyword("PixelResolution", - toString(ui.GetDouble("RESOLUTION"))), + Isis::toString(ui.GetDouble("RESOLUTION"))), Pvl::Replace); if(userGrp.hasKeyword("Scale")) { userGrp.deleteKeyword("Scale"); @@ -154,7 +154,7 @@ void IsisMain() { } else if(ui.GetString("PIXRES") == "PPD") { userGrp.addKeyword(PvlKeyword("Scale", - toString(ui.GetDouble("RESOLUTION"))), + Isis::toString(ui.GetDouble("RESOLUTION"))), Pvl::Replace); if(userGrp.hasKeyword("PixelResolution")) { userGrp.deleteKeyword("PixelResolution"); @@ -196,16 +196,16 @@ void IsisMain() { double minrad, maxrad, minaz, maxaz; incam->ringRange(minrad, maxrad, minaz, maxaz, userMap); if(!ui.WasEntered("MINRINGRAD")) { - userGrp.addKeyword(PvlKeyword("MinimumRingRadius", toString(minrad)), Pvl::Replace); + userGrp.addKeyword(PvlKeyword("MinimumRingRadius", Isis::toString(minrad)), Pvl::Replace); } if(!ui.WasEntered("MAXRINGRAD")) { - userGrp.addKeyword(PvlKeyword("MaximumRingRadius", toString(maxrad)), Pvl::Replace); + userGrp.addKeyword(PvlKeyword("MaximumRingRadius", Isis::toString(maxrad)), Pvl::Replace); } if(!ui.WasEntered("MINRINGLON")) { - userGrp.addKeyword(PvlKeyword("MinimumRingLongitude", toString(minaz)), Pvl::Replace); + userGrp.addKeyword(PvlKeyword("MinimumRingLongitude", Isis::toString(minaz)), Pvl::Replace); } if(!ui.WasEntered("MAXRINGLON")) { - userGrp.addKeyword(PvlKeyword("MaximumRingLongitude", toString(maxaz)), Pvl::Replace); + userGrp.addKeyword(PvlKeyword("MaximumRingLongitude", Isis::toString(maxaz)), Pvl::Replace); } } else if(ui.GetString("RINGLONSEAM") == "ERROR") { @@ -281,14 +281,14 @@ void IsisMain() { // Create an alpha cube group for the output cube if(!ocube->hasGroup("AlphaCube")) { PvlGroup alpha("AlphaCube"); - alpha += PvlKeyword("AlphaSamples", toString(icube->sampleCount())); - alpha += PvlKeyword("AlphaLines", toString(icube->lineCount())); - alpha += PvlKeyword("AlphaStartingSample", toString(0.5)); - alpha += PvlKeyword("AlphaStartingLine", toString(0.5)); - alpha += PvlKeyword("AlphaEndingSample", toString(icube->sampleCount() + 0.5)); - alpha += PvlKeyword("AlphaEndingLine", toString(icube->lineCount() + 0.5)); - alpha += PvlKeyword("BetaSamples", toString(icube->sampleCount())); - alpha += PvlKeyword("BetaLines", toString(icube->lineCount())); + alpha += PvlKeyword("AlphaSamples", Isis::toString(icube->sampleCount())); + alpha += PvlKeyword("AlphaLines", Isis::toString(icube->lineCount())); + alpha += PvlKeyword("AlphaStartingSample", Isis::toString(0.5)); + alpha += PvlKeyword("AlphaStartingLine", Isis::toString(0.5)); + alpha += PvlKeyword("AlphaEndingSample", Isis::toString(icube->sampleCount() + 0.5)); + alpha += PvlKeyword("AlphaEndingLine", Isis::toString(icube->lineCount() + 0.5)); + alpha += PvlKeyword("BetaSamples", Isis::toString(icube->sampleCount())); + alpha += PvlKeyword("BetaLines", Isis::toString(icube->lineCount())); ocube->putGroup(alpha); } diff --git a/isis/src/base/apps/ringsmappt/main.cpp b/isis/src/base/apps/ringsmappt/main.cpp index cfe5f9de77..e6d9dae22d 100644 --- a/isis/src/base/apps/ringsmappt/main.cpp +++ b/isis/src/base/apps/ringsmappt/main.cpp @@ -131,30 +131,30 @@ void IsisMain() { PvlGroup results("Results"); results += PvlKeyword("Filename", FileName(ui.GetCubeName("FROM").toStdString()).expanded()); - results += PvlKeyword("Sample", toString(proj->WorldX())); - results += PvlKeyword("Line", toString(proj->WorldY())); + results += PvlKeyword("Sample", Isis::toString(proj->WorldX())); + results += PvlKeyword("Line", Isis::toString(proj->WorldY())); results += PvlKeyword("PixelValue", PixelToString(b[0])); - results += PvlKeyword("X", toString(proj->XCoord())); - results += PvlKeyword("Y", toString(proj->YCoord())); + results += PvlKeyword("X", Isis::toString(proj->XCoord())); + results += PvlKeyword("Y", Isis::toString(proj->YCoord())); // Put together all the keywords for different coordinate systems. PvlKeyword ringRad = - PvlKeyword("RingRadius", toString(proj->UniversalRingRadius())); + PvlKeyword("RingRadius", Isis::toString(proj->UniversalRingRadius())); PvlKeyword cC360 = - PvlKeyword("CounterClockwise360RingLongitude", toString(proj->UniversalRingLongitude())); + PvlKeyword("CounterClockwise360RingLongitude", Isis::toString(proj->UniversalRingLongitude())); PvlKeyword c360 = PvlKeyword("Clockwise360RingLongitude", - toString(proj->ToClockwise(proj->UniversalRingLongitude(), 360))); + Isis::toString(proj->ToClockwise(proj->UniversalRingLongitude(), 360))); PvlKeyword cC180 = PvlKeyword("CounterClockwise180RingLongitude", - toString(proj->To180Domain(proj->UniversalRingLongitude()))); + Isis::toString(proj->To180Domain(proj->UniversalRingLongitude()))); PvlKeyword c180 = PvlKeyword("Clockwise180RingLongitude", - toString(proj->To180Domain(proj->ToCounterClockwise( + Isis::toString(proj->To180Domain(proj->ToCounterClockwise( proj->UniversalRingLongitude(), 360)))); // Input map coordinate system location diff --git a/isis/src/base/apps/ringspt/CameraRingsPointInfo.cpp b/isis/src/base/apps/ringspt/CameraRingsPointInfo.cpp index f75925e02c..b504dad859 100644 --- a/isis/src/base/apps/ringspt/CameraRingsPointInfo.cpp +++ b/isis/src/base/apps/ringspt/CameraRingsPointInfo.cpp @@ -150,9 +150,9 @@ namespace Isis { // Set all keywords that still have valid information gp->findKeyword("Error").setValue(error); gp->findKeyword("FileName").setValue(cube()->fileName().toStdString()); - gp->findKeyword("Sample").setValue(toString(camera()->Sample())); - gp->findKeyword("Line").setValue(toString(camera()->Line())); - gp->findKeyword("EphemerisTime").setValue(toString(camera()->time().Et()), "seconds"); + gp->findKeyword("Sample").setValue(Isis::toString(camera()->Sample())); + gp->findKeyword("Line").setValue(Isis::toString(camera()->Line())); + gp->findKeyword("EphemerisTime").setValue(Isis::toString(camera()->time().Et()), "seconds"); gp->findKeyword("EphemerisTime").addComment("Time"); QString utc = camera()->time().UTC(); gp->findKeyword("UTC").setValue(utc.toStdString()); @@ -177,12 +177,12 @@ namespace Isis { { gp->findKeyword("FileName").setValue(cube()->fileName().toStdString()); - gp->findKeyword("Sample").setValue(toString(camera()->Sample())); - gp->findKeyword("Line").setValue(toString(camera()->Line())); + gp->findKeyword("Sample").setValue(Isis::toString(camera()->Sample())); + gp->findKeyword("Line").setValue(Isis::toString(camera()->Line())); gp->findKeyword("PixelValue").setValue(PixelToString(b[0])); - gp->findKeyword("RightAscension").setValue(toString(camera()->RightAscension())); - gp->findKeyword("Declination").setValue(toString(camera()->Declination())); - // gp->findKeyword("PlanetocentricLatitude").setValue(toString( + gp->findKeyword("RightAscension").setValue(Isis::toString(camera()->RightAscension())); + gp->findKeyword("Declination").setValue(Isis::toString(camera()->Declination())); + // gp->findKeyword("PlanetocentricLatitude").setValue(Isis::toString( // camera()->UniversalLatitude())); // Convert lat to planetographic @@ -190,114 +190,114 @@ namespace Isis { // camera()->radii(radii); // oglat = Isis::TProjection::ToPlanetographic(camera()->UniversalLatitude(), // radii[0].kilometers(), radii[2].kilometers()); - // gp->findKeyword("PlanetographicLatitude").setValue(toString(oglat)); + // gp->findKeyword("PlanetographicLatitude").setValue(Isis::toString(oglat)); - gp->findKeyword("CounterClockwise360RingLongitude").setValue(toString( + gp->findKeyword("CounterClockwise360RingLongitude").setValue(Isis::toString( camera()->UniversalLongitude())); - // gp->findKeyword("PositiveEast360Longitude").setValue(toString( + // gp->findKeyword("PositiveEast360Longitude").setValue(Isis::toString( // camera()->UniversalLongitude())); //Convert lon to -180 - 180 range - gp->findKeyword("CounterClockwise180RingLongitude").setValue(toString( + gp->findKeyword("CounterClockwise180RingLongitude").setValue(Isis::toString( RingPlaneProjection::To180Domain( camera()->UniversalLongitude()))); - // gp->findKeyword("PositiveEast180Longitude").setValue(toString( + // gp->findKeyword("PositiveEast180Longitude").setValue(Isis::toString( // Isis::TProjection::To180Domain( // camera()->UniversalLongitude()))); //Convert ring longitude (az) to clockwise cwaz = Isis::RingPlaneProjection::ToClockwise(camera()->UniversalLongitude(), 360); - gp->findKeyword("Clockwise360RingLongitude").setValue(toString(cwaz)); + gp->findKeyword("Clockwise360RingLongitude").setValue(Isis::toString(cwaz)); //Convert lon to positive west // pwlon = Isis::TProjection::ToPositiveWest(camera()->UniversalLongitude(), // 360); - // gp->findKeyword("PositiveWest360Longitude").setValue(toString(pwlon)); + // gp->findKeyword("PositiveWest360Longitude").setValue(Isis::toString(pwlon)); //Convert cwaz to -180 - 180 range - gp->findKeyword("Clockwise180RingLongitude").setValue(toString( + gp->findKeyword("Clockwise180RingLongitude").setValue(Isis::toString( Isis::RingPlaneProjection::To180Domain(cwaz))); //Convert pwlon to -180 - 180 range - // gp->findKeyword("PositiveWest180Longitude").setValue(toString( + // gp->findKeyword("PositiveWest180Longitude").setValue(Isis::toString( // Isis::TProjection::To180Domain(pwlon))); camera()->Coordinate(pB); - gp->findKeyword("BodyFixedCoordinate").addValue(toString(pB[0]), "km"); - gp->findKeyword("BodyFixedCoordinate").addValue(toString(pB[1]), "km"); - gp->findKeyword("BodyFixedCoordinate").addValue(toString(pB[2]), "km"); + gp->findKeyword("BodyFixedCoordinate").addValue(Isis::toString(pB[0]), "km"); + gp->findKeyword("BodyFixedCoordinate").addValue(Isis::toString(pB[1]), "km"); + gp->findKeyword("BodyFixedCoordinate").addValue(Isis::toString(pB[2]), "km"); - gp->findKeyword("LocalRingRadius").setValue(toString( + gp->findKeyword("LocalRingRadius").setValue(Isis::toString( camera()->LocalRadius().meters()), "meters"); - gp->findKeyword("SampleResolution").setValue(toString( + gp->findKeyword("SampleResolution").setValue(Isis::toString( camera()->SampleResolution()), "meters/pixel"); - gp->findKeyword("LineResolution").setValue(toString( + gp->findKeyword("LineResolution").setValue(Isis::toString( camera()->LineResolution()), "meters/pixel"); //body fixed camera()->instrumentPosition(spB); - gp->findKeyword("SpacecraftPosition").addValue(toString(spB[0]), "km"); - gp->findKeyword("SpacecraftPosition").addValue(toString(spB[1]), "km"); - gp->findKeyword("SpacecraftPosition").addValue(toString(spB[2]), "km"); + gp->findKeyword("SpacecraftPosition").addValue(Isis::toString(spB[0]), "km"); + gp->findKeyword("SpacecraftPosition").addValue(Isis::toString(spB[1]), "km"); + gp->findKeyword("SpacecraftPosition").addValue(Isis::toString(spB[2]), "km"); gp->findKeyword("SpacecraftPosition").addComment("Spacecraft Information"); // if IsValid if (Isis::IsValidPixel(camera()->SpacecraftAzimuth())) { double spacecraftAzi = camera()->SpacecraftAzimuth(); - gp->findKeyword("SpacecraftAzimuth").setValue(toString(spacecraftAzi)); + gp->findKeyword("SpacecraftAzimuth").setValue(Isis::toString(spacecraftAzi)); } else { gp->findKeyword("SpacecraftAzimuth").setValue("NULL"); } - gp->findKeyword("SlantDistance").setValue(toString(camera()->SlantDistance()), "km"); - gp->findKeyword("TargetCenterDistance").setValue(toString( + gp->findKeyword("SlantDistance").setValue(Isis::toString(camera()->SlantDistance()), "km"); + gp->findKeyword("TargetCenterDistance").setValue(Isis::toString( camera()->targetCenterDistance()), "km"); camera()->subSpacecraftPoint(ssplat, ssplon); - gp->findKeyword("SubSpacecraftLatitude").setValue(toString(ssplat)); - gp->findKeyword("SubSpacecraftLongitude").setValue(toString(ssplon)); - gp->findKeyword("SpacecraftAltitude").setValue(toString( + gp->findKeyword("SubSpacecraftLatitude").setValue(Isis::toString(ssplat)); + gp->findKeyword("SubSpacecraftLongitude").setValue(Isis::toString(ssplon)); + gp->findKeyword("SpacecraftAltitude").setValue(Isis::toString( camera()->SpacecraftAltitude()), "km"); - gp->findKeyword("OffNadirAngle").setValue(toString(camera()->OffNadirAngle())); + gp->findKeyword("OffNadirAngle").setValue(Isis::toString(camera()->OffNadirAngle())); double subspcgrdaz = camera()->GroundAzimuth(camera()->UniversalLatitude(), camera()->UniversalLongitude(), ssplat, ssplon); - gp->findKeyword("SubSpacecraftGroundAzimuth").setValue(toString(subspcgrdaz)); + gp->findKeyword("SubSpacecraftGroundAzimuth").setValue(Isis::toString(subspcgrdaz)); camera()->sunPosition(sB); - gp->findKeyword("SunPosition").addValue(toString(sB[0]), "km"); - gp->findKeyword("SunPosition").addValue(toString(sB[1]), "km"); - gp->findKeyword("SunPosition").addValue(toString(sB[2]), "km"); + gp->findKeyword("SunPosition").addValue(Isis::toString(sB[0]), "km"); + gp->findKeyword("SunPosition").addValue(Isis::toString(sB[1]), "km"); + gp->findKeyword("SunPosition").addValue(Isis::toString(sB[2]), "km"); gp->findKeyword("SunPosition").addComment("Sun Information"); if (Isis::IsValidPixel(camera()->SunAzimuth())) { double sunAzi = camera()->SunAzimuth(); - gp->findKeyword("SubSolarAzimuth").setValue(toString(sunAzi)); + gp->findKeyword("SubSolarAzimuth").setValue(Isis::toString(sunAzi)); } else { gp->findKeyword("SubSolarAzimuth").setValue("NULL"); } - gp->findKeyword("SolarDistance").setValue(toString(camera()->SolarDistance()), "AU"); + gp->findKeyword("SolarDistance").setValue(Isis::toString(camera()->SolarDistance()), "AU"); camera()->subSolarPoint(sslat, sslon); - gp->findKeyword("SubSolarLatitude").setValue(toString(sslat)); - gp->findKeyword("SubSolarLongitude").setValue(toString(sslon)); + gp->findKeyword("SubSolarLatitude").setValue(Isis::toString(sslat)); + gp->findKeyword("SubSolarLongitude").setValue(Isis::toString(sslon)); double subsolgrdaz; subsolgrdaz = camera()->GroundAzimuth(camera()->UniversalLatitude(), camera()->UniversalLongitude(), sslat, sslon); - gp->findKeyword("SubSolarGroundAzimuth").setValue(toString(subsolgrdaz)); + gp->findKeyword("SubSolarGroundAzimuth").setValue(Isis::toString(subsolgrdaz)); - gp->findKeyword("Phase").setValue(toString(camera()->PhaseAngle())); + gp->findKeyword("Phase").setValue(Isis::toString(camera()->PhaseAngle())); gp->findKeyword("Phase").addComment("Illumination and Other"); - gp->findKeyword("Incidence").setValue(toString(camera()->IncidenceAngle())); - gp->findKeyword("Emission").setValue(toString(camera()->EmissionAngle())); + gp->findKeyword("Incidence").setValue(Isis::toString(camera()->IncidenceAngle())); + gp->findKeyword("Emission").setValue(Isis::toString(camera()->EmissionAngle())); - gp->findKeyword("EphemerisTime").setValue(toString(camera()->time().Et()), "seconds"); + gp->findKeyword("EphemerisTime").setValue(Isis::toString(camera()->time().Et()), "seconds"); gp->findKeyword("EphemerisTime").addComment("Time"); utc = camera()->time().UTC(); gp->findKeyword("UTC").setValue(utc.toStdString()); - gp->findKeyword("LocalSolarTime").setValue(toString(camera()->LocalSolarTime()), "hour"); - gp->findKeyword("SolarLongitude").setValue(toString(camera()->solarLongitude().degrees())); + gp->findKeyword("LocalSolarTime").setValue(Isis::toString(camera()->LocalSolarTime()), "hour"); + gp->findKeyword("SolarLongitude").setValue(Isis::toString(camera()->solarLongitude().degrees())); if (allowErrors) gp->findKeyword("Error").setValue("NULL"); } } diff --git a/isis/src/base/apps/shadow/ShadowFunctor.cpp b/isis/src/base/apps/shadow/ShadowFunctor.cpp index b3360dc354..97a5e62e40 100644 --- a/isis/src/base/apps/shadow/ShadowFunctor.cpp +++ b/isis/src/base/apps/shadow/ShadowFunctor.cpp @@ -134,49 +134,49 @@ namespace Isis { PvlGroup shadowStats("ShadowStatistics"); shadowStats += PvlKeyword("NumComputedAzimuthElevations", - toString(m_azimuthStats->ValidPixels())); + Isis::toString(m_azimuthStats->ValidPixels())); if (m_azimuthStats->ValidPixels() > 0) { PvlKeyword averageAzimuth("AverageAzimuth", - toString(m_azimuthStats->Average())); + Isis::toString(m_azimuthStats->Average())); averageAzimuth.addCommentWrapped("The azimuth is measured from three o'clock, going " "clockwise, in degrees"); shadowStats += averageAzimuth; - shadowStats += PvlKeyword("MinimumAzimuth", toString(m_azimuthStats->Minimum())); - shadowStats += PvlKeyword("MaximumAzimuth", toString(m_azimuthStats->Maximum())); + shadowStats += PvlKeyword("MinimumAzimuth", Isis::toString(m_azimuthStats->Minimum())); + shadowStats += PvlKeyword("MaximumAzimuth", Isis::toString(m_azimuthStats->Maximum())); - PvlKeyword averageElevation("AverageElevation", toString(m_elevationStats->Average())); + PvlKeyword averageElevation("AverageElevation", Isis::toString(m_elevationStats->Average())); averageElevation.addCommentWrapped("The elevation is measured from the normal, with directly " "overhead being 0 degrees and the horizon 90 degrees. Elevations are prevented from " "going below the horizon."); shadowStats += averageElevation; - shadowStats += PvlKeyword("MinimumElevation", toString(m_elevationStats->Minimum())); - shadowStats += PvlKeyword("MaximumElevation", toString(m_elevationStats->Maximum())); + shadowStats += PvlKeyword("MinimumElevation", Isis::toString(m_elevationStats->Minimum())); + shadowStats += PvlKeyword("MaximumElevation", Isis::toString(m_elevationStats->Maximum())); } - PvlKeyword numRays("NumRays", toString(m_rayLengthStats->ValidPixels())); + PvlKeyword numRays("NumRays", Isis::toString(m_rayLengthStats->ValidPixels())); numRays.addCommentWrapped("This is the total number of rays traced from the surface towards " "the sun in order to detect if any given pixel is in shadow"); shadowStats += numRays; shadowStats += PvlKeyword("NumRayDemIntersections", - toString(qRound(m_rayLengthStats->Sum()))); + Isis::toString(qRound(m_rayLengthStats->Sum()))); if (m_rayLengthStats->ValidPixels() > 0) { shadowStats += PvlKeyword("AverageRayDemIntersectionsPerRay", - toString(m_rayLengthStats->Average())); + Isis::toString(m_rayLengthStats->Average())); } shadowStats += PvlKeyword("NumLightedPixels", - toString(qRound((1.0 - m_shadowedStats->Average()) * m_shadowedStats->ValidPixels()))); + Isis::toString(qRound((1.0 - m_shadowedStats->Average()) * m_shadowedStats->ValidPixels()))); shadowStats += PvlKeyword("NumShadowedPixels", - toString(qRound(m_shadowedStats->Average() * m_shadowedStats->ValidPixels()))); + Isis::toString(qRound(m_shadowedStats->Average() * m_shadowedStats->ValidPixels()))); shadowStats += PvlKeyword("NumSpecialPixels", - toString(m_shadowedStats->TotalPixels() - m_shadowedStats->ValidPixels())); + Isis::toString(m_shadowedStats->TotalPixels() - m_shadowedStats->ValidPixels())); shadowStats += PvlKeyword("NumPixelsShadowedByRays", - toString(qRound(m_shadowedByRayStats->Sum()))); + Isis::toString(qRound(m_shadowedByRayStats->Sum()))); return shadowStats; } diff --git a/isis/src/base/apps/shadowtau/main.cpp b/isis/src/base/apps/shadowtau/main.cpp index 8b79635447..9b6cada969 100644 --- a/isis/src/base/apps/shadowtau/main.cpp +++ b/isis/src/base/apps/shadowtau/main.cpp @@ -94,25 +94,25 @@ void IsisMain() { QString keyval = ui.GetString("WH"); double wh = keyval.toDouble(); photoPvl.findObject("PhotometricModel").findGroup("Algorithm"). - addKeyword(PvlKeyword("WH",toString(wh)),Pvl::Replace); + addKeyword(PvlKeyword("WH",Isis::toString(wh)),Pvl::Replace); } if (ui.WasEntered("HH")) { QString keyval = ui.GetString("HH"); double hh = keyval.toDouble(); photoPvl.findObject("PhotometricModel").findGroup("Algorithm"). - addKeyword(PvlKeyword("HH",toString(hh)),Pvl::Replace); + addKeyword(PvlKeyword("HH",Isis::toString(hh)),Pvl::Replace); } if (ui.WasEntered("B0")) { QString keyval = ui.GetString("B0"); double b0 = keyval.toDouble(); photoPvl.findObject("PhotometricModel").findGroup("Algorithm"). - addKeyword(PvlKeyword("B0",toString(b0)),Pvl::Replace); + addKeyword(PvlKeyword("B0",Isis::toString(b0)),Pvl::Replace); } if (ui.WasEntered("THETA")) { QString keyval = ui.GetString("THETA"); double theta = keyval.toDouble(); photoPvl.findObject("PhotometricModel").findGroup("Algorithm"). - addKeyword(PvlKeyword("THETA",toString(theta)),Pvl::Replace); + addKeyword(PvlKeyword("THETA",Isis::toString(theta)),Pvl::Replace); } if (ui.WasEntered("ZEROB0STANDARD")) { QString keyval = ui.GetString("ZEROB0STANDARD"); @@ -125,13 +125,13 @@ void IsisMain() { QString keyval = ui.GetString("HG1"); double hg1 = keyval.toDouble(); photoPvl.findObject("PhotometricModel").findGroup("Algorithm"). - addKeyword(PvlKeyword("HG1",toString(hg1)),Pvl::Replace); + addKeyword(PvlKeyword("HG1",Isis::toString(hg1)),Pvl::Replace); } if (ui.WasEntered("HG2")) { QString keyval = ui.GetString("HG2"); double hg2 = keyval.toDouble(); photoPvl.findObject("PhotometricModel").findGroup("Algorithm"). - addKeyword(PvlKeyword("HG2",toString(hg2)),Pvl::Replace); + addKeyword(PvlKeyword("HG2",Isis::toString(hg2)),Pvl::Replace); } } else { @@ -139,13 +139,13 @@ void IsisMain() { QString keyval = ui.GetString("BH"); double bh = keyval.toDouble(); photoPvl.findObject("PhotometricModel").findGroup("Algorithm"). - addKeyword(PvlKeyword("BH",toString(bh)),Pvl::Replace); + addKeyword(PvlKeyword("BH",Isis::toString(bh)),Pvl::Replace); } if (ui.WasEntered("CH")) { QString keyval = ui.GetString("CH"); double ch = keyval.toDouble(); photoPvl.findObject("PhotometricModel").findGroup("Algorithm"). - addKeyword(PvlKeyword("CH",toString(ch)),Pvl::Replace); + addKeyword(PvlKeyword("CH",Isis::toString(ch)),Pvl::Replace); } } } @@ -154,7 +154,7 @@ void IsisMain() { QString keyval = ui.GetString("L"); double l = keyval.toDouble(); photoPvl.findObject("PhotometricModel").findGroup("Algorithm"). - addKeyword(PvlKeyword("L",toString(l)),Pvl::Replace); + addKeyword(PvlKeyword("L",Isis::toString(l)),Pvl::Replace); } } else if (sPhotoFunc == "MINNAERT") { @@ -162,7 +162,7 @@ void IsisMain() { QString keyval = ui.GetString("K"); double k = keyval.toDouble(); photoPvl.findObject("PhotometricModel").findGroup("Algorithm"). - addKeyword(PvlKeyword("K",toString(k)),Pvl::Replace); + addKeyword(PvlKeyword("K",Isis::toString(k)),Pvl::Replace); } } @@ -193,13 +193,13 @@ void IsisMain() { QString keyval = ui.GetString("WHA"); double wha = keyval.toDouble(); asmPvl.findObject("AtmosphericModel").findGroup("Algorithm"). - addKeyword(PvlKeyword("WHA",toString(wha)),Pvl::Replace); + addKeyword(PvlKeyword("WHA",Isis::toString(wha)),Pvl::Replace); } if (ui.WasEntered("HNORM")) { QString keyval = ui.GetString("HNORM"); double hnorm = keyval.toDouble(); asmPvl.findObject("AtmosphericModel").findGroup("Algorithm"). - addKeyword(PvlKeyword("HNORM",toString(hnorm)),Pvl::Replace); + addKeyword(PvlKeyword("HNORM",Isis::toString(hnorm)),Pvl::Replace); } if (sAsmType=="ANISOTROPIC1" || sAsmType=="ANISOTROPIC2" ){ @@ -207,7 +207,7 @@ void IsisMain() { QString keyval = ui.GetString("BHA"); double bha = keyval.toDouble(); asmPvl.findObject("AtmosphericModel").findGroup("Algorithm"). - addKeyword(PvlKeyword("BHA",toString(bha)),Pvl::Replace); + addKeyword(PvlKeyword("BHA",Isis::toString(bha)),Pvl::Replace); } } else if (sAsmType=="HAPKEATM1" || sAsmType=="HAPKEATM2" ) { @@ -215,7 +215,7 @@ void IsisMain() { QString keyval = ui.GetString("HGA"); double hga = keyval.toDouble(); asmPvl.findObject("AtmosphericModel").findGroup("Algorithm"). - addKeyword(PvlKeyword("HGA",toString(hga)),Pvl::Replace); + addKeyword(PvlKeyword("HGA",Isis::toString(hga)),Pvl::Replace); } } diff --git a/isis/src/base/apps/skymap/main.cpp b/isis/src/base/apps/skymap/main.cpp index 39ed118ae5..7e78d7d6e8 100644 --- a/isis/src/base/apps/skymap/main.cpp +++ b/isis/src/base/apps/skymap/main.cpp @@ -85,8 +85,8 @@ void IsisMain() { // Add the default mapping info to the user entered mapping group userGrp.addKeyword(PvlKeyword("TargetName", "Sky"), Pvl::Replace); - userGrp.addKeyword(PvlKeyword("EquatorialRadius", toString(1.0)), Pvl::Replace); - userGrp.addKeyword(PvlKeyword("PolarRadius", toString(1.0)), Pvl::Replace); + userGrp.addKeyword(PvlKeyword("EquatorialRadius", Isis::toString(1.0)), Pvl::Replace); + userGrp.addKeyword(PvlKeyword("PolarRadius", Isis::toString(1.0)), Pvl::Replace); userGrp.addKeyword(PvlKeyword("LatitudeType", "Planetocentric"), Pvl::Replace); if (!userGrp.hasKeyword("LongitudeDirection")) { userGrp.addKeyword(PvlKeyword("LongitudeDirection", "PositiveWest"), Pvl::Replace); @@ -100,36 +100,36 @@ void IsisMain() { // Get the default ra/dec range double minRa, maxRa, minDec, maxDec; incam->RaDecRange(minRa, maxRa, minDec, maxDec); - userGrp.addKeyword(PvlKeyword("MinimumLongitude", toString(minRa)), Pvl::Replace); - userGrp.addKeyword(PvlKeyword("MaximumLongitude", toString(maxRa)), Pvl::Replace); - userGrp.addKeyword(PvlKeyword("MinimumLatitude", toString(minDec)), Pvl::Replace); - userGrp.addKeyword(PvlKeyword("MaximumLatitude", toString(maxDec)), Pvl::Replace); + userGrp.addKeyword(PvlKeyword("MinimumLongitude", Isis::toString(minRa)), Pvl::Replace); + userGrp.addKeyword(PvlKeyword("MaximumLongitude", Isis::toString(maxRa)), Pvl::Replace); + userGrp.addKeyword(PvlKeyword("MinimumLatitude", Isis::toString(minDec)), Pvl::Replace); + userGrp.addKeyword(PvlKeyword("MaximumLatitude", Isis::toString(maxDec)), Pvl::Replace); incam->SetImage(icube->sampleCount() / 2.0, icube->lineCount() / 2.0); double centerRa = incam->RightAscension(); - userGrp.addKeyword(PvlKeyword("CenterLongitude", toString(centerRa)), Pvl::Replace); + userGrp.addKeyword(PvlKeyword("CenterLongitude", Isis::toString(centerRa)), Pvl::Replace); } if(ui.GetString("DEFAULTSCALE") == "CAMERA") { double res = incam->RaDecResolution(); - userGrp.addKeyword(PvlKeyword("Scale", toString(1.0 / res)), Pvl::Replace); + userGrp.addKeyword(PvlKeyword("Scale", Isis::toString(1.0 / res)), Pvl::Replace); } // Override computed range with the users request if(ui.WasEntered("SRA")) { - userGrp.addKeyword(PvlKeyword("MinimumLongitude", toString(ui.GetDouble("SRA"))), Pvl::Replace); + userGrp.addKeyword(PvlKeyword("MinimumLongitude", Isis::toString(ui.GetDouble("SRA"))), Pvl::Replace); } if(ui.WasEntered("ERA")) { - userGrp.addKeyword(PvlKeyword("MaximumLongitude", toString(ui.GetDouble("ERA"))), Pvl::Replace); + userGrp.addKeyword(PvlKeyword("MaximumLongitude", Isis::toString(ui.GetDouble("ERA"))), Pvl::Replace); } if(ui.WasEntered("SDEC")) { - userGrp.addKeyword(PvlKeyword("MinimumLatitude", toString(ui.GetDouble("SDEC"))), Pvl::Replace); + userGrp.addKeyword(PvlKeyword("MinimumLatitude", Isis::toString(ui.GetDouble("SDEC"))), Pvl::Replace); } if(ui.WasEntered("EDEC")) { - userGrp.addKeyword(PvlKeyword("MaximumLatitude", toString(ui.GetDouble("EDEC"))), Pvl::Replace); + userGrp.addKeyword(PvlKeyword("MaximumLatitude", Isis::toString(ui.GetDouble("EDEC"))), Pvl::Replace); } // Get the resolution from the user if they decided to enter it if(ui.GetString("DEFAULTSCALE") == "USER") { - userGrp.addKeyword(PvlKeyword("Scale", toString(ui.GetDouble("SCALE"))), Pvl::Replace); + userGrp.addKeyword(PvlKeyword("Scale", Isis::toString(ui.GetDouble("SCALE"))), Pvl::Replace); } // Create the projection @@ -183,14 +183,14 @@ void IsisMain() { // Create an alpha cube group for the output cube if(!ocube->hasGroup("AlphaCube")) { PvlGroup alpha("AlphaCube"); - alpha += PvlKeyword("AlphaSamples", toString(icube->sampleCount())); - alpha += PvlKeyword("AlphaLines", toString(icube->lineCount())); - alpha += PvlKeyword("AlphaStartingSample", toString(0.5)); - alpha += PvlKeyword("AlphaStartingLine", toString(0.5)); - alpha += PvlKeyword("AlphaEndingSample", toString(icube->sampleCount() + 0.5)); - alpha += PvlKeyword("AlphaEndingLine", toString(icube->lineCount() + 0.5)); - alpha += PvlKeyword("BetaSamples", toString(icube->sampleCount())); - alpha += PvlKeyword("BetaLines", toString(icube->lineCount())); + alpha += PvlKeyword("AlphaSamples", Isis::toString(icube->sampleCount())); + alpha += PvlKeyword("AlphaLines", Isis::toString(icube->lineCount())); + alpha += PvlKeyword("AlphaStartingSample", Isis::toString(0.5)); + alpha += PvlKeyword("AlphaStartingLine", Isis::toString(0.5)); + alpha += PvlKeyword("AlphaEndingSample", Isis::toString(icube->sampleCount() + 0.5)); + alpha += PvlKeyword("AlphaEndingLine", Isis::toString(icube->lineCount() + 0.5)); + alpha += PvlKeyword("BetaSamples", Isis::toString(icube->sampleCount())); + alpha += PvlKeyword("BetaLines", Isis::toString(icube->lineCount())); ocube->putGroup(alpha); } diff --git a/isis/src/base/apps/skypt/skypt.cpp b/isis/src/base/apps/skypt/skypt.cpp index a6c477335d..e566ae2569 100644 --- a/isis/src/base/apps/skypt/skypt.cpp +++ b/isis/src/base/apps/skypt/skypt.cpp @@ -75,13 +75,13 @@ namespace Isis{ PvlGroup sp("SkyPoint"); { sp += PvlKeyword("Filename", FileName(channel.toStdString()).expanded()); - sp += PvlKeyword("Sample", toString(cam->Sample())); - sp += PvlKeyword("Line", toString(cam->Line())); - sp += PvlKeyword("RightAscension", toString(cam->RightAscension())); - sp += PvlKeyword("Declination", toString(cam->Declination())); - sp += PvlKeyword("EphemerisTime", toString(cam->time().Et())); + sp += PvlKeyword("Sample", Isis::toString(cam->Sample())); + sp += PvlKeyword("Line", Isis::toString(cam->Line())); + sp += PvlKeyword("RightAscension", Isis::toString(cam->RightAscension())); + sp += PvlKeyword("Declination", Isis::toString(cam->Declination())); + sp += PvlKeyword("EphemerisTime", Isis::toString(cam->time().Et())); sp += PvlKeyword("PixelValue", PixelToString(b[0])); - sp += PvlKeyword("CelestialNorthClockAngle", toString(rot), "degrees"); + sp += PvlKeyword("CelestialNorthClockAngle", Isis::toString(rot), "degrees"); } //Write the group to the screen diff --git a/isis/src/base/apps/skyrange/main.cpp b/isis/src/base/apps/skyrange/main.cpp index 246b21d62b..2facacf247 100644 --- a/isis/src/base/apps/skyrange/main.cpp +++ b/isis/src/base/apps/skyrange/main.cpp @@ -29,25 +29,25 @@ void IsisMain() { // Setup and log results PvlGroup results("Range"); - results += PvlKeyword("MinimumRightAscension", toString(minRa), "degrees"); - results += PvlKeyword("MaximumRightAscension", toString(maxRa), "degrees"); - results += PvlKeyword("MinimumDeclination", toString(minDec), "degrees"); - results += PvlKeyword("MaximumDeclination", toString(maxDec), "degrees"); + results += PvlKeyword("MinimumRightAscension", Isis::toString(minRa), "degrees"); + results += PvlKeyword("MaximumRightAscension", Isis::toString(maxRa), "degrees"); + results += PvlKeyword("MinimumDeclination", Isis::toString(minDec), "degrees"); + results += PvlKeyword("MaximumDeclination", Isis::toString(maxDec), "degrees"); results += PvlKeyword("MinimumRightAscension", Projection::ToHMS(minRa).toStdString(), "hms"); results += PvlKeyword("MaximumRightAscension", Projection::ToHMS(maxRa).toStdString(), "hms"); results += PvlKeyword("MinimumDeclination", Projection::ToDMS(minDec).toStdString(), "dms"); results += PvlKeyword("MaximumDeclination", Projection::ToDMS(maxDec).toStdString(), "dms"); - results += PvlKeyword("Resolution", toString(res), "degrees/pixel"); + results += PvlKeyword("Resolution", Isis::toString(res), "degrees/pixel"); Application::Log(results); // Setup and log orientation PvlGroup orient("Orientation"); - orient += PvlKeyword("CenterSample", toString(icube->sampleCount() / 2.0)); - orient += PvlKeyword("CenterLine", toString(icube->lineCount() / 2.0)); - orient += PvlKeyword("CenterRightAscension", toString(centerRa), "degrees"); - orient += PvlKeyword("CenterDeclination", toString(centerDec), "degrees"); - orient += PvlKeyword("CelestialNorthClockAngle", toString(rot), "degrees"); - orient += PvlKeyword("Resolution", toString(res), "degrees/pixel"); + orient += PvlKeyword("CenterSample", Isis::toString(icube->sampleCount() / 2.0)); + orient += PvlKeyword("CenterLine", Isis::toString(icube->lineCount() / 2.0)); + orient += PvlKeyword("CenterRightAscension", Isis::toString(centerRa), "degrees"); + orient += PvlKeyword("CenterDeclination", Isis::toString(centerDec), "degrees"); + orient += PvlKeyword("CelestialNorthClockAngle", Isis::toString(rot), "degrees"); + orient += PvlKeyword("Resolution", Isis::toString(res), "degrees/pixel"); Application::Log(orient); // Write the output file if requested diff --git a/isis/src/base/apps/slpmap/main.cpp b/isis/src/base/apps/slpmap/main.cpp index 423dbed6fc..225a2ce3f5 100644 --- a/isis/src/base/apps/slpmap/main.cpp +++ b/isis/src/base/apps/slpmap/main.cpp @@ -139,7 +139,7 @@ void createSlpCubeAutomatic(Buffer &in, double &v) { } catch (IException &e) { std::string msg = "The input cube contains a negative DN at (sample,line,band) " - "[("+toString(in.Sample(4))+","+toString(in.Line(4))+","+toString(in.Band(4))+")]. The automatic pixel resolution option requires the input cube contain " + "[("+Isis::toString(in.Sample(4))+","+Isis::toString(in.Line(4))+","+Isis::toString(in.Band(4))+")]. The automatic pixel resolution option requires the input cube contain " "raduis values. It is possible the input cube contains elevation or other data."; throw IException(e, IException::User, msg, _FILEINFO_); } diff --git a/isis/src/base/apps/smtk/main.cpp b/isis/src/base/apps/smtk/main.cpp index 7d53ff6b03..168144913d 100644 --- a/isis/src/base/apps/smtk/main.cpp +++ b/isis/src/base/apps/smtk/main.cpp @@ -449,10 +449,10 @@ void IsisMain() { // Report Stereo separation angles PvlGroup stresultsPvl("StereoSeparationAngle"); - stresultsPvl += PvlKeyword("Minimum", toString(stAng.Minimum()), "deg"); - stresultsPvl += PvlKeyword("Average", toString(stAng.Average()), "deg"); - stresultsPvl += PvlKeyword("Maximum", toString(stAng.Maximum()), "deg"); - stresultsPvl += PvlKeyword("StandardDeviation", toString(stAng.StandardDeviation()), "deg"); + stresultsPvl += PvlKeyword("Minimum", Isis::toString(stAng.Minimum()), "deg"); + stresultsPvl += PvlKeyword("Average", Isis::toString(stAng.Average()), "deg"); + stresultsPvl += PvlKeyword("Maximum", Isis::toString(stAng.Maximum()), "deg"); + stresultsPvl += PvlKeyword("StandardDeviation", Isis::toString(stAng.StandardDeviation()), "deg"); Application::Log(stresultsPvl); // Update the label with BandBin keywords @@ -481,17 +481,17 @@ void IsisMain() { // Create output data PvlGroup totalPointsPvl("Totals"); - totalPointsPvl += PvlKeyword("AttemptedPoints", toString(numAttemptedInitialPoints)); - totalPointsPvl += PvlKeyword("InitialSuccesses", toString(numOrigPoints)); - totalPointsPvl += PvlKeyword("GrowSuccesses", toString(passpix2)); - totalPointsPvl += PvlKeyword("ResultingPoints", toString(bmf.size())); + totalPointsPvl += PvlKeyword("AttemptedPoints", Isis::toString(numAttemptedInitialPoints)); + totalPointsPvl += PvlKeyword("InitialSuccesses", Isis::toString(numOrigPoints)); + totalPointsPvl += PvlKeyword("GrowSuccesses", Isis::toString(passpix2)); + totalPointsPvl += PvlKeyword("ResultingPoints", Isis::toString(bmf.size())); Application::Log(totalPointsPvl); Pvl arPvl = matcher.RegistrationStatistics(); PvlGroup smtkresultsPvl("SmtkResults"); - smtkresultsPvl += PvlKeyword("SpiceOffImage", toString(matcher.OffImageErrorCount())); - smtkresultsPvl += PvlKeyword("SpiceDistanceError", toString(matcher.SpiceErrorCount())); + smtkresultsPvl += PvlKeyword("SpiceOffImage", Isis::toString(matcher.OffImageErrorCount())); + smtkresultsPvl += PvlKeyword("SpiceDistanceError", Isis::toString(matcher.SpiceErrorCount())); arPvl.addGroup(smtkresultsPvl); for (int i = 0; i < arPvl.groups(); i++) { diff --git a/isis/src/base/apps/spechighpass/main.cpp b/isis/src/base/apps/spechighpass/main.cpp index eec5a7d0e2..fcd0789b14 100644 --- a/isis/src/base/apps/spechighpass/main.cpp +++ b/isis/src/base/apps/spechighpass/main.cpp @@ -28,9 +28,9 @@ void IsisMain() { //Check for cases of too many bands if(bands >= (2 * cubeBands)) { - std::string msg = "Parameter bands [" + toString(bands) + "] " + std::string msg = "Parameter bands [" + Isis::toString(bands) + "] " "exceeds maximum allowable size of [" - + toString((cubeBands * 2) - 1) + "] for cube [" + + Isis::toString((cubeBands * 2) - 1) + "] for cube [" + icube->fileName().toStdString() + "]"; throw IException(IException::User, msg, _FILEINFO_); } diff --git a/isis/src/base/apps/specpix/main.cpp b/isis/src/base/apps/specpix/main.cpp index 95e50068b8..a1faac6a1e 100644 --- a/isis/src/base/apps/specpix/main.cpp +++ b/isis/src/base/apps/specpix/main.cpp @@ -98,14 +98,14 @@ void IsisMain() { // Print out number of values changed PvlGroup results("Results"); results.addComment("The number and type of pixels created"); - results += PvlKeyword("Null", toString(nnull)); - results += PvlKeyword("Lrs", toString(nlrs)); - results += PvlKeyword("Lis", toString(nlis)); - results += PvlKeyword("Hrs", toString(nhrs)); - results += PvlKeyword("His", toString(nhis)); + results += PvlKeyword("Null", Isis::toString(nnull)); + results += PvlKeyword("Lrs", Isis::toString(nlrs)); + results += PvlKeyword("Lis", Isis::toString(nlis)); + results += PvlKeyword("Hrs", Isis::toString(nhrs)); + results += PvlKeyword("His", Isis::toString(nhis)); //tjw: int total -> BigInt total BigInt total = nnull + nlrs + nhrs + nlis + nhis; - results += PvlKeyword("Total", toString(total)); + results += PvlKeyword("Total", Isis::toString(total)); Application::Log(results); diff --git a/isis/src/base/apps/spiceinit/spiceinit.cpp b/isis/src/base/apps/spiceinit/spiceinit.cpp index 4f1a6420ae..b9f4c035b4 100644 --- a/isis/src/base/apps/spiceinit/spiceinit.cpp +++ b/isis/src/base/apps/spiceinit/spiceinit.cpp @@ -440,16 +440,16 @@ namespace Isis { // Add any time padding the user specified to the spice group if (ui.GetDouble("STARTPAD") > DBL_EPSILON) { currentKernels.addKeyword(PvlKeyword("StartPadding", - toString(ui.GetDouble("STARTPAD")), "seconds")); + Isis::toString(ui.GetDouble("STARTPAD")), "seconds")); } if (ui.GetDouble("ENDPAD") > DBL_EPSILON) { currentKernels.addKeyword(PvlKeyword("EndPadding", - toString(ui.GetDouble("ENDPAD")), "seconds")); + Isis::toString(ui.GetDouble("ENDPAD")), "seconds")); } currentKernels.addKeyword( - PvlKeyword("CameraVersion", toString(CameraFactory::CameraVersion(*icube))), + PvlKeyword("CameraVersion", Isis::toString(CameraFactory::CameraVersion(*icube))), Pvl::Replace); // Add the modified Kernels group to the input cube labels @@ -518,7 +518,7 @@ namespace Isis { bodyTable.Label()["Kernels"].addValue(pckKeyword[i]); bodyTable.Label() += PvlKeyword("SolarLongitude", - toString(cam->solarLongitude().degrees())); + Isis::toString(cam->solarLongitude().degrees())); icube->write(bodyTable); Table sunTable = cam->sunPosition()->Cache("SunPosition"); diff --git a/isis/src/base/apps/spiceserver/spiceserver.cpp b/isis/src/base/apps/spiceserver/spiceserver.cpp index f66a2ed5ae..fefdb57184 100644 --- a/isis/src/base/apps/spiceserver/spiceserver.cpp +++ b/isis/src/base/apps/spiceserver/spiceserver.cpp @@ -121,8 +121,8 @@ namespace Isis { else { std::string err = "Unable to read XML. The reason given was ["; err += error.toStdString(); - err += "] on line [" + toString(errorLine) + "] column ["; - err += toString(errorCol) + "]"; + err += "] on line [" + Isis::toString(errorLine) + "] column ["; + err += Isis::toString(errorCol) + "]"; throw IException(IException::Io, err, _FILEINFO_); } } @@ -410,14 +410,14 @@ namespace Isis { // Add any time padding the user specified to the spice group if (g_startPad > DBL_EPSILON) - currentKernels.addKeyword( PvlKeyword("StartPadding", toString(g_startPad), "seconds") ); + currentKernels.addKeyword( PvlKeyword("StartPadding", Isis::toString(g_startPad), "seconds") ); if (g_endPad > DBL_EPSILON) - currentKernels.addKeyword( PvlKeyword("EndPadding", toString(g_endPad), "seconds") ); + currentKernels.addKeyword( PvlKeyword("EndPadding", Isis::toString(g_endPad), "seconds") ); currentKernels.addKeyword( - PvlKeyword( "CameraVersion", toString( CameraFactory::CameraVersion(cube) ) ), Pvl::Replace); + PvlKeyword( "CameraVersion", Isis::toString( CameraFactory::CameraVersion(cube) ) ), Pvl::Replace); // Add the modified Kernels group to the input cube labels cube.putGroup(currentKernels); @@ -468,7 +468,7 @@ namespace Isis { for (int i = 0; i < pckKeyword.size(); i++) bodyTable.Label()["Kernels"].addValue(pckKeyword[i]); - bodyTable.Label() += PvlKeyword( "SolarLongitude", toString( cam->solarLongitude().degrees() ) ); + bodyTable.Label() += PvlKeyword( "SolarLongitude", Isis::toString( cam->solarLongitude().degrees() ) ); bodyTable.toBlob().Write(ui.GetFileName("TO").toStdString() + ".bodyrot"); Table sunTable = cam->sunPosition()->Cache("SunPosition"); diff --git a/isis/src/base/apps/spkwriter/SpkKernelWriter.h b/isis/src/base/apps/spkwriter/SpkKernelWriter.h index f80cb78d79..9990487db4 100644 --- a/isis/src/base/apps/spkwriter/SpkKernelWriter.h +++ b/isis/src/base/apps/spkwriter/SpkKernelWriter.h @@ -83,7 +83,7 @@ class SpkKernelWriter : public KernelWriter { */ void setType(const int spktype) { if ( (spktype != 9) && (spktype != 13) ) { - std::string mess = "SPK kernel type " + toString(spktype) + + std::string mess = "SPK kernel type " + Isis::toString(spktype) + " not valid/supported - must 9 or 13"; throw IException(IException::User, mess, _FILEINFO_); } diff --git a/isis/src/base/apps/stats/stats.cpp b/isis/src/base/apps/stats/stats.cpp index 092b860af8..40219dfee9 100644 --- a/isis/src/base/apps/stats/stats.cpp +++ b/isis/src/base/apps/stats/stats.cpp @@ -117,18 +117,18 @@ namespace Isis { // Construct a label with the results PvlGroup results("Results"); results += PvlKeyword("From", cube->fileName().toStdString()); - results += PvlKeyword("Band", toString(cube->physicalBand(i))); + results += PvlKeyword("Band", Isis::toString(cube->physicalBand(i))); if ( stats->ValidPixels() != 0 ) { - results += PvlKeyword("Average", toString(stats->Average())); - results += PvlKeyword("StandardDeviation", toString(stats->StandardDeviation())); - results += PvlKeyword("Variance", toString(stats->Variance())); + results += PvlKeyword("Average", Isis::toString(stats->Average())); + results += PvlKeyword("StandardDeviation", Isis::toString(stats->StandardDeviation())); + results += PvlKeyword("Variance", Isis::toString(stats->Variance())); // These statistics only worked on a histogram - results += PvlKeyword("Median", toString(stats->Median())); - results += PvlKeyword("Mode", toString(stats->Mode())); - results += PvlKeyword("Skew", toString(stats->Skew())); - results += PvlKeyword("Minimum", toString(stats->Minimum())); - results += PvlKeyword("Maximum", toString(stats->Maximum())); - results += PvlKeyword("Sum", toString(stats->Sum())); + results += PvlKeyword("Median", Isis::toString(stats->Median())); + results += PvlKeyword("Mode", Isis::toString(stats->Mode())); + results += PvlKeyword("Skew", Isis::toString(stats->Skew())); + results += PvlKeyword("Minimum", Isis::toString(stats->Minimum())); + results += PvlKeyword("Maximum", Isis::toString(stats->Maximum())); + results += PvlKeyword("Sum", Isis::toString(stats->Sum())); } else { results += PvlKeyword("Average", "N/A"); @@ -141,15 +141,15 @@ namespace Isis { results += PvlKeyword("Maximum", "N/A"); results += PvlKeyword("Sum", "N/A"); } - results += PvlKeyword("TotalPixels", toString(stats->TotalPixels())); - results += PvlKeyword("ValidPixels", toString(stats->ValidPixels())); - results += PvlKeyword("OverValidMaximumPixels", toString(stats->OverRangePixels())); - results += PvlKeyword("UnderValidMinimumPixels", toString(stats->UnderRangePixels())); - results += PvlKeyword("NullPixels", toString(stats->NullPixels())); - results += PvlKeyword("LisPixels", toString(stats->LisPixels())); - results += PvlKeyword("LrsPixels", toString(stats->LrsPixels())); - results += PvlKeyword("HisPixels", toString(stats->HisPixels())); - results += PvlKeyword("HrsPixels", toString(stats->HrsPixels())); + results += PvlKeyword("TotalPixels", Isis::toString(stats->TotalPixels())); + results += PvlKeyword("ValidPixels", Isis::toString(stats->ValidPixels())); + results += PvlKeyword("OverValidMaximumPixels", Isis::toString(stats->OverRangePixels())); + results += PvlKeyword("UnderValidMinimumPixels", Isis::toString(stats->UnderRangePixels())); + results += PvlKeyword("NullPixels", Isis::toString(stats->NullPixels())); + results += PvlKeyword("LisPixels", Isis::toString(stats->LisPixels())); + results += PvlKeyword("LrsPixels", Isis::toString(stats->LrsPixels())); + results += PvlKeyword("HisPixels", Isis::toString(stats->HisPixels())); + results += PvlKeyword("HrsPixels", Isis::toString(stats->HrsPixels())); statsPvl.addGroup(results); diff --git a/isis/src/base/apps/trackextract/main.cpp b/isis/src/base/apps/trackextract/main.cpp index 12390f5936..fcac277bfd 100644 --- a/isis/src/base/apps/trackextract/main.cpp +++ b/isis/src/base/apps/trackextract/main.cpp @@ -199,7 +199,7 @@ void createMosaicCube(QString inputName, QString outputName, QVector ba void createTrackCube(QString inputName, QString ouputName, int trackBand) { ProcessByLine p; - CubeAttributeInput inAtt = CubeAttributeInput("+" + toString(trackBand)); + CubeAttributeInput inAtt = CubeAttributeInput("+" + Isis::toString(trackBand)); p.SetInputCube(inputName, inAtt); FileName cubeName = FileName(ouputName.toStdString()); diff --git a/isis/src/base/objs/AlbedoAtm/AlbedoAtm.cpp b/isis/src/base/objs/AlbedoAtm/AlbedoAtm.cpp index d39940c8e1..32350f5862 100644 --- a/isis/src/base/objs/AlbedoAtm/AlbedoAtm.cpp +++ b/isis/src/base/objs/AlbedoAtm/AlbedoAtm.cpp @@ -176,7 +176,7 @@ namespace Isis { void AlbedoAtm::SetNormPharef(const double pharef) { if(pharef < 0.0 || pharef >= 180.0) { std::string msg = "Invalid value of normalization pharef [" + - toString(pharef) + "]"; + Isis::toString(pharef) + "]"; throw IException(IException::User, msg, _FILEINFO_); } @@ -195,7 +195,7 @@ namespace Isis { void AlbedoAtm::SetNormIncref(const double incref) { if(incref < 0.0 || incref >= 90.0) { std::string msg = "Invalid value of normalization incref [" + - toString(incref) + "]"; + Isis::toString(incref) + "]"; throw IException(IException::User, msg, _FILEINFO_); } @@ -214,7 +214,7 @@ namespace Isis { void AlbedoAtm::SetNormEmaref(const double emaref) { if(emaref < 0.0 || emaref >= 90.0) { std::string msg = "Invalid value of normalization emaref [" + - toString(emaref) + "]"; + Isis::toString(emaref) + "]"; throw IException(IException::User, msg, _FILEINFO_); } diff --git a/isis/src/base/objs/AlphaCube/AlphaCube.cpp b/isis/src/base/objs/AlphaCube/AlphaCube.cpp index f94c64a072..b5cf2f8bf4 100644 --- a/isis/src/base/objs/AlphaCube/AlphaCube.cpp +++ b/isis/src/base/objs/AlphaCube/AlphaCube.cpp @@ -145,25 +145,25 @@ namespace Isis { *this = temp; Isis::PvlGroup &alpha = cubeObject.findGroup("AlphaCube"); - alpha["AlphaSamples"] = toString(p_alphaSamples); - alpha["AlphaLines"] = toString(p_alphaLines); - alpha["AlphaStartingSample"] = toString(p_alphaStartingSample); - alpha["AlphaStartingLine"] = toString(p_alphaStartingLine); - alpha["AlphaEndingSample"] = toString(p_alphaEndingSample); - alpha["AlphaEndingLine"] = toString(p_alphaEndingLine); - alpha["BetaSamples"] = toString(p_betaSamples); - alpha["BetaLines"] = toString(p_betaLines); + alpha["AlphaSamples"] = Isis::toString(p_alphaSamples); + alpha["AlphaLines"] = Isis::toString(p_alphaLines); + alpha["AlphaStartingSample"] = Isis::toString(p_alphaStartingSample); + alpha["AlphaStartingLine"] = Isis::toString(p_alphaStartingLine); + alpha["AlphaEndingSample"] = Isis::toString(p_alphaEndingSample); + alpha["AlphaEndingLine"] = Isis::toString(p_alphaEndingLine); + alpha["BetaSamples"] = Isis::toString(p_betaSamples); + alpha["BetaLines"] = Isis::toString(p_betaLines); } else { Isis::PvlGroup alpha("AlphaCube"); - alpha += Isis::PvlKeyword("AlphaSamples", toString(p_alphaSamples)); - alpha += Isis::PvlKeyword("AlphaLines", toString(p_alphaLines)); - alpha += Isis::PvlKeyword("AlphaStartingSample", toString(p_alphaStartingSample)); - alpha += Isis::PvlKeyword("AlphaStartingLine", toString(p_alphaStartingLine)); - alpha += Isis::PvlKeyword("AlphaEndingSample", toString(p_alphaEndingSample)); - alpha += Isis::PvlKeyword("AlphaEndingLine", toString(p_alphaEndingLine)); - alpha += Isis::PvlKeyword("BetaSamples", toString(p_betaSamples)); - alpha += Isis::PvlKeyword("BetaLines", toString(p_betaLines)); + alpha += Isis::PvlKeyword("AlphaSamples", Isis::toString(p_alphaSamples)); + alpha += Isis::PvlKeyword("AlphaLines", Isis::toString(p_alphaLines)); + alpha += Isis::PvlKeyword("AlphaStartingSample", Isis::toString(p_alphaStartingSample)); + alpha += Isis::PvlKeyword("AlphaStartingLine", Isis::toString(p_alphaStartingLine)); + alpha += Isis::PvlKeyword("AlphaEndingSample", Isis::toString(p_alphaEndingSample)); + alpha += Isis::PvlKeyword("AlphaEndingLine", Isis::toString(p_alphaEndingLine)); + alpha += Isis::PvlKeyword("BetaSamples", Isis::toString(p_betaSamples)); + alpha += Isis::PvlKeyword("BetaLines", Isis::toString(p_betaLines)); cubeObject.addGroup(alpha); } } diff --git a/isis/src/base/objs/Application/Application.cpp b/isis/src/base/objs/Application/Application.cpp index 19e7a41906..b77d9d3fa9 100644 --- a/isis/src/base/objs/Application/Application.cpp +++ b/isis/src/base/objs/Application/Application.cpp @@ -530,7 +530,7 @@ namespace Isis { "process. A communication channel was established with the parent " "(launcher) process, but when we tried to send data to the parent " "process an error occurred. The parent process has a PID of [" + - std::to_string(iApp->GetUserInterface().ParentId()) + "]"; + Isis::toString(iApp->GetUserInterface().ParentId()) + "]"; throw IException(IException::Unknown, msg, _FILEINFO_); } diff --git a/isis/src/base/objs/AutoReg/AutoReg.cpp b/isis/src/base/objs/AutoReg/AutoReg.cpp index 62a3c6392c..481f824581 100644 --- a/isis/src/base/objs/AutoReg/AutoReg.cpp +++ b/isis/src/base/objs/AutoReg/AutoReg.cpp @@ -201,7 +201,7 @@ namespace Isis { } if(algo.hasKeyword("SubpixelAccuracy")) { - SetSubPixelAccuracy(toBool(algo["SubpixelAccuracy"])); + SetSubPixelAccuracy(Isis::toString((int)algo["SubpixelAccuracy"]) == "True"); } if(algo.hasKeyword("ReductionFactor")) { @@ -1177,30 +1177,30 @@ namespace Isis { Pvl AutoReg::RegistrationStatistics() { Pvl pvl; PvlGroup stats("AutoRegStatistics"); - stats += Isis::PvlKeyword("Total", toString(p_totalRegistrations)); - stats += Isis::PvlKeyword("Successful", toString(p_pixelSuccesses + p_subpixelSuccesses)); - stats += Isis::PvlKeyword("Failure", toString(p_totalRegistrations - (p_pixelSuccesses + p_subpixelSuccesses))); + stats += Isis::PvlKeyword("Total", Isis::toString(p_totalRegistrations)); + stats += Isis::PvlKeyword("Successful", Isis::toString(p_pixelSuccesses + p_subpixelSuccesses)); + stats += Isis::PvlKeyword("Failure", Isis::toString(p_totalRegistrations - (p_pixelSuccesses + p_subpixelSuccesses))); pvl.addGroup(stats); PvlGroup successes("Successes"); - successes += PvlKeyword("SuccessPixel", toString(p_pixelSuccesses)); - successes += PvlKeyword("SuccessSubPixel", toString(p_subpixelSuccesses)); + successes += PvlKeyword("SuccessPixel", Isis::toString(p_pixelSuccesses)); + successes += PvlKeyword("SuccessSubPixel", Isis::toString(p_subpixelSuccesses)); pvl.addGroup(successes); PvlGroup grp("PatternChipFailures"); - grp += PvlKeyword("PatternNotEnoughValidData", toString(p_patternChipNotEnoughValidDataCount)); - grp += PvlKeyword("PatternZScoreNotMet", toString(p_patternZScoreNotMetCount)); + grp += PvlKeyword("PatternNotEnoughValidData", Isis::toString(p_patternChipNotEnoughValidDataCount)); + grp += PvlKeyword("PatternZScoreNotMet", Isis::toString(p_patternZScoreNotMetCount)); pvl.addGroup(grp); PvlGroup fit("FitChipFailures"); - fit += PvlKeyword("FitChipNoData", toString(p_fitChipNoDataCount)); - fit += PvlKeyword("FitChipToleranceNotMet", toString(p_fitChipToleranceNotMetCount)); + fit += PvlKeyword("FitChipNoData", Isis::toString(p_fitChipNoDataCount)); + fit += PvlKeyword("FitChipToleranceNotMet", Isis::toString(p_fitChipToleranceNotMetCount)); pvl.addGroup(fit); PvlGroup model("SurfaceModelFailures"); - model += PvlKeyword("SurfaceModelNotEnoughValidData", toString(p_surfaceModelNotEnoughValidDataCount)); - model += PvlKeyword("SurfaceModelSolutionInvalid", toString(p_surfaceModelSolutionInvalidCount)); - model += PvlKeyword("SurfaceModelDistanceInvalid", toString(p_surfaceModelDistanceInvalidCount)); + model += PvlKeyword("SurfaceModelNotEnoughValidData", Isis::toString(p_surfaceModelNotEnoughValidDataCount)); + model += PvlKeyword("SurfaceModelSolutionInvalid", Isis::toString(p_surfaceModelSolutionInvalidCount)); + model += PvlKeyword("SurfaceModelDistanceInvalid", Isis::toString(p_surfaceModelDistanceInvalidCount)); pvl.addGroup(model); return (AlgorithmStatistics(pvl)); @@ -1290,28 +1290,28 @@ namespace Isis { PvlGroup reg("AutoRegistration"); reg += PvlKeyword("Algorithm", AlgorithmName().toStdString()); - reg += PvlKeyword("Tolerance", toString(Tolerance())); + reg += PvlKeyword("Tolerance", Isis::toString(Tolerance())); reg += PvlKeyword("SubpixelAccuracy", SubPixelAccuracy() ? "True" : "False"); - reg += PvlKeyword("ReductionFactor", toString(ReductionFactor())); + reg += PvlKeyword("ReductionFactor", Isis::toString(ReductionFactor())); reg += PvlKeyword("Gradient", GradientFilterString().toStdString()); Chip *pattern = PatternChip(); - reg += PvlKeyword("PatternSamples", toString(pattern->Samples())); - reg += PvlKeyword("PatternLines", toString(pattern->Lines())); - reg += PvlKeyword("MinimumZScore", toString(MinimumZScore())); - reg += PvlKeyword("ValidPercent", toString(PatternValidPercent())); + reg += PvlKeyword("PatternSamples", Isis::toString(pattern->Samples())); + reg += PvlKeyword("PatternLines", Isis::toString(pattern->Lines())); + reg += PvlKeyword("MinimumZScore", Isis::toString(MinimumZScore())); + reg += PvlKeyword("ValidPercent", Isis::toString(PatternValidPercent())); // TODO Chip needs accessors to valid minimum and maximum Chip *search = SearchChip(); - reg += PvlKeyword("SearchSamples", toString(search->Samples())); - reg += PvlKeyword("SearchLines", toString(search->Lines())); - reg += PvlKeyword("SubchipValidPercent", toString(SubsearchValidPercent())); + reg += PvlKeyword("SearchSamples", Isis::toString(search->Samples())); + reg += PvlKeyword("SearchLines", Isis::toString(search->Lines())); + reg += PvlKeyword("SubchipValidPercent", Isis::toString(SubsearchValidPercent())); // TODO Chip needs accessors to valid minimum and maximum if (SubPixelAccuracy()) { - reg += PvlKeyword("DistanceTolerance", toString(DistanceTolerance())); - reg += PvlKeyword("WindowSize", toString(WindowSize())); + reg += PvlKeyword("DistanceTolerance", Isis::toString(DistanceTolerance())); + reg += PvlKeyword("WindowSize", Isis::toString(WindowSize())); } return reg; diff --git a/isis/src/base/objs/CSVReader/CSVReader.cpp b/isis/src/base/objs/CSVReader/CSVReader.cpp index 0a1c2ae9b3..30187ce9e2 100644 --- a/isis/src/base/objs/CSVReader/CSVReader.cpp +++ b/isis/src/base/objs/CSVReader/CSVReader.cpp @@ -140,7 +140,7 @@ namespace Isis { void CSVReader::read(const QString &csvfile) { ifstream ifile(csvfile.toLatin1().data(), ios::in); if(!ifile) { - std::string mess = "Unable to open file [" + csvfile.toStdString() + "]"; + IString mess = "Unable to open file [" + csvfile.toStdString() + "]"; throw IException(IException::User, mess, _FILEINFO_); } diff --git a/isis/src/base/objs/CSVReader/unitTest.cpp b/isis/src/base/objs/CSVReader/unitTest.cpp index b6b5207a44..c7ffd35c84 100644 --- a/isis/src/base/objs/CSVReader/unitTest.cpp +++ b/isis/src/base/objs/CSVReader/unitTest.cpp @@ -53,7 +53,7 @@ int main(int argc, char *argv[]) { cout.setf(ios::fixed); cout << "Size of column 0/1: " << scol.dim() << endl; for(int i = 0 ; i < dcol.dim() ; i++) { - cout << "IString: " << setw(10)<< scol[i].toStdString() + cout << "IString: " << setw(10)<< scol[i].toStdString().c_str() << " \tDouble: " << setprecision(4) << dcol[i] << endl; } diff --git a/isis/src/base/objs/Camera/Camera.cpp b/isis/src/base/objs/Camera/Camera.cpp index 91322177ab..1355031905 100644 --- a/isis/src/base/objs/Camera/Camera.cpp +++ b/isis/src/base/objs/Camera/Camera.cpp @@ -1206,10 +1206,10 @@ namespace Isis { PvlGroup map = pvl.findGroup("Mapping", Pvl::Traverse); if(map.hasKeyword("EquatorialRadius")) - a = Distance(IString::ToDouble(map["EquatorialRadius"][0]), Distance::Meters); + a = Distance(Isis::toDouble(map["EquatorialRadius"][0]), Distance::Meters); if(map.hasKeyword("PolarRadius")) - b = Distance(IString::ToDouble(map["PolarRadius"][0]), Distance::Meters); + b = Distance(Isis::toDouble(map["PolarRadius"][0]), Distance::Meters); // Convert to planetographic if necessary minlat = p_minlat; @@ -1369,19 +1369,19 @@ namespace Isis { map += PvlKeyword("TargetName", target()->name().toStdString()); std::vector radii = target()->radii(); - map += PvlKeyword("EquatorialRadius", std::to_string(radii[0].meters()), "meters"); - map += PvlKeyword("PolarRadius", std::to_string(radii[2].meters()), "meters"); + map += PvlKeyword("EquatorialRadius", Isis::toString(radii[0].meters()), "meters"); + map += PvlKeyword("PolarRadius", Isis::toString(radii[2].meters()), "meters"); map += PvlKeyword("LatitudeType", "Planetocentric"); map += PvlKeyword("LongitudeDirection", "PositiveEast"); map += PvlKeyword("LongitudeDomain", "360"); GroundRangeResolution(); - map += PvlKeyword("MinimumLatitude", std::to_string(p_minlat)); - map += PvlKeyword("MaximumLatitude", std::to_string(p_maxlat)); - map += PvlKeyword("MinimumLongitude", std::to_string(p_minlon)); - map += PvlKeyword("MaximumLongitude", std::to_string(p_maxlon)); - map += PvlKeyword("PixelResolution", std::to_string(p_minres)); + map += PvlKeyword("MinimumLatitude", Isis::toString(p_minlat)); + map += PvlKeyword("MaximumLatitude", Isis::toString(p_maxlat)); + map += PvlKeyword("MinimumLongitude", Isis::toString(p_minlon)); + map += PvlKeyword("MaximumLongitude", Isis::toString(p_maxlon)); + map += PvlKeyword("PixelResolution", Isis::toString(p_minres)); map += PvlKeyword("ProjectionName", "Sinusoidal"); pvl.addGroup(map); @@ -1408,11 +1408,11 @@ namespace Isis { map += PvlKeyword("RingLongitudeDomain", "360"); ringRangeResolution(); - map += PvlKeyword("MinimumRingRadius", std::to_string(p_minRingRadius)); - map += PvlKeyword("MaximumRingRadius", std::to_string(p_maxRingRadius)); - map += PvlKeyword("MinimumRingLongitude", std::to_string(p_minRingLongitude)); - map += PvlKeyword("MaximumRingLongitude", std::to_string(p_maxRingLongitude)); - map += PvlKeyword("PixelResolution", std::to_string(p_minres)); + map += PvlKeyword("MinimumRingRadius", Isis::toString(p_minRingRadius)); + map += PvlKeyword("MaximumRingRadius", Isis::toString(p_maxRingRadius)); + map += PvlKeyword("MinimumRingLongitude", Isis::toString(p_minRingLongitude)); + map += PvlKeyword("MaximumRingLongitude", Isis::toString(p_maxRingLongitude)); + map += PvlKeyword("PixelResolution", Isis::toString(p_minres)); map += PvlKeyword("ProjectionName", "Planar"); pvl.addGroup(map); diff --git a/isis/src/base/objs/Camera/unitTest.cpp b/isis/src/base/objs/Camera/unitTest.cpp index b7b010870e..f525c313cd 100644 --- a/isis/src/base/objs/Camera/unitTest.cpp +++ b/isis/src/base/objs/Camera/unitTest.cpp @@ -231,7 +231,7 @@ int main() { pixRes2 *= 10000000; pixRes2 = round(pixRes2); pixRes2 /= 10000000; - pvl.findGroup("Mapping")["PixelResolution"] = toString(pixRes2); + pvl.findGroup("Mapping")["PixelResolution"] = Isis::toString(pixRes2); cout << "BasicMapping PVL: " << endl << pvl << endl << endl; cout << "FocalLength: " << c->FocalLength() << endl; @@ -327,19 +327,19 @@ int main() { minLat *= 100; minLat = round(minLat); minLat /= 100; - camMap.findGroup("Mapping")["MinimumLatitude"] = toString(minLat); + camMap.findGroup("Mapping")["MinimumLatitude"] = Isis::toString(minLat); double pixRes = camMap.findGroup("Mapping")["PixelResolution"]; pixRes *= 100; pixRes = round(pixRes); pixRes /= 100; - camMap.findGroup("Mapping")["PixelResolution"] = toString(pixRes); + camMap.findGroup("Mapping")["PixelResolution"] = Isis::toString(pixRes); double minLon = camMap.findGroup("Mapping")["MinimumLongitude"]; minLon *= 100000000000.0; minLon = round(minLon); minLon /= 100000000000.0; - camMap.findGroup("Mapping")["MinimumLongitude"] = toString(minLon); + camMap.findGroup("Mapping")["MinimumLongitude"] = Isis::toString(minLon); cout << camMap << endl; diff --git a/isis/src/base/objs/CameraPointInfo/CameraPointInfo.cpp b/isis/src/base/objs/CameraPointInfo/CameraPointInfo.cpp index 46f417337c..492e225711 100644 --- a/isis/src/base/objs/CameraPointInfo/CameraPointInfo.cpp +++ b/isis/src/base/objs/CameraPointInfo/CameraPointInfo.cpp @@ -366,15 +366,15 @@ namespace Isis { double spB[3], sB[3]; m_camera->instrumentPosition(spB); - gp->findKeyword("SpacecraftPosition").addValue(toString(spB[0]), "km"); - gp->findKeyword("SpacecraftPosition").addValue(toString(spB[1]), "km"); - gp->findKeyword("SpacecraftPosition").addValue(toString(spB[2]), "km"); + gp->findKeyword("SpacecraftPosition").addValue(Isis::toString(spB[0]), "km"); + gp->findKeyword("SpacecraftPosition").addValue(Isis::toString(spB[1]), "km"); + gp->findKeyword("SpacecraftPosition").addValue(Isis::toString(spB[2]), "km"); try { m_camera->sunPosition(sB); - gp->findKeyword("SunPosition").addValue(toString(sB[0]), "km"); - gp->findKeyword("SunPosition").addValue(toString(sB[1]), "km"); - gp->findKeyword("SunPosition").addValue(toString(sB[2]), "km"); + gp->findKeyword("SunPosition").addValue(Isis::toString(sB[0]), "km"); + gp->findKeyword("SunPosition").addValue(Isis::toString(sB[1]), "km"); + gp->findKeyword("SunPosition").addValue(Isis::toString(sB[2]), "km"); } catch (IException &e) { gp->findKeyword("SunPosition").addValue("Null"); @@ -383,15 +383,15 @@ namespace Isis { } std::vectorlookB = m_camera->lookDirectionBodyFixed(); - gp->findKeyword("LookDirectionBodyFixed").addValue(toString(lookB[0]), "DEGREE"); - gp->findKeyword("LookDirectionBodyFixed").addValue(toString(lookB[1]), "DEGREE"); - gp->findKeyword("LookDirectionBodyFixed").addValue(toString(lookB[2]), "DEGREE"); + gp->findKeyword("LookDirectionBodyFixed").addValue(Isis::toString(lookB[0]), "DEGREE"); + gp->findKeyword("LookDirectionBodyFixed").addValue(Isis::toString(lookB[1]), "DEGREE"); + gp->findKeyword("LookDirectionBodyFixed").addValue(Isis::toString(lookB[2]), "DEGREE"); try { std::vectorlookJ = m_camera->lookDirectionJ2000(); - gp->findKeyword("LookDirectionJ2000").addValue(toString(lookJ[0]), "DEGREE"); - gp->findKeyword("LookDirectionJ2000").addValue(toString(lookJ[1]), "DEGREE"); - gp->findKeyword("LookDirectionJ2000").addValue(toString(lookJ[2]), "DEGREE"); + gp->findKeyword("LookDirectionJ2000").addValue(Isis::toString(lookJ[0]), "DEGREE"); + gp->findKeyword("LookDirectionJ2000").addValue(Isis::toString(lookJ[1]), "DEGREE"); + gp->findKeyword("LookDirectionJ2000").addValue(Isis::toString(lookJ[2]), "DEGREE"); } catch (IException &e) { gp->findKeyword("LookDirectionJ2000").addValue("Null"); @@ -402,9 +402,9 @@ namespace Isis { try { double lookC[3]; m_camera->LookDirection(lookC); - gp->findKeyword("LookDirectionCamera").addValue(toString(lookC[0]), "DEGREE"); - gp->findKeyword("LookDirectionCamera").addValue(toString(lookC[1]), "DEGREE"); - gp->findKeyword("LookDirectionCamera").addValue(toString(lookC[2]), "DEGREE"); + gp->findKeyword("LookDirectionCamera").addValue(Isis::toString(lookC[0]), "DEGREE"); + gp->findKeyword("LookDirectionCamera").addValue(Isis::toString(lookC[1]), "DEGREE"); + gp->findKeyword("LookDirectionCamera").addValue(Isis::toString(lookC[2]), "DEGREE"); } catch (IException &e) { gp->findKeyword("LookDirectionCamera").addValue("Null"); @@ -416,10 +416,10 @@ namespace Isis { // Set all keywords that still have valid information gp->findKeyword("Error").setValue(error); gp->findKeyword("FileName").setValue(m_currentCube->fileName().toStdString()); - gp->findKeyword("Sample").setValue(toString(m_camera->Sample())); - gp->findKeyword("Line").setValue(toString(m_camera->Line())); + gp->findKeyword("Sample").setValue(Isis::toString(m_camera->Sample())); + gp->findKeyword("Line").setValue(Isis::toString(m_camera->Line())); gp->findKeyword("EphemerisTime").setValue( - toString(m_camera->time().Et()), "seconds"); + Isis::toString(m_camera->time().Et()), "seconds"); gp->findKeyword("EphemerisTime").addComment("Time"); QString utc = m_camera->time().UTC(); gp->findKeyword("UTC").setValue(utc.toStdString()); @@ -442,25 +442,25 @@ namespace Isis { { gp->findKeyword("FileName").setValue(m_currentCube->fileName().toStdString()); - gp->findKeyword("Sample").setValue(toString(m_camera->Sample())); - gp->findKeyword("Line").setValue(toString(m_camera->Line())); + gp->findKeyword("Sample").setValue(Isis::toString(m_camera->Sample())); + gp->findKeyword("Line").setValue(Isis::toString(m_camera->Line())); gp->findKeyword("PixelValue").setValue(PixelToString(b[0])); try { - gp->findKeyword("RightAscension").setValue(toString( + gp->findKeyword("RightAscension").setValue(Isis::toString( m_camera->RightAscension()), "DEGREE"); } catch (IException &e) { gp->findKeyword("RightAscension").setValue("Null"); } try { - gp->findKeyword("Declination").setValue(toString( + gp->findKeyword("Declination").setValue(Isis::toString( m_camera->Declination()), "DEGREE"); } catch (IException &e) { gp->findKeyword("Declination").setValue("Null"); } ocentricLat = m_camera->UniversalLatitude(); - gp->findKeyword("PlanetocentricLatitude").setValue(toString(ocentricLat), "DEGREE"); + gp->findKeyword("PlanetocentricLatitude").setValue(Isis::toString(ocentricLat), "DEGREE"); // Convert lat to planetographic Distance radii[3]; @@ -468,82 +468,82 @@ namespace Isis { ographicLat = TProjection::ToPlanetographic(ocentricLat, radii[0].kilometers(), radii[2].kilometers()); - gp->findKeyword("PlanetographicLatitude").setValue(toString(ographicLat), "DEGREE"); + gp->findKeyword("PlanetographicLatitude").setValue(Isis::toString(ographicLat), "DEGREE"); pe360Lon = m_camera->UniversalLongitude(); - gp->findKeyword("PositiveEast360Longitude").setValue(toString(pe360Lon), "DEGREE"); + gp->findKeyword("PositiveEast360Longitude").setValue(Isis::toString(pe360Lon), "DEGREE"); //Convert lon to -180 - 180 range - gp->findKeyword("PositiveEast180Longitude").setValue(toString( + gp->findKeyword("PositiveEast180Longitude").setValue(Isis::toString( TProjection::To180Domain(pe360Lon)), "DEGREE"); //Convert lon to positive west pw360Lon = TProjection::ToPositiveWest(pe360Lon, 360); - gp->findKeyword("PositiveWest360Longitude").setValue(toString(pw360Lon), "DEGREE"); + gp->findKeyword("PositiveWest360Longitude").setValue(Isis::toString(pw360Lon), "DEGREE"); //Convert pwlon to -180 - 180 range gp->findKeyword("PositiveWest180Longitude").setValue( - toString( TProjection::To180Domain(pw360Lon)), "DEGREE"); + Isis::toString( TProjection::To180Domain(pw360Lon)), "DEGREE"); m_camera->Coordinate(pB); - gp->findKeyword("BodyFixedCoordinate").addValue(toString(pB[0]), "km"); - gp->findKeyword("BodyFixedCoordinate").addValue(toString(pB[1]), "km"); - gp->findKeyword("BodyFixedCoordinate").addValue(toString(pB[2]), "km"); + gp->findKeyword("BodyFixedCoordinate").addValue(Isis::toString(pB[0]), "km"); + gp->findKeyword("BodyFixedCoordinate").addValue(Isis::toString(pB[1]), "km"); + gp->findKeyword("BodyFixedCoordinate").addValue(Isis::toString(pB[2]), "km"); - gp->findKeyword("LocalRadius").setValue(toString( + gp->findKeyword("LocalRadius").setValue(Isis::toString( m_camera->LocalRadius().meters()), "meters"); - gp->findKeyword("SampleResolution").setValue(toString( + gp->findKeyword("SampleResolution").setValue(Isis::toString( m_camera->SampleResolution()), "meters/pixel"); - gp->findKeyword("LineResolution").setValue(toString( + gp->findKeyword("LineResolution").setValue(Isis::toString( m_camera->LineResolution()), "meters/pixel"); gp->findKeyword("ObliqueDetectorResolution").setValue( - toString(m_camera->ObliqueDetectorResolution()),"meters"); + Isis::toString(m_camera->ObliqueDetectorResolution()),"meters"); gp->findKeyword("ObliqueLineResolution").setValue( - toString(m_camera->ObliqueLineResolution()),"meters"); + Isis::toString(m_camera->ObliqueLineResolution()),"meters"); gp->findKeyword("ObliqueSampleResolution").setValue( - toString(m_camera->ObliqueSampleResolution()),"meters"); + Isis::toString(m_camera->ObliqueSampleResolution()),"meters"); gp->findKeyword("ObliquePixelResolution").setValue( - toString(m_camera->ObliquePixelResolution()), "meters/pix"); + Isis::toString(m_camera->ObliquePixelResolution()), "meters/pix"); //body fixed m_camera->instrumentPosition(spB); - gp->findKeyword("SpacecraftPosition").addValue(toString(spB[0]), "km"); - gp->findKeyword("SpacecraftPosition").addValue(toString(spB[1]), "km"); - gp->findKeyword("SpacecraftPosition").addValue(toString(spB[2]), "km"); + gp->findKeyword("SpacecraftPosition").addValue(Isis::toString(spB[0]), "km"); + gp->findKeyword("SpacecraftPosition").addValue(Isis::toString(spB[1]), "km"); + gp->findKeyword("SpacecraftPosition").addValue(Isis::toString(spB[2]), "km"); gp->findKeyword("SpacecraftPosition").addComment("Spacecraft Information"); double spacecraftAzi = m_camera->SpacecraftAzimuth(); if (Isis::IsValidPixel(spacecraftAzi)) { - gp->findKeyword("SpacecraftAzimuth").setValue(toString(spacecraftAzi), "DEGREE"); + gp->findKeyword("SpacecraftAzimuth").setValue(Isis::toString(spacecraftAzi), "DEGREE"); } else { gp->findKeyword("SpacecraftAzimuth").setValue("NULL"); } - gp->findKeyword("SlantDistance").setValue(toString( + gp->findKeyword("SlantDistance").setValue(Isis::toString( m_camera->SlantDistance()), "km"); - gp->findKeyword("TargetCenterDistance").setValue(toString( + gp->findKeyword("TargetCenterDistance").setValue(Isis::toString( m_camera->targetCenterDistance()), "km"); m_camera->subSpacecraftPoint(ssplat, ssplon); - gp->findKeyword("SubSpacecraftLatitude").setValue(toString(ssplat), "DEGREE"); - gp->findKeyword("SubSpacecraftLongitude").setValue(toString(ssplon), "DEGREE"); - gp->findKeyword("SpacecraftAltitude").setValue(toString( + gp->findKeyword("SubSpacecraftLatitude").setValue(Isis::toString(ssplat), "DEGREE"); + gp->findKeyword("SubSpacecraftLongitude").setValue(Isis::toString(ssplon), "DEGREE"); + gp->findKeyword("SpacecraftAltitude").setValue(Isis::toString( m_camera->SpacecraftAltitude()), "km"); - gp->findKeyword("OffNadirAngle").setValue(toString( + gp->findKeyword("OffNadirAngle").setValue(Isis::toString( m_camera->OffNadirAngle()), "DEGREE"); double subspcgrdaz = m_camera->GroundAzimuth(m_camera->UniversalLatitude(), m_camera->UniversalLongitude(), ssplat, ssplon); gp->findKeyword("SubSpacecraftGroundAzimuth").setValue( - toString(subspcgrdaz), "DEGREE"); + Isis::toString(subspcgrdaz), "DEGREE"); try { m_camera->sunPosition(sB); - gp->findKeyword("SunPosition").addValue(toString(sB[0]), "km"); - gp->findKeyword("SunPosition").addValue(toString(sB[1]), "km"); - gp->findKeyword("SunPosition").addValue(toString(sB[2]), "km"); + gp->findKeyword("SunPosition").addValue(Isis::toString(sB[0]), "km"); + gp->findKeyword("SunPosition").addValue(Isis::toString(sB[1]), "km"); + gp->findKeyword("SunPosition").addValue(Isis::toString(sB[2]), "km"); gp->findKeyword("SunPosition").addComment("Sun Information"); } catch (IException &e) { @@ -556,7 +556,7 @@ namespace Isis { try { double sunAzi = m_camera->SunAzimuth(); if (Isis::IsValidPixel(sunAzi)) { - gp->findKeyword("SubSolarAzimuth").setValue(toString(sunAzi), "DEGREE"); + gp->findKeyword("SubSolarAzimuth").setValue(Isis::toString(sunAzi), "DEGREE"); } else { gp->findKeyword("SubSolarAzimuth").setValue("NULL"); @@ -567,7 +567,7 @@ namespace Isis { } try { - gp->findKeyword("SolarDistance").setValue(toString( + gp->findKeyword("SolarDistance").setValue(Isis::toString( m_camera->SolarDistance()), "AU"); } catch(IException &e) { @@ -576,14 +576,14 @@ namespace Isis { try { double sslat, sslon; m_camera->subSolarPoint(sslat, sslon); - gp->findKeyword("SubSolarLatitude").setValue(toString(sslat), "DEGREE"); - gp->findKeyword("SubSolarLongitude").setValue(toString(sslon), "DEGREE"); + gp->findKeyword("SubSolarLatitude").setValue(Isis::toString(sslat), "DEGREE"); + gp->findKeyword("SubSolarLongitude").setValue(Isis::toString(sslon), "DEGREE"); try { double subsolgrdaz = m_camera->GroundAzimuth(m_camera->UniversalLatitude(), m_camera->UniversalLongitude(), sslat, sslon); - gp->findKeyword("SubSolarGroundAzimuth").setValue(toString(subsolgrdaz), "DEGREE"); + gp->findKeyword("SubSolarGroundAzimuth").setValue(Isis::toString(subsolgrdaz), "DEGREE"); } catch(IException &e) { gp->findKeyword("SubSolarGroundAzimuth").setValue("NULL"); @@ -595,35 +595,35 @@ namespace Isis { gp->findKeyword("SubSolarGroundAzimuth").setValue("NULL"); } - gp->findKeyword("Phase").setValue(toString(m_camera->PhaseAngle()), "DEGREE"); + gp->findKeyword("Phase").setValue(Isis::toString(m_camera->PhaseAngle()), "DEGREE"); gp->findKeyword("Phase").addComment("Illumination and Other"); - gp->findKeyword("Incidence").setValue(toString( + gp->findKeyword("Incidence").setValue(Isis::toString( m_camera->IncidenceAngle()), "DEGREE"); - gp->findKeyword("Emission").setValue(toString( + gp->findKeyword("Emission").setValue(Isis::toString( m_camera->EmissionAngle()), "DEGREE"); double northAzi = m_camera->NorthAzimuth(); if (Isis::IsValidPixel(northAzi)) { - gp->findKeyword("NorthAzimuth").setValue(toString(northAzi), "DEGREE"); + gp->findKeyword("NorthAzimuth").setValue(Isis::toString(northAzi), "DEGREE"); } else { gp->findKeyword("NorthAzimuth").setValue("NULL"); } - gp->findKeyword("EphemerisTime").setValue(toString( + gp->findKeyword("EphemerisTime").setValue(Isis::toString( m_camera->time().Et()), "seconds"); gp->findKeyword("EphemerisTime").addComment("Time"); utc = m_camera->time().UTC(); gp->findKeyword("UTC").setValue(utc.toStdString()); try { - gp->findKeyword("LocalSolarTime").setValue(toString( + gp->findKeyword("LocalSolarTime").setValue(Isis::toString( m_camera->LocalSolarTime()), "hour"); } catch (IException &e) { gp->findKeyword("LocalSolarTime").setValue("Null"); } try { - gp->findKeyword("SolarLongitude").setValue(toString( + gp->findKeyword("SolarLongitude").setValue(Isis::toString( m_camera->solarLongitude().degrees()), "DEGREE"); } catch (IException &e) { @@ -631,16 +631,16 @@ namespace Isis { } std::vectorlookB = m_camera->lookDirectionBodyFixed(); - gp->findKeyword("LookDirectionBodyFixed").addValue(toString(lookB[0]), "DEGREE"); - gp->findKeyword("LookDirectionBodyFixed").addValue(toString(lookB[1]), "DEGREE"); - gp->findKeyword("LookDirectionBodyFixed").addValue(toString(lookB[2]), "DEGREE"); + gp->findKeyword("LookDirectionBodyFixed").addValue(Isis::toString(lookB[0]), "DEGREE"); + gp->findKeyword("LookDirectionBodyFixed").addValue(Isis::toString(lookB[1]), "DEGREE"); + gp->findKeyword("LookDirectionBodyFixed").addValue(Isis::toString(lookB[2]), "DEGREE"); gp->findKeyword("LookDirectionBodyFixed").addComment("Look Direction Unit Vectors in Body Fixed, J2000, and Camera Coordinate Systems."); try { std::vectorlookJ = m_camera->lookDirectionJ2000(); - gp->findKeyword("LookDirectionJ2000").addValue(toString(lookJ[0]), "DEGREE"); - gp->findKeyword("LookDirectionJ2000").addValue(toString(lookJ[1]), "DEGREE"); - gp->findKeyword("LookDirectionJ2000").addValue(toString(lookJ[2]), "DEGREE"); + gp->findKeyword("LookDirectionJ2000").addValue(Isis::toString(lookJ[0]), "DEGREE"); + gp->findKeyword("LookDirectionJ2000").addValue(Isis::toString(lookJ[1]), "DEGREE"); + gp->findKeyword("LookDirectionJ2000").addValue(Isis::toString(lookJ[2]), "DEGREE"); } catch (IException &e) { gp->findKeyword("LookDirectionJ2000").addValue("Null"); @@ -651,9 +651,9 @@ namespace Isis { try { double lookC[3]; m_camera->LookDirection(lookC); - gp->findKeyword("LookDirectionCamera").addValue(toString(lookC[0]), "DEGREE"); - gp->findKeyword("LookDirectionCamera").addValue(toString(lookC[1]), "DEGREE"); - gp->findKeyword("LookDirectionCamera").addValue(toString(lookC[2]), "DEGREE"); + gp->findKeyword("LookDirectionCamera").addValue(Isis::toString(lookC[0]), "DEGREE"); + gp->findKeyword("LookDirectionCamera").addValue(Isis::toString(lookC[1]), "DEGREE"); + gp->findKeyword("LookDirectionCamera").addValue(Isis::toString(lookC[2]), "DEGREE"); } catch (IException &e) { gp->findKeyword("LookDirectionCamera").addValue("Null"); diff --git a/isis/src/base/objs/CameraPointInfo/unitTest.cpp b/isis/src/base/objs/CameraPointInfo/unitTest.cpp index 37fb217fce..f95f5ae832 100644 --- a/isis/src/base/objs/CameraPointInfo/unitTest.cpp +++ b/isis/src/base/objs/CameraPointInfo/unitTest.cpp @@ -45,15 +45,15 @@ int main() { void LowerPrecision(PvlKeyword &keyword) { if (keyword.name() != "LookDirectionCamera") { - double value = IString::ToDouble(keyword[0]); + double value = Isis::toDouble(keyword[0]); value = round(value * 1000) / 1000.0; - keyword[0] = toString(value); + keyword[0] = Isis::toString(value); } else { for (int i = 0; i < 3; i++) { - double value = IString::ToDouble(keyword[i]); + double value = Isis::toDouble(keyword[i]); value = round(value * 10000000000) / 10000000000.0; - keyword[i] = toString(value); + keyword[i] = Isis::toString(value); } } } diff --git a/isis/src/base/objs/CameraStatistics/CameraStatistics.cpp b/isis/src/base/objs/CameraStatistics/CameraStatistics.cpp index 2f4b515bb1..454b51e416 100644 --- a/isis/src/base/objs/CameraStatistics/CameraStatistics.cpp +++ b/isis/src/base/objs/CameraStatistics/CameraStatistics.cpp @@ -284,7 +284,7 @@ namespace Isis { return (PvlKeyword(keyname.toStdString(), "NULL")); } else { - return (PvlKeyword(keyname.toStdString(), toString(value), unit.toStdString())); + return (PvlKeyword(keyname.toStdString(), Isis::toString(value), unit.toStdString())); } } @@ -368,8 +368,8 @@ namespace Isis { // object PvlGroup pUser("User Parameters"); if (m_filename != "") pUser += PvlKeyword("Filename", m_filename.toStdString()); - pUser += PvlKeyword("Linc", toString(m_linc)); - pUser += PvlKeyword("Sinc", toString(m_sinc)); + pUser += PvlKeyword("Linc", Isis::toString(m_linc)); + pUser += PvlKeyword("Sinc", Isis::toString(m_sinc)); PvlGroup pLat("Latitude"); pLat += constructKeyword("LatitudeMinimum", m_latStat->Minimum()); diff --git a/isis/src/base/objs/CameraStatistics/unitTest.cpp b/isis/src/base/objs/CameraStatistics/unitTest.cpp index 345adb1ab9..f793bf9ee4 100644 --- a/isis/src/base/objs/CameraStatistics/unitTest.cpp +++ b/isis/src/base/objs/CameraStatistics/unitTest.cpp @@ -37,7 +37,7 @@ int main(int argc, char *argv[]) { for (int j = 0; j < group.keywords(); j++) { PvlKeyword &keyword = group[j]; - cout << " " << keyword.name() << " = " << IString::ToDouble(keyword[0]) << endl; + cout << " " << keyword.name() << " = " << Isis::toDouble(keyword[0]) << endl; } cout << endl; diff --git a/isis/src/base/objs/Cube/Cube.cpp b/isis/src/base/objs/Cube/Cube.cpp index 35d7851b3c..2bd9a084af 100644 --- a/isis/src/base/objs/Cube/Cube.cpp +++ b/isis/src/base/objs/Cube/Cube.cpp @@ -412,8 +412,8 @@ namespace Isis { } if (m_samples < 1 || m_lines < 1 || m_bands < 1) { - std::string msg = "Number of samples [" + toString(m_samples) + - "], lines [" + toString(m_lines) + "], or bands [" + toString(m_bands) + + std::string msg = "Number of samples [" + Isis::toString(m_samples) + + "], lines [" + Isis::toString(m_lines) + "], or bands [" + Isis::toString(m_bands) + "] cannot be less than 1"; throw IException(IException::Programmer, msg, _FILEINFO_); } @@ -440,11 +440,11 @@ namespace Isis { if (size > maxSizePreference) { std::string msg; msg += "The cube you are attempting to create [" + cubeFileName.toStdString() + "] is [" - + toString(size) + "GB]. This is larger than the current allowed " - "size of [" + toString(maxSizePreference) + "GB]. The cube " - "dimensions were (S,L,B) [" + toString(m_samples) + ", " + - toString(m_lines) + ", " + toString(m_bands) + "] with [" + - toString(SizeOf(m_pixelType)) + "] bytes per pixel. If you still " + + Isis::toString(size) + "GB]. This is larger than the current allowed " + "size of [" + Isis::toString(maxSizePreference) + "GB]. The cube " + "dimensions were (S,L,B) [" + Isis::toString(m_samples) + ", " + + Isis::toString(m_lines) + ", " + Isis::toString(m_bands) + "] with [" + + Isis::toString(SizeOf(m_pixelType)) + "] bytes per pixel. If you still " "wish to create this cube, the maximum value can be changed in your personal " "preference file located in [~/.Isis/IsisPreferences] within the group " "CubeCustomization, keyword MaximumSize. If you do not have an ISISPreference file, " @@ -464,13 +464,13 @@ namespace Isis { // See if we have attached or detached labels if (m_attached) { // StartByte is 1-based (why!!) so we need to do + 1 - core += PvlKeyword("StartByte", toString(m_labelBytes + 1)); + core += PvlKeyword("StartByte", Isis::toString(m_labelBytes + 1)); m_labelFileName = new FileName(cubFile); m_dataFileName = new FileName(cubFile); m_labelFile = new QFile(QString::fromStdString(m_labelFileName->expanded())); } else { - core += PvlKeyword("StartByte", toString(1)); + core += PvlKeyword("StartByte", Isis::toString(1)); core += PvlKeyword("^Core", cubFile.name()); m_dataFileName = new FileName(cubFile); m_dataFile = new QFile(QString::fromStdString(realDataFileName().expanded())); @@ -483,9 +483,9 @@ namespace Isis { // Create the size of the core PvlGroup dims("Dimensions"); - dims += PvlKeyword("Samples", toString(m_samples)); - dims += PvlKeyword("Lines", toString(m_lines)); - dims += PvlKeyword("Bands", toString(m_bands)); + dims += PvlKeyword("Samples", Isis::toString(m_samples)); + dims += PvlKeyword("Lines", Isis::toString(m_lines)); + dims += PvlKeyword("Bands", Isis::toString(m_bands)); core.addGroup(dims); // Create the pixel type @@ -494,8 +494,8 @@ namespace Isis { // And the byte ordering ptype += PvlKeyword("ByteOrder", ByteOrderName(m_byteOrder)); - ptype += PvlKeyword("Base", toString(m_base)); - ptype += PvlKeyword("Multiplier", toString(m_multiplier)); + ptype += PvlKeyword("Base", Isis::toString(m_base)); + ptype += PvlKeyword("Multiplier", Isis::toString(m_multiplier)); core.addGroup(ptype); } else { @@ -516,7 +516,7 @@ namespace Isis { // Setup storage reserved for the label PvlObject lbl("Label"); - lbl += PvlKeyword("Bytes", toString(m_labelBytes)); + lbl += PvlKeyword("Bytes", Isis::toString(m_labelBytes)); m_label->addObject(lbl); const PvlGroup &pref = @@ -1490,7 +1490,7 @@ namespace Isis { bodyTable.Label()["Kernels"].addValue(pckKeyword[i]); bodyTable.Label() += PvlKeyword("SolarLongitude", - toString(spice.solarLongitude().degrees())); + Isis::toString(spice.solarLongitude().degrees())); this->write(bodyTable); Table sunTable = spice.sunPosition()->Cache("SunPosition"); @@ -1773,7 +1773,7 @@ namespace Isis { if (m_virtualBandList) { if ((virtualBand < 1) || (virtualBand > m_virtualBandList->size())) { - std::string msg = "Out of array bounds [" + toString(virtualBand) + "]"; + std::string msg = "Out of array bounds [" + Isis::toString(virtualBand) + "]"; throw IException(IException::Programmer, msg, _FILEINFO_); } physicalBand = m_virtualBandList->at(virtualBand - 1); @@ -2091,7 +2091,7 @@ namespace Isis { } // Change the number of bands in the labels of the cube - if (m_virtualBandList && core.hasGroup("Dimensions")) core.findGroup("Dimensions")["Bands"] = toString(m_virtualBandList->size()); + if (m_virtualBandList && core.hasGroup("Dimensions")) core.findGroup("Dimensions")["Bands"] = Isis::toString(m_virtualBandList->size()); } diff --git a/isis/src/base/objs/Cube/CubeBsqHandler.cpp b/isis/src/base/objs/Cube/CubeBsqHandler.cpp index a880ba066b..7e71a39ea6 100644 --- a/isis/src/base/objs/Cube/CubeBsqHandler.cpp +++ b/isis/src/base/objs/Cube/CubeBsqHandler.cpp @@ -90,8 +90,8 @@ namespace Isis { if(!success) { IString msg = "Reading from the file [" + dataFile->fileName().toStdString() + "] " "failed with reading [" + - toString(chunkToFill.getByteCount()) + - "] bytes at position [" + toString(startByte) + "]"; + Isis::toString(chunkToFill.getByteCount()) + + "] bytes at position [" + Isis::toString(startByte) + "]"; throw IException(IException::Io, msg, _FILEINFO_); } } @@ -114,8 +114,8 @@ namespace Isis { if(!success) { IString msg = "Writing to the file [" + dataFile->fileName().toStdString() + "] " "failed with writing [" + - toString(chunkToWrite.getByteCount()) + - "] bytes at position [" + toString(startByte) + "]"; + Isis::toString(chunkToWrite.getByteCount()) + + "] bytes at position [" + Isis::toString(startByte) + "]"; throw IException(IException::Io, msg, _FILEINFO_); } } diff --git a/isis/src/base/objs/Cube/CubeTileHandler.cpp b/isis/src/base/objs/Cube/CubeTileHandler.cpp index f6e257cc67..319b2d327e 100644 --- a/isis/src/base/objs/Cube/CubeTileHandler.cpp +++ b/isis/src/base/objs/Cube/CubeTileHandler.cpp @@ -67,9 +67,9 @@ namespace Isis { PvlObject &core = labels.findObject("IsisCube").findObject("Core"); core.addKeyword(PvlKeyword("Format", "Tile"), PvlContainer::Replace); - core.addKeyword(PvlKeyword("TileSamples", toString(getSampleCountInChunk())), + core.addKeyword(PvlKeyword("TileSamples", Isis::toString(getSampleCountInChunk())), PvlContainer::Replace); - core.addKeyword(PvlKeyword("TileLines", toString(getLineCountInChunk())), + core.addKeyword(PvlKeyword("TileLines", Isis::toString(getLineCountInChunk())), PvlContainer::Replace); } @@ -92,8 +92,8 @@ namespace Isis { if(!success) { IString msg = "Reading from the file [" + dataFile->fileName().toStdString() + "] " "failed with reading [" + - toString(chunkToFill.getByteCount()) + - "] bytes at position [" + toString(startByte) + "]"; + Isis::toString(chunkToFill.getByteCount()) + + "] bytes at position [" + Isis::toString(startByte) + "]"; throw IException(IException::Io, msg, _FILEINFO_); } } @@ -115,8 +115,8 @@ namespace Isis { if(!success) { IString msg = "Writing to the file [" + dataFile->fileName().toStdString() + "] " "failed with writing [" + - toString(chunkToWrite.getByteCount()) + - "] bytes at position [" + toString(startByte) + "]"; + Isis::toString(chunkToWrite.getByteCount()) + + "] bytes at position [" + Isis::toString(startByte) + "]"; throw IException(IException::Io, msg, _FILEINFO_); } } diff --git a/isis/src/base/objs/CubeAttribute/CubeAttribute.h b/isis/src/base/objs/CubeAttribute/CubeAttribute.h index c76474f247..05db708af7 100644 --- a/isis/src/base/objs/CubeAttribute/CubeAttribute.h +++ b/isis/src/base/objs/CubeAttribute/CubeAttribute.h @@ -54,7 +54,7 @@ namespace Isis { if(labelType == DetachedLabel) return "Detached"; if(labelType == ExternalLabel) return "External"; - std::string msg = "Invalid label attachment type [" + toString(labelType) + "]"; + std::string msg = "Invalid label attachment type [" + Isis::toString(labelType) + "]"; throw IException(IException::Programmer, msg, _FILEINFO_); } diff --git a/isis/src/base/objs/CubeDataThread/CubeDataThread.cpp b/isis/src/base/objs/CubeDataThread/CubeDataThread.cpp index dd32cee25f..59842e5e28 100644 --- a/isis/src/base/objs/CubeDataThread/CubeDataThread.cpp +++ b/isis/src/base/objs/CubeDataThread/CubeDataThread.cpp @@ -197,7 +197,7 @@ namespace Isis { if (i == p_managedCubes->end()) { p_threadSafeMutex->unlock(); std::string msg = "CubeDataThread::RemoveCube failed because cube ID ["; - msg += std::to_string(cubeId); + msg += Isis::toString(cubeId); msg += "] not found"; throw IException(IException::Programmer, msg, _FILEINFO_); } @@ -205,7 +205,7 @@ namespace Isis { if (p_managedDataSources->contains(cubeId)) { p_threadSafeMutex->unlock(); std::string msg = "CubeDataThread::RemoveCube failed cube ID ["; - msg += std::to_string(cubeId); + msg += Isis::toString(cubeId); msg += "] has requested Bricks"; throw IException(IException::Programmer, msg, _FILEINFO_); } diff --git a/isis/src/base/objs/CubeStretch/CubeStretch.cpp b/isis/src/base/objs/CubeStretch/CubeStretch.cpp index 45ac2185f2..12717162c0 100644 --- a/isis/src/base/objs/CubeStretch/CubeStretch.cpp +++ b/isis/src/base/objs/CubeStretch/CubeStretch.cpp @@ -65,7 +65,7 @@ namespace Isis { setName(QString::fromStdString(blob.Label()["Name"][0])); setType(QString::fromStdString(blob.Label()["StretchType"][0])); Parse(QString::fromStdString(stringFromBuffer)); - setBandNumber(IString::ToInteger(blob.Label()["BandNumber"][0])); + setBandNumber(Isis::toInt(blob.Label()["BandNumber"][0])); } @@ -86,7 +86,7 @@ namespace Isis { blob.Label()["Name"] = getName().toStdString(); blob.Label() += PvlKeyword("StretchType", getType().toStdString()); - blob.Label() += PvlKeyword("BandNumber", toString(getBandNumber())); + blob.Label() += PvlKeyword("BandNumber", Isis::toString(getBandNumber())); std::string blobString = Text().toStdString(); blob.setData(blobString.c_str(), blobString.size()); return blob; diff --git a/isis/src/base/objs/DemShape/unitTest.cpp b/isis/src/base/objs/DemShape/unitTest.cpp index 06af88a2a6..31c6914750 100644 --- a/isis/src/base/objs/DemShape/unitTest.cpp +++ b/isis/src/base/objs/DemShape/unitTest.cpp @@ -74,7 +74,7 @@ int main() { cout << " Shape name is " << shape.name().toStdString() << endl; cout << " Shape name is " << defaultShape.name().toStdString() << endl; - cout << " Shape is DEM type? " << toString(shape.isDEM()) << endl; + cout << " Shape is DEM type? " << Isis::toString((bool)shape.isDEM()) << endl; cout << endl << " Testing method intersectSurface..." << endl; cout << " Do we have an intersection? " << shape.hasIntersection() << endl; diff --git a/isis/src/base/objs/EllipsoidShape/unitTest.cpp b/isis/src/base/objs/EllipsoidShape/unitTest.cpp index 1e10d6b7df..91c8d11e3e 100644 --- a/isis/src/base/objs/EllipsoidShape/unitTest.cpp +++ b/isis/src/base/objs/EllipsoidShape/unitTest.cpp @@ -61,7 +61,7 @@ int main() { cout << " Shape name is " << shape.name().toStdString() << endl; cout << " Shape2 name is " << shape2.name().toStdString() << endl; - cout << " Shape is DEM type?" << toString(shape.isDEM()) << endl; + cout << " Shape is DEM type?" << Isis::toString((bool)shape.isDEM()) << endl; std::vector sB(3); sB[0] = -2399.54; diff --git a/isis/src/base/objs/Enlarge/Enlarge.cpp b/isis/src/base/objs/Enlarge/Enlarge.cpp index bae8608458..a9388cc632 100644 --- a/isis/src/base/objs/Enlarge/Enlarge.cpp +++ b/isis/src/base/objs/Enlarge/Enlarge.cpp @@ -120,16 +120,16 @@ namespace Isis { // Information will be added to it if the Mapping or Instrument // groups are deleted from the output image label PvlGroup resultsGrp("Results"); - resultsGrp += PvlKeyword("InputLines", toString(iNumLines)); - resultsGrp += PvlKeyword("InputSamples", toString(iNumSamples)); - resultsGrp += PvlKeyword("StartingLine", toString((int)mdStartLine)); - resultsGrp += PvlKeyword("StartingSample", toString((int)mdStartSample)); - resultsGrp += PvlKeyword("EndingLine", toString((int)mdEndLine)); - resultsGrp += PvlKeyword("EndingSample", toString((int)mdEndSample)); - resultsGrp += PvlKeyword("LineIncrement", toString(1. / mdLineScale)); - resultsGrp += PvlKeyword("SampleIncrement", toString(1. / mdSampleScale)); - resultsGrp += PvlKeyword("OutputLines", toString(miOutputLines)); - resultsGrp += PvlKeyword("OutputSamples", toString(miOutputSamples)); + resultsGrp += PvlKeyword("InputLines", Isis::toString(iNumLines)); + resultsGrp += PvlKeyword("InputSamples", Isis::toString(iNumSamples)); + resultsGrp += PvlKeyword("StartingLine", Isis::toString((int)mdStartLine)); + resultsGrp += PvlKeyword("StartingSample", Isis::toString((int)mdStartSample)); + resultsGrp += PvlKeyword("EndingLine", Isis::toString((int)mdEndLine)); + resultsGrp += PvlKeyword("EndingSample", Isis::toString((int)mdEndSample)); + resultsGrp += PvlKeyword("LineIncrement", Isis::toString(1. / mdLineScale)); + resultsGrp += PvlKeyword("SampleIncrement", Isis::toString(1. / mdSampleScale)); + resultsGrp += PvlKeyword("OutputLines", Isis::toString(miOutputLines)); + resultsGrp += PvlKeyword("OutputSamples", Isis::toString(miOutputSamples)); SubArea subArea; subArea.SetSubArea(mInCube->lineCount(), mInCube->sampleCount(), (int)mdStartLine, (int)mdStartSample, diff --git a/isis/src/base/objs/Equalization/Equalization.cpp b/isis/src/base/objs/Equalization/Equalization.cpp index bc08a8d56a..4fa9ac8573 100644 --- a/isis/src/base/objs/Equalization/Equalization.cpp +++ b/isis/src/base/objs/Equalization/Equalization.cpp @@ -332,16 +332,16 @@ namespace Isis { PvlObject equ("EqualizationInformation"); PvlGroup gen("General"); - gen += PvlKeyword("TotalOverlaps", std::to_string(m_validCnt + m_invalidCnt)); - gen += PvlKeyword("ValidOverlaps", std::to_string(m_validCnt)); - gen += PvlKeyword("InvalidOverlaps", std::to_string(m_invalidCnt)); - gen += PvlKeyword("MinCount", std::to_string(m_mincnt)); - gen += PvlKeyword("SamplingPercent", std::to_string(m_samplingPercent)); + gen += PvlKeyword("TotalOverlaps", Isis::toString(m_validCnt + m_invalidCnt)); + gen += PvlKeyword("ValidOverlaps", Isis::toString(m_validCnt)); + gen += PvlKeyword("InvalidOverlaps", Isis::toString(m_invalidCnt)); + gen += PvlKeyword("MinCount", Isis::toString(m_mincnt)); + gen += PvlKeyword("SamplingPercent", Isis::toString(m_samplingPercent)); gen += PvlKeyword("Weighted", (m_wtopt) ? "true" : "false"); int solType = m_sType; int lsqMethod = m_lsqMethod; - gen += PvlKeyword("SolutionType", std::to_string(solType)); - gen += PvlKeyword("SolveMethod" , std::to_string(lsqMethod)); + gen += PvlKeyword("SolutionType", Isis::toString(solType)); + gen += PvlKeyword("SolveMethod" , Isis::toString(lsqMethod)); PvlKeyword nonOverlaps("NonOverlaps"); for (int img = 0; img < m_badFiles.size(); img++) { nonOverlaps += m_badFiles[img].toStdString(); @@ -386,18 +386,18 @@ namespace Isis { if (m_sType == OverlapNormalization::Both || m_sType == OverlapNormalization::Gains || m_sType == OverlapNormalization::GainsWithoutNormalization) { - bandStats += std::to_string(m_adjustments[img]->getGain(band - 1)); + bandStats += Isis::toString(m_adjustments[img]->getGain(band - 1)); } // OFFSET if (m_sType == OverlapNormalization::Both || m_sType == OverlapNormalization::Offsets) { - bandStats += std::to_string(m_adjustments[img]->getOffset(band - 1)); + bandStats += Isis::toString(m_adjustments[img]->getOffset(band - 1)); } // AVERAGE if (m_sType == OverlapNormalization::Both || m_sType == OverlapNormalization::Gains || m_sType == OverlapNormalization::Offsets) { - bandStats += std::to_string(m_adjustments[img]->getAverage(band - 1)); + bandStats += Isis::toString(m_adjustments[img]->getAverage(band - 1)); } norm += bandStats; } @@ -468,9 +468,9 @@ namespace Isis { // Get and store the modifiers for each band for (int band = 1; band < normalization.keywords(); band++) { - adjustment->addGain(IString::ToDouble(normalization[band][0])); - adjustment->addOffset(IString::ToDouble(normalization[band][1])); - adjustment->addAverage(IString::ToDouble(normalization[band][2])); + adjustment->addGain(Isis::toDouble(normalization[band][0])); + adjustment->addOffset(Isis::toDouble(normalization[band][1])); + adjustment->addAverage(Isis::toDouble(normalization[band][2])); } addAdjustment(adjustment); @@ -815,7 +815,7 @@ namespace Isis { m_mincnt = eqGen["MinCount"]; m_wtopt = (eqGen["Weighted"][0] == "true") ? true : false; m_sType = static_cast((int)eqGen["SolutionType"]); - m_lsqMethod = static_cast(IString::ToInteger(eqGen["SolveMethod"][0])); + m_lsqMethod = static_cast(Isis::toInt(eqGen["SolveMethod"][0])); // Unserialize previous overlap statistics PvlObject::ConstPvlObjectIterator curObj = inStats.beginObject(); diff --git a/isis/src/base/objs/EquatorialCylindricalShape/unitTest.cpp b/isis/src/base/objs/EquatorialCylindricalShape/unitTest.cpp index daafff7c48..d8cf90149f 100644 --- a/isis/src/base/objs/EquatorialCylindricalShape/unitTest.cpp +++ b/isis/src/base/objs/EquatorialCylindricalShape/unitTest.cpp @@ -59,7 +59,7 @@ int main() { EquatorialCylindricalShape shape(&targ, pvl); cout << "Shape name is " << shape.name().toStdString() << endl; - cout << "Shape is DEM type? " << toString(shape.isDEM()) << endl; + cout << "Shape is DEM type? " << Isis::toString((bool)shape.isDEM()) << endl; cout << endl << "Testing method intersectSurface..." << endl; cout << " Do we have an intersection? " << shape.hasIntersection() << endl; diff --git a/isis/src/base/objs/Equirectangular/Equirectangular.cpp b/isis/src/base/objs/Equirectangular/Equirectangular.cpp index 4c7e79eed6..3d6587ae3e 100644 --- a/isis/src/base/objs/Equirectangular/Equirectangular.cpp +++ b/isis/src/base/objs/Equirectangular/Equirectangular.cpp @@ -56,7 +56,7 @@ namespace Isis { if (!mapGroup.hasKeyword("CenterLongitude")) { if (allowDefaults) { double lon = (m_minimumLongitude + m_maximumLongitude) / 2.0; - mapGroup += PvlKeyword("CenterLongitude", toString(lon)); + mapGroup += PvlKeyword("CenterLongitude", Isis::toString(lon)); } else { std::string message = "Cannot project using Equirectangular Cylindrical"; @@ -69,7 +69,7 @@ namespace Isis { if (!mapGroup.hasKeyword("CenterLatitude")) { if (allowDefaults) { double lat = (m_minimumLatitude + m_maximumLatitude) / 2.0; - mapGroup += PvlKeyword("CenterLatitude", toString(lat)); + mapGroup += PvlKeyword("CenterLatitude", Isis::toString(lat)); } else { std::string message = "Cannot project using Equirectangular Cylindrical"; @@ -95,7 +95,7 @@ namespace Isis { mapGroup += PvlKeyword("CenterLatitudeRadius"); } - mapGroup["CenterLatitudeRadius"] = toString(m_clatRadius); + mapGroup["CenterLatitudeRadius"] = Isis::toString(m_clatRadius); // Compute cos of the center latitude and make sure it is valid as // we will be dividing with it later on diff --git a/isis/src/base/objs/Equirectangular/unitTest.cpp b/isis/src/base/objs/Equirectangular/unitTest.cpp index b950986c25..76efe49e24 100644 --- a/isis/src/base/objs/Equirectangular/unitTest.cpp +++ b/isis/src/base/objs/Equirectangular/unitTest.cpp @@ -23,15 +23,15 @@ int main(int argc, char *argv[]) { Pvl lab; lab.addGroup(PvlGroup("Mapping")); PvlGroup &mapGroup = lab.findGroup("Mapping"); - mapGroup += PvlKeyword("EquatorialRadius", toString(1.0)); - mapGroup += PvlKeyword("PolarRadius", toString(1.0)); + mapGroup += PvlKeyword("EquatorialRadius", Isis::toString(1.0)); + mapGroup += PvlKeyword("PolarRadius", Isis::toString(1.0)); mapGroup += PvlKeyword("LatitudeType", "Planetocentric"); mapGroup += PvlKeyword("LongitudeDirection", "PositiveEast"); - mapGroup += PvlKeyword("LongitudeDomain", toString(180)); - mapGroup += PvlKeyword("MinimumLatitude", toString(-90.0)); - mapGroup += PvlKeyword("MaximumLatitude", toString(90.0)); - mapGroup += PvlKeyword("MinimumLongitude", toString(-180.0)); - mapGroup += PvlKeyword("MaximumLongitude", toString(180.0)); + mapGroup += PvlKeyword("LongitudeDomain", Isis::toString(180)); + mapGroup += PvlKeyword("MinimumLatitude", Isis::toString(-90.0)); + mapGroup += PvlKeyword("MaximumLatitude", Isis::toString(90.0)); + mapGroup += PvlKeyword("MinimumLongitude", Isis::toString(-180.0)); + mapGroup += PvlKeyword("MaximumLongitude", Isis::toString(180.0)); mapGroup += PvlKeyword("ProjectionName", "Equirectangular"); cout << "Test missing center longitude keyword ..." << endl; @@ -43,7 +43,7 @@ int main(int argc, char *argv[]) { } cout << endl; - mapGroup += PvlKeyword("CenterLongitude", toString(-90.0)); + mapGroup += PvlKeyword("CenterLongitude", Isis::toString(-90.0)); cout << "Test missing center latitude keyword ..." << endl; try { @@ -54,7 +54,7 @@ int main(int argc, char *argv[]) { } cout << endl; - mapGroup += PvlKeyword("CenterLatitude", toString(0.0)); + mapGroup += PvlKeyword("CenterLatitude", Isis::toString(0.0)); Projection &proj = *ProjectionFactory::Create(lab); TProjection *p = (TProjection *) &proj; @@ -109,8 +109,8 @@ int main(int argc, char *argv[]) { cout << "Testing allow defaults option ... " << endl; mapGroup.deleteKeyword("CenterLongitude"); mapGroup.deleteKeyword("CenterLatitude"); - mapGroup.findKeyword("MinimumLatitude").setValue(toString(0.0)); - mapGroup.findKeyword("MinimumLongitude").setValue(toString(0.0)); + mapGroup.findKeyword("MinimumLatitude").setValue(Isis::toString(0.0)); + mapGroup.findKeyword("MinimumLongitude").setValue(Isis::toString(0.0)); mapGroup.findKeyword("LongitudeDirection").setValue("PositiveWest"); Equirectangular p2(lab, true); cout << lab << endl; @@ -134,7 +134,7 @@ int main(int argc, char *argv[]) { cout << endl; std::cout << "Check Invalid Latitude" << std::endl; - mapGroup.addKeyword(PvlKeyword("CenterLatitude", toString(90.0)), Pvl::Replace); + mapGroup.addKeyword(PvlKeyword("CenterLatitude", Isis::toString(90.0)), Pvl::Replace); std::cout << mapGroup << std::endl; try { Equirectangular p2(lab); diff --git a/isis/src/base/objs/ExportPdsTable/ExportPdsTable.cpp b/isis/src/base/objs/ExportPdsTable/ExportPdsTable.cpp index e254347237..ebc2ca1376 100644 --- a/isis/src/base/objs/ExportPdsTable/ExportPdsTable.cpp +++ b/isis/src/base/objs/ExportPdsTable/ExportPdsTable.cpp @@ -129,16 +129,16 @@ namespace Isis { // NOTE: this class is currently only exporting BINARY format PDS tables. // implementation may be added later to export ASCII PDS tables. pdsTableLabelInfo.addKeyword(PvlKeyword("INTERCHANGE_FORMAT", "BINARY")); - pdsTableLabelInfo.addKeyword(PvlKeyword("ROWS", toString(m_isisTable->Records()))); - pdsTableLabelInfo.addKeyword(PvlKeyword("COLUMNS", toString(m_isisTable->RecordFields()))); - pdsTableLabelInfo.addKeyword(PvlKeyword("ROW_BYTES", toString(m_rowBytes))); - pdsTableLabelInfo.addKeyword(PvlKeyword("ROW_SUFFIX_BYTES", toString(m_outputRecordBytes - m_rowBytes))); + pdsTableLabelInfo.addKeyword(PvlKeyword("ROWS", Isis::toString(m_isisTable->Records()))); + pdsTableLabelInfo.addKeyword(PvlKeyword("COLUMNS", Isis::toString(m_isisTable->RecordFields()))); + pdsTableLabelInfo.addKeyword(PvlKeyword("ROW_BYTES", Isis::toString(m_rowBytes))); + pdsTableLabelInfo.addKeyword(PvlKeyword("ROW_SUFFIX_BYTES", Isis::toString(m_outputRecordBytes - m_rowBytes))); int startByte = 1; // PDS begins indexing at 1 for(int fieldIndex = 0; fieldIndex < m_isisTable->RecordFields(); fieldIndex++) { int columnBytes = 0; TableField field = (*m_isisTable)[0][fieldIndex]; PvlObject columnObj("COLUMN"); - columnObj.addKeyword(PvlKeyword("COLUMN_NUMBER", toString(fieldIndex + 1))); + columnObj.addKeyword(PvlKeyword("COLUMN_NUMBER", Isis::toString(fieldIndex + 1))); columnObj.addKeyword(PvlKeyword("NAME", field.name())); @@ -188,9 +188,9 @@ namespace Isis { "field type found for [" + field.name() + "]."; throw IException(IException::Programmer, msg, _FILEINFO_); } - columnObj.addKeyword(PvlKeyword("START_BYTE", toString(startByte))); + columnObj.addKeyword(PvlKeyword("START_BYTE", Isis::toString(startByte))); startByte += columnBytes; - columnObj.addKeyword(PvlKeyword("BYTES", toString(columnBytes))); + columnObj.addKeyword(PvlKeyword("BYTES", Isis::toString(columnBytes))); pdsTableLabelInfo.addObject(columnObj); } return pdsTableLabelInfo; diff --git a/isis/src/base/objs/ExportPdsTable/unitTest.cpp b/isis/src/base/objs/ExportPdsTable/unitTest.cpp index ad1bcd875b..f46b54f97e 100644 --- a/isis/src/base/objs/ExportPdsTable/unitTest.cpp +++ b/isis/src/base/objs/ExportPdsTable/unitTest.cpp @@ -56,7 +56,7 @@ int main(int argc, char *argv[]) { FileName lsbLabelFile("$temporary/lsbPdsTable.lbl"); ofstream outputLsbLabel((lsbLabelFile.expanded()).c_str()); outputLsbLabel << PvlKeyword("RECORD_TYPE", "FIXED_LENGTH") << endl; - outputLsbLabel << PvlKeyword("RECORD_BYTES", toString(tableRecBytes)) << endl; + outputLsbLabel << PvlKeyword("RECORD_BYTES", Isis::toString(tableRecBytes)) << endl; QString tableName = ExportPdsTable::formatPdsTableName(QString::fromStdString(table.Name())); outputLsbLabel << PvlKeyword("^" + tableName.toStdString(), "lsbPdsTable.dat") << endl; outputLsbLabel << endl; @@ -76,10 +76,10 @@ int main(int argc, char *argv[]) { cout << reimportedLsbTable[0][2].name() << "\t"; cout << reimportedLsbTable[0][3].name() << "\n"; for (int i = 0; i < reimportedLsbTable.Records(); i++) { - cout << toString((double) reimportedLsbTable[i][0]) << "\t\t\t"; - cout << toString((int) reimportedLsbTable[i][1]) << "\t\t\t\t"; + cout << Isis::toString((double) reimportedLsbTable[i][0]) << "\t\t\t"; + cout << Isis::toString((int) reimportedLsbTable[i][1]) << "\t\t\t\t"; cout << (std::string) reimportedLsbTable[i][2] << "\t\t\t"; - cout << toString((float) reimportedLsbTable[i][3]) << "\n"; + cout << Isis::toString((float) reimportedLsbTable[i][3]) << "\n"; } // remove files and reset buffer QFile::remove(QString::fromStdString(lsbLabelFile.expanded())); @@ -98,7 +98,7 @@ int main(int argc, char *argv[]) { FileName msbLabelFile("$temporary/msbPdsTable.lbl"); ofstream outputMsbLabel((msbLabelFile.expanded()).c_str()); outputMsbLabel << PvlKeyword("RECORD_TYPE", "FIXED_LENGTH") << endl; - outputMsbLabel << PvlKeyword("RECORD_BYTES", toString(tableRecBytes)) << endl; + outputMsbLabel << PvlKeyword("RECORD_BYTES", Isis::toString(tableRecBytes)) << endl; outputMsbLabel << PvlKeyword("^" + tableName.toStdString(), "msbPdsTable.dat") << endl; outputMsbLabel << endl; // Add table object to label keywords diff --git a/isis/src/base/objs/FitsToJson/FitsToJson.cpp b/isis/src/base/objs/FitsToJson/FitsToJson.cpp index eded25e81f..a49f9888f9 100644 --- a/isis/src/base/objs/FitsToJson/FitsToJson.cpp +++ b/isis/src/base/objs/FitsToJson/FitsToJson.cpp @@ -123,16 +123,16 @@ namespace Isis { bytesPerPixel /= 8; unsigned int axis1 = 1; - axis1 = IString::ToInteger((*fitsLabel)["NAXIS1"]); + axis1 = Isis::toInt((*fitsLabel)["NAXIS1"]); unsigned int axis2 = 1; if (fitsLabel->hasKeyword("NAXIS2")) { - axis2 = IString::ToInteger((*fitsLabel)["NAXIS2"]); + axis2 = Isis::toInt((*fitsLabel)["NAXIS2"]); } unsigned int axis3 = 1; if (fitsLabel->hasKeyword("NAXIS3")) { - axis3 = IString::ToInteger((*fitsLabel)["NAXIS3"]); + axis3 = Isis::toInt((*fitsLabel)["NAXIS3"]); } jump = (int)(ceil(bytesPerPixel * axis1 * axis2 * axis3 / 2880.0) * 2880.0); diff --git a/isis/src/base/objs/GridPolygonSeeder/GridPolygonSeeder.cpp b/isis/src/base/objs/GridPolygonSeeder/GridPolygonSeeder.cpp index d9a7d186ca..0810d71bd9 100644 --- a/isis/src/base/objs/GridPolygonSeeder/GridPolygonSeeder.cpp +++ b/isis/src/base/objs/GridPolygonSeeder/GridPolygonSeeder.cpp @@ -441,11 +441,11 @@ namespace Isis { PvlGroup pluginInfo(grpName.toStdString()); PvlKeyword name("Name", Algorithm().toStdString()); - PvlKeyword minThickness("MinimumThickness", toString(MinimumThickness())); - PvlKeyword minArea("MinimumArea", toString(MinimumArea())); - PvlKeyword xSpac("XSpacing", toString(p_Xspacing)); - PvlKeyword ySpac("YSpacing", toString(p_Yspacing)); - PvlKeyword subGrid("SubGrid", toString(p_subGrid)); + PvlKeyword minThickness("MinimumThickness", Isis::toString(MinimumThickness())); + PvlKeyword minArea("MinimumArea", Isis::toString(MinimumArea())); + PvlKeyword xSpac("XSpacing", Isis::toString(p_Xspacing)); + PvlKeyword ySpac("YSpacing", Isis::toString(p_Yspacing)); + PvlKeyword subGrid("SubGrid", Isis::toString(p_subGrid)); pluginInfo.addKeyword(name); pluginInfo.addKeyword(minThickness); diff --git a/isis/src/base/objs/GridPolygonSeeder/unitTest.cpp b/isis/src/base/objs/GridPolygonSeeder/unitTest.cpp index ebe7db51c2..d4ebbd8227 100644 --- a/isis/src/base/objs/GridPolygonSeeder/unitTest.cpp +++ b/isis/src/base/objs/GridPolygonSeeder/unitTest.cpp @@ -39,14 +39,14 @@ int main() { if(!alg.hasKeyword("Name")) { cout << "Test without subgrid" << endl; alg += PvlKeyword("Name", "Grid"); - alg += PvlKeyword("MinimumThickness", toString(0.3)); - alg += PvlKeyword("MinimumArea", toString(10)); - alg += PvlKeyword("XSpacing", toString(1500)); - alg += PvlKeyword("YSpacing", toString(1500)); + alg += PvlKeyword("MinimumThickness", Isis::toString(0.3)); + alg += PvlKeyword("MinimumArea", Isis::toString(10)); + alg += PvlKeyword("XSpacing", Isis::toString(1500)); + alg += PvlKeyword("YSpacing", Isis::toString(1500)); } else { cout << "Test with subgrid" << endl; - alg += PvlKeyword("SubGrid", toString(true)); + alg += PvlKeyword("SubGrid", Isis::toString(true)); } PvlObject o("AutoSeed"); @@ -93,9 +93,9 @@ int main() { mapGroup += Isis::PvlKeyword("PolarRadius", radii["PolarRadius"]); mapGroup += Isis::PvlKeyword("LatitudeType", "Planetocentric"); mapGroup += Isis::PvlKeyword("LongitudeDirection", "PositiveEast"); - mapGroup += Isis::PvlKeyword("LongitudeDomain", toString(360)); - mapGroup += Isis::PvlKeyword("CenterLatitude", toString(0)); - mapGroup += Isis::PvlKeyword("CenterLongitude", toString(0)); + mapGroup += Isis::PvlKeyword("LongitudeDomain", Isis::toString(360)); + mapGroup += Isis::PvlKeyword("CenterLatitude", Isis::toString(0)); + mapGroup += Isis::PvlKeyword("CenterLongitude", Isis::toString(0)); mapGroup += Isis::PvlKeyword("ProjectionName", "Sinusoidal"); TProjection *proj = (TProjection *) Isis::ProjectionFactory::Create(maplab); @@ -155,9 +155,9 @@ int main() { mapGroup += Isis::PvlKeyword("PolarRadius", radii["PolarRadius"]); mapGroup += Isis::PvlKeyword("LatitudeType", "Planetocentric"); mapGroup += Isis::PvlKeyword("LongitudeDirection", "PositiveEast"); - mapGroup += Isis::PvlKeyword("LongitudeDomain", toString(360)); - mapGroup += Isis::PvlKeyword("CenterLatitude", toString(0)); - mapGroup += Isis::PvlKeyword("CenterLongitude", toString(0)); + mapGroup += Isis::PvlKeyword("LongitudeDomain", Isis::toString(360)); + mapGroup += Isis::PvlKeyword("CenterLatitude", Isis::toString(0)); + mapGroup += Isis::PvlKeyword("CenterLongitude", Isis::toString(0)); mapGroup += Isis::PvlKeyword("ProjectionName", "Sinusoidal"); TProjection *proj = (TProjection *) Isis::ProjectionFactory::Create(maplab); diff --git a/isis/src/base/objs/GroundGrid/GroundGrid.cpp b/isis/src/base/objs/GroundGrid/GroundGrid.cpp index d0c02a5cc6..9f6db4b72c 100644 --- a/isis/src/base/objs/GroundGrid/GroundGrid.cpp +++ b/isis/src/base/objs/GroundGrid/GroundGrid.cpp @@ -98,7 +98,7 @@ namespace Isis { Distance::Meters); if (p_mapping->hasKeyword("MinimumLatitude")) { - p_minLat = new Latitude(IString::ToDouble((*p_mapping)["MinimumLatitude"][0]), + p_minLat = new Latitude(Isis::toDouble((*p_mapping)["MinimumLatitude"][0]), *p_mapping, Angle::Degrees, Latitude::AllowPastPole); @@ -108,7 +108,7 @@ namespace Isis { } if (p_mapping->hasKeyword("MaximumLatitude")) { - p_maxLat = new Latitude(IString::ToDouble((*p_mapping)["MaximumLatitude"][0]), + p_maxLat = new Latitude(Isis::toDouble((*p_mapping)["MaximumLatitude"][0]), *p_mapping, Angle::Degrees); } @@ -117,7 +117,7 @@ namespace Isis { } if (p_mapping->hasKeyword("MinimumLongitude")) { - p_minLon = new Longitude(IString::ToDouble((*p_mapping)["MinimumLongitude"][0]), + p_minLon = new Longitude(Isis::toDouble((*p_mapping)["MinimumLongitude"][0]), *p_mapping, Angle::Degrees); } @@ -126,7 +126,7 @@ namespace Isis { } if (p_mapping->hasKeyword("MaximumLongitude")) { - p_maxLon = new Longitude(IString::ToDouble((*p_mapping)["MaximumLongitude"][0]), + p_maxLon = new Longitude(Isis::toDouble((*p_mapping)["MaximumLongitude"][0]), *p_mapping, Angle::Degrees); } diff --git a/isis/src/base/objs/Gruen/Gruen.cpp b/isis/src/base/objs/Gruen/Gruen.cpp index de9b19123d..f8e7a373fb 100644 --- a/isis/src/base/objs/Gruen/Gruen.cpp +++ b/isis/src/base/objs/Gruen/Gruen.cpp @@ -832,7 +832,7 @@ namespace Isis { } if (m_unclassified > 0) { - algo += PvlKeyword("UnclassifiedErrors", toString(m_unclassified)); + algo += PvlKeyword("UnclassifiedErrors", Isis::toString(m_unclassified)); } pvl.addGroup(algo); pvl.addGroup(StatsLog()); @@ -853,7 +853,7 @@ namespace Isis { PvlGroup Gruen::StatsLog() const { PvlGroup stats("GruenStatistics"); - stats += PvlKeyword("TotalIterations", toString(m_totalIterations)); + stats += PvlKeyword("TotalIterations", Isis::toString(m_totalIterations)); stats += ValidateKey("IterationMinimum", m_iterStat.Minimum()); stats += ValidateKey("IterationAverage", m_iterStat.Average()); stats += ValidateKey("IterationMaximum", m_iterStat.Maximum()); @@ -890,7 +890,7 @@ namespace Isis { PvlGroup Gruen::ParameterLog() const { PvlGroup parms("GruenParameters"); - parms += PvlKeyword("MaximumIterations", toString(m_maxIters)); + parms += PvlKeyword("MaximumIterations", Isis::toString(m_maxIters)); parms += ValidateKey("AffineScaleTolerance", m_scaleTol); parms += ValidateKey("AffineShearTolerance", m_shearTol); parms += ValidateKey("AffineTranslationTolerance", m_transTol); @@ -976,22 +976,22 @@ namespace Isis { if (m_prof.Name().isEmpty()) m_prof.setName("Gruen"); // Define internal parameters - m_maxIters = toInt(ConfKey(m_prof, "MaximumIterations", toString(30))); + m_maxIters = Isis::toInt(ConfKey(m_prof, "MaximumIterations", Isis::toString(30))); - m_transTol = toDouble(ConfKey(m_prof, "AffineTranslationTolerance", toString(0.1))); - m_scaleTol = toDouble(ConfKey(m_prof, "AffineScaleTolerance", toString(0.3))); - m_shearTol = toDouble(ConfKey(m_prof, "AffineShearTolerance", toString(m_scaleTol))); - m_affineTol = toDouble(ConfKey(m_prof, "AffineTolerance", toString(DBL_MAX))); + m_transTol = Isis::toDouble(ConfKey(m_prof, "AffineTranslationTolerance", Isis::toString(0.1))); + m_scaleTol = Isis::toDouble(ConfKey(m_prof, "AffineScaleTolerance", Isis::toString(0.3))); + m_shearTol = Isis::toDouble(ConfKey(m_prof, "AffineShearTolerance", Isis::toString(m_scaleTol))); + m_affineTol = Isis::toDouble(ConfKey(m_prof, "AffineTolerance", Isis::toString(DBL_MAX))); - m_spiceTol = toDouble(ConfKey(m_prof, "SpiceTolerance", toString(DBL_MAX))); + m_spiceTol = Isis::toDouble(ConfKey(m_prof, "SpiceTolerance", Isis::toString(DBL_MAX))); - m_shiftTol = toDouble(ConfKey(m_prof, "RadioShiftTolerance", toString(DBL_MAX))); - m_rgainMinTol = toDouble(ConfKey(m_prof, "RadioGainMinTolerance", toString(-DBL_MAX))); - m_rgainMaxTol = toDouble(ConfKey(m_prof, "RadioGainMaxTolerance", toString(DBL_MAX))); + m_shiftTol = Isis::toDouble(ConfKey(m_prof, "RadioShiftTolerance", Isis::toString(DBL_MAX))); + m_rgainMinTol = Isis::toDouble(ConfKey(m_prof, "RadioGainMinTolerance", Isis::toString(-DBL_MAX))); + m_rgainMaxTol = Isis::toDouble(ConfKey(m_prof, "RadioGainMaxTolerance", Isis::toString(DBL_MAX))); // Set radiometric defaults - m_defGain = toDouble(ConfKey(m_prof, "DefaultRadioGain", toString(0.0))); - m_defShift = toDouble(ConfKey(m_prof, "DefaultRadioShift", toString(0.0))); + m_defGain = Isis::toDouble(ConfKey(m_prof, "DefaultRadioGain", Isis::toString(0.0))); + m_defShift = Isis::toDouble(ConfKey(m_prof, "DefaultRadioShift", Isis::toString(0.0))); m_callCount = 0; m_filePattern = ""; diff --git a/isis/src/base/objs/Gruen/Gruen.h b/isis/src/base/objs/Gruen/Gruen.h index 7d55bd138f..2604f9cffb 100644 --- a/isis/src/base/objs/Gruen/Gruen.h +++ b/isis/src/base/objs/Gruen/Gruen.h @@ -171,7 +171,7 @@ namespace Isis { inline int Errno() const { return (m_gerrno); } inline BigInt Count() const { return (m_count); } inline void BumpIt() { m_count++; } - PvlKeyword LogIt() const { return (PvlKeyword(m_keyname.toStdString(), toString(m_count))); } + PvlKeyword LogIt() const { return (PvlKeyword(m_keyname.toStdString(), Isis::toString(m_count))); } int m_gerrno; QString m_keyname; @@ -325,7 +325,7 @@ namespace Isis { return (PvlKeyword(keyname.toStdString(), "NULL")); } else { - return (PvlKeyword(keyname.toStdString(), toString(value), unit.toStdString())); + return (PvlKeyword(keyname.toStdString(), Isis::toString(value), unit.toStdString())); } } diff --git a/isis/src/base/objs/Gruen/unitTest.cpp b/isis/src/base/objs/Gruen/unitTest.cpp index 89a7bd8899..7d7998b41f 100644 --- a/isis/src/base/objs/Gruen/unitTest.cpp +++ b/isis/src/base/objs/Gruen/unitTest.cpp @@ -23,18 +23,18 @@ int main() { try { PvlGroup alg("Algorithm"); alg += PvlKeyword("Name", "Gruen"); - alg += PvlKeyword("Tolerance", toString(100.0)); - alg += PvlKeyword("AffineTranslationTolerance", toString(0.15)); - alg += PvlKeyword("AffineScaleTolerance", toString(0.3)); - alg += PvlKeyword("MaximumIterations", toString(30)); + alg += PvlKeyword("Tolerance", Isis::toString(100.0)); + alg += PvlKeyword("AffineTranslationTolerance", Isis::toString(0.15)); + alg += PvlKeyword("AffineScaleTolerance", Isis::toString(0.3)); + alg += PvlKeyword("MaximumIterations", Isis::toString(30)); PvlGroup pchip("PatternChip"); - pchip += PvlKeyword("Samples", toString(19)); - pchip += PvlKeyword("Lines", toString(19)); + pchip += PvlKeyword("Samples", Isis::toString(19)); + pchip += PvlKeyword("Lines", Isis::toString(19)); PvlGroup schip("SearchChip"); - schip += PvlKeyword("Samples", toString(25)); - schip += PvlKeyword("Lines", toString(25)); + schip += PvlKeyword("Samples", Isis::toString(25)); + schip += PvlKeyword("Lines", Isis::toString(25)); PvlObject o("AutoRegistration"); o.addGroup(alg); diff --git a/isis/src/base/objs/Hapke/unitTest.cpp b/isis/src/base/objs/Hapke/unitTest.cpp index 16282d055f..870c37f269 100644 --- a/isis/src/base/objs/Hapke/unitTest.cpp +++ b/isis/src/base/objs/Hapke/unitTest.cpp @@ -52,12 +52,12 @@ int main() { PvlGroup algp2("Algorithm"); algp2 += PvlKeyword("Name", "HapkeHen"); - algp2 += PvlKeyword("Wh", toString(0.52)); - algp2 += PvlKeyword("B0", toString(1.0)); - algp2 += PvlKeyword("Hh", toString(1.0)); - algp2 += PvlKeyword("Theta", toString(30.0)); - algp2 += PvlKeyword("Hg1", toString(0.213)); - algp2 += PvlKeyword("Hg2", toString(1.0)); + algp2 += PvlKeyword("Wh", Isis::toString(0.52)); + algp2 += PvlKeyword("B0", Isis::toString(1.0)); + algp2 += PvlKeyword("Hh", Isis::toString(1.0)); + algp2 += PvlKeyword("Theta", Isis::toString(30.0)); + algp2 += PvlKeyword("Hg1", Isis::toString(0.213)); + algp2 += PvlKeyword("Hg2", Isis::toString(1.0)); algp2 += PvlKeyword("ZeroB0St", "TRUE"); PvlObject op2("PhotometricModel"); @@ -88,12 +88,12 @@ int main() { PvlGroup algp3("Algorithm"); algp3 += PvlKeyword("Name", "HapkeHen"); - algp3 += PvlKeyword("Wh", toString(0.52)); - algp3 += PvlKeyword("B0", toString(1.0)); - algp3 += PvlKeyword("Hh", toString(1.0)); - algp3 += PvlKeyword("Theta", toString(30.0)); - algp3 += PvlKeyword("Hg1", toString(0.213)); - algp3 += PvlKeyword("Hg2", toString(1.0)); + algp3 += PvlKeyword("Wh", Isis::toString(0.52)); + algp3 += PvlKeyword("B0", Isis::toString(1.0)); + algp3 += PvlKeyword("Hh", Isis::toString(1.0)); + algp3 += PvlKeyword("Theta", Isis::toString(30.0)); + algp3 += PvlKeyword("Hg1", Isis::toString(0.213)); + algp3 += PvlKeyword("Hg2", Isis::toString(1.0)); algp3 += PvlKeyword("ZeroB0St", "YES"); PvlObject op3("PhotometricModel"); @@ -127,12 +127,12 @@ int main() { PvlGroup algp4("Algorithm"); algp4 += PvlKeyword("Name", "HapkeLeg"); - algp4 += PvlKeyword("Wh", toString(0.52)); - algp4 += PvlKeyword("B0", toString(1.0)); - algp4 += PvlKeyword("Hh", toString(1.0)); - algp4 += PvlKeyword("Bh", toString(0.0)); - algp4 += PvlKeyword("Ch", toString(0.0)); - algp4 += PvlKeyword("Theta", toString(30.0)); + algp4 += PvlKeyword("Wh", Isis::toString(0.52)); + algp4 += PvlKeyword("B0", Isis::toString(1.0)); + algp4 += PvlKeyword("Hh", Isis::toString(1.0)); + algp4 += PvlKeyword("Bh", Isis::toString(0.0)); + algp4 += PvlKeyword("Ch", Isis::toString(0.0)); + algp4 += PvlKeyword("Theta", Isis::toString(30.0)); algp4 += PvlKeyword("ZeroB0Standard", "FALSE"); PvlObject op4("PhotometricModel"); @@ -163,12 +163,12 @@ int main() { PvlGroup algp5("Algorithm"); algp5 += PvlKeyword("Name", "HapkeLeg"); - algp5 += PvlKeyword("Wh", toString(0.52)); - algp5 += PvlKeyword("B0", toString(1.0)); - algp5 += PvlKeyword("Hh", toString(1.0)); - algp5 += PvlKeyword("Bh", toString(0.0)); - algp5 += PvlKeyword("Ch", toString(0.0)); - algp5 += PvlKeyword("Theta", toString(30.0)); + algp5 += PvlKeyword("Wh", Isis::toString(0.52)); + algp5 += PvlKeyword("B0", Isis::toString(1.0)); + algp5 += PvlKeyword("Hh", Isis::toString(1.0)); + algp5 += PvlKeyword("Bh", Isis::toString(0.0)); + algp5 += PvlKeyword("Ch", Isis::toString(0.0)); + algp5 += PvlKeyword("Theta", Isis::toString(30.0)); algp5 += PvlKeyword("ZeroB0Standard", "NO"); PvlObject op5("PhotometricModel"); @@ -199,12 +199,12 @@ int main() { PvlGroup algp6("Algorithm"); algp6 += PvlKeyword("Name", "HapkeLeg"); - algp6 += PvlKeyword("Wh", toString(0.52)); - algp6 += PvlKeyword("B0", toString(1.0)); - algp6 += PvlKeyword("Hh", toString(1.0)); - algp6 += PvlKeyword("Bh", toString(0.0)); - algp6 += PvlKeyword("Ch", toString(0.0)); - algp6 += PvlKeyword("Theta", toString(30.0)); + algp6 += PvlKeyword("Wh", Isis::toString(0.52)); + algp6 += PvlKeyword("B0", Isis::toString(1.0)); + algp6 += PvlKeyword("Hh", Isis::toString(1.0)); + algp6 += PvlKeyword("Bh", Isis::toString(0.0)); + algp6 += PvlKeyword("Ch", Isis::toString(0.0)); + algp6 += PvlKeyword("Theta", Isis::toString(30.0)); algp6 += PvlKeyword("ZeroB0Standard", "MAYBE"); PvlObject op6("PhotometricModel"); diff --git a/isis/src/base/objs/Hillshade/Hillshade.cpp b/isis/src/base/objs/Hillshade/Hillshade.cpp index 31db3911eb..4c8b505aac 100644 --- a/isis/src/base/objs/Hillshade/Hillshade.cpp +++ b/isis/src/base/objs/Hillshade/Hillshade.cpp @@ -164,7 +164,7 @@ namespace Isis { if (input.SampleDimension() != 3 || input.LineDimension() != 3 || input.BandDimension() != 1) { - throw IException(IException::Programmer,"Hillshade requires a 3x3x1 portal of data, but a " + std::to_string(input.SampleDimension()) + "x" + std::to_string(input.LineDimension()) + "x" + std::to_string(input.BandDimension()) + " portal of data was provided instead", + throw IException(IException::Programmer,"Hillshade requires a 3x3x1 portal of data, but a " + Isis::toString(input.SampleDimension()) + "x" + Isis::toString(input.LineDimension()) + "x" + Isis::toString(input.BandDimension()) + " portal of data was provided instead", _FILEINFO_); } diff --git a/isis/src/base/objs/IdealCamera/IdealCamera.cpp b/isis/src/base/objs/IdealCamera/IdealCamera.cpp index 09fada81b5..4d80620452 100644 --- a/isis/src/base/objs/IdealCamera/IdealCamera.cpp +++ b/isis/src/base/objs/IdealCamera/IdealCamera.cpp @@ -223,7 +223,7 @@ namespace Isis { NaifStatus::CheckErrors(); } else { - std::string msg = "Unknown InstrumentType [" + toString((int)inst["InstrumentType"]) + "]"; + std::string msg = "Unknown InstrumentType [" + Isis::toString((int)inst["InstrumentType"]) + "]"; throw IException(IException::User, msg, _FILEINFO_); } } diff --git a/isis/src/base/objs/ImageExporter/ImageExporter.cpp b/isis/src/base/objs/ImageExporter/ImageExporter.cpp index ee3a066583..a3f3a3ca1d 100644 --- a/isis/src/base/objs/ImageExporter/ImageExporter.cpp +++ b/isis/src/base/objs/ImageExporter/ImageExporter.cpp @@ -265,7 +265,7 @@ namespace Isis { break; default: throw IException(IException::Programmer, - "Cannot export an image with [" + toString(m_exportDescription->channelCount()) + + "Cannot export an image with [" + Isis::toString(m_exportDescription->channelCount()) + "] channels", _FILEINFO_); } diff --git a/isis/src/base/objs/ImportPdsTable/ImportPdsTable.cpp b/isis/src/base/objs/ImportPdsTable/ImportPdsTable.cpp index 3849137e33..a773ba0dc2 100644 --- a/isis/src/base/objs/ImportPdsTable/ImportPdsTable.cpp +++ b/isis/src/base/objs/ImportPdsTable/ImportPdsTable.cpp @@ -142,7 +142,7 @@ namespace Isis { // check here. FileName tableFile(tempTblFile.toStdString()); try { - int tableStartRecord = IString::ToInteger(tableFile.baseName()); + int tableStartRecord = Isis::toInt(tableFile.baseName()); tempTblFile = pdsLabFile; m_pdsTableStart = tableStartRecord; } @@ -215,8 +215,8 @@ namespace Isis { if ((int) index >= columns() - 1) { std::string msg = "Unable to import the binary PDS table [" + m_tableName.toStdString() + "] into Isis. The requested column index [" - + toString((int) index) + "] exceeds the last column index [" - + toString(columns() - 1) + "]"; + + Isis::toString((int) index) + "] exceeds the last column index [" + + Isis::toString(columns() - 1) + "]"; throw IException(IException::Programmer, msg, _FILEINFO_); } QString name = m_coldesc[index].m_name; @@ -617,8 +617,8 @@ namespace Isis { // Ensure the nrequested column is valid if ( (nth >= columns()) || ( nth < 0) ) { - std::string mess = "Index (" + toString(nth) + - ") into Columns invalid (max: " + toString(columns()) + ")"; + std::string mess = "Index (" + Isis::toString(nth) + + ") into Columns invalid (max: " + Isis::toString(columns()) + ")"; throw IException(IException::Programmer, mess, _FILEINFO_); } @@ -958,7 +958,7 @@ namespace Isis { table += extract(m_rows[i], cols, record); } catch (IException &e) { - std::string msg = "Failed to convert data in row [" + toString((int) i) + "]"; + std::string msg = "Failed to convert data in row [" + Isis::toString((int) i) + "]"; throw IException(e, IException::Programmer, msg, _FILEINFO_); } } @@ -1111,7 +1111,7 @@ namespace Isis { std::string msg = "Only 4 byte integer values are supported in Isis. " "PDS Column [" + cdesc.m_name.toStdString() + "] has an integer DATA_TYPE with [BYTES = " - + toString(cdesc.m_numBytes) + "]."; + + Isis::toString(cdesc.m_numBytes) + "]."; throw IException(IException::Unknown, msg, _FILEINFO_); } setPdsByteOrder("MSB"); @@ -1123,7 +1123,7 @@ namespace Isis { std::string msg = "Only 4 byte integer values are supported in Isis. " "PDS Column [" + cdesc.m_name.toStdString() + "] has an integer DATA_TYPE with [BYTES = " - + toString(cdesc.m_numBytes) + "]."; + + Isis::toString(cdesc.m_numBytes) + "]."; throw IException(IException::Unknown, msg, _FILEINFO_); } setPdsByteOrder("LSB"); @@ -1145,7 +1145,7 @@ namespace Isis { IString msg = "Only 4 byte or 8 byte real values are supported in Isis. " "PDS Column [" + cdesc.m_name.toStdString() + "] has a real DATA_TYPE with [BYTES = " - + toString(cdesc.m_numBytes) + "]."; + + Isis::toString(cdesc.m_numBytes) + "]."; throw IException(IException::Unknown, msg, _FILEINFO_); } } @@ -1161,7 +1161,7 @@ namespace Isis { std::string msg = "Only 4 byte or 8 byte real values are supported in Isis. " "PDS Column [" + cdesc.m_name.toStdString() + "] has a real DATA_TYPE with [BYTES = " - + toString(cdesc.m_numBytes) + "]."; + + Isis::toString(cdesc.m_numBytes) + "]."; throw IException(IException::Unknown, msg, _FILEINFO_); } } diff --git a/isis/src/base/objs/InfixToPostfix/InfixToPostfix.cpp b/isis/src/base/objs/InfixToPostfix/InfixToPostfix.cpp index c91e24f292..68e9cb02e9 100644 --- a/isis/src/base/objs/InfixToPostfix/InfixToPostfix.cpp +++ b/isis/src/base/objs/InfixToPostfix/InfixToPostfix.cpp @@ -696,7 +696,7 @@ namespace Isis { if(argument == "") { throw IException(IException::User, - "Argument " + toString(argNum + 1) + " in function " + funcName.toStdString() + " must not be empty.", + "Argument " + Isis::toString(argNum + 1) + " in function " + funcName.toStdString() + " must not be empty.", _FILEINFO_); } } diff --git a/isis/src/base/objs/LambertAzimuthalEqualArea/LambertAzimuthalEqualArea.cpp b/isis/src/base/objs/LambertAzimuthalEqualArea/LambertAzimuthalEqualArea.cpp index 06d635242f..5ed8513539 100644 --- a/isis/src/base/objs/LambertAzimuthalEqualArea/LambertAzimuthalEqualArea.cpp +++ b/isis/src/base/objs/LambertAzimuthalEqualArea/LambertAzimuthalEqualArea.cpp @@ -75,7 +75,7 @@ namespace Isis { if (!mapGroup.hasKeyword("CenterLongitude")) { if (allowDefaults) { double centerLon = (MinimumLongitude() + MaximumLongitude()) / 2.0; - mapGroup += PvlKeyword("CenterLongitude", toString(centerLon), "Degrees"); + mapGroup += PvlKeyword("CenterLongitude", Isis::toString(centerLon), "Degrees"); } else { std::string message = "Cannot project using Lambert Azimuthal equal-area"; @@ -90,7 +90,7 @@ namespace Isis { if (!mapGroup.hasKeyword("CenterLatitude")) { if (allowDefaults) { double centerLat = (MinimumLatitude() + MaximumLatitude()) / 2.0; - mapGroup += PvlKeyword("CenterLatitude", toString(centerLat), "Degrees"); + mapGroup += PvlKeyword("CenterLatitude", Isis::toString(centerLat), "Degrees"); } else { std::string message = "Cannot project using Lambert Azimuthal equal-area"; diff --git a/isis/src/base/objs/LambertAzimuthalEqualArea/unitTest.cpp b/isis/src/base/objs/LambertAzimuthalEqualArea/unitTest.cpp index 14042ff456..681b5085b2 100644 --- a/isis/src/base/objs/LambertAzimuthalEqualArea/unitTest.cpp +++ b/isis/src/base/objs/LambertAzimuthalEqualArea/unitTest.cpp @@ -1170,7 +1170,7 @@ int main(int argc, char *argv[]) { mapGroup.findKeyword("LongitudeDirection").setValue("PositiveEast"); mapGroup.deleteKeyword("EquatorialRadius"); mapGroup += PvlKeyword("EquatorialRadius", "6378388.0"); - mapGroup.findKeyword("PolarRadius").setValue(toString(6378388.0*sqrt(1-.00672267))); + mapGroup.findKeyword("PolarRadius").setValue(Isis::toString(6378388.0*sqrt(1-.00672267))); mapGroup.findKeyword("MinimumLatitude").setValue("-89.99999"); mapGroup.findKeyword("CenterLongitude").setValue("-100.0"); mapGroup.findKeyword("MinimumLongitude").setValue("-100.0"); @@ -1621,7 +1621,7 @@ int main(int argc, char *argv[]) { //|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||| mapGroup.deleteKeyword("EquatorialRadius"); mapGroup += PvlKeyword("EquatorialRadius", "6378206.4"); - mapGroup.findKeyword("PolarRadius").setValue(toString(6378206.4*sqrt(1-.00676866))); + mapGroup.findKeyword("PolarRadius").setValue(Isis::toString(6378206.4*sqrt(1-.00676866))); mapGroup.findKeyword("CenterLatitude").setValue("40.0"); mapGroup.findKeyword("CenterLongitude").setValue("-100.0"); mapGroup.findKeyword("MinimumLatitude").setValue("-50"); @@ -2002,7 +2002,7 @@ int main(int argc, char *argv[]) { cout << "\t\t\t\t\t TESTING OTHER METHODS " << endl; cout << border << endl << endl; //|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||| - mapGroup.findKeyword("PolarRadius").setValue(toString(p8->EquatorialRadius())); + mapGroup.findKeyword("PolarRadius").setValue(Isis::toString(p8->EquatorialRadius())); TProjection *p9 = (TProjection *) ProjectionFactory::Create(lab); TProjection *s = p1; cout << "Name: " << s->Name().toStdString() << endl; diff --git a/isis/src/base/objs/LambertConformal/LambertConformal.cpp b/isis/src/base/objs/LambertConformal/LambertConformal.cpp index 143d85fb81..902942e4cc 100644 --- a/isis/src/base/objs/LambertConformal/LambertConformal.cpp +++ b/isis/src/base/objs/LambertConformal/LambertConformal.cpp @@ -48,14 +48,14 @@ namespace Isis { // necessary if ((allowDefaults) && (!mapGroup.hasKeyword("CenterLongitude"))) { double lon = (m_minimumLongitude + m_maximumLongitude) / 2.0; - mapGroup += PvlKeyword("CenterLongitude", toString(lon)); + mapGroup += PvlKeyword("CenterLongitude", Isis::toString(lon)); } // Compute and write the default center latitude if allowed and // necessary if ((allowDefaults) && (!mapGroup.hasKeyword("CenterLatitude"))) { double lat = (m_minimumLatitude + m_maximumLatitude) / 2.0; - mapGroup += PvlKeyword("CenterLatitude", toString(lat)); + mapGroup += PvlKeyword("CenterLatitude", Isis::toString(lat)); } // Get the center longitude & latitude diff --git a/isis/src/base/objs/Latitude/Latitude.cpp b/isis/src/base/objs/Latitude/Latitude.cpp index d114091f8a..20104e4c65 100644 --- a/isis/src/base/objs/Latitude/Latitude.cpp +++ b/isis/src/base/objs/Latitude/Latitude.cpp @@ -94,17 +94,17 @@ namespace Isis { m_polarRadius = NULL; if (mapping.hasKeyword("EquatorialRadius") && mapping.hasKeyword("PolarRadius")) { - m_equatorialRadius = new Distance(IString::ToDouble(mapping["EquatorialRadius"][0]), + m_equatorialRadius = new Distance(Isis::toDouble(mapping["EquatorialRadius"][0]), Distance::Meters); - m_polarRadius = new Distance(IString::ToDouble(mapping["PolarRadius"][0]), + m_polarRadius = new Distance(Isis::toDouble(mapping["PolarRadius"][0]), Distance::Meters); } else { try { PvlGroup radiiGrp = Target::radiiGroup(QString::fromStdString(mapping["TargetName"][0])); - m_equatorialRadius = new Distance(IString::ToDouble(radiiGrp["EquatorialRadius"][0]), + m_equatorialRadius = new Distance(Isis::toDouble(radiiGrp["EquatorialRadius"][0]), Distance::Meters); - m_polarRadius = new Distance(IString::ToDouble(radiiGrp["PolarRadius"][0]), + m_polarRadius = new Distance(Isis::toDouble(radiiGrp["PolarRadius"][0]), Distance::Meters); } catch (IException &e) { @@ -154,17 +154,17 @@ namespace Isis { m_polarRadius = NULL; if (mapping.hasKeyword("EquatorialRadius") && mapping.hasKeyword("PolarRadius")) { - m_equatorialRadius = new Distance(IString::ToDouble(mapping["EquatorialRadius"][0]), + m_equatorialRadius = new Distance(Isis::toDouble(mapping["EquatorialRadius"][0]), Distance::Meters); - m_polarRadius = new Distance(IString::ToDouble(mapping["PolarRadius"][0]), + m_polarRadius = new Distance(Isis::toDouble(mapping["PolarRadius"][0]), Distance::Meters); } else { try { PvlGroup radiiGrp = Target::radiiGroup(QString::fromStdString(mapping["TargetName"][0])); - m_equatorialRadius = new Distance(IString::ToDouble(radiiGrp["EquatorialRadius"][0]), + m_equatorialRadius = new Distance(Isis::toDouble(radiiGrp["EquatorialRadius"][0]), Distance::Meters); - m_polarRadius = new Distance(IString::ToDouble(radiiGrp["PolarRadius"][0]), + m_polarRadius = new Distance(Isis::toDouble(radiiGrp["PolarRadius"][0]), Distance::Meters); } catch (IException &e) { @@ -226,7 +226,7 @@ namespace Isis { setPlanetographic(latitude, latitudeUnits); } else { - std::string msg = "Enumeration value [" + std::to_string(latType) + "] is not a valid CoordinateType"; + std::string msg = "Enumeration value [" + Isis::toString(latType) + "] is not a valid CoordinateType"; throw IException(IException::Programmer, msg, _FILEINFO_); } } @@ -315,7 +315,7 @@ namespace Isis { double Latitude::planetographic(Angle::Units units) const { if (m_equatorialRadius == NULL || m_polarRadius == NULL) { - std::string msg = "Latitude [" + std::to_string(true) + "] cannot " + std::string msg = "Latitude [" + Isis::toString(true) + "] cannot " "be converted to Planetographic without the planetary radii, please " "use the other Latitude constructor."; throw IException(IException::Programmer, msg, _FILEINFO_); @@ -507,17 +507,17 @@ namespace Isis { Distance equatorialRadius; Distance polarRadius; if (mapping.hasKeyword("EquatorialRadius") && mapping.hasKeyword("PolarRadius")) { - equatorialRadius = Distance(IString::ToDouble(mapping["EquatorialRadius"][0]), + equatorialRadius = Distance(Isis::toDouble(mapping["EquatorialRadius"][0]), Distance::Meters); - polarRadius = Distance(IString::ToDouble(mapping["PolarRadius"][0]), + polarRadius = Distance(Isis::toDouble(mapping["PolarRadius"][0]), Distance::Meters); } else { try { PvlGroup radiiGrp = Target::radiiGroup(QString::fromStdString(mapping["TargetName"][0])); - equatorialRadius = Distance(IString::ToDouble(radiiGrp["EquatorialRadius"][0]), + equatorialRadius = Distance(Isis::toDouble(radiiGrp["EquatorialRadius"][0]), Distance::Meters); - polarRadius = Distance(IString::ToDouble(radiiGrp["PolarRadius"][0]), + polarRadius = Distance(Isis::toDouble(radiiGrp["PolarRadius"][0]), Distance::Meters); } catch (IException &e) { diff --git a/isis/src/base/objs/LimitPolygonSeeder/LimitPolygonSeeder.cpp b/isis/src/base/objs/LimitPolygonSeeder/LimitPolygonSeeder.cpp index be826bf2c7..69f8f5183b 100644 --- a/isis/src/base/objs/LimitPolygonSeeder/LimitPolygonSeeder.cpp +++ b/isis/src/base/objs/LimitPolygonSeeder/LimitPolygonSeeder.cpp @@ -199,10 +199,10 @@ namespace Isis { PvlGroup pluginInfo(grpName.toStdString()); PvlKeyword name("Name", Algorithm().toStdString()); - PvlKeyword minThickness("MinimumThickness", toString(MinimumThickness())); - PvlKeyword minArea("MinimumArea", toString(MinimumArea())); - PvlKeyword majAxis("MajorAxisPoints", toString(p_majorAxisPts)); - PvlKeyword minAxis("MinorAxisPoints", toString(p_minorAxisPts)); + PvlKeyword minThickness("MinimumThickness", Isis::toString(MinimumThickness())); + PvlKeyword minArea("MinimumArea", Isis::toString(MinimumArea())); + PvlKeyword majAxis("MajorAxisPoints", Isis::toString(p_majorAxisPts)); + PvlKeyword minAxis("MinorAxisPoints", Isis::toString(p_minorAxisPts)); pluginInfo.addKeyword(name); pluginInfo.addKeyword(minThickness); diff --git a/isis/src/base/objs/LunarAzimuthalEqualArea/unitTest.cpp b/isis/src/base/objs/LunarAzimuthalEqualArea/unitTest.cpp index 100375ce88..fc83bd5a56 100644 --- a/isis/src/base/objs/LunarAzimuthalEqualArea/unitTest.cpp +++ b/isis/src/base/objs/LunarAzimuthalEqualArea/unitTest.cpp @@ -27,16 +27,16 @@ int main(int argc, char *argv[]) { Pvl lab; lab.addGroup(PvlGroup("Mapping")); PvlGroup &mapGroup = lab.findGroup("Mapping"); - mapGroup += PvlKeyword("EquatorialRadius", toString(6378206.4)); - mapGroup += PvlKeyword("PolarRadius", toString(6378206.4)); + mapGroup += PvlKeyword("EquatorialRadius", Isis::toString(6378206.4)); + mapGroup += PvlKeyword("PolarRadius", Isis::toString(6378206.4)); mapGroup += PvlKeyword("LatitudeType", "Planetographic"); mapGroup += PvlKeyword("LongitudeDirection", "PositiveEast"); - mapGroup += PvlKeyword("LongitudeDomain", toString(180)); - mapGroup += PvlKeyword("MinimumLatitude", toString(-30.0)); - mapGroup += PvlKeyword("MaximumLatitude", toString(-15.0)); - mapGroup += PvlKeyword("MinimumLongitude", toString(-30.0)); - mapGroup += PvlKeyword("MaximumLongitude", toString(-15.0)); - mapGroup += PvlKeyword("MaximumLibration", toString(1)); + mapGroup += PvlKeyword("LongitudeDomain", Isis::toString(180)); + mapGroup += PvlKeyword("MinimumLatitude", Isis::toString(-30.0)); + mapGroup += PvlKeyword("MaximumLatitude", Isis::toString(-15.0)); + mapGroup += PvlKeyword("MinimumLongitude", Isis::toString(-30.0)); + mapGroup += PvlKeyword("MaximumLongitude", Isis::toString(-15.0)); + mapGroup += PvlKeyword("MaximumLibration", Isis::toString(1)); mapGroup += PvlKeyword("ProjectionName", "LunarAzimuthalEqualArea"); @@ -85,7 +85,7 @@ int main(int argc, char *argv[]) { cout << "true! ..................................... [ OK ]\n"; else cout << "false! .................................... [ FAILED ]\n"; - mapGroup["PolarRadius"].setValue(toString(42)); + mapGroup["PolarRadius"].setValue(Isis::toString(42)); Pvl tmp1; TProjection *p2 = (TProjection *) ProjectionFactory::Create(lab); tmp1.addGroup(p2->Mapping()); diff --git a/isis/src/base/objs/LunarLambertEmpirical/LunarLambertEmpirical.cpp b/isis/src/base/objs/LunarLambertEmpirical/LunarLambertEmpirical.cpp index 0c6705a87c..82c7bf65de 100755 --- a/isis/src/base/objs/LunarLambertEmpirical/LunarLambertEmpirical.cpp +++ b/isis/src/base/objs/LunarLambertEmpirical/LunarLambertEmpirical.cpp @@ -86,7 +86,7 @@ namespace Isis { phaseangle = strlist.Token(","); if (phaseangle < 0.0 || phaseangle > 180.0) { std::string msg = "Invalid value of empirical Lunar Lambert phase angle list value [" + - std::to_string(phaseangle) + "]"; + Isis::toString(phaseangle) + "]"; throw IException(IException::User, msg, _FILEINFO_); } p_photoPhaseList.push_back(phaseangle); @@ -115,7 +115,7 @@ namespace Isis { p_photoPhaseList.clear(); for (int i=0; i< phaseList.size(); i++) { - phaseAngle = IString::ToDouble(phaseList[i]); + phaseAngle = Isis::toDouble(phaseList[i]); if (phaseAngle < 0.0 || phaseAngle > 180.0) { std::string msg = "Invalid value of empirical Lunar Lambert phase angle list value [" + @@ -169,7 +169,7 @@ namespace Isis { p_photoLList.clear(); for (int i=0; i 180.0) { std::string msg = "Invalid value of empirical Minnaert phase angle list value [" + @@ -168,7 +168,7 @@ namespace Isis { p_photoKList.clear(); for (int i=0; isecond.second; } else { - snGroup += PvlKeyword("ObservationKeys", toString(snGroup.keywords())); + snGroup += PvlKeyword("ObservationKeys", Isis::toString(snGroup.keywords())); } return snGroup; diff --git a/isis/src/base/objs/OriginalXmlLabel/OriginalXmlLabel.cpp b/isis/src/base/objs/OriginalXmlLabel/OriginalXmlLabel.cpp index f412bdc663..2ebd9fcc52 100644 --- a/isis/src/base/objs/OriginalXmlLabel/OriginalXmlLabel.cpp +++ b/isis/src/base/objs/OriginalXmlLabel/OriginalXmlLabel.cpp @@ -113,7 +113,7 @@ namespace Isis { if ( !m_originalLabel.setContent(&xmlFile, false, &errmsg, &errline, &errcol) ) { xmlFile.close(); std::string msg = "XML read/parse error in file [" + xmlFileName.expanded() - + "] at line [" + std::to_string(errline) + "], column [" + std::to_string(errcol) + + "] at line [" + Isis::toString(errline) + "], column [" + Isis::toString(errcol) + "], message: " + errmsg.toStdString(); throw IException(IException::Unknown, msg, _FILEINFO_); } diff --git a/isis/src/base/objs/Orthographic/Orthographic.cpp b/isis/src/base/objs/Orthographic/Orthographic.cpp index 331942e211..4f229ca537 100644 --- a/isis/src/base/objs/Orthographic/Orthographic.cpp +++ b/isis/src/base/objs/Orthographic/Orthographic.cpp @@ -48,7 +48,7 @@ namespace Isis { */ if ((allowDefaults) && (!mapGroup.hasKeyword("CenterLongitude"))) { double lon = (m_minimumLongitude + m_maximumLongitude) / 2.0; - mapGroup += PvlKeyword("CenterLongitude", toString(lon)); + mapGroup += PvlKeyword("CenterLongitude", Isis::toString(lon)); } /* @@ -57,7 +57,7 @@ namespace Isis { */ if ((allowDefaults) && (!mapGroup.hasKeyword("CenterLatitude"))) { double lat = (m_minimumLatitude + m_maximumLatitude) / 2.0; - mapGroup += PvlKeyword("CenterLatitude", toString(lat)); + mapGroup += PvlKeyword("CenterLatitude", Isis::toString(lat)); } // Get the center longitude & latitude diff --git a/isis/src/base/objs/OverlapStatistics/OverlapStatistics.cpp b/isis/src/base/objs/OverlapStatistics/OverlapStatistics.cpp index 2e9b0f0f1c..9fdfc3d401 100644 --- a/isis/src/base/objs/OverlapStatistics/OverlapStatistics.cpp +++ b/isis/src/base/objs/OverlapStatistics/OverlapStatistics.cpp @@ -200,26 +200,26 @@ namespace Isis { PvlObject o(name.toStdString()); o += PvlKeyword("File1", FileNameX().name()); o += PvlKeyword("File2", FileNameY().name()); - o += PvlKeyword("Width", toString(Samples())); - o += PvlKeyword("Height", toString(Lines())); - o += PvlKeyword("Bands", toString(Bands())); - o += PvlKeyword("SamplingPercent", toString(SampPercent())); - o += PvlKeyword("MinCount", toString(MinCount())); // Do we need this if EqInfo has this? + o += PvlKeyword("Width", Isis::toString(Samples())); + o += PvlKeyword("Height", Isis::toString(Lines())); + o += PvlKeyword("Bands", Isis::toString(Bands())); + o += PvlKeyword("SamplingPercent", Isis::toString(SampPercent())); + o += PvlKeyword("MinCount", Isis::toString(MinCount())); // Do we need this if EqInfo has this? // Create group for first file of overlap PvlGroup gX("File1"); - PvlKeyword stsX("StartSample", toString(StartSampleX())); - PvlKeyword ensX("EndSample", toString(EndSampleX())); - PvlKeyword stlX("StartLine", toString(StartLineX())); - PvlKeyword enlX("EndLine", toString(EndLineX())); + PvlKeyword stsX("StartSample", Isis::toString(StartSampleX())); + PvlKeyword ensX("EndSample", Isis::toString(EndSampleX())); + PvlKeyword stlX("StartLine", Isis::toString(StartLineX())); + PvlKeyword enlX("EndLine", Isis::toString(EndLineX())); PvlKeyword avgX("Average"); PvlKeyword stdX("StandardDeviation"); PvlKeyword varX("Variance"); for (int band = 1; band <= Bands(); band++) { if (HasOverlap(band)) { - avgX += toString(GetMStats(band).X().Average()); - stdX += toString(GetMStats(band).X().StandardDeviation()); - varX += toString(GetMStats(band).X().Variance()); + avgX += Isis::toString(GetMStats(band).X().Average()); + stdX += Isis::toString(GetMStats(band).X().StandardDeviation()); + varX += Isis::toString(GetMStats(band).X().Variance()); } } gX += stsX; @@ -232,18 +232,18 @@ namespace Isis { // Create group for second file of overlap PvlGroup gY("File2"); - PvlKeyword stsY("StartSample", toString(StartSampleY())); - PvlKeyword ensY("EndSample", toString(EndSampleY())); - PvlKeyword stlY("StartLine", toString(StartLineY())); - PvlKeyword enlY("EndLine", toString(EndLineY())); + PvlKeyword stsY("StartSample", Isis::toString(StartSampleY())); + PvlKeyword ensY("EndSample", Isis::toString(EndSampleY())); + PvlKeyword stlY("StartLine", Isis::toString(StartLineY())); + PvlKeyword enlY("EndLine", Isis::toString(EndLineY())); PvlKeyword avgY("Average"); PvlKeyword stdY("StandardDeviation"); PvlKeyword varY("Variance"); for (int band = 1; band <= Bands(); band++) { if (HasOverlap(band)) { - avgY += toString(GetMStats(band).Y().Average()); - stdY += toString(GetMStats(band).Y().StandardDeviation()); - varY += toString(GetMStats(band).Y().Variance()); + avgY += Isis::toString(GetMStats(band).Y().Average()); + stdY += Isis::toString(GetMStats(band).Y().StandardDeviation()); + varY += Isis::toString(GetMStats(band).Y().Variance()); } } gY += stsY; diff --git a/isis/src/base/objs/Pipeline/Pipeline.cpp b/isis/src/base/objs/Pipeline/Pipeline.cpp index 4cf30e0577..10515af863 100644 --- a/isis/src/base/objs/Pipeline/Pipeline.cpp +++ b/isis/src/base/objs/Pipeline/Pipeline.cpp @@ -727,7 +727,7 @@ namespace Isis { */ PipelineApplication &Pipeline::Application(const int &index) { if (index > Size()) { - std::string msg = "Index [" + std::to_string(index) + "] out of bounds"; + std::string msg = "Index [" + Isis::toString(index) + "] out of bounds"; throw IException(IException::Programmer, msg, _FILEINFO_); } @@ -811,7 +811,7 @@ namespace Isis { if (p_finalOutput.size() > 1) { if ((unsigned int)branch >= p_finalOutput.size()) { - std::string msg = "Output not set for branch [" + std::to_string(branch) + "]"; + std::string msg = "Output not set for branch [" + Isis::toString(branch) + "]"; throw IException(IException::Programmer, msg, _FILEINFO_); } diff --git a/isis/src/base/objs/Planar/Planar.cpp b/isis/src/base/objs/Planar/Planar.cpp index 18ac7763db..6a663a4638 100644 --- a/isis/src/base/objs/Planar/Planar.cpp +++ b/isis/src/base/objs/Planar/Planar.cpp @@ -50,14 +50,14 @@ namespace Isis { // necessary if ((allowDefaults) && (!mapGroup.hasKeyword("CenterRingLongitude"))) { double azimuth = (m_minimumRingLongitude + m_maximumRingLongitude) / 2.0; - mapGroup += PvlKeyword("CenterRingLongitude", toString(azimuth)); + mapGroup += PvlKeyword("CenterRingLongitude", Isis::toString(azimuth)); } // Compute and write the default center radius if allowed and // necessary if ((allowDefaults) && (!mapGroup.hasKeyword("CenterRingRadius"))) { double radius = (m_minimumRingRadius + m_maximumRingRadius) / 2.0; - mapGroup += PvlKeyword("CenterRingRadius", toString(radius)); + mapGroup += PvlKeyword("CenterRingRadius", Isis::toString(radius)); } // Get the center longitude & radius @@ -434,11 +434,11 @@ namespace Isis { PvlGroup Planar::Mapping() { PvlGroup mapping = RingPlaneProjection::Mapping(); - mapping += PvlKeyword("CenterRingRadius", toString(m_centerRingRadius)); + mapping += PvlKeyword("CenterRingRadius", Isis::toString(m_centerRingRadius)); double dir = 1.0; if (m_ringLongitudeDirection == Clockwise) dir = -1.0; double lonDegrees = m_centerRingLongitude*RAD2DEG*dir; - mapping += PvlKeyword("CenterRingLongitude", toString(lonDegrees)); + mapping += PvlKeyword("CenterRingLongitude", Isis::toString(lonDegrees)); return mapping; } diff --git a/isis/src/base/objs/PlaneShape/unitTest.cpp b/isis/src/base/objs/PlaneShape/unitTest.cpp index 67dc6bbf2e..6a12958c10 100644 --- a/isis/src/base/objs/PlaneShape/unitTest.cpp +++ b/isis/src/base/objs/PlaneShape/unitTest.cpp @@ -64,7 +64,7 @@ int main() { cout << " Shape1 name is " << shape.name().toStdString() << endl; cout << " Shape2 name is " << shape2.name().toStdString() << endl; cout << " Shape3 name is " << shape3.name().toStdString() << endl; - cout << " Shape is DEM type? " << toString(shape3.isDEM()) << endl; + cout << " Shape is DEM type? " << Isis::toString((bool)shape3.isDEM()) << endl; std::vector sB(3); sB[0] = -19584.5; diff --git a/isis/src/base/objs/PointPerspective/PointPerspective.cpp b/isis/src/base/objs/PointPerspective/PointPerspective.cpp index 428a765529..1f3ee59709 100644 --- a/isis/src/base/objs/PointPerspective/PointPerspective.cpp +++ b/isis/src/base/objs/PointPerspective/PointPerspective.cpp @@ -46,14 +46,14 @@ namespace Isis { // necessary if ((allowDefaults) && (!mapGroup.hasKeyword("CenterLongitude"))) { double lon = (m_minimumLongitude + m_maximumLongitude) / 2.0; - mapGroup += PvlKeyword("CenterLongitude", toString(lon)); + mapGroup += PvlKeyword("CenterLongitude", Isis::toString(lon)); } // Compute and write the default center latitude if allowed and // necessary if ((allowDefaults) && (!mapGroup.hasKeyword("CenterLatitude"))) { double lat = (m_minimumLatitude + m_maximumLatitude) / 2.0; - mapGroup += PvlKeyword("CenterLatitude", toString(lat)); + mapGroup += PvlKeyword("CenterLatitude", Isis::toString(lat)); } // Get the center longitude & latitude diff --git a/isis/src/base/objs/PointPerspective/unitTest.cpp b/isis/src/base/objs/PointPerspective/unitTest.cpp index 829c9d8db7..ce04054d9e 100644 --- a/isis/src/base/objs/PointPerspective/unitTest.cpp +++ b/isis/src/base/objs/PointPerspective/unitTest.cpp @@ -23,15 +23,15 @@ int main(int argc, char *argv[]) { Pvl lab; lab.addGroup(PvlGroup("Mapping")); PvlGroup &mapGroup = lab.findGroup("Mapping"); - mapGroup += PvlKeyword("EquatorialRadius", toString(1.0)); - mapGroup += PvlKeyword("PolarRadius", toString(1.0)); + mapGroup += PvlKeyword("EquatorialRadius", Isis::toString(1.0)); + mapGroup += PvlKeyword("PolarRadius", Isis::toString(1.0)); mapGroup += PvlKeyword("LatitudeType", "Planetographic"); mapGroup += PvlKeyword("LongitudeDirection", "PositiveEast"); - mapGroup += PvlKeyword("LongitudeDomain", toString(180)); - mapGroup += PvlKeyword("MinimumLatitude", toString(0.0)); - mapGroup += PvlKeyword("MaximumLatitude", toString(80.0)); - mapGroup += PvlKeyword("MinimumLongitude", toString(0.0)); - mapGroup += PvlKeyword("MaximumLongitude", toString(80.0)); + mapGroup += PvlKeyword("LongitudeDomain", Isis::toString(180)); + mapGroup += PvlKeyword("MinimumLatitude", Isis::toString(0.0)); + mapGroup += PvlKeyword("MaximumLatitude", Isis::toString(80.0)); + mapGroup += PvlKeyword("MinimumLongitude", Isis::toString(0.0)); + mapGroup += PvlKeyword("MaximumLongitude", Isis::toString(80.0)); mapGroup += PvlKeyword("ProjectionName", "PointPerspective"); cout << "Test missing center longitude keyword ..." << endl; @@ -43,7 +43,7 @@ int main(int argc, char *argv[]) { } cout << endl; - mapGroup += PvlKeyword("CenterLongitude", toString(0.0)); + mapGroup += PvlKeyword("CenterLongitude", Isis::toString(0.0)); cout << "Test missing center latitude keyword..." << endl; try { @@ -54,7 +54,7 @@ int main(int argc, char *argv[]) { } cout << endl; - mapGroup += PvlKeyword("CenterLatitude", toString(0.0)); + mapGroup += PvlKeyword("CenterLatitude", Isis::toString(0.0)); cout << "Test missing distance keyword..." << endl; try { @@ -65,7 +65,7 @@ int main(int argc, char *argv[]) { } cout << endl; - mapGroup += PvlKeyword("Distance", toString(.00562)); + mapGroup += PvlKeyword("Distance", Isis::toString(.00562)); try { TProjection *p = (TProjection *) ProjectionFactory::Create(lab); @@ -168,18 +168,18 @@ int main(int argc, char *argv[]) { Pvl lab1; lab1.addGroup(PvlGroup("Mapping")); PvlGroup &mapGroup = lab1.findGroup("Mapping"); - mapGroup += PvlKeyword("EquatorialRadius", toString(6371000)); - mapGroup+= PvlKeyword("PolarRadius",toString(6371000)); + mapGroup += PvlKeyword("EquatorialRadius", Isis::toString(6371000)); + mapGroup+= PvlKeyword("PolarRadius",Isis::toString(6371000)); mapGroup += PvlKeyword("LatitudeType", "Planetographic"); mapGroup += PvlKeyword("LongitudeDirection", "PositiveEast"); - mapGroup += PvlKeyword("LongitudeDomain", toString(180)); - mapGroup += PvlKeyword("MinimumLatitude", toString(-90.0)); - mapGroup += PvlKeyword("MaximumLatitude", toString(90.0)); - mapGroup += PvlKeyword("MinimumLongitude", toString(-180.0)); - mapGroup += PvlKeyword("MaximumLongitude", toString(180.0)); - mapGroup += PvlKeyword("CenterLongitude", toString(-77.0)); - mapGroup += PvlKeyword("CenterLatitude", toString(39.0)); - mapGroup += PvlKeyword("Distance", toString(500000)); + mapGroup += PvlKeyword("LongitudeDomain", Isis::toString(180)); + mapGroup += PvlKeyword("MinimumLatitude", Isis::toString(-90.0)); + mapGroup += PvlKeyword("MaximumLatitude", Isis::toString(90.0)); + mapGroup += PvlKeyword("MinimumLongitude", Isis::toString(-180.0)); + mapGroup += PvlKeyword("MaximumLongitude", Isis::toString(180.0)); + mapGroup += PvlKeyword("CenterLongitude", Isis::toString(-77.0)); + mapGroup += PvlKeyword("CenterLatitude", Isis::toString(39.0)); + mapGroup += PvlKeyword("Distance", Isis::toString(500000)); mapGroup += PvlKeyword("ProjectionName", "PointPerspective"); TProjection *p1 = (TProjection *) ProjectionFactory::Create(lab1); diff --git a/isis/src/base/objs/PolarStereographic/PolarStereographic.cpp b/isis/src/base/objs/PolarStereographic/PolarStereographic.cpp index 24d5600ebe..c0a039511b 100644 --- a/isis/src/base/objs/PolarStereographic/PolarStereographic.cpp +++ b/isis/src/base/objs/PolarStereographic/PolarStereographic.cpp @@ -49,7 +49,7 @@ namespace Isis { // necessary if ((allowDefaults) && (!mapGroup.hasKeyword("CenterLongitude"))) { double lon = (m_minimumLongitude + m_maximumLongitude) / 2.0; - mapGroup += PvlKeyword("CenterLongitude", toString(lon)); + mapGroup += PvlKeyword("CenterLongitude", Isis::toString(lon)); } // Compute and write the default center latitude if allowed and @@ -57,10 +57,10 @@ namespace Isis { if ((allowDefaults) && (!mapGroup.hasKeyword("CenterLatitude"))) { double lat = (m_minimumLatitude + m_maximumLatitude) / 2.0; if (lat > 0.0) { - mapGroup += PvlKeyword("CenterLatitude", toString(90.0)); + mapGroup += PvlKeyword("CenterLatitude", Isis::toString(90.0)); } else { - mapGroup += PvlKeyword("CenterLatitude", toString(-90.0)); + mapGroup += PvlKeyword("CenterLatitude", Isis::toString(-90.0)); } } diff --git a/isis/src/base/objs/PolarStereographic/unitTest.cpp b/isis/src/base/objs/PolarStereographic/unitTest.cpp index ded540a398..d1f22965b6 100644 --- a/isis/src/base/objs/PolarStereographic/unitTest.cpp +++ b/isis/src/base/objs/PolarStereographic/unitTest.cpp @@ -24,15 +24,15 @@ int main(int argc, char *argv[]) { Pvl lab; lab.addGroup(PvlGroup("Mapping")); PvlGroup &mg = lab.findGroup("Mapping"); - mg += PvlKeyword("EquatorialRadius", toString(6378388.0)); - mg += PvlKeyword("PolarRadius", toString(6356911.9)); + mg += PvlKeyword("EquatorialRadius", Isis::toString(6378388.0)); + mg += PvlKeyword("PolarRadius", Isis::toString(6356911.9)); mg += PvlKeyword("LatitudeType", "Planetographic"); mg += PvlKeyword("LongitudeDirection", "PositiveEast"); - mg += PvlKeyword("LongitudeDomain", toString(180)); - mg += PvlKeyword("MinimumLatitude", toString(-90.0)); - mg += PvlKeyword("MaximumLatitude", toString(0.0)); - mg += PvlKeyword("MinimumLongitude", toString(-180.0)); - mg += PvlKeyword("MaximumLongitude", toString(180.0)); + mg += PvlKeyword("LongitudeDomain", Isis::toString(180)); + mg += PvlKeyword("MinimumLatitude", Isis::toString(-90.0)); + mg += PvlKeyword("MaximumLatitude", Isis::toString(0.0)); + mg += PvlKeyword("MinimumLongitude", Isis::toString(-180.0)); + mg += PvlKeyword("MaximumLongitude", Isis::toString(180.0)); mg += PvlKeyword("ProjectionName", "PolarStereographic"); @@ -44,7 +44,7 @@ int main(int argc, char *argv[]) { e.print(); } cout << endl; - mg += PvlKeyword("CenterLongitude", toString(-100.0)); + mg += PvlKeyword("CenterLongitude", Isis::toString(-100.0)); cout << "Test missing center latitude keyword ..." << endl; try { @@ -55,7 +55,7 @@ int main(int argc, char *argv[]) { } cout << endl; cout << "Test invalid center latitude keyword ..." << endl; - mg += PvlKeyword("CenterLatitude", toString(0.0)); + mg += PvlKeyword("CenterLatitude", Isis::toString(0.0)); try { PolarStereographic p(lab); } @@ -63,7 +63,7 @@ int main(int argc, char *argv[]) { e.print(); } cout << endl; - mg.addKeyword(PvlKeyword("CenterLatitude", toString(-71.0)), PvlGroup::Replace); + mg.addKeyword(PvlKeyword("CenterLatitude", Isis::toString(-71.0)), PvlGroup::Replace); try { TProjection *p = (TProjection *) ProjectionFactory::Create(lab); diff --git a/isis/src/base/objs/PolygonSeeder/PolygonSeeder.cpp b/isis/src/base/objs/PolygonSeeder/PolygonSeeder.cpp index 95c98abf0d..d3b9f20ec7 100644 --- a/isis/src/base/objs/PolygonSeeder/PolygonSeeder.cpp +++ b/isis/src/base/objs/PolygonSeeder/PolygonSeeder.cpp @@ -147,7 +147,7 @@ namespace Isis { const geos::geom::Envelope *xyBoundBox) { if(xymp->getArea() < MinimumArea()) { std::string msg = "Polygon did not meet the minimum area of ["; - msg += toString(MinimumArea()) + "]"; + msg += Isis::toString(MinimumArea()) + "]"; return QString::fromStdString(msg); } @@ -156,7 +156,7 @@ namespace Isis { pow(std::max(xyBoundBox->getWidth(), xyBoundBox->getHeight()), 2.0); if(thickness < MinimumThickness()) { std::string msg = "Polygon did not meet the minimum thickness ratio of ["; - msg += toString(MinimumThickness()) + "]"; + msg += Isis::toString(MinimumThickness()) + "]"; return QString::fromStdString(msg); } @@ -211,8 +211,8 @@ namespace Isis { PvlGroup pluginInfo(grpName.toStdString()); PvlKeyword name("Name", p_algorithmName.toStdString()); - PvlKeyword minThickness("MinimumThickness", toString(p_minimumThickness)); - PvlKeyword minArea("MinimumArea", toString(p_minimumArea)); + PvlKeyword minThickness("MinimumThickness", Isis::toString(p_minimumThickness)); + PvlKeyword minArea("MinimumArea", Isis::toString(p_minimumArea)); pluginInfo.addKeyword(name); pluginInfo.addKeyword(minThickness); diff --git a/isis/src/base/objs/PrincipalComponentAnalysis/PrincipalComponentAnalysis.cpp b/isis/src/base/objs/PrincipalComponentAnalysis/PrincipalComponentAnalysis.cpp index dc95cb9f66..0056c42502 100644 --- a/isis/src/base/objs/PrincipalComponentAnalysis/PrincipalComponentAnalysis.cpp +++ b/isis/src/base/objs/PrincipalComponentAnalysis/PrincipalComponentAnalysis.cpp @@ -114,7 +114,7 @@ namespace Isis { // Transform the vector into principal component space TNT::Array2D PrincipalComponentAnalysis::Transform(TNT::Array2D data) { if(data.dim1() != 1 || data.dim2() != p_dimensions) { - std::string m = "Transform input must be of dimension 1 x " + toString(p_dimensions); + std::string m = "Transform input must be of dimension 1 x " + Isis::toString(p_dimensions); throw IException(IException::Programmer, m, _FILEINFO_); } @@ -125,7 +125,7 @@ namespace Isis { // Transform the vector from principal component space TNT::Array2D PrincipalComponentAnalysis::Inverse(TNT::Array2D data) { if(data.dim1() != 1 || data.dim2() != p_dimensions) { - std::string m = "Transform input must be of dimension 1 x " + toString(p_dimensions); + std::string m = "Transform input must be of dimension 1 x " + Isis::toString(p_dimensions); throw IException(IException::Programmer, m, _FILEINFO_); } diff --git a/isis/src/base/objs/ProcessExportPds/ProcessExportPds.cpp b/isis/src/base/objs/ProcessExportPds/ProcessExportPds.cpp index 0c5a9b7d0b..0637329daf 100644 --- a/isis/src/base/objs/ProcessExportPds/ProcessExportPds.cpp +++ b/isis/src/base/objs/ProcessExportPds/ProcessExportPds.cpp @@ -271,7 +271,7 @@ namespace Isis { if(p_pixelType == Isis::UnsignedWord || p_pixelType == Isis::SignedWord) { storagebytes = storagebytes * 2; } - cmpObj += PvlKeyword("REQUIRED_STORAGE_BYTES", toString(storagebytes)); + cmpObj += PvlKeyword("REQUIRED_STORAGE_BYTES", Isis::toString(storagebytes)); mainPvl.addObject(cmpObj); PvlObject ucmpObj("UNCOMPRESSED_FILE"); ucmpObj += PvlKeyword("FILE_NAME", infilename.name()); @@ -280,8 +280,8 @@ namespace Isis { if(p_pixelType == Isis::UnsignedWord || p_pixelType == Isis::SignedWord) { recordbytes = recordbytes * 2; } - ucmpObj += PvlKeyword("RECORD_BYTES", toString(recordbytes)); - ucmpObj += PvlKeyword("FILE_RECORDS", toString(InputCubes[0]->lineCount())); + ucmpObj += PvlKeyword("RECORD_BYTES", Isis::toString(recordbytes)); + ucmpObj += PvlKeyword("FILE_RECORDS", Isis::toString(InputCubes[0]->lineCount())); ucmpObj += PvlKeyword("^IMAGE", infilename.name()); mainPvl.addObject(ucmpObj); } @@ -362,7 +362,7 @@ namespace Isis { if(p_pixelType == Isis::UnsignedWord || p_pixelType == Isis::SignedWord) { storagebytes = storagebytes * 2; } - cmpObj += PvlKeyword("REQUIRED_STORAGE_BYTES", toString(storagebytes)); + cmpObj += PvlKeyword("REQUIRED_STORAGE_BYTES", Isis::toString(storagebytes)); mainPvl.addObject(cmpObj); PvlObject ucmpObj("UNCOMPRESSED_FILE"); ucmpObj += PvlKeyword("FILE_NAME", infilename.name()); @@ -371,8 +371,8 @@ namespace Isis { if(p_pixelType == Isis::UnsignedWord || p_pixelType == Isis::SignedWord) { recordbytes = recordbytes * 2; } - ucmpObj += PvlKeyword("RECORD_BYTES", toString(recordbytes)); - ucmpObj += PvlKeyword("FILE_RECORDS", toString(InputCubes[0]->lineCount())); + ucmpObj += PvlKeyword("RECORD_BYTES", Isis::toString(recordbytes)); + ucmpObj += PvlKeyword("FILE_RECORDS", Isis::toString(InputCubes[0]->lineCount())); ucmpObj += PvlKeyword("^IMAGE", infilename.name()); mainPvl.addObject(ucmpObj); } @@ -436,68 +436,68 @@ namespace Isis { if(!m_forceBandwidth && imgObj.hasKeyword("BANDWIDTH")) imgObj.deleteKeyword("BANDWIDTH"); if(m_forceBandStorageType) imgObj += PvlKeyword("BAND_STORAGE_TYPE", "BAND_SEQUENTIAL"); - if(m_forceOffset) imgObj += PvlKeyword("OFFSET", toString(base)); - if(m_forceScalingFactor) imgObj += PvlKeyword("SCALING_FACTOR", toString(multiplier)); + if(m_forceOffset) imgObj += PvlKeyword("OFFSET", Isis::toString(base)); + if(m_forceScalingFactor) imgObj += PvlKeyword("SCALING_FACTOR", Isis::toString(multiplier)); // Manually set the keyword for pixel type and special pixels if(p_pixelType == Isis::UnsignedByte) { if(m_forceSampleBits) imgObj += PvlKeyword("SAMPLE_BITS", "8"); - if(m_forceSampleBitMask) imgObj += PvlKeyword("SAMPLE_BIT_MASK", toString(0xff)); + if(m_forceSampleBitMask) imgObj += PvlKeyword("SAMPLE_BIT_MASK", Isis::toString(0xff)); if(m_forceSampleType) imgObj += PvlKeyword("SAMPLE_TYPE", "MSB_UNSIGNED_INTEGER"); - if(m_forceCoreNull) imgObj += PvlKeyword("CORE_NULL", toString((int)OutputNull())); - if(m_forceCoreLrs) imgObj += PvlKeyword("CORE_LOW_REPR_SATURATION", toString((int)OutputLrs())); - if(m_forceCoreLis) imgObj += PvlKeyword("CORE_LOW_INSTR_SATURATION", toString((int)OutputLis())); - if(m_forceCoreHrs) imgObj += PvlKeyword("CORE_HIGH_REPR_SATURATION", toString((int)OutputHrs())); - if(m_forceCoreHis) imgObj += PvlKeyword("CORE_HIGH_INSTR_SATURATION", toString((int)OutputHis())); + if(m_forceCoreNull) imgObj += PvlKeyword("CORE_NULL", Isis::toString((int)OutputNull())); + if(m_forceCoreLrs) imgObj += PvlKeyword("CORE_LOW_REPR_SATURATION", Isis::toString((int)OutputLrs())); + if(m_forceCoreLis) imgObj += PvlKeyword("CORE_LOW_INSTR_SATURATION", Isis::toString((int)OutputLis())); + if(m_forceCoreHrs) imgObj += PvlKeyword("CORE_HIGH_REPR_SATURATION", Isis::toString((int)OutputHrs())); + if(m_forceCoreHis) imgObj += PvlKeyword("CORE_HIGH_INSTR_SATURATION", Isis::toString((int)OutputHis())); mainPvl.format()->add("$ISISROOT/appdata/translations/pdsExportImageImagePixel8.typ"); } else if((p_pixelType == Isis::UnsignedWord) && (p_endianType == Isis::Msb)) { if(m_forceSampleBits) imgObj += PvlKeyword("SAMPLE_BITS", "16"); - if(m_forceSampleBitMask) imgObj += PvlKeyword("SAMPLE_BIT_MASK", toString(0xffff)); + if(m_forceSampleBitMask) imgObj += PvlKeyword("SAMPLE_BIT_MASK", Isis::toString(0xffff)); if(m_forceSampleType) imgObj += PvlKeyword("SAMPLE_TYPE", "MSB_UNSIGNED_INTEGER"); - if(m_forceCoreNull) imgObj += PvlKeyword("CORE_NULL", toString((int)OutputNull())); - if(m_forceCoreLrs) imgObj += PvlKeyword("CORE_LOW_REPR_SATURATION", toString((int)OutputLrs())); - if(m_forceCoreLis) imgObj += PvlKeyword("CORE_LOW_INSTR_SATURATION", toString((int)OutputLis())); - if(m_forceCoreHrs) imgObj += PvlKeyword("CORE_HIGH_REPR_SATURATION", toString((int)OutputHrs())); - if(m_forceCoreHis) imgObj += PvlKeyword("CORE_HIGH_INSTR_SATURATION", toString((int)OutputHis())); + if(m_forceCoreNull) imgObj += PvlKeyword("CORE_NULL", Isis::toString((int)OutputNull())); + if(m_forceCoreLrs) imgObj += PvlKeyword("CORE_LOW_REPR_SATURATION", Isis::toString((int)OutputLrs())); + if(m_forceCoreLis) imgObj += PvlKeyword("CORE_LOW_INSTR_SATURATION", Isis::toString((int)OutputLis())); + if(m_forceCoreHrs) imgObj += PvlKeyword("CORE_HIGH_REPR_SATURATION", Isis::toString((int)OutputHrs())); + if(m_forceCoreHis) imgObj += PvlKeyword("CORE_HIGH_INSTR_SATURATION", Isis::toString((int)OutputHis())); mainPvl.format()->add("$ISISROOT/appdata/translations/pdsExportImageImagePixel16.typ"); } else if((p_pixelType == Isis::UnsignedWord) && (p_endianType == Isis::Lsb)) { if(m_forceSampleBits) imgObj += PvlKeyword("SAMPLE_BITS", "16"); - if(m_forceSampleBitMask) imgObj += PvlKeyword("SAMPLE_BIT_MASK", toString(0xffff)); + if(m_forceSampleBitMask) imgObj += PvlKeyword("SAMPLE_BIT_MASK", Isis::toString(0xffff)); if(m_forceSampleType) imgObj += PvlKeyword("SAMPLE_TYPE", "LSB_UNSIGNED_INTEGER"); - if(m_forceCoreNull) imgObj += PvlKeyword("CORE_NULL", toString((int)OutputNull())); - if(m_forceCoreLrs) imgObj += PvlKeyword("CORE_LOW_REPR_SATURATION", toString((int)OutputLrs())); - if(m_forceCoreLis) imgObj += PvlKeyword("CORE_LOW_INSTR_SATURATION", toString((int)OutputLis())); - if(m_forceCoreHrs) imgObj += PvlKeyword("CORE_HIGH_REPR_SATURATION", toString((int)OutputHrs())); - if(m_forceCoreHis) imgObj += PvlKeyword("CORE_HIGH_INSTR_SATURATION", toString((int)OutputHis())); + if(m_forceCoreNull) imgObj += PvlKeyword("CORE_NULL", Isis::toString((int)OutputNull())); + if(m_forceCoreLrs) imgObj += PvlKeyword("CORE_LOW_REPR_SATURATION", Isis::toString((int)OutputLrs())); + if(m_forceCoreLis) imgObj += PvlKeyword("CORE_LOW_INSTR_SATURATION", Isis::toString((int)OutputLis())); + if(m_forceCoreHrs) imgObj += PvlKeyword("CORE_HIGH_REPR_SATURATION", Isis::toString((int)OutputHrs())); + if(m_forceCoreHis) imgObj += PvlKeyword("CORE_HIGH_INSTR_SATURATION", Isis::toString((int)OutputHis())); mainPvl.format()->add("$ISISROOT/appdata/translations/pdsExportImageImagePixel16.typ"); } else if((p_pixelType == Isis::SignedWord) && (p_endianType == Isis::Msb)) { if(m_forceSampleBits) imgObj += PvlKeyword("SAMPLE_BITS", "16"); - if(m_forceSampleBitMask) imgObj += PvlKeyword("SAMPLE_BIT_MASK", toString(0xffff)); + if(m_forceSampleBitMask) imgObj += PvlKeyword("SAMPLE_BIT_MASK", Isis::toString(0xffff)); if(m_forceSampleType) imgObj += PvlKeyword("SAMPLE_TYPE", "MSB_INTEGER"); - if(m_forceCoreNull) imgObj += PvlKeyword("CORE_NULL", toString((int)OutputNull())); - if(m_forceCoreLrs) imgObj += PvlKeyword("CORE_LOW_REPR_SATURATION", toString((int)OutputLrs())); - if(m_forceCoreLis) imgObj += PvlKeyword("CORE_LOW_INSTR_SATURATION", toString((int)OutputLis())); - if(m_forceCoreHrs) imgObj += PvlKeyword("CORE_HIGH_REPR_SATURATION", toString((int)OutputHrs())); - if(m_forceCoreHis) imgObj += PvlKeyword("CORE_HIGH_INSTR_SATURATION", toString((int)OutputHis())); + if(m_forceCoreNull) imgObj += PvlKeyword("CORE_NULL", Isis::toString((int)OutputNull())); + if(m_forceCoreLrs) imgObj += PvlKeyword("CORE_LOW_REPR_SATURATION", Isis::toString((int)OutputLrs())); + if(m_forceCoreLis) imgObj += PvlKeyword("CORE_LOW_INSTR_SATURATION", Isis::toString((int)OutputLis())); + if(m_forceCoreHrs) imgObj += PvlKeyword("CORE_HIGH_REPR_SATURATION", Isis::toString((int)OutputHrs())); + if(m_forceCoreHis) imgObj += PvlKeyword("CORE_HIGH_INSTR_SATURATION", Isis::toString((int)OutputHis())); mainPvl.format()->add("$ISISROOT/appdata/translations/pdsExportImageImagePixel16.typ"); } else if((p_pixelType == Isis::SignedWord) && (p_endianType == Isis::Lsb)) { if(m_forceSampleBits) imgObj += PvlKeyword("SAMPLE_BITS", "16"); - if(m_forceSampleBitMask) imgObj += PvlKeyword("SAMPLE_BIT_MASK", toString((BigInt)0xffff)); + if(m_forceSampleBitMask) imgObj += PvlKeyword("SAMPLE_BIT_MASK", Isis::toString((BigInt)0xffff)); if(m_forceSampleType) imgObj += PvlKeyword("SAMPLE_TYPE", "LSB_INTEGER"); - if(m_forceCoreNull) imgObj += PvlKeyword("CORE_NULL", toString((int)OutputNull())); - if(m_forceCoreLrs) imgObj += PvlKeyword("CORE_LOW_REPR_SATURATION", toString((int)OutputLrs())); - if(m_forceCoreLis) imgObj += PvlKeyword("CORE_LOW_INSTR_SATURATION", toString((int)OutputLis())); - if(m_forceCoreHrs) imgObj += PvlKeyword("CORE_HIGH_REPR_SATURATION", toString((int)OutputHrs())); - if(m_forceCoreHis) imgObj += PvlKeyword("CORE_HIGH_INSTR_SATURATION", toString((int)OutputHis())); + if(m_forceCoreNull) imgObj += PvlKeyword("CORE_NULL", Isis::toString((int)OutputNull())); + if(m_forceCoreLrs) imgObj += PvlKeyword("CORE_LOW_REPR_SATURATION", Isis::toString((int)OutputLrs())); + if(m_forceCoreLis) imgObj += PvlKeyword("CORE_LOW_INSTR_SATURATION", Isis::toString((int)OutputLis())); + if(m_forceCoreHrs) imgObj += PvlKeyword("CORE_HIGH_REPR_SATURATION", Isis::toString((int)OutputHrs())); + if(m_forceCoreHis) imgObj += PvlKeyword("CORE_HIGH_INSTR_SATURATION", Isis::toString((int)OutputHis())); mainPvl.format()->add("$ISISROOT/appdata/translations/pdsExportImageImagePixel16.typ"); } else if(p_pixelType == Isis::Real) { if(m_forceSampleBits) imgObj += PvlKeyword("SAMPLE_BITS", "32"); - if(m_forceSampleBitMask) imgObj += PvlKeyword("SAMPLE_BIT_MASK", toString((BigInt)0xffffffff)); + if(m_forceSampleBitMask) imgObj += PvlKeyword("SAMPLE_BIT_MASK", Isis::toString((BigInt)0xffffffff)); if(p_endianType == Isis::Msb) { if(m_forceSampleType) imgObj += PvlKeyword("SAMPLE_TYPE", "IEEE_REAL"); @@ -505,11 +505,11 @@ namespace Isis { else { if(m_forceSampleType) imgObj += PvlKeyword("SAMPLE_TYPE", "PC_REAL"); } - if(m_forceCoreNull) imgObj += PvlKeyword("CORE_NULL", toString(Isis::INULL4)); - if(m_forceCoreLrs) imgObj += PvlKeyword("CORE_LOW_REPR_SATURATION", toString(Isis::ILOW_REPR_SAT4)); - if(m_forceCoreLis) imgObj += PvlKeyword("CORE_LOW_INSTR_SATURATION", toString(Isis::ILOW_INSTR_SAT4)); - if(m_forceCoreHrs) imgObj += PvlKeyword("CORE_HIGH_REPR_SATURATION", toString(Isis::IHIGH_REPR_SAT4)); - if(m_forceCoreHis) imgObj += PvlKeyword("CORE_HIGH_INSTR_SATURATION", toString(Isis::IHIGH_INSTR_SAT4)); + if(m_forceCoreNull) imgObj += PvlKeyword("CORE_NULL", Isis::toString(Isis::INULL4)); + if(m_forceCoreLrs) imgObj += PvlKeyword("CORE_LOW_REPR_SATURATION", Isis::toString(Isis::ILOW_REPR_SAT4)); + if(m_forceCoreLis) imgObj += PvlKeyword("CORE_LOW_INSTR_SATURATION", Isis::toString(Isis::ILOW_INSTR_SAT4)); + if(m_forceCoreHrs) imgObj += PvlKeyword("CORE_HIGH_REPR_SATURATION", Isis::toString(Isis::IHIGH_REPR_SAT4)); + if(m_forceCoreHis) imgObj += PvlKeyword("CORE_HIGH_INSTR_SATURATION", Isis::toString(Isis::IHIGH_INSTR_SAT4)); mainPvl.format()->add("$ISISROOT/appdata/translations/pdsExportImageImagePixel32.typ"); } else { @@ -580,68 +580,68 @@ namespace Isis { if(!m_forceBandwidth && imgObj.hasKeyword("BANDWIDTH")) imgObj.deleteKeyword("BANDWIDTH"); if(m_forceBandStorageType) imgObj += PvlKeyword("BAND_STORAGE_TYPE", "BAND_SEQUENTIAL"); - if(m_forceOffset) imgObj += PvlKeyword("OFFSET", toString(base)); - if(m_forceScalingFactor) imgObj += PvlKeyword("SCALING_FACTOR", toString(multiplier)); + if(m_forceOffset) imgObj += PvlKeyword("OFFSET", Isis::toString(base)); + if(m_forceScalingFactor) imgObj += PvlKeyword("SCALING_FACTOR", Isis::toString(multiplier)); // Manually set the keyword for pixel type and special pixels if(p_pixelType == Isis::UnsignedByte) { if(m_forceSampleBits) imgObj += PvlKeyword("SAMPLE_BITS", "8"); - if(m_forceSampleBitMask) imgObj += PvlKeyword("SAMPLE_BIT_MASK", toString(0xff)); + if(m_forceSampleBitMask) imgObj += PvlKeyword("SAMPLE_BIT_MASK", Isis::toString(0xff)); if(m_forceSampleType) imgObj += PvlKeyword("SAMPLE_TYPE", "MSB_UNSIGNED_INTEGER"); - if(m_forceCoreNull) imgObj += PvlKeyword("CORE_NULL", toString((int)OutputNull())); - if(m_forceCoreLrs) imgObj += PvlKeyword("CORE_LOW_REPR_SATURATION", toString((int)OutputLrs())); - if(m_forceCoreLis) imgObj += PvlKeyword("CORE_LOW_INSTR_SATURATION", toString((int)OutputLis())); - if(m_forceCoreHrs) imgObj += PvlKeyword("CORE_HIGH_REPR_SATURATION", toString((int)OutputHrs())); - if(m_forceCoreHis) imgObj += PvlKeyword("CORE_HIGH_INSTR_SATURATION", toString((int)OutputHis())); + if(m_forceCoreNull) imgObj += PvlKeyword("CORE_NULL", Isis::toString((int)OutputNull())); + if(m_forceCoreLrs) imgObj += PvlKeyword("CORE_LOW_REPR_SATURATION", Isis::toString((int)OutputLrs())); + if(m_forceCoreLis) imgObj += PvlKeyword("CORE_LOW_INSTR_SATURATION", Isis::toString((int)OutputLis())); + if(m_forceCoreHrs) imgObj += PvlKeyword("CORE_HIGH_REPR_SATURATION", Isis::toString((int)OutputHrs())); + if(m_forceCoreHis) imgObj += PvlKeyword("CORE_HIGH_INSTR_SATURATION", Isis::toString((int)OutputHis())); mainPvl.format()->add("$ISISROOT/appdata/translations/pdsExportImageImagePixel8.typ"); } else if((p_pixelType == Isis::UnsignedWord) && (p_endianType == Isis::Msb)) { if(m_forceSampleBits) imgObj += PvlKeyword("SAMPLE_BITS", "16"); - if(m_forceSampleBitMask) imgObj += PvlKeyword("SAMPLE_BIT_MASK", toString(0xffff)); + if(m_forceSampleBitMask) imgObj += PvlKeyword("SAMPLE_BIT_MASK", Isis::toString(0xffff)); if(m_forceSampleType) imgObj += PvlKeyword("SAMPLE_TYPE", "MSB_UNSIGNED_INTEGER"); - if(m_forceCoreNull) imgObj += PvlKeyword("CORE_NULL", toString((int)OutputNull())); - if(m_forceCoreLrs) imgObj += PvlKeyword("CORE_LOW_REPR_SATURATION", toString((int)OutputLrs())); - if(m_forceCoreLis) imgObj += PvlKeyword("CORE_LOW_INSTR_SATURATION", toString((int)OutputLis())); - if(m_forceCoreHrs) imgObj += PvlKeyword("CORE_HIGH_REPR_SATURATION", toString((int)OutputHrs())); - if(m_forceCoreHis) imgObj += PvlKeyword("CORE_HIGH_INSTR_SATURATION", toString((int)OutputHis())); + if(m_forceCoreNull) imgObj += PvlKeyword("CORE_NULL", Isis::toString((int)OutputNull())); + if(m_forceCoreLrs) imgObj += PvlKeyword("CORE_LOW_REPR_SATURATION", Isis::toString((int)OutputLrs())); + if(m_forceCoreLis) imgObj += PvlKeyword("CORE_LOW_INSTR_SATURATION", Isis::toString((int)OutputLis())); + if(m_forceCoreHrs) imgObj += PvlKeyword("CORE_HIGH_REPR_SATURATION", Isis::toString((int)OutputHrs())); + if(m_forceCoreHis) imgObj += PvlKeyword("CORE_HIGH_INSTR_SATURATION", Isis::toString((int)OutputHis())); mainPvl.format()->add("$ISISROOT/appdata/translations/pdsExportImageImagePixel16.typ"); } else if((p_pixelType == Isis::UnsignedWord) && (p_endianType == Isis::Lsb)) { if(m_forceSampleBits) imgObj += PvlKeyword("SAMPLE_BITS", "16"); - if(m_forceSampleBitMask) imgObj += PvlKeyword("SAMPLE_BIT_MASK", toString(0xffff)); + if(m_forceSampleBitMask) imgObj += PvlKeyword("SAMPLE_BIT_MASK", Isis::toString(0xffff)); if(m_forceSampleType) imgObj += PvlKeyword("SAMPLE_TYPE", "LSB_UNSIGNED_INTEGER"); - if(m_forceCoreNull) imgObj += PvlKeyword("CORE_NULL", toString((int)OutputNull())); - if(m_forceCoreLrs) imgObj += PvlKeyword("CORE_LOW_REPR_SATURATION", toString((int)OutputLrs())); - if(m_forceCoreLis) imgObj += PvlKeyword("CORE_LOW_INSTR_SATURATION", toString((int)OutputLis())); - if(m_forceCoreHrs) imgObj += PvlKeyword("CORE_HIGH_REPR_SATURATION", toString((int)OutputHrs())); - if(m_forceCoreHis) imgObj += PvlKeyword("CORE_HIGH_INSTR_SATURATION", toString((int)OutputHis())); + if(m_forceCoreNull) imgObj += PvlKeyword("CORE_NULL", Isis::toString((int)OutputNull())); + if(m_forceCoreLrs) imgObj += PvlKeyword("CORE_LOW_REPR_SATURATION", Isis::toString((int)OutputLrs())); + if(m_forceCoreLis) imgObj += PvlKeyword("CORE_LOW_INSTR_SATURATION", Isis::toString((int)OutputLis())); + if(m_forceCoreHrs) imgObj += PvlKeyword("CORE_HIGH_REPR_SATURATION", Isis::toString((int)OutputHrs())); + if(m_forceCoreHis) imgObj += PvlKeyword("CORE_HIGH_INSTR_SATURATION", Isis::toString((int)OutputHis())); mainPvl.format()->add("$ISISROOT/appdata/translations/pdsExportImageImagePixel16.typ"); } else if((p_pixelType == Isis::SignedWord) && (p_endianType == Isis::Msb)) { if(m_forceSampleBits) imgObj += PvlKeyword("SAMPLE_BITS", "16"); - if(m_forceSampleBitMask) imgObj += PvlKeyword("SAMPLE_BIT_MASK", toString(0xffff)); + if(m_forceSampleBitMask) imgObj += PvlKeyword("SAMPLE_BIT_MASK", Isis::toString(0xffff)); if(m_forceSampleType) imgObj += PvlKeyword("SAMPLE_TYPE", "MSB_INTEGER"); - if(m_forceCoreNull) imgObj += PvlKeyword("CORE_NULL", toString((int)OutputNull())); - if(m_forceCoreLrs) imgObj += PvlKeyword("CORE_LOW_REPR_SATURATION", toString((int)OutputLrs())); - if(m_forceCoreLis) imgObj += PvlKeyword("CORE_LOW_INSTR_SATURATION", toString((int)OutputLis())); - if(m_forceCoreHrs) imgObj += PvlKeyword("CORE_HIGH_REPR_SATURATION", toString((int)OutputHrs())); - if(m_forceCoreHis) imgObj += PvlKeyword("CORE_HIGH_INSTR_SATURATION", toString((int)OutputHis())); + if(m_forceCoreNull) imgObj += PvlKeyword("CORE_NULL", Isis::toString((int)OutputNull())); + if(m_forceCoreLrs) imgObj += PvlKeyword("CORE_LOW_REPR_SATURATION", Isis::toString((int)OutputLrs())); + if(m_forceCoreLis) imgObj += PvlKeyword("CORE_LOW_INSTR_SATURATION", Isis::toString((int)OutputLis())); + if(m_forceCoreHrs) imgObj += PvlKeyword("CORE_HIGH_REPR_SATURATION", Isis::toString((int)OutputHrs())); + if(m_forceCoreHis) imgObj += PvlKeyword("CORE_HIGH_INSTR_SATURATION", Isis::toString((int)OutputHis())); mainPvl.format()->add("$ISISROOT/appdata/translations/pdsExportImageImagePixel16.typ"); } else if((p_pixelType == Isis::SignedWord) && (p_endianType == Isis::Lsb)) { if(m_forceSampleBits) imgObj += PvlKeyword("SAMPLE_BITS", "16"); - if(m_forceSampleBitMask) imgObj += PvlKeyword("SAMPLE_BIT_MASK", toString((BigInt)0xffff)); + if(m_forceSampleBitMask) imgObj += PvlKeyword("SAMPLE_BIT_MASK", Isis::toString((BigInt)0xffff)); if(m_forceSampleType) imgObj += PvlKeyword("SAMPLE_TYPE", "LSB_INTEGER"); - if(m_forceCoreNull) imgObj += PvlKeyword("CORE_NULL", toString((int)OutputNull())); - if(m_forceCoreLrs) imgObj += PvlKeyword("CORE_LOW_REPR_SATURATION", toString((int)OutputLrs())); - if(m_forceCoreLis) imgObj += PvlKeyword("CORE_LOW_INSTR_SATURATION", toString((int)OutputLis())); - if(m_forceCoreHrs) imgObj += PvlKeyword("CORE_HIGH_REPR_SATURATION", toString((int)OutputHrs())); - if(m_forceCoreHis) imgObj += PvlKeyword("CORE_HIGH_INSTR_SATURATION", toString((int)OutputHis())); + if(m_forceCoreNull) imgObj += PvlKeyword("CORE_NULL", Isis::toString((int)OutputNull())); + if(m_forceCoreLrs) imgObj += PvlKeyword("CORE_LOW_REPR_SATURATION", Isis::toString((int)OutputLrs())); + if(m_forceCoreLis) imgObj += PvlKeyword("CORE_LOW_INSTR_SATURATION", Isis::toString((int)OutputLis())); + if(m_forceCoreHrs) imgObj += PvlKeyword("CORE_HIGH_REPR_SATURATION", Isis::toString((int)OutputHrs())); + if(m_forceCoreHis) imgObj += PvlKeyword("CORE_HIGH_INSTR_SATURATION", Isis::toString((int)OutputHis())); mainPvl.format()->add("$ISISROOT/appdata/translations/pdsExportImageImagePixel16.typ"); } else if(p_pixelType == Isis::Real) { if(m_forceSampleBits) imgObj += PvlKeyword("SAMPLE_BITS", "32"); - if(m_forceSampleBitMask) imgObj += PvlKeyword("SAMPLE_BIT_MASK", toString((BigInt)0xffffffff)); + if(m_forceSampleBitMask) imgObj += PvlKeyword("SAMPLE_BIT_MASK", Isis::toString((BigInt)0xffffffff)); if(p_endianType == Isis::Msb) { if(m_forceSampleType) imgObj += PvlKeyword("SAMPLE_TYPE", "IEEE_REAL"); @@ -649,11 +649,11 @@ namespace Isis { else { if(m_forceSampleType) imgObj += PvlKeyword("SAMPLE_TYPE", "PC_REAL"); } - if(m_forceCoreNull) imgObj += PvlKeyword("CORE_NULL", toString(Isis::INULL4)); - if(m_forceCoreLrs) imgObj += PvlKeyword("CORE_LOW_REPR_SATURATION", toString(Isis::ILOW_REPR_SAT4)); - if(m_forceCoreLis) imgObj += PvlKeyword("CORE_LOW_INSTR_SATURATION", toString(Isis::ILOW_INSTR_SAT4)); - if(m_forceCoreHrs) imgObj += PvlKeyword("CORE_HIGH_REPR_SATURATION", toString(Isis::IHIGH_REPR_SAT4)); - if(m_forceCoreHis) imgObj += PvlKeyword("CORE_HIGH_INSTR_SATURATION", toString(Isis::IHIGH_INSTR_SAT4)); + if(m_forceCoreNull) imgObj += PvlKeyword("CORE_NULL", Isis::toString(Isis::INULL4)); + if(m_forceCoreLrs) imgObj += PvlKeyword("CORE_LOW_REPR_SATURATION", Isis::toString(Isis::ILOW_REPR_SAT4)); + if(m_forceCoreLis) imgObj += PvlKeyword("CORE_LOW_INSTR_SATURATION", Isis::toString(Isis::ILOW_INSTR_SAT4)); + if(m_forceCoreHrs) imgObj += PvlKeyword("CORE_HIGH_REPR_SATURATION", Isis::toString(Isis::IHIGH_REPR_SAT4)); + if(m_forceCoreHis) imgObj += PvlKeyword("CORE_HIGH_INSTR_SATURATION", Isis::toString(Isis::IHIGH_INSTR_SAT4)); mainPvl.format()->add("$ISISROOT/appdata/translations/pdsExportImageImagePixel32.typ"); } else { @@ -702,21 +702,21 @@ namespace Isis { if( (unit.toUpper() == "METERS") || (unit == "") ) { //if no units, assume in meters double dValue = (double)aRadius; dValue /= 1000.0; - aRadius.setValue(toString(dValue), "KM"); + aRadius.setValue(Isis::toString(dValue), "KM"); } PvlKeyword &bRadius = pdsMapObj["B_AXIS_RADIUS"]; unit = QString::fromStdString(bRadius.unit()); if( (unit.toUpper() == "METERS") || (unit == "") ) { double dValue = (double)bRadius; dValue /= 1000.0; - bRadius.setValue(toString(dValue), "KM"); + bRadius.setValue(Isis::toString(dValue), "KM"); } PvlKeyword &cRadius = pdsMapObj["C_AXIS_RADIUS"]; unit = QString::fromStdString(cRadius.unit()); if( (unit.toUpper() == "METERS") || (unit == "") ) { double dValue = (double)cRadius; dValue /= 1000.0; - cRadius.setValue(toString(dValue), "KM"); + cRadius.setValue(Isis::toString(dValue), "KM"); } // Modify the units on MAP_SCALE and MAP_RESOLUTION @@ -727,10 +727,10 @@ namespace Isis { if(m_exportResolution == Kilometer) { double dValue = (double)mapScale; dValue /= 1000.0; - mapScale.setValue(toString(dValue), "KM/PIXEL"); + mapScale.setValue(Isis::toString(dValue), "KM/PIXEL"); } else { - mapScale.setValue(toString((double)mapScale), "METERS/PIXEL"); + mapScale.setValue(Isis::toString((double)mapScale), "METERS/PIXEL"); } } PvlKeyword &mapRes = pdsMapObj["MAP_RESOLUTION"]; @@ -748,12 +748,12 @@ namespace Isis { double maxLon = inputMapping.findKeyword("MaximumLongitude"); double minLon = inputMapping.findKeyword("MinimumLongitude"); if(lonDir == "POSITIVEEAST") { - pdsMapObj += PvlKeyword("EASTERNMOST_LONGITUDE", toString(maxLon)); - pdsMapObj += PvlKeyword("WESTERNMOST_LONGITUDE", toString(minLon)); + pdsMapObj += PvlKeyword("EASTERNMOST_LONGITUDE", Isis::toString(maxLon)); + pdsMapObj += PvlKeyword("WESTERNMOST_LONGITUDE", Isis::toString(minLon)); } else { - pdsMapObj += PvlKeyword("EASTERNMOST_LONGITUDE", toString(minLon)); - pdsMapObj += PvlKeyword("WESTERNMOST_LONGITUDE", toString(maxLon)); + pdsMapObj += PvlKeyword("EASTERNMOST_LONGITUDE", Isis::toString(minLon)); + pdsMapObj += PvlKeyword("WESTERNMOST_LONGITUDE", Isis::toString(maxLon)); } } @@ -765,12 +765,12 @@ namespace Isis { lineOffset /= (double)inputMapping.findKeyword("PixelResolution"); lineOffset *= 1.0; lineOffset -= 0.5; // Add half a line to get to the center of (1,1) - pdsMapObj += PvlKeyword("LINE_PROJECTION_OFFSET", toString(lineOffset), "PIXEL"); + pdsMapObj += PvlKeyword("LINE_PROJECTION_OFFSET", Isis::toString(lineOffset), "PIXEL"); double sampleOffset = inputMapping.findKeyword("UpperLeftCornerX"); sampleOffset /= (double)inputMapping.findKeyword("PixelResolution"); sampleOffset *= -1.0; sampleOffset -= 0.5; // Add half a sample to get to the center of (1,1) - pdsMapObj += PvlKeyword("SAMPLE_PROJECTION_OFFSET", toString(sampleOffset), "PIXEL"); + pdsMapObj += PvlKeyword("SAMPLE_PROJECTION_OFFSET", Isis::toString(sampleOffset), "PIXEL"); // Add units to keywords already in the IMAGE_MAP_PROJECTION object as necessary if(pdsMapObj.hasKeyword("CENTER_LATITUDE")) { @@ -889,9 +889,9 @@ namespace Isis { if(m_exportType == Stream) { if(m_pdsFileType != ProcessExportPds::JP2Image) { - (*m_label)["LABEL_RECORDS"].setValue(toString(labSize), "BYTES"); + (*m_label)["LABEL_RECORDS"].setValue(Isis::toString(labSize), "BYTES"); if(!m_detachedLabel) { - (*m_label)["^IMAGE"].setValue(toString(labSize + 1), "BYTES"); + (*m_label)["^IMAGE"].setValue(Isis::toString(labSize + 1), "BYTES"); } } if(m_label->format() != NULL) { @@ -910,13 +910,13 @@ namespace Isis { int labelRecords; if(m_pdsFileType != ProcessExportPds::JP2Image) { lineBytes = LineBytes(); - (*m_label)["RECORD_BYTES"].setValue(toString(lineBytes)); + (*m_label)["RECORD_BYTES"].setValue(Isis::toString(lineBytes)); // The number of label records is dependent on the number of label bytes // and the lint bytes labelRecords = (int)ceil((double)labSize / (double)lineBytes); if(m_label->hasKeyword("LABEL_RECORDS")) { //LRO MRF doesn't have this keyword - (*m_label)["LABEL_RECORDS"].setValue(toString(labelRecords)); + (*m_label)["LABEL_RECORDS"].setValue(Isis::toString(labelRecords)); } int totalTableRecords = 0; for (unsigned int i = 0; i < m_tableRecords.size(); i++) { @@ -925,10 +925,10 @@ namespace Isis { int imageRecords = InputCubes[0]->lineCount() * InputCubes[0]->bandCount(); int fileRecords = labelRecords + imageRecords + totalTableRecords; - (*m_label)["FILE_RECORDS"].setValue(toString(fileRecords)); + (*m_label)["FILE_RECORDS"].setValue(Isis::toString(fileRecords)); if(!m_detachedLabel) { - (*m_label)["^IMAGE"].setValue(toString(labelRecords + 1)); + (*m_label)["^IMAGE"].setValue(Isis::toString(labelRecords + 1)); } } if(m_label->format() != NULL) { @@ -1034,7 +1034,7 @@ namespace Isis { } // for start record values, indexing begins with 1 int tableStartRecord = 1 + labelRecords + imageRecords + totalTableRecords; - mainPvl += PvlKeyword("^" + pdsTableName.toStdString(), toString(tableStartRecord)); + mainPvl += PvlKeyword("^" + pdsTableName.toStdString(), Isis::toString(tableStartRecord)); } else { mainPvl += PvlKeyword("^" + pdsTableName.toStdString(), detachedPdsTableFileName.toStdString()); diff --git a/isis/src/base/objs/ProcessImportFits/ProcessImportFits.cpp b/isis/src/base/objs/ProcessImportFits/ProcessImportFits.cpp index 777e45eb43..662687127e 100644 --- a/isis/src/base/objs/ProcessImportFits/ProcessImportFits.cpp +++ b/isis/src/base/objs/ProcessImportFits/ProcessImportFits.cpp @@ -162,16 +162,16 @@ namespace Isis { bytesPerPixel /= 8; unsigned int axis1 = 1; - axis1 = IString::ToInteger((*fitsLabel)["NAXIS1"]); + axis1 = Isis::toInt((*fitsLabel)["NAXIS1"]); unsigned int axis2 = 1; if (fitsLabel->hasKeyword("NAXIS2")) { - axis2 = IString::ToInteger((*fitsLabel)["NAXIS2"]); + axis2 = Isis::toInt((*fitsLabel)["NAXIS2"]); } unsigned int axis3 = 1; if (fitsLabel->hasKeyword("NAXIS3")) { - axis3 = IString::ToInteger((*fitsLabel)["NAXIS3"]); + axis3 = Isis::toInt((*fitsLabel)["NAXIS3"]); } jump = (int)(ceil(bytesPerPixel * axis1 * axis2 * axis3 / 2880.0) * 2880.0); @@ -223,9 +223,9 @@ namespace Isis { */ PvlGroup ProcessImportFits::extraFitsLabel(int labelNumber) const { if (labelNumber >= m_extraFitsLabels->size()) { - std::string msg = "The requested label number [" + toString(labelNumber) + "], from file [" + m_name.expanded() + "] is " + std::string msg = "The requested label number [" + Isis::toString(labelNumber) + "], from file [" + m_name.expanded() + "] is " "past the last extra group found in this FITS file. " - "Extra label count is [" + toString(m_extraFitsLabels->size()-1) + "]"; + "Extra label count is [" + Isis::toString(m_extraFitsLabels->size()-1) + "]"; throw IException(IException::User, msg, _FILEINFO_); } @@ -257,9 +257,9 @@ namespace Isis { PvlGroup ProcessImportFits::fitsImageLabel(int labelNumber) const { if (labelNumber >= m_fitsImageLabels->size()) { - std::string msg = "The requested label number [" + toString(labelNumber) + "], from file [" + m_name.expanded() + "] is " + std::string msg = "The requested label number [" + Isis::toString(labelNumber) + "], from file [" + m_name.expanded() + "] is " "past the last image group found in this FITS file. " - "Image label count is [" + toString(m_fitsImageLabels->size()-1) + "]"; + "Image label count is [" + Isis::toString(m_fitsImageLabels->size()-1) + "]"; throw IException(IException::User, msg, _FILEINFO_); } @@ -356,8 +356,8 @@ namespace Isis { void ProcessImportFits::setProcessFileStructure(int labelNumber) { if (labelNumber >= m_fitsImageLabels->size()) { - std::string msg = "The requested label number [" + toString(labelNumber) + "], from file [" + InputFile().toStdString() + "] is " - "past the last image in this FITS file [" + toString(m_fitsImageLabels->size()-1) + "]."; + std::string msg = "The requested label number [" + Isis::toString(labelNumber) + "], from file [" + InputFile().toStdString() + "] is " + "past the last image in this FITS file [" + Isis::toString(m_fitsImageLabels->size()-1) + "]."; throw IException(IException::User, msg, _FILEINFO_); } @@ -370,7 +370,7 @@ namespace Isis { // Find pixel type. NOTE: There are several unsupported possiblites Isis::PixelType type; std::string msg = ""; - switch (IString::ToInteger(label["BITPIX"][0])) { + switch (Isis::toInt(label["BITPIX"][0])) { case 8: type = Isis::UnsignedByte; break; @@ -406,15 +406,15 @@ namespace Isis { // considered part of the DNs. So, use the parent class' prefix/suffix byte count to reduce // the number of samples. if (Organization() == BSQ) { - if (IString::ToInteger(label["NAXIS"][0]) == 2) { - SetDimensions(IString::ToInteger(label["NAXIS1"][0]) + if (Isis::toInt(label["NAXIS"][0]) == 2) { + SetDimensions(Isis::toInt(label["NAXIS1"][0]) - (DataPrefixBytes()+DataSuffixBytes())/SizeOf(type), - IString::ToInteger(label["NAXIS2"][0]), 1); + Isis::toInt(label["NAXIS2"][0]), 1); } - else if (IString::ToInteger(label["NAXIS"][0]) == 3) { - SetDimensions(IString::ToInteger(label["NAXIS1"][0]) + else if (Isis::toInt(label["NAXIS"][0]) == 3) { + SetDimensions(Isis::toInt(label["NAXIS1"][0]) - (DataPrefixBytes()+DataSuffixBytes())/SizeOf(type), - IString::ToInteger(label["NAXIS2"][0]), IString::ToInteger(label["NAXIS3"][0])); + Isis::toInt(label["NAXIS2"][0]), Isis::toInt(label["NAXIS3"][0])); } else { std::string msg = "NAXIS count of [" @@ -424,15 +424,15 @@ namespace Isis { } } else if (Organization() == BIL) { - if (IString::ToInteger(label["NAXIS"][0]) == 2) { - SetDimensions(IString::ToInteger(label["NAXIS1"][0]) + if (Isis::toInt(label["NAXIS"][0]) == 2) { + SetDimensions(Isis::toInt(label["NAXIS1"][0]) - (DataPrefixBytes()+DataSuffixBytes())/SizeOf(type), - 1, IString::ToInteger(label["NAXIS2"][0])); + 1, Isis::toInt(label["NAXIS2"][0])); } - else if (IString::ToInteger(label["NAXIS"][0]) == 3) { - SetDimensions(IString::ToInteger(label["NAXIS1"][0]) + else if (Isis::toInt(label["NAXIS"][0]) == 3) { + SetDimensions(Isis::toInt(label["NAXIS1"][0]) - (DataPrefixBytes()+DataSuffixBytes())/SizeOf(type), - IString::ToInteger(label["NAXIS3"][0]), IString::ToInteger(label["NAXIS2"][0])); + Isis::toInt(label["NAXIS3"][0]), Isis::toInt(label["NAXIS2"][0])); } else { std::string msg = "NAXIS count of [" @@ -453,13 +453,13 @@ namespace Isis { // Base and multiplier if (label.hasKeyword("BZERO")) { - SetBase(IString::ToDouble(label["BZERO"][0])); + SetBase(Isis::toDouble(label["BZERO"][0])); } else { SetBase(0.0); } if (label.hasKeyword("BSCALE")) { - SetMultiplier(IString::ToDouble(label["BSCALE"][0])); + SetMultiplier(Isis::toDouble(label["BSCALE"][0])); } else { SetMultiplier(1.0); diff --git a/isis/src/base/objs/ProcessImportPds/ProcessImportPds.cpp b/isis/src/base/objs/ProcessImportPds/ProcessImportPds.cpp index 34ca366135..3af740ebb4 100644 --- a/isis/src/base/objs/ProcessImportPds/ProcessImportPds.cpp +++ b/isis/src/base/objs/ProcessImportPds/ProcessImportPds.cpp @@ -295,10 +295,10 @@ namespace Isis { p_sampleProjectionOffset = str.toDouble(); p_upperLeftX = xmult * (p_sampleProjectionOffset + xoff) * p_pixelResolution; - p_projectionOffsetGroup.addKeyword(PvlKeyword("xOffset", toString(xoff))); - p_projectionOffsetGroup.addKeyword(PvlKeyword("yOffset", toString(yoff))); - p_projectionOffsetGroup.addKeyword(PvlKeyword("xMultiplier", toString(xmult))); - p_projectionOffsetGroup.addKeyword(PvlKeyword("yMultiplier", toString(ymult))); + p_projectionOffsetGroup.addKeyword(PvlKeyword("xOffset", Isis::toString(xoff))); + p_projectionOffsetGroup.addKeyword(PvlKeyword("yOffset", Isis::toString(yoff))); + p_projectionOffsetGroup.addKeyword(PvlKeyword("xMultiplier", Isis::toString(xmult))); + p_projectionOffsetGroup.addKeyword(PvlKeyword("yMultiplier", Isis::toString(ymult))); } @@ -1153,7 +1153,7 @@ namespace Isis { else { std::string msg = "Invalid PixelType and BitsPerPixel combination [" + str.toStdString() + - ", " + toString(bitsPerPixel) + "]"; + ", " + Isis::toString(bitsPerPixel) + "]"; throw IException(IException::Io, msg, _FILEINFO_); } } @@ -1604,44 +1604,44 @@ namespace Isis { Isis::PvlGroup mapGroup("Mapping"); mapGroup += Isis::PvlKeyword("ProjectionName", p_projection.toStdString()); mapGroup += Isis::PvlKeyword("TargetName", p_targetName.toStdString()); - mapGroup += Isis::PvlKeyword("EquatorialRadius", toString(p_equatorialRadius), "meters"); - mapGroup += Isis::PvlKeyword("PolarRadius", toString(p_polarRadius), "meters"); + mapGroup += Isis::PvlKeyword("EquatorialRadius", Isis::toString(p_equatorialRadius), "meters"); + mapGroup += Isis::PvlKeyword("PolarRadius", Isis::toString(p_polarRadius), "meters"); mapGroup += Isis::PvlKeyword("LongitudeDirection", p_longitudeDirection.toStdString()); - mapGroup += Isis::PvlKeyword("LongitudeDomain", toString(p_longitudeDomain)); + mapGroup += Isis::PvlKeyword("LongitudeDomain", Isis::toString(p_longitudeDomain)); mapGroup += Isis::PvlKeyword("LatitudeType", p_latitudeType.toStdString()); if (p_minimumLatitude != Isis::NULL8) { - mapGroup += Isis::PvlKeyword("MinimumLatitude", toString(p_minimumLatitude)); + mapGroup += Isis::PvlKeyword("MinimumLatitude", Isis::toString(p_minimumLatitude)); } if (p_maximumLatitude != Isis::NULL8) { - mapGroup += Isis::PvlKeyword("MaximumLatitude", toString(p_maximumLatitude)); + mapGroup += Isis::PvlKeyword("MaximumLatitude", Isis::toString(p_maximumLatitude)); } if (p_minimumLongitude != Isis::NULL8) { - mapGroup += Isis::PvlKeyword("MinimumLongitude", toString(p_minimumLongitude)); + mapGroup += Isis::PvlKeyword("MinimumLongitude", Isis::toString(p_minimumLongitude)); } if (p_maximumLongitude != Isis::NULL8) { - mapGroup += Isis::PvlKeyword("MaximumLongitude", toString(p_maximumLongitude)); + mapGroup += Isis::PvlKeyword("MaximumLongitude", Isis::toString(p_maximumLongitude)); } // if both longitudes exist, verify they are ordered correctly if (p_minimumLongitude != Isis::NULL8 && p_maximumLongitude != Isis::NULL8) { if (p_maximumLongitude <= p_minimumLongitude) { if (p_longitudeDomain == 180) { - mapGroup["MinimumLongitude"] = toString(-180); - mapGroup["MaximumLongitude"] = toString(180); + mapGroup["MinimumLongitude"] = Isis::toString(-180); + mapGroup["MaximumLongitude"] = Isis::toString(180); } else { - mapGroup["MinimumLongitude"] = toString(0); - mapGroup["MaximumLongitude"] = toString(360); + mapGroup["MinimumLongitude"] = Isis::toString(0); + mapGroup["MaximumLongitude"] = Isis::toString(360); } } } - mapGroup += Isis::PvlKeyword("PixelResolution", toString(p_pixelResolution), "meters/pixel"); - mapGroup += Isis::PvlKeyword("Scale", toString(p_scaleFactor), "pixels/degree"); - mapGroup += Isis::PvlKeyword("UpperLeftCornerX", toString(p_upperLeftX), "meters"); - mapGroup += Isis::PvlKeyword("UpperLeftCornerY", toString(p_upperLeftY), "meters"); + mapGroup += Isis::PvlKeyword("PixelResolution", Isis::toString(p_pixelResolution), "meters/pixel"); + mapGroup += Isis::PvlKeyword("Scale", Isis::toString(p_scaleFactor), "pixels/degree"); + mapGroup += Isis::PvlKeyword("UpperLeftCornerX", Isis::toString(p_upperLeftX), "meters"); + mapGroup += Isis::PvlKeyword("UpperLeftCornerY", Isis::toString(p_upperLeftY), "meters"); if (p_rotation != 0.0) { - mapGroup += Isis::PvlKeyword("Rotation", toString(p_rotation)); + mapGroup += Isis::PvlKeyword("Rotation", Isis::toString(p_rotation)); } // To handle new projections without the need to modify source code @@ -1659,17 +1659,17 @@ namespace Isis { if (lab.findGroup("Mapping").hasKeyword("CenterLongitude")) { PvlKeyword ¢erLon = lab.findGroup("Mapping")["CenterLongitude"]; if (p_longitudeDomain == 180) - centerLon = toString(TProjection::To180Domain((double)centerLon)); + centerLon = Isis::toString(TProjection::To180Domain((double)centerLon)); else - centerLon = toString(TProjection::To360Domain((double)centerLon)); + centerLon = Isis::toString(TProjection::To360Domain((double)centerLon)); } if (lab.findGroup("Mapping").hasKeyword("PoleLongitude")) { PvlKeyword &poleLon = lab.findGroup("Mapping")["PoleLongitude"]; if (p_longitudeDomain == 180) - poleLon = toString(TProjection::To180Domain((double)poleLon)); + poleLon = Isis::toString(TProjection::To180Domain((double)poleLon)); else - poleLon = toString(TProjection::To360Domain((double)poleLon)); + poleLon = Isis::toString(TProjection::To360Domain((double)poleLon)); } OutputCubes[0]->putGroup(lab.findGroup("Mapping")); diff --git a/isis/src/base/objs/ProcessMapMosaic/ProcessMapMosaic.cpp b/isis/src/base/objs/ProcessMapMosaic/ProcessMapMosaic.cpp index fc5126e321..5e0b37b243 100644 --- a/isis/src/base/objs/ProcessMapMosaic/ProcessMapMosaic.cpp +++ b/isis/src/base/objs/ProcessMapMosaic/ProcessMapMosaic.cpp @@ -365,10 +365,10 @@ namespace Isis { // range. If the current values for the latitude and longitude range are out of // order or equal, then we don't write them to the labels. if (slat < elat && slon < elon) { - mGroup.addKeyword(PvlKeyword("MinimumLatitude", toString(slat)), Pvl::Replace); - mGroup.addKeyword(PvlKeyword("MaximumLatitude", toString(elat)), Pvl::Replace); - mGroup.addKeyword(PvlKeyword("MinimumLongitude", toString(slon)), Pvl::Replace); - mGroup.addKeyword(PvlKeyword("MaximumLongitude", toString(elon)), Pvl::Replace); + mGroup.addKeyword(PvlKeyword("MinimumLatitude", Isis::toString(slat)), Pvl::Replace); + mGroup.addKeyword(PvlKeyword("MaximumLatitude", Isis::toString(elat)), Pvl::Replace); + mGroup.addKeyword(PvlKeyword("MinimumLongitude", Isis::toString(slon)), Pvl::Replace); + mGroup.addKeyword(PvlKeyword("MaximumLongitude", Isis::toString(elon)), Pvl::Replace); } if (mGroup.hasKeyword("UpperLeftCornerX")) @@ -445,10 +445,10 @@ namespace Isis { Pvl label; label.read(propagationCubes[0].toString()); PvlGroup mGroup = label.findGroup("Mapping", Pvl::Traverse); - mGroup.addKeyword(PvlKeyword("MinimumRingRadius", toString(srad)), Pvl::Replace); - mGroup.addKeyword(PvlKeyword("MaximumRingRadius", toString(erad)), Pvl::Replace); - mGroup.addKeyword(PvlKeyword("MinimumRingLongitude", toString(saz)), Pvl::Replace); - mGroup.addKeyword(PvlKeyword("MaximumRingLongitude", toString(eaz)), Pvl::Replace); + mGroup.addKeyword(PvlKeyword("MinimumRingRadius", Isis::toString(srad)), Pvl::Replace); + mGroup.addKeyword(PvlKeyword("MaximumRingRadius", Isis::toString(erad)), Pvl::Replace); + mGroup.addKeyword(PvlKeyword("MinimumRingLongitude", Isis::toString(saz)), Pvl::Replace); + mGroup.addKeyword(PvlKeyword("MaximumRingLongitude", Isis::toString(eaz)), Pvl::Replace); if (mGroup.hasKeyword("UpperLeftCornerX")) mGroup.deleteKeyword("UpperLeftCornerX"); @@ -519,10 +519,10 @@ namespace Isis { // range. If the current values for the latitude and longitude range are out of // order or equal, then we don't write them to the labels. if (latlonflag && slat < elat && slon < elon) { - mapping.addKeyword(PvlKeyword("MinimumLatitude", toString(slat)), Pvl::Replace); - mapping.addKeyword(PvlKeyword("MaximumLatitude", toString(elat)), Pvl::Replace); - mapping.addKeyword(PvlKeyword("MinimumLongitude", toString(slon)), Pvl::Replace); - mapping.addKeyword(PvlKeyword("MaximumLongitude", toString(elon)), Pvl::Replace); + mapping.addKeyword(PvlKeyword("MinimumLatitude", Isis::toString(slat)), Pvl::Replace); + mapping.addKeyword(PvlKeyword("MaximumLatitude", Isis::toString(elat)), Pvl::Replace); + mapping.addKeyword(PvlKeyword("MinimumLongitude", Isis::toString(slon)), Pvl::Replace); + mapping.addKeyword(PvlKeyword("MaximumLongitude", Isis::toString(elon)), Pvl::Replace); } else { if (mapping.hasKeyword("MinimumLatitude")) { @@ -613,12 +613,12 @@ namespace Isis { Pvl fileLab(inputFile.toStdString()); PvlGroup &mapping = fileLab.findGroup("Mapping", Pvl::Traverse); - mapping["UpperLeftCornerX"] = toString(xmin); - mapping["UpperLeftCornerY"] = toString(ymax); - mapping.addKeyword(PvlKeyword("MinimumRingRadius", toString(srad)), Pvl::Replace); - mapping.addKeyword(PvlKeyword("MaximumRingRadius", toString(erad)), Pvl::Replace); - mapping.addKeyword(PvlKeyword("MinimumRingLongitude", toString(saz)), Pvl::Replace); - mapping.addKeyword(PvlKeyword("MaximumRingLongitude", toString(eaz)), Pvl::Replace); + mapping["UpperLeftCornerX"] = Isis::toString(xmin); + mapping["UpperLeftCornerY"] = Isis::toString(ymax); + mapping.addKeyword(PvlKeyword("MinimumRingRadius", Isis::toString(srad)), Pvl::Replace); + mapping.addKeyword(PvlKeyword("MaximumRingRadius", Isis::toString(erad)), Pvl::Replace); + mapping.addKeyword(PvlKeyword("MinimumRingLongitude", Isis::toString(saz)), Pvl::Replace); + mapping.addKeyword(PvlKeyword("MaximumRingLongitude", Isis::toString(eaz)), Pvl::Replace); Projection *firstProj = ProjectionFactory::RingsCreateFromCube(fileLab); int samps = (int)(ceil(firstProj->ToWorldX(xmax) - firstProj->ToWorldX(xmin)) + 0.5); diff --git a/isis/src/base/objs/ProcessMapMosaic/unitTest.cpp b/isis/src/base/objs/ProcessMapMosaic/unitTest.cpp index e9dbb1c3fb..87f852e71e 100644 --- a/isis/src/base/objs/ProcessMapMosaic/unitTest.cpp +++ b/isis/src/base/objs/ProcessMapMosaic/unitTest.cpp @@ -116,10 +116,10 @@ void IsisMain() { inCube.open(QString::fromStdString(inputFile)); PvlGroup mapGroup = inCube.label()->findGroup("Mapping", Pvl::Traverse); - mapGroup.addKeyword(PvlKeyword("MinimumLatitude", toString(-4.9)), Pvl::Replace); - mapGroup.addKeyword(PvlKeyword("MaximumLatitude", toString(-4.7)), Pvl::Replace); - mapGroup.addKeyword(PvlKeyword("MinimumLongitude", toString(30.7)), Pvl::Replace); - mapGroup.addKeyword(PvlKeyword("MaximumLongitude", toString(31)), Pvl::Replace); + mapGroup.addKeyword(PvlKeyword("MinimumLatitude", Isis::toString(-4.9)), Pvl::Replace); + mapGroup.addKeyword(PvlKeyword("MaximumLatitude", Isis::toString(-4.7)), Pvl::Replace); + mapGroup.addKeyword(PvlKeyword("MinimumLongitude", Isis::toString(30.7)), Pvl::Replace); + mapGroup.addKeyword(PvlKeyword("MaximumLongitude", Isis::toString(31)), Pvl::Replace); inCube.close(); CubeAttributeOutput oAtt2( FileName("./unitTest3.cub") ); diff --git a/isis/src/base/objs/ProcessMosaic/ProcessMosaic.cpp b/isis/src/base/objs/ProcessMosaic/ProcessMosaic.cpp index 714d578fac..5e06fd19b6 100644 --- a/isis/src/base/objs/ProcessMosaic/ProcessMosaic.cpp +++ b/isis/src/base/objs/ProcessMosaic/ProcessMosaic.cpp @@ -165,8 +165,8 @@ namespace Isis { PvlGroup imgPosition("ImageLocation"); imgPosition += PvlKeyword("File", InputCubes[0]->fileName().toStdString()); - imgPosition += PvlKeyword("StartSample", toString(m_oss)); - imgPosition += PvlKeyword("StartLine", toString(m_osl)); + imgPosition += PvlKeyword("StartSample", Isis::toString(m_oss)); + imgPosition += PvlKeyword("StartLine", Isis::toString(m_osl)); m_imagePositions += imgPosition; // Tests for completly off the mosaic @@ -919,7 +919,7 @@ namespace Isis { if (result == "") { throw IException(IException::Unknown, - "Cannot convert overlay [" + toString((int)imageOverlay) + "] to a string", + "Cannot convert overlay [" + Isis::toString((int)imageOverlay) + "] to a string", _FILEINFO_); } @@ -1117,8 +1117,8 @@ namespace Isis { else if (outKey[j] != inKey[k]) { std::string msg = "The input cube [" + inLab->fileName() + "] and the base mosaic values " "of the Pvl Group [BandBin] for Keyword [" + outKey.name() + "] do not " - "match. Base mosaic value at index [" + toString(j) + "] = " + - outKey[j] + ". Input cube value at index [" + toString(k) + "] = " + "match. Base mosaic value at index [" + Isis::toString(j) + "] = " + + outKey[j] + ". Input cube value at index [" + Isis::toString(k) + "] = " + inKey[k] + ". **Note: use mapmos/automos MatchBandBin = false to " "override this check**"; //std::string msg = "Pvl Group [BandBin] in Key[" + outKey.name() + "] In value" + inKey[k] + diff --git a/isis/src/base/objs/Projection/Projection.cpp b/isis/src/base/objs/Projection/Projection.cpp index 03f667b4e9..fd4af7c217 100644 --- a/isis/src/base/objs/Projection/Projection.cpp +++ b/isis/src/base/objs/Projection/Projection.cpp @@ -1372,8 +1372,8 @@ namespace Isis { */ void Projection::SetUpperLeftCorner(const Displacement &x, const Displacement &y) { - PvlKeyword xKeyword("UpperLeftCornerX", toString(x.meters()), "meters"); - PvlKeyword yKeyword("UpperLeftCornerY", toString(y.meters()), "meters"); + PvlKeyword xKeyword("UpperLeftCornerX", Isis::toString(x.meters()), "meters"); + PvlKeyword yKeyword("UpperLeftCornerY", Isis::toString(y.meters()), "meters"); m_mappingGrp.addKeyword(xKeyword,Pvl::Replace); m_mappingGrp.addKeyword(yKeyword,Pvl::Replace); } diff --git a/isis/src/base/objs/Projection/unitTest.cpp b/isis/src/base/objs/Projection/unitTest.cpp index c98acea3f2..b7a2274ee7 100644 --- a/isis/src/base/objs/Projection/unitTest.cpp +++ b/isis/src/base/objs/Projection/unitTest.cpp @@ -460,7 +460,7 @@ int main(int argc, char *argv[]) { cout << endl; cout << "Test == operator with pixel resolutions not matching, but names do" << endl; - mg += PvlKeyword("PixelResolution", toString(2.0)); + mg += PvlKeyword("PixelResolution", Isis::toString(2.0)); MyProjection pMy3(lab); pMy3.SetWorldMapper(new MyMapper()); cout << "Projection 1 resolution = " << p.Resolution() << endl; @@ -529,18 +529,18 @@ int main(int argc, char *argv[]) { Isis::PvlGroup &latTestGroup = latRangeTest.findGroup("Mapping"); latTestGroup += Isis::PvlKeyword("TargetName", "Moon"); latTestGroup += Isis::PvlKeyword("ProjectionName", "PolarStereographic"); - latTestGroup += Isis::PvlKeyword("EquatorialRadius", toString(1737400.0)); - latTestGroup += Isis::PvlKeyword("PolarRadius", toString(1737400.0)); + latTestGroup += Isis::PvlKeyword("EquatorialRadius", Isis::toString(1737400.0)); + latTestGroup += Isis::PvlKeyword("PolarRadius", Isis::toString(1737400.0)); latTestGroup += Isis::PvlKeyword("LatitudeType", "Planetocentric"); latTestGroup += Isis::PvlKeyword("LongitudeDirection", "PositiveEast"); - latTestGroup += Isis::PvlKeyword("LongitudeDomain", toString(360)); - latTestGroup += Isis::PvlKeyword("Scale", toString(5.0)); - latTestGroup += Isis::PvlKeyword("MinimumLatitude", toString(-90.0)); - latTestGroup += Isis::PvlKeyword("MaximumLatitude", toString(-45.0)); - latTestGroup += Isis::PvlKeyword("MinimumLongitude", toString(0.0)); - latTestGroup += Isis::PvlKeyword("MaximumLongitude", toString(360.0)); - latTestGroup += Isis::PvlKeyword("CenterLatitude", toString(-90.0)); - latTestGroup += Isis::PvlKeyword("CenterLongitude", toString(0.0)); + latTestGroup += Isis::PvlKeyword("LongitudeDomain", Isis::toString(360)); + latTestGroup += Isis::PvlKeyword("Scale", Isis::toString(5.0)); + latTestGroup += Isis::PvlKeyword("MinimumLatitude", Isis::toString(-90.0)); + latTestGroup += Isis::PvlKeyword("MaximumLatitude", Isis::toString(-45.0)); + latTestGroup += Isis::PvlKeyword("MinimumLongitude", Isis::toString(0.0)); + latTestGroup += Isis::PvlKeyword("MaximumLongitude", Isis::toString(360.0)); + latTestGroup += Isis::PvlKeyword("CenterLatitude", Isis::toString(-90.0)); + latTestGroup += Isis::PvlKeyword("CenterLongitude", Isis::toString(0.0)); Isis::Projection &latTestProjection = *Isis::ProjectionFactory::Create(latRangeTest); cout << "PolarStereographic Projection Specifications" << endl; @@ -654,7 +654,7 @@ int main(int argc, char *argv[]) { cout << endl; cout << "Rotation Tests" << endl; - mg += PvlKeyword("Rotation", toString(90.0)); + mg += PvlKeyword("Rotation", Isis::toString(90.0)); mg["LongitudeDirection"] = "PositiveEast"; mg.deleteKeyword("EquatorialRadius"); mg.deleteKeyword("PolarRadius"); diff --git a/isis/src/base/objs/ProjectionFactory/ProjectionFactory.cpp b/isis/src/base/objs/ProjectionFactory/ProjectionFactory.cpp index 8daafcbb87..9cdc92146c 100644 --- a/isis/src/base/objs/ProjectionFactory/ProjectionFactory.cpp +++ b/isis/src/base/objs/ProjectionFactory/ProjectionFactory.cpp @@ -212,9 +212,9 @@ namespace Isis { pixelResolution = (2.0 * Isis::PI * localRadius) / (360.0 * scale); } // Write out the scale and resolution with units and truescale latitude - mapGroup.addKeyword(Isis::PvlKeyword("PixelResolution", toString(pixelResolution), "meters/pixel"), + mapGroup.addKeyword(Isis::PvlKeyword("PixelResolution", Isis::toString(pixelResolution), "meters/pixel"), Isis::Pvl::Replace); - mapGroup.addKeyword(Isis::PvlKeyword("Scale", toString(scale), "pixels/degree"), Isis::Pvl::Replace); + mapGroup.addKeyword(Isis::PvlKeyword("Scale", Isis::toString(scale), "pixels/degree"), Isis::Pvl::Replace); //mapGroup.addKeyword(Isis::PvlKeyword ("TrueScaleLatitude", trueScaleLat), // Isis::Pvl::Replace); @@ -334,7 +334,7 @@ namespace Isis { else { upperLeftX = minXFlipped; } - mapGroup.addKeyword(Isis::PvlKeyword("UpperLeftCornerX", toString(upperLeftX)), + mapGroup.addKeyword(Isis::PvlKeyword("UpperLeftCornerX", Isis::toString(upperLeftX)), Isis::Pvl::Replace); if (flipY) { @@ -346,7 +346,7 @@ namespace Isis { } - mapGroup.addKeyword(Isis::PvlKeyword("UpperLeftCornerY", toString(upperLeftY)), + mapGroup.addKeyword(Isis::PvlKeyword("UpperLeftCornerY", Isis::toString(upperLeftY)), Isis::Pvl::Replace); // Write it in pixel units as well @@ -457,10 +457,10 @@ namespace Isis { } // Write out the scale and resolution with units and truescale radius - mapGroup.addKeyword(Isis::PvlKeyword("PixelResolution", toString(pixelResolution), + mapGroup.addKeyword(Isis::PvlKeyword("PixelResolution", Isis::toString(pixelResolution), "meters/pixel"), Isis::Pvl::Replace); - mapGroup.addKeyword(Isis::PvlKeyword("Scale", toString(scale), "pixels/degree"), + mapGroup.addKeyword(Isis::PvlKeyword("Scale", Isis::toString(scale), "pixels/degree"), Isis::Pvl::Replace); //mapGroup.AddKeyword(Isis::PvlKeyword ("TrueScaleRadius", trueScaleRadius), @@ -539,11 +539,11 @@ namespace Isis { // Set the upper left corner and add to the labels upperLeftX = minX; - mapGroup.addKeyword(Isis::PvlKeyword("UpperLeftCornerX", toString(upperLeftX)), + mapGroup.addKeyword(Isis::PvlKeyword("UpperLeftCornerX", Isis::toString(upperLeftX)), Isis::Pvl::Replace); upperLeftY = maxY; - mapGroup.addKeyword(Isis::PvlKeyword("UpperLeftCornerY", toString(upperLeftY)), + mapGroup.addKeyword(Isis::PvlKeyword("UpperLeftCornerY", Isis::toString(upperLeftY)), Isis::Pvl::Replace); // Write it in pixel units as well @@ -642,9 +642,9 @@ namespace Isis { pixelResolution = (2.0 * Isis::PI * localRadius) / (360.0 * scale); } // Write out the scale and resolution with units and truescale latitude - mapGroup.addKeyword(Isis::PvlKeyword("PixelResolution", toString(pixelResolution), "meters/pixel"), + mapGroup.addKeyword(Isis::PvlKeyword("PixelResolution", Isis::toString(pixelResolution), "meters/pixel"), Isis::Pvl::Replace); - mapGroup.addKeyword(Isis::PvlKeyword("Scale", toString(scale), "pixels/degree"), Isis::Pvl::Replace); + mapGroup.addKeyword(Isis::PvlKeyword("Scale", Isis::toString(scale), "pixels/degree"), Isis::Pvl::Replace); //mapGroup.AddKeyword(Isis::PvlKeyword ("TrueScaleLatitude", trueScaleLatitude), // Isis::Pvl::Replace); @@ -797,11 +797,11 @@ namespace Isis { // Set the upper left corner and add to the labels double upperLeftX = minX; - mapGroup.addKeyword(Isis::PvlKeyword("UpperLeftCornerX", toString(upperLeftX)), + mapGroup.addKeyword(Isis::PvlKeyword("UpperLeftCornerX", Isis::toString(upperLeftX)), Isis::Pvl::Replace); double upperLeftY = maxY; - mapGroup.addKeyword(Isis::PvlKeyword("UpperLeftCornerY", toString(upperLeftY)), + mapGroup.addKeyword(Isis::PvlKeyword("UpperLeftCornerY", Isis::toString(upperLeftY)), Isis::Pvl::Replace); // Make sure labels have good units @@ -895,9 +895,9 @@ namespace Isis { pixelResolution = (2.0 * Isis::PI * localRadius) / (360.0 * scale); } // Write out the scale and resolution with units and truescale radius - mapGroup.addKeyword(Isis::PvlKeyword("PixelResolution", toString(pixelResolution), + mapGroup.addKeyword(Isis::PvlKeyword("PixelResolution", Isis::toString(pixelResolution), "meters/pixel"), Isis::Pvl::Replace); - mapGroup.addKeyword(Isis::PvlKeyword("Scale", toString(scale), "pixels/degree"), + mapGroup.addKeyword(Isis::PvlKeyword("Scale", Isis::toString(scale), "pixels/degree"), Isis::Pvl::Replace); // Initialize the rest of the projection @@ -1019,11 +1019,11 @@ namespace Isis { // Set the upper left corner and add to the labels double upperLeftX = minX; - mapGroup.addKeyword(Isis::PvlKeyword("UpperLeftCornerX", toString(upperLeftX)), + mapGroup.addKeyword(Isis::PvlKeyword("UpperLeftCornerX", Isis::toString(upperLeftX)), Isis::Pvl::Replace); double upperLeftY = maxY; - mapGroup.addKeyword(Isis::PvlKeyword("UpperLeftCornerY", toString(upperLeftY)), + mapGroup.addKeyword(Isis::PvlKeyword("UpperLeftCornerY", Isis::toString(upperLeftY)), Isis::Pvl::Replace); // Make sure labels have good units diff --git a/isis/src/base/objs/ProjectionFactory/unitTest.cpp b/isis/src/base/objs/ProjectionFactory/unitTest.cpp index a8aea67ffb..bd84486d79 100644 --- a/isis/src/base/objs/ProjectionFactory/unitTest.cpp +++ b/isis/src/base/objs/ProjectionFactory/unitTest.cpp @@ -30,29 +30,29 @@ int main(int argc, char *argv[]) { Pvl lab; lab.addGroup(PvlGroup("Mapping")); PvlGroup &mapGroup = lab.findGroup("Mapping"); - mapGroup += PvlKeyword("EquatorialRadius", toString(3396190.0)); - mapGroup += PvlKeyword("PolarRadius", toString(3376200.0)); + mapGroup += PvlKeyword("EquatorialRadius", Isis::toString(3396190.0)); + mapGroup += PvlKeyword("PolarRadius", Isis::toString(3376200.0)); mapGroup += PvlKeyword("LatitudeType", "Planetographic"); mapGroup += PvlKeyword("LongitudeDirection", "PositiveEast"); - mapGroup += PvlKeyword("LongitudeDomain", toString(360)); + mapGroup += PvlKeyword("LongitudeDomain", Isis::toString(360)); mapGroup += PvlKeyword("ProjectionName", "SimpleCylindrical"); - mapGroup += PvlKeyword("CenterLongitude", toString(220.0)); + mapGroup += PvlKeyword("CenterLongitude", Isis::toString(220.0)); cout << "Test for missing pixel resolution ... " << endl; doit(lab); doit2(lab); - mapGroup += PvlKeyword("PixelResolution", toString(2000.0)); + mapGroup += PvlKeyword("PixelResolution", Isis::toString(2000.0)); cout << "Test for missing upper left X ... " << endl; doit(lab); - mapGroup += PvlKeyword("UpperLeftCornerX", toString(-18000.0)); + mapGroup += PvlKeyword("UpperLeftCornerX", Isis::toString(-18000.0)); cout << "Test for missing upper left Y ... " << endl; doit(lab); - mapGroup += PvlKeyword("UpperLeftCornerY", toString(2062000.0)); + mapGroup += PvlKeyword("UpperLeftCornerY", Isis::toString(2062000.0)); cout << "Testing conversion from image to ground ... " << endl; TProjection *proj = (TProjection *) ProjectionFactory::CreateFromCube(lab); @@ -71,10 +71,10 @@ int main(int argc, char *argv[]) { cout << "Testing missing ground range on create method ... " << endl; doit2(lab); - mapGroup += PvlKeyword("MinimumLatitude", toString(10.8920539924144)); - mapGroup += PvlKeyword("MaximumLatitude", toString(34.7603960060206)); - mapGroup += PvlKeyword("MinimumLongitude", toString(219.72432466275)); - mapGroup += PvlKeyword("MaximumLongitude", toString(236.186050244411)); + mapGroup += PvlKeyword("MinimumLatitude", Isis::toString(10.8920539924144)); + mapGroup += PvlKeyword("MaximumLatitude", Isis::toString(34.7603960060206)); + mapGroup += PvlKeyword("MinimumLongitude", Isis::toString(219.72432466275)); + mapGroup += PvlKeyword("MaximumLongitude", Isis::toString(236.186050244411)); mapGroup.deleteKeyword("UpperLeftCornerX"); mapGroup.deleteKeyword("UpperLeftCornerY"); @@ -88,15 +88,15 @@ int main(int argc, char *argv[]) { cout << endl; cout << "Testing create method with existing cube labels" << endl; - mapGroup.addKeyword(PvlKeyword("UpperLeftCornerX", toString(-16000.0)), Pvl::Replace); - mapGroup.addKeyword(PvlKeyword("UpperLeftCornerY", toString(2060000.0)), Pvl::Replace); + mapGroup.addKeyword(PvlKeyword("UpperLeftCornerX", Isis::toString(-16000.0)), Pvl::Replace); + mapGroup.addKeyword(PvlKeyword("UpperLeftCornerY", Isis::toString(2060000.0)), Pvl::Replace); Pvl lab2; PvlObject icube("IsisCube"); PvlObject core("Core"); PvlGroup dims("Dimensions"); - dims += PvlKeyword("Lines", toString(400)); - dims += PvlKeyword("Samples", toString(600)); + dims += PvlKeyword("Lines", Isis::toString(400)); + dims += PvlKeyword("Samples", Isis::toString(600)); core.addGroup(dims); icube.addObject(core); icube.addGroup(mapGroup); @@ -122,18 +122,18 @@ int main(int argc, char *argv[]) { Pvl lab; lab.addGroup(PvlGroup("Mapping")); PvlGroup &mapGroup = lab.findGroup("Mapping"); - mapGroup += PvlKeyword("EquatorialRadius", toString(3396190.0)); - mapGroup += PvlKeyword("PolarRadius", toString(3376200.0)); + mapGroup += PvlKeyword("EquatorialRadius", Isis::toString(3396190.0)); + mapGroup += PvlKeyword("PolarRadius", Isis::toString(3376200.0)); mapGroup += PvlKeyword("LatitudeType", "Planetographic"); mapGroup += PvlKeyword("LongitudeDirection", "PositiveEast"); - mapGroup += PvlKeyword("LongitudeDomain", toString(360)); + mapGroup += PvlKeyword("LongitudeDomain", Isis::toString(360)); mapGroup += PvlKeyword("ProjectionName", "UnsupportedProjection"); - mapGroup += PvlKeyword("CenterLongitude", toString(220.0)); - mapGroup += PvlKeyword("PixelResolution", toString(2000.0)); - mapGroup += PvlKeyword("UpperLeftCornerX", toString(-18000.0)); - mapGroup += PvlKeyword("UpperLeftCornerY", toString(2062000.0)); + mapGroup += PvlKeyword("CenterLongitude", Isis::toString(220.0)); + mapGroup += PvlKeyword("PixelResolution", Isis::toString(2000.0)); + mapGroup += PvlKeyword("UpperLeftCornerX", Isis::toString(-18000.0)); + mapGroup += PvlKeyword("UpperLeftCornerY", Isis::toString(2062000.0)); TProjection *proj = (TProjection *) ProjectionFactory::Create(lab); proj->SetWorld(245.0, 355.0); @@ -153,18 +153,18 @@ int main(int argc, char *argv[]) { southMap.addGroup(PvlGroup("Mapping")); PvlGroup &mapGroupSouth = southMap.findGroup("Mapping"); mapGroupSouth += PvlKeyword("ProjectionName", "Equirectangular"); - mapGroupSouth += PvlKeyword("CenterLongitude", toString(0.0)); - mapGroupSouth += PvlKeyword("CenterLatitude", toString(0.0)); - mapGroupSouth += PvlKeyword("EquatorialRadius", toString(13400.0)); - mapGroupSouth += PvlKeyword("PolarRadius", toString(9200.0)); + mapGroupSouth += PvlKeyword("CenterLongitude", Isis::toString(0.0)); + mapGroupSouth += PvlKeyword("CenterLatitude", Isis::toString(0.0)); + mapGroupSouth += PvlKeyword("EquatorialRadius", Isis::toString(13400.0)); + mapGroupSouth += PvlKeyword("PolarRadius", Isis::toString(9200.0)); mapGroupSouth += PvlKeyword("LatitudeType", "Planetocentric"); mapGroupSouth += PvlKeyword("LongitudeDirection", "PositiveEast"); - mapGroupSouth += PvlKeyword("LongitudeDomain", toString(360)); - mapGroupSouth += PvlKeyword("MinimumLatitude", toString(-60.0)); - mapGroupSouth += PvlKeyword("MaximumLatitude", toString(0.0)); - mapGroupSouth += PvlKeyword("MinimumLongitude", toString(0.0)); - mapGroupSouth += PvlKeyword("MaximumLongitude", toString(360.0)); - mapGroupSouth += PvlKeyword("PixelResolution", toString(10.0)); + mapGroupSouth += PvlKeyword("LongitudeDomain", Isis::toString(360)); + mapGroupSouth += PvlKeyword("MinimumLatitude", Isis::toString(-60.0)); + mapGroupSouth += PvlKeyword("MaximumLatitude", Isis::toString(0.0)); + mapGroupSouth += PvlKeyword("MinimumLongitude", Isis::toString(0.0)); + mapGroupSouth += PvlKeyword("MaximumLongitude", Isis::toString(360.0)); + mapGroupSouth += PvlKeyword("PixelResolution", Isis::toString(10.0)); Pvl northMap; @@ -172,18 +172,18 @@ int main(int argc, char *argv[]) { northMap.addGroup(PvlGroup("Mapping")); PvlGroup &mapGroupNorth = northMap.findGroup("Mapping"); mapGroupNorth += PvlKeyword("ProjectionName", "Equirectangular"); - mapGroupNorth += PvlKeyword("CenterLongitude", toString(0.0)); - mapGroupNorth += PvlKeyword("CenterLatitude", toString(0.0)); - mapGroupNorth += PvlKeyword("EquatorialRadius", toString(13400.0)); - mapGroupNorth += PvlKeyword("PolarRadius", toString(9200.0)); + mapGroupNorth += PvlKeyword("CenterLongitude", Isis::toString(0.0)); + mapGroupNorth += PvlKeyword("CenterLatitude", Isis::toString(0.0)); + mapGroupNorth += PvlKeyword("EquatorialRadius", Isis::toString(13400.0)); + mapGroupNorth += PvlKeyword("PolarRadius", Isis::toString(9200.0)); mapGroupNorth += PvlKeyword("LatitudeType", "Planetocentric"); mapGroupNorth += PvlKeyword("LongitudeDirection", "PositiveEast"); - mapGroupNorth += PvlKeyword("LongitudeDomain", toString(360)); - mapGroupNorth += PvlKeyword("MinimumLatitude", toString(0.0)); - mapGroupNorth += PvlKeyword("MaximumLatitude", toString(60.0)); - mapGroupNorth += PvlKeyword("MinimumLongitude", toString(0.0)); - mapGroupNorth += PvlKeyword("MaximumLongitude", toString(360.0)); - mapGroupNorth += PvlKeyword("PixelResolution", toString(10.0)); + mapGroupNorth += PvlKeyword("LongitudeDomain", Isis::toString(360)); + mapGroupNorth += PvlKeyword("MinimumLatitude", Isis::toString(0.0)); + mapGroupNorth += PvlKeyword("MaximumLatitude", Isis::toString(60.0)); + mapGroupNorth += PvlKeyword("MinimumLongitude", Isis::toString(0.0)); + mapGroupNorth += PvlKeyword("MaximumLongitude", Isis::toString(360.0)); + mapGroupNorth += PvlKeyword("PixelResolution", Isis::toString(10.0)); TProjection *projNorth = (TProjection *) ProjectionFactory::CreateForCube(southMap, @@ -223,18 +223,18 @@ int main(int argc, char *argv[]) { eastMap.addGroup(PvlGroup("Mapping")); PvlGroup &mapGroupEast = eastMap.findGroup("Mapping"); mapGroupEast += PvlKeyword("ProjectionName", "Equirectangular"); - mapGroupEast += PvlKeyword("CenterLongitude", toString(0.0)); - mapGroupEast += PvlKeyword("CenterLatitude", toString(0.0)); - mapGroupEast += PvlKeyword("EquatorialRadius", toString(13400.0)); - mapGroupEast += PvlKeyword("PolarRadius", toString(9200.0)); + mapGroupEast += PvlKeyword("CenterLongitude", Isis::toString(0.0)); + mapGroupEast += PvlKeyword("CenterLatitude", Isis::toString(0.0)); + mapGroupEast += PvlKeyword("EquatorialRadius", Isis::toString(13400.0)); + mapGroupEast += PvlKeyword("PolarRadius", Isis::toString(9200.0)); mapGroupEast += PvlKeyword("LatitudeType", "Planetocentric"); mapGroupEast += PvlKeyword("LongitudeDirection", "PositiveEast"); - mapGroupEast += PvlKeyword("LongitudeDomain", toString(360)); - mapGroupEast += PvlKeyword("MinimumLatitude", toString(0.0)); - mapGroupEast += PvlKeyword("MaximumLatitude", toString(60.0)); - mapGroupEast += PvlKeyword("MinimumLongitude", toString(0.0)); - mapGroupEast += PvlKeyword("MaximumLongitude", toString(90.0)); - mapGroupEast += PvlKeyword("PixelResolution", toString(10.0)); + mapGroupEast += PvlKeyword("LongitudeDomain", Isis::toString(360)); + mapGroupEast += PvlKeyword("MinimumLatitude", Isis::toString(0.0)); + mapGroupEast += PvlKeyword("MaximumLatitude", Isis::toString(60.0)); + mapGroupEast += PvlKeyword("MinimumLongitude", Isis::toString(0.0)); + mapGroupEast += PvlKeyword("MaximumLongitude", Isis::toString(90.0)); + mapGroupEast += PvlKeyword("PixelResolution", Isis::toString(10.0)); Pvl westMap; @@ -242,18 +242,18 @@ int main(int argc, char *argv[]) { westMap.addGroup(PvlGroup("Mapping")); PvlGroup &mapGroupWest = westMap.findGroup("Mapping"); mapGroupWest += PvlKeyword("ProjectionName", "Equirectangular"); - mapGroupWest += PvlKeyword("CenterLongitude", toString(0.0)); - mapGroupWest += PvlKeyword("CenterLatitude", toString(0.0)); - mapGroupWest += PvlKeyword("EquatorialRadius", toString(13400.0)); - mapGroupWest += PvlKeyword("PolarRadius", toString(9200.0)); + mapGroupWest += PvlKeyword("CenterLongitude", Isis::toString(0.0)); + mapGroupWest += PvlKeyword("CenterLatitude", Isis::toString(0.0)); + mapGroupWest += PvlKeyword("EquatorialRadius", Isis::toString(13400.0)); + mapGroupWest += PvlKeyword("PolarRadius", Isis::toString(9200.0)); mapGroupWest += PvlKeyword("LatitudeType", "Planetocentric"); mapGroupWest += PvlKeyword("LongitudeDirection", "PositiveEast"); - mapGroupWest += PvlKeyword("LongitudeDomain", toString(360)); - mapGroupWest += PvlKeyword("MinimumLatitude", toString(0.0)); - mapGroupWest += PvlKeyword("MaximumLatitude", toString(60.0)); - mapGroupWest += PvlKeyword("MinimumLongitude", toString(-90.0)); - mapGroupWest += PvlKeyword("MaximumLongitude", toString(0.0)); - mapGroupWest += PvlKeyword("PixelResolution", toString(10.0)); + mapGroupWest += PvlKeyword("LongitudeDomain", Isis::toString(360)); + mapGroupWest += PvlKeyword("MinimumLatitude", Isis::toString(0.0)); + mapGroupWest += PvlKeyword("MaximumLatitude", Isis::toString(60.0)); + mapGroupWest += PvlKeyword("MinimumLongitude", Isis::toString(-90.0)); + mapGroupWest += PvlKeyword("MaximumLongitude", Isis::toString(0.0)); + mapGroupWest += PvlKeyword("PixelResolution", Isis::toString(10.0)); TProjection *projEast = (TProjection *) ProjectionFactory::CreateForCube(eastMap, diff --git a/isis/src/base/objs/RadarSlantRangeMap/RadarSlantRangeMap.cpp b/isis/src/base/objs/RadarSlantRangeMap/RadarSlantRangeMap.cpp index b5d9c35154..c170b48f5f 100644 --- a/isis/src/base/objs/RadarSlantRangeMap/RadarSlantRangeMap.cpp +++ b/isis/src/base/objs/RadarSlantRangeMap/RadarSlantRangeMap.cpp @@ -262,10 +262,10 @@ namespace Isis { double et; utc2et_c(array[0].c_str(), &et); p_time.push_back(et); - p_a0.push_back(IString::ToDouble(array[1])); - p_a1.push_back(IString::ToDouble(array[2])); - p_a2.push_back(IString::ToDouble(array[3])); - p_a3.push_back(IString::ToDouble(array[4])); + p_a0.push_back(Isis::toDouble(array[1])); + p_a1.push_back(Isis::toDouble(array[2])); + p_a2.push_back(Isis::toDouble(array[3])); + p_a3.push_back(Isis::toDouble(array[4])); // TODO: Test that times are ordered if not throw error // Make the mrf2isis program sort them if necessary } diff --git a/isis/src/base/objs/Reduce/Reduce.cpp b/isis/src/base/objs/Reduce/Reduce.cpp index f6210eb7f2..346d009c20 100644 --- a/isis/src/base/objs/Reduce/Reduce.cpp +++ b/isis/src/base/objs/Reduce/Reduce.cpp @@ -117,16 +117,16 @@ namespace Isis { // Information will be added to it if the Mapping or Instrument // groups are deleted from the output image label PvlGroup resultsGrp("Results"); - resultsGrp += PvlKeyword("InputLines", toString(miInputLines)); - resultsGrp += PvlKeyword("InputSamples", toString(miInputSamples)); - resultsGrp += PvlKeyword("StartingLine", toString(miStartLine)); - resultsGrp += PvlKeyword("StartingSample", toString(miStartSample)); - resultsGrp += PvlKeyword("EndingLine", toString(miEndLine)); - resultsGrp += PvlKeyword("EndingSample", toString(miEndSample)); - resultsGrp += PvlKeyword("LineIncrement", toString(mdLineScale)); - resultsGrp += PvlKeyword("SampleIncrement", toString(mdSampleScale)); - resultsGrp += PvlKeyword("OutputLines", toString(miOutputLines)); - resultsGrp += PvlKeyword("OutputSamples", toString(miOutputSamples)); + resultsGrp += PvlKeyword("InputLines", Isis::toString(miInputLines)); + resultsGrp += PvlKeyword("InputSamples", Isis::toString(miInputSamples)); + resultsGrp += PvlKeyword("StartingLine", Isis::toString(miStartLine)); + resultsGrp += PvlKeyword("StartingSample", Isis::toString(miStartSample)); + resultsGrp += PvlKeyword("EndingLine", Isis::toString(miEndLine)); + resultsGrp += PvlKeyword("EndingSample", Isis::toString(miEndSample)); + resultsGrp += PvlKeyword("LineIncrement", Isis::toString(mdLineScale)); + resultsGrp += PvlKeyword("SampleIncrement", Isis::toString(mdSampleScale)); + resultsGrp += PvlKeyword("OutputLines", Isis::toString(miOutputLines)); + resultsGrp += PvlKeyword("OutputSamples", Isis::toString(miOutputSamples)); Isis::SubArea subArea; subArea.SetSubArea(mInCube->lineCount(), mInCube->sampleCount(), miStartLine, miStartSample, diff --git a/isis/src/base/objs/ReseauDistortionMap/ReseauDistortionMap.cpp b/isis/src/base/objs/ReseauDistortionMap/ReseauDistortionMap.cpp index 26f70435d4..cd7bce04dc 100644 --- a/isis/src/base/objs/ReseauDistortionMap/ReseauDistortionMap.cpp +++ b/isis/src/base/objs/ReseauDistortionMap/ReseauDistortionMap.cpp @@ -44,8 +44,8 @@ namespace Isis { throw IException(IException::User, msg, _FILEINFO_); } for(int i = 0; i < p_numRes; i++) { - p_mlines.push_back(IString::ToDouble(mline[i])); - p_msamps.push_back(IString::ToDouble(msamp[i])); + p_mlines.push_back(Isis::toDouble(mline[i])); + p_msamps.push_back(Isis::toDouble(msamp[i])); } p_pixelPitch = parent->PixelPitch(); @@ -58,8 +58,8 @@ namespace Isis { throw IException(IException::User, msg, _FILEINFO_); } for(int i = 0; i < p_numRes; i++) { - p_rlines.push_back(IString::ToDouble(rline[i])); - p_rsamps.push_back(IString::ToDouble(rsamp[i])); + p_rlines.push_back(Isis::toDouble(rline[i])); + p_rsamps.push_back(Isis::toDouble(rsamp[i])); } if(p_mlines.size() != p_rlines.size()) { string msg = "The number of master reseaus and refined reseaus"; diff --git a/isis/src/base/objs/RingCylindrical/RingCylindrical.cpp b/isis/src/base/objs/RingCylindrical/RingCylindrical.cpp index 1a235f0a2d..94a6520311 100644 --- a/isis/src/base/objs/RingCylindrical/RingCylindrical.cpp +++ b/isis/src/base/objs/RingCylindrical/RingCylindrical.cpp @@ -45,14 +45,14 @@ namespace Isis { // Compute the default value if allowed and needed if ((allowDefaults) && (!mapGroup.hasKeyword("CenterRingLongitude"))) { double az = (m_minimumRingLongitude + m_maximumRingLongitude) / 2.0; - mapGroup += PvlKeyword("CenterRingLongitude", toString(az)); + mapGroup += PvlKeyword("CenterRingLongitude", Isis::toString(az)); } // Compute and write the default center radius if allowed and // necessary if ((allowDefaults) && (!mapGroup.hasKeyword("CenterRingRadius"))) { double radius = (m_minimumRingRadius + m_maximumRingRadius) / 2.0; - mapGroup += PvlKeyword("CenterRingRadius", toString(radius)); + mapGroup += PvlKeyword("CenterRingRadius", Isis::toString(radius)); } // Get the center ring radius and center ring longitude. @@ -274,11 +274,11 @@ namespace Isis { PvlGroup RingCylindrical::Mapping() { PvlGroup mapping = RingPlaneProjection::Mapping(); - mapping += PvlKeyword("CenterRingRadius", toString(m_centerRingRadius)); + mapping += PvlKeyword("CenterRingRadius", Isis::toString(m_centerRingRadius)); double dir = 1.0; if (m_ringLongitudeDirection == Clockwise) dir = -1.0; double lonDegrees = m_centerRingLongitude*RAD2DEG*dir; - mapping += PvlKeyword("CenterRingLongitude", toString(lonDegrees)); + mapping += PvlKeyword("CenterRingLongitude", Isis::toString(lonDegrees)); return mapping; } diff --git a/isis/src/base/objs/Robinson/Robinson.cpp b/isis/src/base/objs/Robinson/Robinson.cpp index f10c7f7205..19aa3f661a 100644 --- a/isis/src/base/objs/Robinson/Robinson.cpp +++ b/isis/src/base/objs/Robinson/Robinson.cpp @@ -93,7 +93,7 @@ namespace Isis { // necessary if ((allowDefaults) && (!mapGroup.hasKeyword("CenterLongitude"))) { double lon = (m_minimumLongitude + m_maximumLongitude) / 2.0; - mapGroup += PvlKeyword("CenterLongitude", toString(lon)); + mapGroup += PvlKeyword("CenterLongitude", Isis::toString(lon)); } // Get the center longitude diff --git a/isis/src/base/objs/SerialNumber/SerialNumber.cpp b/isis/src/base/objs/SerialNumber/SerialNumber.cpp index 8e3c5c2b9e..a7ae79ff05 100644 --- a/isis/src/base/objs/SerialNumber/SerialNumber.cpp +++ b/isis/src/base/objs/SerialNumber/SerialNumber.cpp @@ -149,7 +149,7 @@ namespace Isis { } PvlGroup snGroup = outLabel.findGroup("SerialNumberKeywords"); - snGroup += PvlKeyword("ObservationKeys", toString(snGroup.keywords())); + snGroup += PvlKeyword("ObservationKeys", Isis::toString(snGroup.keywords())); return snGroup; } diff --git a/isis/src/base/objs/SessionLog/unitTest.cpp b/isis/src/base/objs/SessionLog/unitTest.cpp index b10541d00c..5b80eaf2df 100644 --- a/isis/src/base/objs/SessionLog/unitTest.cpp +++ b/isis/src/base/objs/SessionLog/unitTest.cpp @@ -23,17 +23,17 @@ int main(int argc, char *argv[]) { try { PvlGroup results("Results");; results.addComment("// This is an example of the results group"); - results += PvlKeyword("Average", toString(13.5), "Meters"); + results += PvlKeyword("Average", Isis::toString(13.5), "Meters"); results[0].addComment("// Average size of a rock"); Pvl error; PvlGroup temp("Error"); temp += PvlKeyword("Program", "ratio"); temp += PvlKeyword("Class", "I/O ERROR"); - temp += PvlKeyword("Status", toString(-1)); + temp += PvlKeyword("Status", Isis::toString(-1)); temp += PvlKeyword("Message", "Unable to open file"); temp += PvlKeyword("File", "unitTest.cpp"); - temp += PvlKeyword("Line", toString(501)); + temp += PvlKeyword("Line", Isis::toString(501)); error.addGroup(temp); char **s_argv; s_argv = new char*[10]; diff --git a/isis/src/base/objs/ShapeModelFactory/ShapeModelFactory.cpp b/isis/src/base/objs/ShapeModelFactory/ShapeModelFactory.cpp index 30d8841fca..a4b600d7d1 100644 --- a/isis/src/base/objs/ShapeModelFactory/ShapeModelFactory.cpp +++ b/isis/src/base/objs/ShapeModelFactory/ShapeModelFactory.cpp @@ -183,7 +183,7 @@ namespace Isis { // Do this here, otherwise default behavior will ensue from here on out kernelsPvlGroup.addKeyword(PvlKeyword("RayTraceEngine", preferred.toStdString()), PvlContainer::Replace); kernelsPvlGroup.addKeyword(PvlKeyword("OnError", onerror.toStdString()), PvlContainer::Replace); - kernelsPvlGroup.addKeyword(PvlKeyword("Tolerance", toString(tolerance)), + kernelsPvlGroup.addKeyword(PvlKeyword("Tolerance", Isis::toString(tolerance)), PvlContainer::Replace); return ( b_model ); @@ -220,7 +220,7 @@ namespace Isis { // Do this here, otherwise default behavior will ensue from here on out kernelsPvlGroup.addKeyword(PvlKeyword("RayTraceEngine", preferred.toStdString()), PvlContainer::Replace); kernelsPvlGroup.addKeyword(PvlKeyword("OnError", onerror.toStdString()), PvlContainer::Replace); - kernelsPvlGroup.addKeyword(PvlKeyword("Tolerance", toString(tolerance)), + kernelsPvlGroup.addKeyword(PvlKeyword("Tolerance", Isis::toString(tolerance)), PvlContainer::Replace); return ( embreeModel ); diff --git a/isis/src/base/objs/ShapeModelFactory/unitTest.cpp b/isis/src/base/objs/ShapeModelFactory/unitTest.cpp index b514a2afa1..fd9fdba12a 100644 --- a/isis/src/base/objs/ShapeModelFactory/unitTest.cpp +++ b/isis/src/base/objs/ShapeModelFactory/unitTest.cpp @@ -68,7 +68,7 @@ int main() { QString dir = QString::fromStdString(f.expanded()) + "/"; QString dir2 = QString::fromStdString(f2.expanded()) + "/"; QString dir3 = QString::fromStdString(f3.expanded()) + "/"; - kern1 += PvlKeyword("NaifFrameCode", toString(-94031)); + kern1 += PvlKeyword("NaifFrameCode", Isis::toString(-94031)); kern1 += PvlKeyword("LeapSecond", dir.toStdString() + "naif0007.tls"); kern1 += PvlKeyword("SpacecraftClock", dir.toStdString() + "MGS_SCLKSCET.00045.tsc"); kern1 += PvlKeyword("TargetPosition", dir.toStdString() + "de405.bsp"); @@ -78,14 +78,14 @@ int main() { kern1 += PvlKeyword("InstrumentPosition", dir.toStdString() + "moc.bsp"); kern1 += PvlKeyword("InstrumentPointing", dir.toStdString() + "moc.bc"); kern1 += PvlKeyword("Frame", ""); - kern1 += PvlKeyword("NaifBodyCode", toString(499)); + kern1 += PvlKeyword("NaifBodyCode", Isis::toString(499)); // Time Setup double startTime = -69382819.0; double endTime = -69382512.0; double slope = (endTime - startTime) / (10 - 1); - kern1 += PvlKeyword("StartPadding", toString(slope)); - kern1 += PvlKeyword("EndPadding", toString(slope)); + kern1 += PvlKeyword("StartPadding", Isis::toString(slope)); + kern1 += PvlKeyword("EndPadding", Isis::toString(slope)); Pvl lab1; lab1.addGroup(inst1); diff --git a/isis/src/base/objs/SimpleCylindrical/SimpleCylindrical.cpp b/isis/src/base/objs/SimpleCylindrical/SimpleCylindrical.cpp index 9df7ae7502..c0071b2f3e 100644 --- a/isis/src/base/objs/SimpleCylindrical/SimpleCylindrical.cpp +++ b/isis/src/base/objs/SimpleCylindrical/SimpleCylindrical.cpp @@ -44,7 +44,7 @@ namespace Isis { // Compute the default value if allowed and needed if ((allowDefaults) && (!mapGroup.hasKeyword("CenterLongitude"))) { double lon = (m_minimumLongitude + m_maximumLongitude) / 2.0; - mapGroup += PvlKeyword("CenterLongitude", toString(lon)); + mapGroup += PvlKeyword("CenterLongitude", Isis::toString(lon)); } // Get the center longitude, convert to radians, adjust for longitude diff --git a/isis/src/base/objs/SimpleCylindrical/unitTest.cpp b/isis/src/base/objs/SimpleCylindrical/unitTest.cpp index 35894fb115..b39aa51edd 100644 --- a/isis/src/base/objs/SimpleCylindrical/unitTest.cpp +++ b/isis/src/base/objs/SimpleCylindrical/unitTest.cpp @@ -23,15 +23,15 @@ int main(int argc, char *argv[]) { Pvl lab; lab.addGroup(PvlGroup("Mapping")); PvlGroup &mapGrp = lab.findGroup("Mapping"); - mapGrp += PvlKeyword("EquatorialRadius", toString(1.0)); - mapGrp += PvlKeyword("PolarRadius", toString(1.0)); + mapGrp += PvlKeyword("EquatorialRadius", Isis::toString(1.0)); + mapGrp += PvlKeyword("PolarRadius", Isis::toString(1.0)); mapGrp += PvlKeyword("LatitudeType", "Planetocentric"); mapGrp += PvlKeyword("LongitudeDirection", "PositiveEast"); - mapGrp += PvlKeyword("LongitudeDomain", toString(180)); - mapGrp += PvlKeyword("MinimumLatitude", toString(-90.0)); - mapGrp += PvlKeyword("MaximumLatitude", toString(90.0)); - mapGrp += PvlKeyword("MinimumLongitude", toString(-180.0)); - mapGrp += PvlKeyword("MaximumLongitude", toString(180.0)); + mapGrp += PvlKeyword("LongitudeDomain", Isis::toString(180)); + mapGrp += PvlKeyword("MinimumLatitude", Isis::toString(-90.0)); + mapGrp += PvlKeyword("MaximumLatitude", Isis::toString(90.0)); + mapGrp += PvlKeyword("MinimumLongitude", Isis::toString(-180.0)); + mapGrp += PvlKeyword("MaximumLongitude", Isis::toString(180.0)); mapGrp += PvlKeyword("ProjectionName", "SimpleCylindrical"); cout << "Test missing center longitude keyword ..." << endl; @@ -44,7 +44,7 @@ int main(int argc, char *argv[]) { cout << endl; try { - mapGrp += PvlKeyword("CenterLongitude", toString(-90.0)); + mapGrp += PvlKeyword("CenterLongitude", Isis::toString(-90.0)); TProjection *p = (TProjection *) ProjectionFactory::Create(lab); cout << "Test SetGround method ... " << endl; diff --git a/isis/src/base/objs/Sinusoidal/Sinusoidal.cpp b/isis/src/base/objs/Sinusoidal/Sinusoidal.cpp index 3eca8d8cc8..5e18d209c0 100644 --- a/isis/src/base/objs/Sinusoidal/Sinusoidal.cpp +++ b/isis/src/base/objs/Sinusoidal/Sinusoidal.cpp @@ -45,7 +45,7 @@ namespace Isis { // necessary if ((allowDefaults) && (!mapGroup.hasKeyword("CenterLongitude"))) { double lon = (m_minimumLongitude + m_maximumLongitude) / 2.0; - mapGroup += PvlKeyword("CenterLongitude", toString(lon)); + mapGroup += PvlKeyword("CenterLongitude", Isis::toString(lon)); } // Get the center longitude diff --git a/isis/src/base/objs/Sinusoidal/unitTest.cpp b/isis/src/base/objs/Sinusoidal/unitTest.cpp index 1451139529..2e95b0266c 100644 --- a/isis/src/base/objs/Sinusoidal/unitTest.cpp +++ b/isis/src/base/objs/Sinusoidal/unitTest.cpp @@ -23,15 +23,15 @@ int main(int argc, char *argv[]) { Pvl lab; lab.addGroup(PvlGroup("Mapping")); PvlGroup &mapGroup = lab.findGroup("Mapping"); - mapGroup += PvlKeyword("EquatorialRadius", toString(1.0)); - mapGroup += PvlKeyword("PolarRadius", toString(1.0)); + mapGroup += PvlKeyword("EquatorialRadius", Isis::toString(1.0)); + mapGroup += PvlKeyword("PolarRadius", Isis::toString(1.0)); mapGroup += PvlKeyword("LatitudeType", "Planetocentric"); mapGroup += PvlKeyword("LongitudeDirection", "PositiveEast"); - mapGroup += PvlKeyword("LongitudeDomain", toString(180)); - mapGroup += PvlKeyword("MinimumLatitude", toString(-90.0)); - mapGroup += PvlKeyword("MaximumLatitude", toString(90.0)); - mapGroup += PvlKeyword("MinimumLongitude", toString(-180.0)); - mapGroup += PvlKeyword("MaximumLongitude", toString(180.0)); + mapGroup += PvlKeyword("LongitudeDomain", Isis::toString(180)); + mapGroup += PvlKeyword("MinimumLatitude", Isis::toString(-90.0)); + mapGroup += PvlKeyword("MaximumLatitude", Isis::toString(90.0)); + mapGroup += PvlKeyword("MinimumLongitude", Isis::toString(-180.0)); + mapGroup += PvlKeyword("MaximumLongitude", Isis::toString(180.0)); mapGroup += PvlKeyword("ProjectionName", "Sinusoidal"); cout << "Test missing center longitude keyword ..." << endl; @@ -43,7 +43,7 @@ int main(int argc, char *argv[]) { } cout << endl; - mapGroup += PvlKeyword("CenterLongitude", toString(-90.0)); + mapGroup += PvlKeyword("CenterLongitude", Isis::toString(-90.0)); try { TProjection *p = (TProjection *) ProjectionFactory::Create(lab); diff --git a/isis/src/base/objs/Spice/Spice.cpp b/isis/src/base/objs/Spice/Spice.cpp index 6ca7783100..2034f5a295 100644 --- a/isis/src/base/objs/Spice/Spice.cpp +++ b/isis/src/base/objs/Spice/Spice.cpp @@ -171,14 +171,14 @@ namespace Isis { // Get the time padding first if (kernels.hasKeyword("StartPadding")) { - *m_startTimePadding = IString::ToDouble(kernels["StartPadding"][0]); + *m_startTimePadding = Isis::toDouble(kernels["StartPadding"][0]); } else { *m_startTimePadding = 0.0; } if (kernels.hasKeyword("EndPadding")) { - *m_endTimePadding = IString::ToDouble(kernels["EndPadding"][0]); + *m_endTimePadding = Isis::toDouble(kernels["EndPadding"][0]); } else { *m_endTimePadding = 0.0; @@ -297,7 +297,7 @@ namespace Isis { QString trykey = "NaifIkCode"; if (kernels.hasKeyword("NaifFrameCode")) trykey = "NaifFrameCode"; - *m_ikCode = IString::ToInteger(kernels[trykey.toStdString()][0]); + *m_ikCode = Isis::toInt(kernels[trykey.toStdString()][0]); *m_spkCode = *m_ikCode / 1000; *m_sclkCode = *m_spkCode; @@ -1217,10 +1217,10 @@ namespace Isis { storedKey[index] = value.toString().toStdString(); } else if (type == SpiceDoubleType) { - storedKey[index] = toString(value.toDouble()); + storedKey[index] = Isis::toString(value.toDouble()); } else if (type == SpiceIntType) { - storedKey[index] = toString(value.toInt()); + storedKey[index] = Isis::toString(value.toInt()); } else { std::string msg = "Unable to store variant in labels for key [" + key.toStdString() + "]"; @@ -1239,7 +1239,7 @@ namespace Isis { try { if (type == SpiceDoubleType) { - result = IString::ToDouble(storedKeyword[index]); + result = Isis::toDouble(storedKeyword[index]); } else if (type == SpiceStringType) { result = QString::fromStdString(storedKeyword[index]); @@ -1248,7 +1248,7 @@ namespace Isis { result = QString::fromStdString(storedKeyword[index]); } else if (type == SpiceIntType) { - result = IString::ToInteger(storedKeyword[index]); + result = Isis::toInt(storedKeyword[index]); } } catch(IException &e) { diff --git a/isis/src/base/objs/Spice/unitTest.cpp b/isis/src/base/objs/Spice/unitTest.cpp index d7f28c1978..c317db2978 100644 --- a/isis/src/base/objs/Spice/unitTest.cpp +++ b/isis/src/base/objs/Spice/unitTest.cpp @@ -121,8 +121,8 @@ int main(int argc, char *argv[]) { double endTime = -69382512.0; double slope = (endTime - startTime) / (10 - 1); - kernelsGroup += PvlKeyword("StartPadding", toString(slope)); - kernelsGroup += PvlKeyword("EndPadding", toString(slope)); + kernelsGroup += PvlKeyword("StartPadding", Isis::toString(slope)); + kernelsGroup += PvlKeyword("EndPadding", Isis::toString(slope)); Pvl &lab = *dummyCube.label(); PvlObject &isisCubeObj = lab.findObject("IsisCube"); diff --git a/isis/src/base/objs/SpicePosition/SpicePosition.cpp b/isis/src/base/objs/SpicePosition/SpicePosition.cpp index 97d7c83271..ebd21d5404 100644 --- a/isis/src/base/objs/SpicePosition/SpicePosition.cpp +++ b/isis/src/base/objs/SpicePosition/SpicePosition.cpp @@ -436,13 +436,13 @@ namespace Isis { // Load the full cache time information from the label if available if(table.Label().hasKeyword("SpkTableStartTime")) { - p_fullCacheStartTime = IString::ToDouble(table.Label().findKeyword("SpkTableStartTime")[0]); + p_fullCacheStartTime = Isis::toDouble(table.Label().findKeyword("SpkTableStartTime")[0]); } if(table.Label().hasKeyword("SpkTableEndTime")) { - p_fullCacheEndTime = IString::ToDouble(table.Label().findKeyword("SpkTableEndTime")[0]); + p_fullCacheEndTime = Isis::toDouble(table.Label().findKeyword("SpkTableEndTime")[0]); } if(table.Label().hasKeyword("SpkTableOriginalSize")) { - p_fullCacheSize = IString::ToDouble(table.Label().findKeyword("SpkTableOriginalSize")[0]); + p_fullCacheSize = Isis::toDouble(table.Label().findKeyword("SpkTableOriginalSize")[0]); } @@ -674,15 +674,15 @@ namespace Isis { // Write original time coverage if(p_fullCacheStartTime != 0) { table.Label() += PvlKeyword("SpkTableStartTime"); - table.Label()["SpkTableStartTime"].addValue(toString(p_fullCacheStartTime)); + table.Label()["SpkTableStartTime"].addValue(Isis::toString(p_fullCacheStartTime)); } if(p_fullCacheEndTime != 0) { table.Label() += PvlKeyword("SpkTableEndTime"); - table.Label()["SpkTableEndTime"].addValue(toString(p_fullCacheEndTime)); + table.Label()["SpkTableEndTime"].addValue(Isis::toString(p_fullCacheEndTime)); } if(p_fullCacheSize != 0) { table.Label() += PvlKeyword("SpkTableOriginalSize"); - table.Label()["SpkTableOriginalSize"].addValue(toString(p_fullCacheSize)); + table.Label()["SpkTableOriginalSize"].addValue(Isis::toString(p_fullCacheSize)); } } diff --git a/isis/src/base/objs/SpicePosition/unitTest.cpp b/isis/src/base/objs/SpicePosition/unitTest.cpp index 17ad5947fe..918ef2ba99 100644 --- a/isis/src/base/objs/SpicePosition/unitTest.cpp +++ b/isis/src/base/objs/SpicePosition/unitTest.cpp @@ -216,11 +216,11 @@ int main(int argc, char *argv[]) { // Add table label table.Label() += PvlKeyword("CacheType", "HermiteSpline"); table.Label() += PvlKeyword("SpkTableStartTime"); - table.Label()["SpkTableStartTime"].addValue(toString(-69382819.360519)); + table.Label()["SpkTableStartTime"].addValue(Isis::toString(-69382819.360519)); table.Label() += PvlKeyword("SpkTableEndTime"); - table.Label()["SpkTableEndTime"].addValue(toString(-69382512.160519)); + table.Label()["SpkTableEndTime"].addValue(Isis::toString(-69382512.160519)); table.Label() += PvlKeyword("SpkTableOriginalSize"); - table.Label()["SpkTableOriginalSize"].addValue(toString(769)); + table.Label()["SpkTableOriginalSize"].addValue(Isis::toString(769)); // Load table into the object pos4.LoadCache(table); diff --git a/isis/src/base/objs/SpiceRotation/SpiceRotation.cpp b/isis/src/base/objs/SpiceRotation/SpiceRotation.cpp index 61c9bc57aa..0d8d7e065a 100644 --- a/isis/src/base/objs/SpiceRotation/SpiceRotation.cpp +++ b/isis/src/base/objs/SpiceRotation/SpiceRotation.cpp @@ -551,7 +551,7 @@ namespace Isis { if (table.Label().hasKeyword("TimeDependentFrames")) { PvlKeyword labelTimeFrames = table.Label()["TimeDependentFrames"]; for (int i = 0; i < labelTimeFrames.size(); i++) { - p_timeFrames.push_back(IString::ToInteger(labelTimeFrames[i])); + p_timeFrames.push_back(Isis::toInt(labelTimeFrames[i])); } } else { @@ -564,12 +564,12 @@ namespace Isis { p_constantFrames.clear(); for (int i = 0; i < labelConstantFrames.size(); i++) { - p_constantFrames.push_back(IString::ToInteger(labelConstantFrames[i])); + p_constantFrames.push_back(Isis::toInt(labelConstantFrames[i])); } PvlKeyword labelConstantRotation = table.Label()["ConstantRotation"]; for (int i = 0; i < labelConstantRotation.size(); i++) { - p_TC.push_back(IString::ToDouble(labelConstantRotation[i])); + p_TC.push_back(Isis::toDouble(labelConstantRotation[i])); } } else { @@ -579,18 +579,18 @@ namespace Isis { // Load the full cache time information from the label if available if (table.Label().hasKeyword("CkTableStartTime")) { - p_fullCacheStartTime = IString::ToDouble(table.Label().findKeyword("CkTableStartTime")[0]); + p_fullCacheStartTime = Isis::toDouble(table.Label().findKeyword("CkTableStartTime")[0]); } if (table.Label().hasKeyword("CkTableEndTime")) { - p_fullCacheEndTime = IString::ToDouble(table.Label().findKeyword("CkTableEndTime")[0]); + p_fullCacheEndTime = Isis::toDouble(table.Label().findKeyword("CkTableEndTime")[0]); } if (table.Label().hasKeyword("CkTableOriginalSize")) { - p_fullCacheSize = IString::ToInteger(table.Label().findKeyword("CkTableOriginalSize")[0]); + p_fullCacheSize = Isis::toInt(table.Label().findKeyword("CkTableOriginalSize")[0]); } // Load FrameTypeCode from labels if available and the planetary constants keywords if (table.Label().hasKeyword("FrameTypeCode")) { - m_frameType = (FrameType) IString::ToInteger(table.Label().findKeyword("FrameTypeCode")[0]); + m_frameType = (FrameType) Isis::toInt(table.Label().findKeyword("FrameTypeCode")[0]); } else { m_frameType = UNKNOWN; @@ -1104,21 +1104,21 @@ namespace Isis { if (label.hasKeyword("PoleRa")) { PvlKeyword labelCoeffs = label["PoleRa"]; for (int i = 0; i < labelCoeffs.size(); i++){ - m_raPole.push_back(Angle(IString::ToDouble(labelCoeffs[i]), Angle::Degrees)); + m_raPole.push_back(Angle(Isis::toDouble(labelCoeffs[i]), Angle::Degrees)); } numLoaded += 1; } if (label.hasKeyword("PoleDec")) { PvlKeyword labelCoeffs = label["PoleDec"]; for (int i = 0; i < labelCoeffs.size(); i++){ - m_decPole.push_back(Angle(IString::ToDouble(labelCoeffs[i]), Angle::Degrees)); + m_decPole.push_back(Angle(Isis::toDouble(labelCoeffs[i]), Angle::Degrees)); } numLoaded += 1; } if (label.hasKeyword("PrimeMeridian")) { PvlKeyword labelCoeffs = label["PrimeMeridian"]; for (int i = 0; i < labelCoeffs.size(); i++){ - m_pm.push_back(Angle(IString::ToDouble(labelCoeffs[i]), Angle::Degrees)); + m_pm.push_back(Angle(Isis::toDouble(labelCoeffs[i]), Angle::Degrees)); } numLoaded += 1; } @@ -1127,31 +1127,31 @@ namespace Isis { if (label.hasKeyword("PoleRaNutPrec")) { PvlKeyword labelCoeffs = label["PoleRaNutPrec"]; for (int i = 0; i < labelCoeffs.size(); i++){ - m_raNutPrec.push_back(IString::ToDouble(labelCoeffs[i])); + m_raNutPrec.push_back(Isis::toDouble(labelCoeffs[i])); } } if (label.hasKeyword("PoleDecNutPrec")) { PvlKeyword labelCoeffs = label["PoleDecNutPrec"]; for (int i = 0; i < labelCoeffs.size(); i++){ - m_decNutPrec.push_back(IString::ToDouble(labelCoeffs[i])); + m_decNutPrec.push_back(Isis::toDouble(labelCoeffs[i])); } } if (label.hasKeyword("PmNutPrec")) { PvlKeyword labelCoeffs = label["PmNutPrec"]; for (int i = 0; i < labelCoeffs.size(); i++){ - m_pmNutPrec.push_back(IString::ToDouble(labelCoeffs[i])); + m_pmNutPrec.push_back(Isis::toDouble(labelCoeffs[i])); } } if (label.hasKeyword("SysNutPrec0")) { PvlKeyword labelCoeffs = label["SysNutPrec0"]; for (int i = 0; i < labelCoeffs.size(); i++){ - m_sysNutPrec0.push_back(Angle(IString::ToDouble(labelCoeffs[i]), Angle::Degrees)); + m_sysNutPrec0.push_back(Angle(Isis::toDouble(labelCoeffs[i]), Angle::Degrees)); } } if (label.hasKeyword("SysNutPrec1")) { PvlKeyword labelCoeffs = label["SysNutPrec1"]; for (int i = 0; i < labelCoeffs.size(); i++){ - m_sysNutPrec1.push_back(Angle(IString::ToDouble(labelCoeffs[i]), Angle::Degrees)); + m_sysNutPrec1.push_back(Angle(Isis::toDouble(labelCoeffs[i]), Angle::Degrees)); } } @@ -1174,7 +1174,7 @@ namespace Isis { table.Label() += PvlKeyword("TimeDependentFrames"); for (int i = 0; i < (int) p_timeFrames.size(); i++) { - table.Label()["TimeDependentFrames"].addValue(toString(p_timeFrames[i])); + table.Label()["TimeDependentFrames"].addValue(Isis::toString(p_timeFrames[i])); } } @@ -1182,33 +1182,33 @@ namespace Isis { table.Label() += PvlKeyword("ConstantFrames"); for (int i = 0; i < (int) p_constantFrames.size(); i++) { - table.Label()["ConstantFrames"].addValue(toString(p_constantFrames[i])); + table.Label()["ConstantFrames"].addValue(Isis::toString(p_constantFrames[i])); } table.Label() += PvlKeyword("ConstantRotation"); for (int i = 0; i < (int) p_TC.size(); i++) { - table.Label()["ConstantRotation"].addValue(toString(p_TC[i])); + table.Label()["ConstantRotation"].addValue(Isis::toString(p_TC[i])); } } // Write original time coverage if (p_fullCacheStartTime != 0) { table.Label() += PvlKeyword("CkTableStartTime"); - table.Label()["CkTableStartTime"].addValue(toString(p_fullCacheStartTime)); + table.Label()["CkTableStartTime"].addValue(Isis::toString(p_fullCacheStartTime)); } if (p_fullCacheEndTime != 0) { table.Label() += PvlKeyword("CkTableEndTime"); - table.Label()["CkTableEndTime"].addValue(toString(p_fullCacheEndTime)); + table.Label()["CkTableEndTime"].addValue(Isis::toString(p_fullCacheEndTime)); } if (p_fullCacheSize != 0) { table.Label() += PvlKeyword("CkTableOriginalSize"); - table.Label()["CkTableOriginalSize"].addValue(toString(p_fullCacheSize)); + table.Label()["CkTableOriginalSize"].addValue(Isis::toString(p_fullCacheSize)); } // Begin section added 06-20-2015 DAC table.Label() += PvlKeyword("FrameTypeCode"); - table.Label()["FrameTypeCode"].addValue(toString(m_frameType)); + table.Label()["FrameTypeCode"].addValue(Isis::toString(m_frameType)); if (m_frameType == PCK) { // Write out all the body orientation constants @@ -1216,50 +1216,50 @@ namespace Isis { table.Label() += PvlKeyword("PoleRa"); for (int i = 0; i < (int) m_raPole.size(); i++) { - table.Label()["PoleRa"].addValue(toString(m_raPole[i].degrees())); + table.Label()["PoleRa"].addValue(Isis::toString(m_raPole[i].degrees())); } // Pole right ascension, declination coefficients for a quadratic equation table.Label() += PvlKeyword("PoleDec"); for (int i = 0; i < (int) m_decPole.size(); i++) { - table.Label()["PoleDec"].addValue(toString(m_decPole[i].degrees())); + table.Label()["PoleDec"].addValue(Isis::toString(m_decPole[i].degrees())); } // Prime meridian coefficients for a quadratic equation table.Label() += PvlKeyword("PrimeMeridian"); for (int i = 0; i < (int) m_pm.size(); i++) { - table.Label()["PrimeMeridian"].addValue(toString(m_pm[i].degrees())); + table.Label()["PrimeMeridian"].addValue(Isis::toString(m_pm[i].degrees())); } if (m_raNutPrec.size() > 0) { // Pole right ascension nutation precision coefficients to the trig terms table.Label() += PvlKeyword("PoleRaNutPrec"); for (int i = 0; i < (int) m_raNutPrec.size(); i++) { - table.Label()["PoleRaNutPrec"].addValue(toString(m_raNutPrec[i])); + table.Label()["PoleRaNutPrec"].addValue(Isis::toString(m_raNutPrec[i])); } // Pole declination nutation precision coefficients to the trig terms table.Label() += PvlKeyword("PoleDecNutPrec"); for (int i = 0; i < (int) m_decNutPrec.size(); i++) { - table.Label()["PoleDecNutPrec"].addValue(toString(m_decNutPrec[i])); + table.Label()["PoleDecNutPrec"].addValue(Isis::toString(m_decNutPrec[i])); } // Prime meridian nutation precision coefficients to the trig terms table.Label() += PvlKeyword("PmNutPrec"); for (int i = 0; i < (int) m_pmNutPrec.size(); i++) { - table.Label()["PmNutPrec"].addValue(toString(m_pmNutPrec[i])); + table.Label()["PmNutPrec"].addValue(Isis::toString(m_pmNutPrec[i])); } // System nutation precision constant terms of linear model of periods table.Label() += PvlKeyword("SysNutPrec0"); for (int i = 0; i < (int) m_sysNutPrec0.size(); i++) { - table.Label()["SysNutPrec0"].addValue(toString(m_sysNutPrec0[i].degrees())); + table.Label()["SysNutPrec0"].addValue(Isis::toString(m_sysNutPrec0[i].degrees())); } // System nutation precision linear terms of linear model of periods table.Label() += PvlKeyword("SysNutPrec1"); for (int i = 0; i < (int) m_sysNutPrec1.size(); i++) { - table.Label()["SysNutPrec1"].addValue(toString(m_sysNutPrec1[i].degrees())); + table.Label()["SysNutPrec1"].addValue(Isis::toString(m_sysNutPrec1[i].degrees())); } } } diff --git a/isis/src/base/objs/Statistics/Statistics.cpp b/isis/src/base/objs/Statistics/Statistics.cpp index 5eacd0b199..054eaa55ee 100644 --- a/isis/src/base/objs/Statistics/Statistics.cpp +++ b/isis/src/base/objs/Statistics/Statistics.cpp @@ -408,8 +408,8 @@ namespace Isis { if (m_validMaximum < m_validMinimum) { // get the min and max DN values in the chosen range - std::string msg = "Invalid Range: Minimum [" + toString(minimum) - + "] must be less than the Maximum [" + toString(maximum) + "]."; + std::string msg = "Invalid Range: Minimum [" + Isis::toString(minimum) + + "] must be less than the Maximum [" + Isis::toString(maximum) + "]."; throw IException(IException::Programmer, msg, _FILEINFO_); } //??? throw exception if data has already been added??? @@ -801,7 +801,7 @@ namespace Isis { if (value == Maximum()) return 0; else { std::string msg = "Undefined Z-score. Standard deviation is zero and the input value[" - + toString(value) + "] is out of range [" + toString(Maximum()) + "]."; + + Isis::toString(value) + "] is out of range [" + Isis::toString(Maximum()) + "]."; throw IException(IException::Programmer, msg, _FILEINFO_); } } @@ -848,26 +848,26 @@ namespace Isis { } // Construct a label with the results PvlGroup results(name.toStdString()); - results += PvlKeyword("Sum", toString(Sum())); - results += PvlKeyword("SumSquare", toString(SumSquare())); - results += PvlKeyword("Minimum", toString(Minimum())); - results += PvlKeyword("Maximum", toString(Maximum())); - results += PvlKeyword("ValidMinimum", toString(ValidMinimum())); - results += PvlKeyword("ValidMaximum", toString(ValidMaximum())); + results += PvlKeyword("Sum", Isis::toString(Sum())); + results += PvlKeyword("SumSquare", Isis::toString(SumSquare())); + results += PvlKeyword("Minimum", Isis::toString(Minimum())); + results += PvlKeyword("Maximum", Isis::toString(Maximum())); + results += PvlKeyword("ValidMinimum", Isis::toString(ValidMinimum())); + results += PvlKeyword("ValidMaximum", Isis::toString(ValidMaximum())); if (ValidPixels() != 0) { - results += PvlKeyword("Average", toString(Average())); - results += PvlKeyword("StandardDeviation", toString(StandardDeviation())); - results += PvlKeyword("Variance", toString(Variance())); + results += PvlKeyword("Average", Isis::toString(Average())); + results += PvlKeyword("StandardDeviation", Isis::toString(StandardDeviation())); + results += PvlKeyword("Variance", Isis::toString(Variance())); } - results += PvlKeyword("TotalPixels", toString(TotalPixels())); - results += PvlKeyword("ValidPixels", toString(ValidPixels())); - results += PvlKeyword("OverValidMaximumPixels", toString(OverRangePixels())); - results += PvlKeyword("UnderValidMinimumPixels", toString(UnderRangePixels())); - results += PvlKeyword("NullPixels", toString(NullPixels())); - results += PvlKeyword("LisPixels", toString(LisPixels())); - results += PvlKeyword("LrsPixels", toString(LrsPixels())); - results += PvlKeyword("HisPixels", toString(HisPixels())); - results += PvlKeyword("HrsPixels", toString(HrsPixels())); + results += PvlKeyword("TotalPixels", Isis::toString(TotalPixels())); + results += PvlKeyword("ValidPixels", Isis::toString(ValidPixels())); + results += PvlKeyword("OverValidMaximumPixels", Isis::toString(OverRangePixels())); + results += PvlKeyword("UnderValidMinimumPixels", Isis::toString(UnderRangePixels())); + results += PvlKeyword("NullPixels", Isis::toString(NullPixels())); + results += PvlKeyword("LisPixels", Isis::toString(LisPixels())); + results += PvlKeyword("LrsPixels", Isis::toString(LrsPixels())); + results += PvlKeyword("HisPixels", Isis::toString(HisPixels())); + results += PvlKeyword("HrsPixels", Isis::toString(HrsPixels())); return results; } @@ -876,7 +876,7 @@ namespace Isis { void Statistics::save(QXmlStreamWriter &stream, const Project *project) const { // TODO: does xml stuff need project??? stream.writeStartElement("statistics"); -// stream.writeTextElement("id", m_id->toString()); +// stream.writeTextElement("id", m_id->Isis::toString()); stream.writeTextElement("sum",QString::fromStdString(toString(m_sum))); stream.writeTextElement("sumSquares",QString::fromStdString(toString(m_sumsum))); diff --git a/isis/src/base/objs/Stretch/Stretch.cpp b/isis/src/base/objs/Stretch/Stretch.cpp index d4f7214564..c8fe7e49de 100644 --- a/isis/src/base/objs/Stretch/Stretch.cpp +++ b/isis/src/base/objs/Stretch/Stretch.cpp @@ -349,7 +349,7 @@ namespace Isis { throw IException(IException::User, msg, _FILEINFO_); } for(int i = 0; i < inputs.size(); i++) { - AddPair(IString::ToDouble(inputs[i]), IString::ToDouble(outputs[i])); + AddPair(Isis::toDouble(inputs[i]), Isis::toDouble(outputs[i])); } } @@ -375,8 +375,8 @@ namespace Isis { PvlKeyword inputs("Input"); PvlKeyword outputs("Output"); for(int i = 0; i < Pairs(); i++) { - inputs.addValue(toString(Input(i))); - outputs.addValue(toString(Output(i))); + inputs.addValue(Isis::toString(Input(i))); + outputs.addValue(Isis::toString(Output(i))); } grp->addKeyword(inputs); grp->addKeyword(outputs); diff --git a/isis/src/base/objs/StripPolygonSeeder/StripPolygonSeeder.cpp b/isis/src/base/objs/StripPolygonSeeder/StripPolygonSeeder.cpp index 8594fe4978..a395bde931 100644 --- a/isis/src/base/objs/StripPolygonSeeder/StripPolygonSeeder.cpp +++ b/isis/src/base/objs/StripPolygonSeeder/StripPolygonSeeder.cpp @@ -162,10 +162,10 @@ namespace Isis { PvlGroup pluginInfo(grpName.toStdString()); PvlKeyword name("Name", Algorithm().toStdString()); - PvlKeyword minThickness("MinimumThickness", toString(MinimumThickness())); - PvlKeyword minArea("MinimumArea", toString(MinimumArea())); - PvlKeyword xSpac("XSpacing", toString(p_Xspacing)); - PvlKeyword ySpac("YSpacing", toString(p_Yspacing)); + PvlKeyword minThickness("MinimumThickness", Isis::toString(MinimumThickness())); + PvlKeyword minArea("MinimumArea", Isis::toString(MinimumArea())); + PvlKeyword xSpac("XSpacing", Isis::toString(p_Xspacing)); + PvlKeyword ySpac("YSpacing", Isis::toString(p_Yspacing)); pluginInfo.addKeyword(name); pluginInfo.addKeyword(minThickness); diff --git a/isis/src/base/objs/StripPolygonSeeder/unitTest.cpp b/isis/src/base/objs/StripPolygonSeeder/unitTest.cpp index 219df5d28f..79c821cf23 100644 --- a/isis/src/base/objs/StripPolygonSeeder/unitTest.cpp +++ b/isis/src/base/objs/StripPolygonSeeder/unitTest.cpp @@ -38,10 +38,10 @@ int main() { if(!alg.hasKeyword("Name")) { cout << "Test without subgrid" << endl; alg += PvlKeyword("Name", "Strip"); - alg += PvlKeyword("MinimumThickness", toString(0.3)); - alg += PvlKeyword("MinimumArea", toString(10)); - alg += PvlKeyword("XSpacing", toString(1500)); - alg += PvlKeyword("YSpacing", toString(1500)); + alg += PvlKeyword("MinimumThickness", Isis::toString(0.3)); + alg += PvlKeyword("MinimumArea", Isis::toString(10)); + alg += PvlKeyword("XSpacing", Isis::toString(1500)); + alg += PvlKeyword("YSpacing", Isis::toString(1500)); } PvlObject o("AutoSeed"); @@ -85,7 +85,7 @@ int main() { mapGroup += Isis::PvlKeyword("PolarRadius", (std::string)radii["PolarRadius"]); mapGroup += Isis::PvlKeyword("LatitudeType", "Planetocentric"); mapGroup += Isis::PvlKeyword("LongitudeDirection", "PositiveEast"); - mapGroup += Isis::PvlKeyword("LongitudeDomain", toString(360)); + mapGroup += Isis::PvlKeyword("LongitudeDomain", Isis::toString(360)); mapGroup += Isis::PvlKeyword("CenterLatitude", "0"); mapGroup += Isis::PvlKeyword("CenterLongitude", "0"); mapGroup += Isis::PvlKeyword("ProjectionName", "Sinusoidal"); @@ -161,9 +161,9 @@ int main() { mapGroup += Isis::PvlKeyword("PolarRadius", (std::string)radii["PolarRadius"]); mapGroup += Isis::PvlKeyword("LatitudeType", "Planetocentric"); mapGroup += Isis::PvlKeyword("LongitudeDirection", "PositiveEast"); - mapGroup += Isis::PvlKeyword("LongitudeDomain", toString(360)); - mapGroup += Isis::PvlKeyword("CenterLatitude", toString(0)); - mapGroup += Isis::PvlKeyword("CenterLongitude", toString(0)); + mapGroup += Isis::PvlKeyword("LongitudeDomain", Isis::toString(360)); + mapGroup += Isis::PvlKeyword("CenterLatitude", Isis::toString(0)); + mapGroup += Isis::PvlKeyword("CenterLongitude", Isis::toString(0)); mapGroup += Isis::PvlKeyword("ProjectionName", "Sinusoidal"); TProjection *proj = (TProjection *) Isis::ProjectionFactory::Create(maplab); diff --git a/isis/src/base/objs/SubArea/SubArea.cpp b/isis/src/base/objs/SubArea/SubArea.cpp index 90011c1842..17c3c1914d 100644 --- a/isis/src/base/objs/SubArea/SubArea.cpp +++ b/isis/src/base/objs/SubArea/SubArea.cpp @@ -151,9 +151,9 @@ namespace Isis { if(p_sl != 1 || p_ss != 1) { proj->SetWorld(p_ss - 0.5, p_sl - 0.5); PvlGroup &mapgroup = inlabel.findObject("IsisCube").findGroup("Mapping", Pvl::Traverse); - mapgroup.addKeyword(PvlKeyword("UpperLeftCornerX", toString(proj->XCoord())), + mapgroup.addKeyword(PvlKeyword("UpperLeftCornerX", Isis::toString(proj->XCoord())), Pvl::Replace); - mapgroup.addKeyword(PvlKeyword("UpperLeftCornerY", toString(proj->YCoord())), + mapgroup.addKeyword(PvlKeyword("UpperLeftCornerY", Isis::toString(proj->YCoord())), Pvl::Replace); } @@ -162,12 +162,12 @@ namespace Isis { if(p_linc == p_sinc && p_linc != 1.0) { PvlGroup &mapgroup = inlabel.findObject("IsisCube").findGroup("Mapping", Pvl::Traverse); QString pixresUnit = QString::fromStdString(mapgroup["PixelResolution"].unit()); - double pixres = IString::ToDouble(mapgroup["PixelResolution"][0]); - mapgroup["PixelResolution"] = toString(pixres * p_linc); + double pixres = Isis::toDouble(mapgroup["PixelResolution"][0]); + mapgroup["PixelResolution"] = Isis::toString(pixres * p_linc); mapgroup["PixelResolution"].setUnits(pixresUnit.toStdString()); QString scaleUnit = QString::fromStdString(mapgroup["Scale"].unit()); double scale = mapgroup["Scale"]; - mapgroup["Scale"] = toString(scale / p_linc); + mapgroup["Scale"] = Isis::toString(scale / p_linc); mapgroup["Scale"].setUnits(scaleUnit.toStdString()); } @@ -218,10 +218,10 @@ namespace Isis { maxlon = proj->ToPositiveWest(proj->Longitude(), 180); } } - mapgroup.addKeyword(PvlKeyword("MinimumLatitude",toString(minlat)),Pvl::Replace); - mapgroup.addKeyword(PvlKeyword("MaximumLatitude",toString(maxlat)),Pvl::Replace); - mapgroup.addKeyword(PvlKeyword("MinimumLongitude",toString(minlon)),Pvl::Replace); - mapgroup.addKeyword(PvlKeyword("MaximumLongitude",toString(maxlon)),Pvl::Replace); + mapgroup.addKeyword(PvlKeyword("MinimumLatitude",Isis::toString(minlat)),Pvl::Replace); + mapgroup.addKeyword(PvlKeyword("MaximumLatitude",Isis::toString(maxlat)),Pvl::Replace); + mapgroup.addKeyword(PvlKeyword("MinimumLongitude",Isis::toString(minlon)),Pvl::Replace); + mapgroup.addKeyword(PvlKeyword("MaximumLongitude",Isis::toString(maxlon)),Pvl::Replace); } } } diff --git a/isis/src/base/objs/SubArea/unitTest.cpp b/isis/src/base/objs/SubArea/unitTest.cpp index 7155642ae4..914dcc11a1 100644 --- a/isis/src/base/objs/SubArea/unitTest.cpp +++ b/isis/src/base/objs/SubArea/unitTest.cpp @@ -47,16 +47,16 @@ void IsisMain() { Cube *onomapcube = p1.SetOutputCube("TO", ons, onl, 1); PvlGroup results("Results"); - results += PvlKeyword("InputLines", toString(inl)); - results += PvlKeyword("InputSamples", toString(ins)); - results += PvlKeyword("StartingLine", toString(sl)); - results += PvlKeyword("StartingSample", toString(ss)); - results += PvlKeyword("EndingLine", toString(el)); - results += PvlKeyword("EndingSample", toString(es)); - results += PvlKeyword("LineIncrement", toString(linc)); - results += PvlKeyword("SampleIncrement", toString(sinc)); - results += PvlKeyword("OutputLines", toString(onl)); - results += PvlKeyword("OutputSamples", toString(ons)); + results += PvlKeyword("InputLines", Isis::toString(inl)); + results += PvlKeyword("InputSamples", Isis::toString(ins)); + results += PvlKeyword("StartingLine", Isis::toString(sl)); + results += PvlKeyword("StartingSample", Isis::toString(ss)); + results += PvlKeyword("EndingLine", Isis::toString(el)); + results += PvlKeyword("EndingSample", Isis::toString(es)); + results += PvlKeyword("LineIncrement", Isis::toString(linc)); + results += PvlKeyword("SampleIncrement", Isis::toString(sinc)); + results += PvlKeyword("OutputLines", Isis::toString(onl)); + results += PvlKeyword("OutputSamples", Isis::toString(ons)); SubArea s; s.SetSubArea(inl, ins, sl, ss, el, es, linc, sinc); @@ -107,16 +107,16 @@ void IsisMain() { ons = (int)ceil((double)(es - ss + 1) / sinc); onomapcube = p2.SetOutputCube("TO", ons, onl, 1); - results += PvlKeyword("InputLines", toString(inl)); - results += PvlKeyword("InputSamples", toString(ins)); - results += PvlKeyword("StartingLine", toString(sl)); - results += PvlKeyword("StartingSample", toString(ss)); - results += PvlKeyword("EndingLine", toString(el)); - results += PvlKeyword("EndingSample", toString(es)); - results += PvlKeyword("LineIncrement", toString(linc)); - results += PvlKeyword("SampleIncrement", toString(sinc)); - results += PvlKeyword("OutputLines", toString(onl)); - results += PvlKeyword("OutputSamples", toString(ons)); + results += PvlKeyword("InputLines", Isis::toString(inl)); + results += PvlKeyword("InputSamples", Isis::toString(ins)); + results += PvlKeyword("StartingLine", Isis::toString(sl)); + results += PvlKeyword("StartingSample", Isis::toString(ss)); + results += PvlKeyword("EndingLine", Isis::toString(el)); + results += PvlKeyword("EndingSample", Isis::toString(es)); + results += PvlKeyword("LineIncrement", Isis::toString(linc)); + results += PvlKeyword("SampleIncrement", Isis::toString(sinc)); + results += PvlKeyword("OutputLines", Isis::toString(onl)); + results += PvlKeyword("OutputSamples", Isis::toString(ons)); s.SetSubArea(inl, ins, sl, ss, el, es, linc, sinc); s.UpdateLabel(&inomapcube, onomapcube, results); @@ -153,16 +153,16 @@ void IsisMain() { ons = (int)ceil((double)(es - ss + 1) / sinc); onomapcube = p3.SetOutputCube("TO", ons, onl, 1); - results += PvlKeyword("InputLines", toString(inl)); - results += PvlKeyword("InputSamples", toString(ins)); - results += PvlKeyword("StartingLine", toString(sl)); - results += PvlKeyword("StartingSample", toString(ss)); - results += PvlKeyword("EndingLine", toString(el)); - results += PvlKeyword("EndingSample", toString(es)); - results += PvlKeyword("LineIncrement", toString(linc)); - results += PvlKeyword("SampleIncrement", toString(sinc)); - results += PvlKeyword("OutputLines", toString(onl)); - results += PvlKeyword("OutputSamples", toString(ons)); + results += PvlKeyword("InputLines", Isis::toString(inl)); + results += PvlKeyword("InputSamples", Isis::toString(ins)); + results += PvlKeyword("StartingLine", Isis::toString(sl)); + results += PvlKeyword("StartingSample", Isis::toString(ss)); + results += PvlKeyword("EndingLine", Isis::toString(el)); + results += PvlKeyword("EndingSample", Isis::toString(es)); + results += PvlKeyword("LineIncrement", Isis::toString(linc)); + results += PvlKeyword("SampleIncrement", Isis::toString(sinc)); + results += PvlKeyword("OutputLines", Isis::toString(onl)); + results += PvlKeyword("OutputSamples", Isis::toString(ons)); s.SetSubArea(inl, ins, sl, ss, el, es, linc, sinc); s.UpdateLabel(&inomapcube, onomapcube, results); @@ -203,16 +203,16 @@ void IsisMain() { ons = (int)ceil((double)(es - ss + 1) / sinc); onomapcube = p4.SetOutputCube("TO", ons, onl, 1); - results += PvlKeyword("InputLines", toString(inl)); - results += PvlKeyword("InputSamples", toString(ins)); - results += PvlKeyword("StartingLine", toString(sl)); - results += PvlKeyword("StartingSample", toString(ss)); - results += PvlKeyword("EndingLine", toString(el)); - results += PvlKeyword("EndingSample", toString(es)); - results += PvlKeyword("LineIncrement", toString(linc)); - results += PvlKeyword("SampleIncrement", toString(sinc)); - results += PvlKeyword("OutputLines", toString(onl)); - results += PvlKeyword("OutputSamples", toString(ons)); + results += PvlKeyword("InputLines", Isis::toString(inl)); + results += PvlKeyword("InputSamples", Isis::toString(ins)); + results += PvlKeyword("StartingLine", Isis::toString(sl)); + results += PvlKeyword("StartingSample", Isis::toString(ss)); + results += PvlKeyword("EndingLine", Isis::toString(el)); + results += PvlKeyword("EndingSample", Isis::toString(es)); + results += PvlKeyword("LineIncrement", Isis::toString(linc)); + results += PvlKeyword("SampleIncrement", Isis::toString(sinc)); + results += PvlKeyword("OutputLines", Isis::toString(onl)); + results += PvlKeyword("OutputSamples", Isis::toString(ons)); s.SetSubArea(inl, ins, sl, ss, el, es, linc, sinc); s.UpdateLabel(&inomapcube, onomapcube, results); @@ -249,16 +249,16 @@ void IsisMain() { ons = (int)ceil((double)(es - ss + 1) / sinc); onomapcube = p5.SetOutputCube("TO", ons, onl, 1); - results += PvlKeyword("InputLines", toString(inl)); - results += PvlKeyword("InputSamples", toString(ins)); - results += PvlKeyword("StartingLine", toString(sl)); - results += PvlKeyword("StartingSample", toString(ss)); - results += PvlKeyword("EndingLine", toString(el)); - results += PvlKeyword("EndingSample", toString(es)); - results += PvlKeyword("LineIncrement", toString(linc)); - results += PvlKeyword("SampleIncrement", toString(sinc)); - results += PvlKeyword("OutputLines", toString(onl)); - results += PvlKeyword("OutputSamples", toString(ons)); + results += PvlKeyword("InputLines", Isis::toString(inl)); + results += PvlKeyword("InputSamples", Isis::toString(ins)); + results += PvlKeyword("StartingLine", Isis::toString(sl)); + results += PvlKeyword("StartingSample", Isis::toString(ss)); + results += PvlKeyword("EndingLine", Isis::toString(el)); + results += PvlKeyword("EndingSample", Isis::toString(es)); + results += PvlKeyword("LineIncrement", Isis::toString(linc)); + results += PvlKeyword("SampleIncrement", Isis::toString(sinc)); + results += PvlKeyword("OutputLines", Isis::toString(onl)); + results += PvlKeyword("OutputSamples", Isis::toString(ons)); s.SetSubArea(inl, ins, sl, ss, el, es, linc, sinc); s.UpdateLabel(&inomapcube, onomapcube, results); @@ -306,16 +306,16 @@ void IsisMain() { ons = (int)ceil((double)(es - ss + 1) / sinc); Cube *omapcube = p6.SetOutputCube("TO", ons, onl, 1); - results += PvlKeyword("InputLines", toString(inl)); - results += PvlKeyword("InputSamples", toString(ins)); - results += PvlKeyword("StartingLine", toString(sl)); - results += PvlKeyword("StartingSample", toString(ss)); - results += PvlKeyword("EndingLine", toString(el)); - results += PvlKeyword("EndingSample", toString(es)); - results += PvlKeyword("LineIncrement", toString(linc)); - results += PvlKeyword("SampleIncrement", toString(sinc)); - results += PvlKeyword("OutputLines", toString(onl)); - results += PvlKeyword("OutputSamples", toString(ons)); + results += PvlKeyword("InputLines", Isis::toString(inl)); + results += PvlKeyword("InputSamples", Isis::toString(ins)); + results += PvlKeyword("StartingLine", Isis::toString(sl)); + results += PvlKeyword("StartingSample", Isis::toString(ss)); + results += PvlKeyword("EndingLine", Isis::toString(el)); + results += PvlKeyword("EndingSample", Isis::toString(es)); + results += PvlKeyword("LineIncrement", Isis::toString(linc)); + results += PvlKeyword("SampleIncrement", Isis::toString(sinc)); + results += PvlKeyword("OutputLines", Isis::toString(onl)); + results += PvlKeyword("OutputSamples", Isis::toString(ons)); s.SetSubArea(inl, ins, sl, ss, el, es, linc, sinc); s.UpdateLabel(&imapcube, omapcube, results); @@ -363,16 +363,16 @@ void IsisMain() { ons = (int)ceil((double)(es - ss + 1) / sinc); omapcube = p7.SetOutputCube("TO", ons, onl, 1); - results += PvlKeyword("InputLines", toString(inl)); - results += PvlKeyword("InputSamples", toString(ins)); - results += PvlKeyword("StartingLine", toString(sl)); - results += PvlKeyword("StartingSample", toString(ss)); - results += PvlKeyword("EndingLine", toString(el)); - results += PvlKeyword("EndingSample", toString(es)); - results += PvlKeyword("LineIncrement", toString(linc)); - results += PvlKeyword("SampleIncrement", toString(sinc)); - results += PvlKeyword("OutputLines", toString(onl)); - results += PvlKeyword("OutputSamples", toString(ons)); + results += PvlKeyword("InputLines", Isis::toString(inl)); + results += PvlKeyword("InputSamples", Isis::toString(ins)); + results += PvlKeyword("StartingLine", Isis::toString(sl)); + results += PvlKeyword("StartingSample", Isis::toString(ss)); + results += PvlKeyword("EndingLine", Isis::toString(el)); + results += PvlKeyword("EndingSample", Isis::toString(es)); + results += PvlKeyword("LineIncrement", Isis::toString(linc)); + results += PvlKeyword("SampleIncrement", Isis::toString(sinc)); + results += PvlKeyword("OutputLines", Isis::toString(onl)); + results += PvlKeyword("OutputSamples", Isis::toString(ons)); s.SetSubArea(inl, ins, sl, ss, el, es, linc, sinc); s.UpdateLabel(&imapcube, omapcube, results); @@ -409,16 +409,16 @@ void IsisMain() { ons = (int)ceil((double)(es - ss + 1) / sinc); omapcube = p8.SetOutputCube("TO", ons, onl, 1); - results += PvlKeyword("InputLines", toString(inl)); - results += PvlKeyword("InputSamples", toString(ins)); - results += PvlKeyword("StartingLine", toString(sl)); - results += PvlKeyword("StartingSample", toString(ss)); - results += PvlKeyword("EndingLine", toString(el)); - results += PvlKeyword("EndingSample", toString(es)); - results += PvlKeyword("LineIncrement", toString(linc)); - results += PvlKeyword("SampleIncrement", toString(sinc)); - results += PvlKeyword("OutputLines", toString(onl)); - results += PvlKeyword("OutputSamples", toString(ons)); + results += PvlKeyword("InputLines", Isis::toString(inl)); + results += PvlKeyword("InputSamples", Isis::toString(ins)); + results += PvlKeyword("StartingLine", Isis::toString(sl)); + results += PvlKeyword("StartingSample", Isis::toString(ss)); + results += PvlKeyword("EndingLine", Isis::toString(el)); + results += PvlKeyword("EndingSample", Isis::toString(es)); + results += PvlKeyword("LineIncrement", Isis::toString(linc)); + results += PvlKeyword("SampleIncrement", Isis::toString(sinc)); + results += PvlKeyword("OutputLines", Isis::toString(onl)); + results += PvlKeyword("OutputSamples", Isis::toString(ons)); s.SetSubArea(inl, ins, sl, ss, el, es, linc, sinc); s.UpdateLabel(&imapcube, omapcube, results); @@ -459,16 +459,16 @@ void IsisMain() { ons = (int)ceil((double)(es - ss + 1) / sinc); omapcube = p9.SetOutputCube("TO", ons, onl, 1); - results += PvlKeyword("InputLines", toString(inl)); - results += PvlKeyword("InputSamples", toString(ins)); - results += PvlKeyword("StartingLine", toString(sl)); - results += PvlKeyword("StartingSample", toString(ss)); - results += PvlKeyword("EndingLine", toString(el)); - results += PvlKeyword("EndingSample", toString(es)); - results += PvlKeyword("LineIncrement", toString(linc)); - results += PvlKeyword("SampleIncrement", toString(sinc)); - results += PvlKeyword("OutputLines", toString(onl)); - results += PvlKeyword("OutputSamples", toString(ons)); + results += PvlKeyword("InputLines", Isis::toString(inl)); + results += PvlKeyword("InputSamples", Isis::toString(ins)); + results += PvlKeyword("StartingLine", Isis::toString(sl)); + results += PvlKeyword("StartingSample", Isis::toString(ss)); + results += PvlKeyword("EndingLine", Isis::toString(el)); + results += PvlKeyword("EndingSample", Isis::toString(es)); + results += PvlKeyword("LineIncrement", Isis::toString(linc)); + results += PvlKeyword("SampleIncrement", Isis::toString(sinc)); + results += PvlKeyword("OutputLines", Isis::toString(onl)); + results += PvlKeyword("OutputSamples", Isis::toString(ons)); s.SetSubArea(inl, ins, sl, ss, el, es, linc, sinc); s.UpdateLabel(&imapcube, omapcube, results); @@ -505,16 +505,16 @@ void IsisMain() { ons = (int)ceil((double)(es - ss + 1) / sinc); omapcube = p10.SetOutputCube("TO", ons, onl, 1); - results += PvlKeyword("InputLines", toString(inl)); - results += PvlKeyword("InputSamples", toString(ins)); - results += PvlKeyword("StartingLine", toString(sl)); - results += PvlKeyword("StartingSample", toString(ss)); - results += PvlKeyword("EndingLine", toString(el)); - results += PvlKeyword("EndingSample", toString(es)); - results += PvlKeyword("LineIncrement", toString(linc)); - results += PvlKeyword("SampleIncrement", toString(sinc)); - results += PvlKeyword("OutputLines", toString(onl)); - results += PvlKeyword("OutputSamples", toString(ons)); + results += PvlKeyword("InputLines", Isis::toString(inl)); + results += PvlKeyword("InputSamples", Isis::toString(ins)); + results += PvlKeyword("StartingLine", Isis::toString(sl)); + results += PvlKeyword("StartingSample", Isis::toString(ss)); + results += PvlKeyword("EndingLine", Isis::toString(el)); + results += PvlKeyword("EndingSample", Isis::toString(es)); + results += PvlKeyword("LineIncrement", Isis::toString(linc)); + results += PvlKeyword("SampleIncrement", Isis::toString(sinc)); + results += PvlKeyword("OutputLines", Isis::toString(onl)); + results += PvlKeyword("OutputSamples", Isis::toString(ons)); s.SetSubArea(inl, ins, sl, ss, el, es, linc, sinc); s.UpdateLabel(&imapcube, omapcube, results); @@ -562,16 +562,16 @@ void IsisMain() { ons = (int)ceil((double)(es - ss + 1) / sinc); omapcube = p11.SetOutputCube("TO", ons, onl, 1); - results += PvlKeyword("InputLines", toString(inl)); - results += PvlKeyword("InputSamples", toString(ins)); - results += PvlKeyword("StartingLine", toString(sl)); - results += PvlKeyword("StartingSample", toString(ss)); - results += PvlKeyword("EndingLine", toString(el)); - results += PvlKeyword("EndingSample", toString(es)); - results += PvlKeyword("LineIncrement", toString(linc)); - results += PvlKeyword("SampleIncrement", toString(sinc)); - results += PvlKeyword("OutputLines", toString(onl)); - results += PvlKeyword("OutputSamples", toString(ons)); + results += PvlKeyword("InputLines", Isis::toString(inl)); + results += PvlKeyword("InputSamples", Isis::toString(ins)); + results += PvlKeyword("StartingLine", Isis::toString(sl)); + results += PvlKeyword("StartingSample", Isis::toString(ss)); + results += PvlKeyword("EndingLine", Isis::toString(el)); + results += PvlKeyword("EndingSample", Isis::toString(es)); + results += PvlKeyword("LineIncrement", Isis::toString(linc)); + results += PvlKeyword("SampleIncrement", Isis::toString(sinc)); + results += PvlKeyword("OutputLines", Isis::toString(onl)); + results += PvlKeyword("OutputSamples", Isis::toString(ons)); s.SetSubArea(inl, ins, sl, ss, el, es, linc, sinc); s.UpdateLabel(&smapcube, omapcube, results); diff --git a/isis/src/base/objs/TProjection/TProjection.cpp b/isis/src/base/objs/TProjection/TProjection.cpp index d29c65852a..ea8b661802 100644 --- a/isis/src/base/objs/TProjection/TProjection.cpp +++ b/isis/src/base/objs/TProjection/TProjection.cpp @@ -175,14 +175,14 @@ namespace Isis { if ((m_minimumLatitude < -90.0) || (m_minimumLatitude > 90.0)) { std::string msg = "Projection failed. " - "[MinimumLatitude] of [" + toString(m_minimumLatitude) + "[MinimumLatitude] of [" + Isis::toString(m_minimumLatitude) + "] is outside the range of [-90:90]"; throw IException(IException::Unknown, msg, _FILEINFO_); } if ((m_maximumLatitude < -90.0) || (m_maximumLatitude > 90.0)) { std::string msg = "Projection failed. " - "[MaximumLatitude] of [" + toString(m_maximumLatitude) + "[MaximumLatitude] of [" + Isis::toString(m_maximumLatitude) + "] is outside the range of [-90:90]"; throw IException(IException::Unknown, msg, _FILEINFO_); } @@ -190,8 +190,8 @@ namespace Isis { if (m_minimumLatitude >= m_maximumLatitude) { std::string msg = "Projection failed. " "[MinimumLatitude,MaximumLatitude] of [" - + toString(m_minimumLatitude) + "," - + toString(m_maximumLatitude) + "] are not " + + Isis::toString(m_minimumLatitude) + "," + + Isis::toString(m_maximumLatitude) + "] are not " + "properly ordered"; throw IException(IException::Unknown, msg, _FILEINFO_); } @@ -199,8 +199,8 @@ namespace Isis { if (m_minimumLongitude >= m_maximumLongitude) { std::string msg = "Projection failed. " "[MinimumLongitude,MaximumLongitude] of [" - + toString(m_minimumLongitude) + "," - + toString(m_maximumLongitude) + "] are not " + + Isis::toString(m_minimumLongitude) + "," + + Isis::toString(m_maximumLongitude) + "] are not " + "properly ordered"; throw IException(IException::Unknown, msg, _FILEINFO_); } @@ -218,9 +218,9 @@ namespace Isis { // Initialize miscellaneous protected data elements if (m_equatorialRadius < m_polarRadius) { std::string msg = "Projection failed. Invalid keyword value(s). " - "[EquatorialRadius] = " + toString(m_equatorialRadius) + "[EquatorialRadius] = " + Isis::toString(m_equatorialRadius) + " must be greater than or equal to [PolarRadius] = " - + toString(m_polarRadius); + + Isis::toString(m_polarRadius); throw IException(IException::Unknown, msg, _FILEINFO_); } else { @@ -327,7 +327,7 @@ namespace Isis { if (latitude == Null) { throw IException(IException::Unknown, "Unable to calculate local radius. The given latitude value [" - + toString(latitude) + "] is invalid.", + + Isis::toString(latitude) + "] is invalid.", _FILEINFO_); } double a = m_equatorialRadius; @@ -436,7 +436,7 @@ namespace Isis { if (lat == Null || abs(lat) > 90.0) { throw IException(IException::Unknown, "Unable to convert to Planetocentric. The given latitude value [" - + toString(lat) + "] is invalid.", + + Isis::toString(lat) + "] is invalid.", _FILEINFO_); } double mylat = lat; @@ -486,7 +486,7 @@ namespace Isis { if (lat == Null || fabs(lat) > 90.0) { throw IException(IException::Unknown, "Unable to convert to Planetographic. The given latitude value [" - + toString(lat) + "] is invalid.", + + Isis::toString(lat) + "] is invalid.", _FILEINFO_); } double mylat = lat; @@ -549,7 +549,7 @@ namespace Isis { if (lon == Null) { throw IException(IException::Unknown, "Unable to convert to PositiveEast. The given longitude value [" - + toString(lon) + "] is invalid.", + + Isis::toString(lon) + "] is invalid.", _FILEINFO_); } double mylon = lon; @@ -563,7 +563,7 @@ namespace Isis { mylon = To180Domain(mylon); } else { - std::string msg = "Unable to convert longitude. Domain [" + toString(domain) + std::string msg = "Unable to convert longitude. Domain [" + Isis::toString(domain) + "] is not 180 or 360."; throw IException(IException::Unknown, msg, _FILEINFO_); } @@ -588,7 +588,7 @@ namespace Isis { if (lon == Null) { throw IException(IException::Unknown, "Unable to convert to PositiveWest. The given longitude value [" - + toString(lon) + "] is invalid.", + + Isis::toString(lon) + "] is invalid.", _FILEINFO_); } double mylon = lon; @@ -602,7 +602,7 @@ namespace Isis { mylon = To180Domain(mylon); } else { - std::string msg = "Unable to convert longitude. Domain [" + toString(domain) + std::string msg = "Unable to convert longitude. Domain [" + Isis::toString(domain) + "] is not 180 or 360."; throw IException(IException::Unknown, msg, _FILEINFO_); } @@ -658,7 +658,7 @@ namespace Isis { if (lon == Null) { throw IException(IException::Unknown, "Unable to convert to 180 degree domain. The given longitude value [" - + toString(lon) + "] is invalid.", + + Isis::toString(lon) + "] is invalid.", _FILEINFO_); } return Isis::Longitude(lon, Angle::Degrees).force180Domain().degrees(); @@ -676,7 +676,7 @@ namespace Isis { if (lon == Null) { throw IException(IException::Unknown, "Unable to convert to 360 degree domain. The given longitude value [" - + toString(lon) + "] is invalid.", + + Isis::toString(lon) + "] is invalid.", _FILEINFO_); } double result = lon; diff --git a/isis/src/base/objs/Target/Target.cpp b/isis/src/base/objs/Target/Target.cpp index f6a3eca0bf..fb9c637801 100644 --- a/isis/src/base/objs/Target/Target.cpp +++ b/isis/src/base/objs/Target/Target.cpp @@ -62,7 +62,7 @@ namespace Isis { if (name().toUpper() == "SKY") { m_radii[0] = m_radii[1] = m_radii[2] = Distance(1000.0, Distance::Meters); m_sky = true; - int ikCode = IString::ToInteger(kernels[trykey.toStdString()][0]); + int ikCode = Isis::toInt(kernels[trykey.toStdString()][0]); *m_bodyCode = ikCode / 1000; // Check for override in kernel group if (kernels.hasKeyword("NaifSpkCode")) { @@ -133,7 +133,7 @@ namespace Isis { if (name().toUpper() == "SKY" && kernels.hasKeyword(trykey)) { m_radii[0] = m_radii[1] = m_radii[2] = Distance(1000.0, Distance::Meters); m_sky = true; - int ikCode = IString::ToInteger(kernels[trykey][0]); + int ikCode = Isis::toInt(kernels[trykey][0]); *m_bodyCode = ikCode / 1000; // Check for override in kernel group if (kernels.hasKeyword("NaifSpkCode")) { @@ -368,15 +368,15 @@ namespace Isis { catch (IException &e2) { throw IException(e, IException::Unknown, e2.what(), _FILEINFO_); } - std::string radiiKeyword = "BODY" + toString(int(bodyCode)) + "_RADII"; + std::string radiiKeyword = "BODY" + Isis::toString(int(bodyCode)) + "_RADII"; if (naifKeywords.hasKeyword(radiiKeyword)) { PvlKeyword radii = naifKeywords.findKeyword(radiiKeyword); mapping.addKeyword( PvlKeyword("EquatorialRadius", - toString(IString::ToDouble(radii[0]) * 1000.0), "meters"), + Isis::toString(Isis::toDouble(radii[0]) * 1000.0), "meters"), PvlContainer::Replace); mapping.addKeyword( PvlKeyword("PolarRadius", - toString(IString::ToDouble(radii[2]) * 1000.0), "meters"), + Isis::toString(Isis::toDouble(radii[2]) * 1000.0), "meters"), PvlContainer::Replace); return mapping; } @@ -391,11 +391,11 @@ namespace Isis { if (naifKeywords.hasKeyword(radiiKeyword.toStdString())) { PvlKeyword radii = naifKeywords.findKeyword(radiiKeyword.toStdString()); mapping.addKeyword( PvlKeyword("EquatorialRadius", - toString(IString::ToDouble(radii[0]) * 1000.0), + Isis::toString(Isis::toDouble(radii[0]) * 1000.0), "meters"), PvlContainer::Replace); mapping.addKeyword( PvlKeyword("PolarRadius", - toString(IString::ToDouble(radii[2]) * 1000.0), + Isis::toString(Isis::toDouble(radii[2]) * 1000.0), "meters"), PvlContainer::Replace); return mapping; @@ -498,15 +498,15 @@ namespace Isis { NaifStatus::CheckErrors(); } catch (IException &e) { - std::string msg = "Unable to find radii for target code [" + toString(bodyCode) + std::string msg = "Unable to find radii for target code [" + Isis::toString(bodyCode) + "]. Target code was not found in furnished kernels."; throw IException(e, IException::Unknown, msg, _FILEINFO_); } PvlGroup radiiGroup; - radiiGroup += PvlKeyword("EquatorialRadius", toString(radii[0] * 1000.0), "meters"); - radiiGroup += PvlKeyword("PolarRadius", toString(radii[2] * 1000.0), "meters"); + radiiGroup += PvlKeyword("EquatorialRadius", Isis::toString(radii[0] * 1000.0), "meters"); + radiiGroup += PvlKeyword("PolarRadius", Isis::toString(radii[2] * 1000.0), "meters"); return radiiGroup; diff --git a/isis/src/base/objs/Target/unitTest.cpp b/isis/src/base/objs/Target/unitTest.cpp index 54104abdd4..781565e942 100644 --- a/isis/src/base/objs/Target/unitTest.cpp +++ b/isis/src/base/objs/Target/unitTest.cpp @@ -50,7 +50,7 @@ int main(int argc, char *argv[]) { FileName f2("$base/dems"); std::string dir = f.expanded() + "/"; std::string dir2 = f2.expanded() + "/"; - kern1 += PvlKeyword("NaifFrameCode", toString(-94031)); + kern1 += PvlKeyword("NaifFrameCode", Isis::toString(-94031)); kern1 += PvlKeyword("LeapSecond", dir + "naif0007.tls"); kern1 += PvlKeyword("SpacecraftClock", dir + "MGS_SCLKSCET.00045.tsc"); kern1 += PvlKeyword("TargetPosition", dir + "de405.bsp"); @@ -62,7 +62,7 @@ int main(int argc, char *argv[]) { kern1 += PvlKeyword("Frame", ""); PvlGroup kern2("Kernels"); - kern2 += PvlKeyword("NaifIkCode", toString(-94031)); + kern2 += PvlKeyword("NaifIkCode", Isis::toString(-94031)); kern2 += PvlKeyword("LeapSecond", dir + "naif0007.tls"); kern2 += PvlKeyword("SpacecraftClock", dir + "MGS_SCLKSCET.00045.tsc"); kern2 += PvlKeyword("TargetPosition", dir + "de405.bsp"); @@ -72,7 +72,7 @@ int main(int argc, char *argv[]) { kern2 += PvlKeyword("InstrumentPosition", dir + "moc.bsp"); kern2 += PvlKeyword("InstrumentPointing", dir + "moc.bc"); kern2 += PvlKeyword("Frame", ""); - kern2 += PvlKeyword("NaifBodyCode", toString(499)); + kern2 += PvlKeyword("NaifBodyCode", Isis::toString(499)); PvlGroup kern3 = kern2; kern3 += PvlKeyword("ShapeModel", dir2 + "molaMarsPlanetaryRadius0005.cub"); @@ -82,8 +82,8 @@ int main(int argc, char *argv[]) { double endTime = -69382512.0; double slope = (endTime - startTime) / (10 - 1); - kern1 += PvlKeyword("StartPadding", toString(slope)); - kern1 += PvlKeyword("EndPadding", toString(slope)); + kern1 += PvlKeyword("StartPadding", Isis::toString(slope)); + kern1 += PvlKeyword("EndPadding", Isis::toString(slope)); Pvl lab1; lab1.addGroup(inst1); diff --git a/isis/src/base/objs/TiffImporter/TiffImporter.cpp b/isis/src/base/objs/TiffImporter/TiffImporter.cpp index dc57b37e42..16eb40925b 100644 --- a/isis/src/base/objs/TiffImporter/TiffImporter.cpp +++ b/isis/src/base/objs/TiffImporter/TiffImporter.cpp @@ -128,10 +128,10 @@ namespace Isis { // Get the mapping group data for this code: proj name, clat, clon, ... FileName transFile("$ISISROOT/appdata/translations/" + - toString(coordSysType) + ".trn"); + Isis::toString(coordSysType) + ".trn"); if (transFile.fileExists()) { Pvl tmp; - tmp += PvlKeyword("Code", toString(coordSysType)); + tmp += PvlKeyword("Code", Isis::toString(coordSysType)); PvlToPvlTranslationManager geoTiffCodeTranslater(tmp, QString::fromStdString(transFile.expanded())); geoTiffCodeTranslater.Auto(outPvl); } @@ -350,7 +350,7 @@ namespace Isis { double localRadius = proj->LocalRadius(trueScaleLat); double scale = (2.0 * Isis::PI * localRadius) / (360.0 * pixelResolution); - mapGroup += PvlKeyword("Scale", toString(scale), "pixels/degree"); + mapGroup += PvlKeyword("Scale", Isis::toString(scale), "pixels/degree"); } catch (IException &e) { outPvl.findGroup("Mapping").clear(); @@ -392,19 +392,19 @@ namespace Isis { if (gdalElement.tagName() == "Item") { if (gdalElement.attribute("name", "") == "WEST_LONGITUDE") { QString westLon = gdalElement.text(); - map += PvlKeyword("MinimumLongitude", toString(Angle(westLon).degrees())); + map += PvlKeyword("MinimumLongitude", Isis::toString(Angle(westLon).degrees())); } else if (gdalElement.attribute("name", "") == "EAST_LONGITUDE") { QString eastLon = gdalElement.text(); - map += PvlKeyword("MaximumLongitude", toString(Angle(eastLon).degrees())); + map += PvlKeyword("MaximumLongitude", Isis::toString(Angle(eastLon).degrees())); } else if (gdalElement.attribute("name", "") == "SOUTH_LATITUDE") { QString southLat = gdalElement.text(); - map += PvlKeyword("MinimumLatitude", toString(Angle(southLat).degrees())); + map += PvlKeyword("MinimumLatitude", Isis::toString(Angle(southLat).degrees())); } else if (gdalElement.attribute("name", "") == "NORTH_LATITUDE") { QString northLat = gdalElement.text(); - map += PvlKeyword("MaximumLatitude", toString(Angle(northLat).degrees())); + map += PvlKeyword("MaximumLatitude", Isis::toString(Angle(northLat).degrees())); } } } @@ -450,8 +450,8 @@ namespace Isis { map.deleteKeyword("FalseNorthing"); } - map += PvlKeyword("UpperLeftCornerX", toString(x), "meters"); - map += PvlKeyword("UpperLeftCornerY", toString(y), "meters"); + map += PvlKeyword("UpperLeftCornerX", Isis::toString(x), "meters"); + map += PvlKeyword("UpperLeftCornerY", Isis::toString(y), "meters"); } else { std::string msg = "The upper left X and Y can not be calculated. Unsupported tiepoint " @@ -484,7 +484,7 @@ namespace Isis { // The expected scales are TIFF(x, y, z) = ISIS(sample, line, 0) // Make sure the (x, y) are the same but not zero (0) for ISIS if ((scaleCount == 3) && (scales[0] > 0.0 && scales[1] > 0.0) && (scales[0] == scales[1])) { - map += PvlKeyword("PixelResolution", toString(scales[0]), "meters"); + map += PvlKeyword("PixelResolution", Isis::toString(scales[0]), "meters"); } else { std::string msg = "The pixel resolution could not be retrieved from the TIFF file. Unsupported " diff --git a/isis/src/base/objs/TransverseMercator/TransverseMercator.cpp b/isis/src/base/objs/TransverseMercator/TransverseMercator.cpp index 352630c330..a707571d8f 100644 --- a/isis/src/base/objs/TransverseMercator/TransverseMercator.cpp +++ b/isis/src/base/objs/TransverseMercator/TransverseMercator.cpp @@ -46,14 +46,14 @@ namespace Isis { // necessary if ((allowDefaults) && (!mapGroup.hasKeyword("CenterLongitude"))) { double lon = (m_minimumLongitude + m_maximumLongitude) / 2.0; - mapGroup += PvlKeyword("CenterLongitude", toString(lon)); + mapGroup += PvlKeyword("CenterLongitude", Isis::toString(lon)); } // Compute and write the default center latitude if allowed and // necessary if ((allowDefaults) && (!mapGroup.hasKeyword("CenterLatitude"))) { double lat = (m_minimumLatitude + m_maximumLatitude) / 2.0; - mapGroup += PvlKeyword("CenterLatitude", toString(lat)); + mapGroup += PvlKeyword("CenterLatitude", Isis::toString(lat)); } // Get the center longitude & latitude @@ -101,7 +101,7 @@ namespace Isis { // Get the scale factor if ((allowDefaults) && (!mapGroup.hasKeyword("ScaleFactor"))) { - mapGroup += PvlKeyword("ScaleFactor", toString(1.0)); + mapGroup += PvlKeyword("ScaleFactor", Isis::toString(1.0)); } m_scalefactor = mapGroup["ScaleFactor"]; } diff --git a/isis/src/base/objs/TransverseMercator/unitTest.cpp b/isis/src/base/objs/TransverseMercator/unitTest.cpp index 386fc97033..270640197a 100644 --- a/isis/src/base/objs/TransverseMercator/unitTest.cpp +++ b/isis/src/base/objs/TransverseMercator/unitTest.cpp @@ -25,15 +25,15 @@ int main(int argc, char *argv[]) { Pvl lab; lab.addGroup(PvlGroup("Mapping")); PvlGroup &mapGroup = lab.findGroup("Mapping"); - mapGroup += PvlKeyword("EquatorialRadius", toString(1.0)); - mapGroup += PvlKeyword("PolarRadius", toString(1.0)); + mapGroup += PvlKeyword("EquatorialRadius", Isis::toString(1.0)); + mapGroup += PvlKeyword("PolarRadius", Isis::toString(1.0)); mapGroup += PvlKeyword("LatitudeType", "Planetographic"); mapGroup += PvlKeyword("LongitudeDirection", "PositiveEast"); - mapGroup += PvlKeyword("LongitudeDomain", toString(180)); - mapGroup += PvlKeyword("MinimumLatitude", toString(-70.0)); - mapGroup += PvlKeyword("MaximumLatitude", toString(70.0)); - mapGroup += PvlKeyword("MinimumLongitude", toString(-90.0)); - mapGroup += PvlKeyword("MaximumLongitude", toString(-60.0)); + mapGroup += PvlKeyword("LongitudeDomain", Isis::toString(180)); + mapGroup += PvlKeyword("MinimumLatitude", Isis::toString(-70.0)); + mapGroup += PvlKeyword("MaximumLatitude", Isis::toString(70.0)); + mapGroup += PvlKeyword("MinimumLongitude", Isis::toString(-90.0)); + mapGroup += PvlKeyword("MaximumLongitude", Isis::toString(-60.0)); mapGroup += PvlKeyword("ProjectionName", "TransverseMercator"); cout << "Test missing center longitude keyword ..." << endl; @@ -45,7 +45,7 @@ int main(int argc, char *argv[]) { } cout << endl; - mapGroup += PvlKeyword("CenterLongitude", toString(-75.0)); + mapGroup += PvlKeyword("CenterLongitude", Isis::toString(-75.0)); cout << "Test missing center latitude keyword..." << endl; try { @@ -56,7 +56,7 @@ int main(int argc, char *argv[]) { } cout << endl; - mapGroup += PvlKeyword("CenterLatitude", toString(0.0)); + mapGroup += PvlKeyword("CenterLatitude", Isis::toString(0.0)); cout << "Test missing scale factor keyword..." << endl; try { @@ -67,7 +67,7 @@ int main(int argc, char *argv[]) { } cout << endl; - mapGroup += PvlKeyword("ScaleFactor", toString(1.0)); + mapGroup += PvlKeyword("ScaleFactor", Isis::toString(1.0)); try { TProjection *p = (TProjection *) ProjectionFactory::Create(lab); @@ -130,19 +130,19 @@ int main(int argc, char *argv[]) { Pvl lab2; lab2.addGroup(PvlGroup("Mapping")); PvlGroup &mapGroup2 = lab2.findGroup("Mapping"); - mapGroup2 += PvlKeyword("EquatorialRadius", toString(6378206.4)); - mapGroup2 += PvlKeyword("PolarRadius", toString(6356583.8)); + mapGroup2 += PvlKeyword("EquatorialRadius", Isis::toString(6378206.4)); + mapGroup2 += PvlKeyword("PolarRadius", Isis::toString(6356583.8)); mapGroup2 += PvlKeyword("LatitudeType", "Planetographic"); mapGroup2 += PvlKeyword("LongitudeDirection", "PositiveEast"); - mapGroup2 += PvlKeyword("LongitudeDomain", toString(180)); - mapGroup2 += PvlKeyword("MinimumLatitude", toString(-70.0)); - mapGroup2 += PvlKeyword("MaximumLatitude", toString(70.0)); - mapGroup2 += PvlKeyword("MinimumLongitude", toString(-90.0)); - mapGroup2 += PvlKeyword("MaximumLongitude", toString(-60.0)); + mapGroup2 += PvlKeyword("LongitudeDomain", Isis::toString(180)); + mapGroup2 += PvlKeyword("MinimumLatitude", Isis::toString(-70.0)); + mapGroup2 += PvlKeyword("MaximumLatitude", Isis::toString(70.0)); + mapGroup2 += PvlKeyword("MinimumLongitude", Isis::toString(-90.0)); + mapGroup2 += PvlKeyword("MaximumLongitude", Isis::toString(-60.0)); mapGroup2 += PvlKeyword("ProjectionName", "TransverseMercator"); - mapGroup2 += PvlKeyword("CenterLongitude", toString(-75.0)); - mapGroup2 += PvlKeyword("CenterLatitude", toString(0.0)); - mapGroup2 += PvlKeyword("ScaleFactor", toString(0.9996)); + mapGroup2 += PvlKeyword("CenterLongitude", Isis::toString(-75.0)); + mapGroup2 += PvlKeyword("CenterLatitude", Isis::toString(0.0)); + mapGroup2 += PvlKeyword("ScaleFactor", Isis::toString(0.9996)); cout << endl; try { diff --git a/isis/src/base/objs/UpturnedEllipsoidTransverseAzimuthal/UpturnedEllipsoidTransverseAzimuthal.cpp b/isis/src/base/objs/UpturnedEllipsoidTransverseAzimuthal/UpturnedEllipsoidTransverseAzimuthal.cpp index 4a94289048..6cfc7f42e5 100644 --- a/isis/src/base/objs/UpturnedEllipsoidTransverseAzimuthal/UpturnedEllipsoidTransverseAzimuthal.cpp +++ b/isis/src/base/objs/UpturnedEllipsoidTransverseAzimuthal/UpturnedEllipsoidTransverseAzimuthal.cpp @@ -62,7 +62,7 @@ namespace Isis { if (!mapGroup.hasKeyword("CenterLongitude")) { if (allowDefaults) { // centerLongitude still 0.0 here - mapGroup += PvlKeyword("CenterLongitude", toString(centerLongitude), "Degrees"); + mapGroup += PvlKeyword("CenterLongitude", Isis::toString(centerLongitude), "Degrees"); } else { std::string message = "Cannot project using upturned ellipsoid Transverse Azimuthal"; @@ -77,16 +77,16 @@ namespace Isis { if (MinimumLongitude() < centerLongitude - 90.0) { std::string message = "MinimumLongitude [" - + toString(MinimumLongitude()) + + Isis::toString(MinimumLongitude()) + "] is invalid. Must be within -90 degrees of the CenterLongitude [" - + toString(centerLongitude) + "]."; + + Isis::toString(centerLongitude) + "]."; throw IException(IException::Unknown, message, _FILEINFO_); } if (MaximumLongitude() > centerLongitude + 90.0) { std::string message = "MaximumLongitude [" - + toString(MaximumLongitude()) + + Isis::toString(MaximumLongitude()) + "] is invalid. Must be within +90 degrees of the CenterLongitude [" - + toString(centerLongitude) + "]."; + + Isis::toString(centerLongitude) + "]."; throw IException(IException::Unknown, message, _FILEINFO_); } @@ -682,7 +682,7 @@ namespace Isis { */ PvlGroup UpturnedEllipsoidTransverseAzimuthal::Mapping() { PvlGroup mapping = TProjection::Mapping(); - mapping += PvlKeyword("CenterLongitude", toString(m_lambda0 * RAD2DEG)); + mapping += PvlKeyword("CenterLongitude", Isis::toString(m_lambda0 * RAD2DEG)); return mapping; } @@ -723,7 +723,7 @@ namespace Isis { */ PvlGroup UpturnedEllipsoidTransverseAzimuthal::MappingLongitudes() { PvlGroup mapping = TProjection::MappingLongitudes(); - mapping += PvlKeyword("CenterLongitude", toString(m_lambda0 * RAD2DEG)); + mapping += PvlKeyword("CenterLongitude", Isis::toString(m_lambda0 * RAD2DEG)); return mapping; } diff --git a/isis/src/base/objs/UpturnedEllipsoidTransverseAzimuthal/unitTest.cpp b/isis/src/base/objs/UpturnedEllipsoidTransverseAzimuthal/unitTest.cpp index 1ab8159d23..6951fd0173 100644 --- a/isis/src/base/objs/UpturnedEllipsoidTransverseAzimuthal/unitTest.cpp +++ b/isis/src/base/objs/UpturnedEllipsoidTransverseAzimuthal/unitTest.cpp @@ -585,7 +585,7 @@ int main(int argc, char *argv[]) { cout << "\t\t\t TESTING OTHER METHODS" << endl; cout << border << endl << endl; //|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||| - mapGroup.findKeyword("PolarRadius").setValue(toString(p2a->EquatorialRadius())); + mapGroup.findKeyword("PolarRadius").setValue(Isis::toString(p2a->EquatorialRadius())); TProjection *p9 = (TProjection *) ProjectionFactory::Create(lab); TProjection *s = p1; cout << "Name: " << s->Name().toStdString() << endl; diff --git a/isis/src/base/objs/UserInterface/UserInterface.cpp b/isis/src/base/objs/UserInterface/UserInterface.cpp index 3726f0f887..96db20d9c4 100644 --- a/isis/src/base/objs/UserInterface/UserInterface.cpp +++ b/isis/src/base/objs/UserInterface/UserInterface.cpp @@ -297,7 +297,7 @@ namespace Isis { hist.addGroup( cmdLine.findGroup("UserParameters") ); // See if we have exceeded history length - while( hist.groups() > IString::ToInteger(grp["HistoryLength"][0]) ) { + while( hist.groups() > Isis::toInt(grp["HistoryLength"][0]) ) { hist.deleteGroup("UserParameters"); } diff --git a/isis/src/base/objs/XmlToPvlTranslationManager/XmlToPvlTranslationManager.cpp b/isis/src/base/objs/XmlToPvlTranslationManager/XmlToPvlTranslationManager.cpp index 4fbe80c507..955cb91db7 100644 --- a/isis/src/base/objs/XmlToPvlTranslationManager/XmlToPvlTranslationManager.cpp +++ b/isis/src/base/objs/XmlToPvlTranslationManager/XmlToPvlTranslationManager.cpp @@ -474,7 +474,7 @@ namespace Isis { if ( !m_xmlLabel.setContent(&xmlFile, false, &errmsg, &errline, &errcol) ) { xmlFile.close(); std::string msg = "XML read/parse error in file [" + xmlFileName.expanded() - + "] at line [" + toString(errline) + "], column [" + toString(errcol) + + "] at line [" + Isis::toString(errline) + "], column [" + Isis::toString(errcol) + "], message: " + errmsg.toStdString(); throw IException(IException::Unknown, msg, _FILEINFO_); } diff --git a/isis/src/cassini/apps/ciss2isis/ciss2isis.cpp b/isis/src/cassini/apps/ciss2isis/ciss2isis.cpp index df3dd551b6..e48963b0d8 100644 --- a/isis/src/cassini/apps/ciss2isis/ciss2isis.cpp +++ b/isis/src/cassini/apps/ciss2isis/ciss2isis.cpp @@ -94,7 +94,7 @@ namespace Isis{ //Adjust Table-encoded values from 8 bit back to 12 bit. PvlGroup &inst = outputLabel->findGroup("Instrument", Pvl::Traverse); double biasStripMean = inst.findKeyword("BiasStripMean"); - inst.findKeyword("BiasStripMean").setValue(toString(stretch.Map(biasStripMean))); + inst.findKeyword("BiasStripMean").setValue(Isis::toString(stretch.Map(biasStripMean))); inst.findKeyword("BiasStripMean").addComment("BiasStripMean value converted back to 12 bit."); p.Progress()->SetText("Image was converted using 12-to-8 bit table. \nConverting prefix pixels back to 12 bit and saving line prefix data..."); } @@ -103,7 +103,7 @@ namespace Isis{ if (inputLabel.hasKeyword("VALID_MAXIMUM")) { PvlKeyword labelValidMax = inputLabel.findKeyword("VALID_MAXIMUM"); if (labelValidMax[1] != "UNK") { - validMax = IString::ToInteger(labelValidMax[1]); + validMax = Isis::toInt(labelValidMax[1]); } } @@ -120,7 +120,7 @@ namespace Isis{ int roo = *(header + 50 + vicarLabelBytes) / 32 % 2; //**** THIS MAY NEED TO BE CHANGED, // SEE BOTTOM OF THIS FILE FOR IN DEPTH COMMENTS ON READOUTORDER PvlGroup &inst = ocube->label()->findGroup("Instrument", Pvl::Traverse); - inst.addKeyword(PvlKeyword("ReadoutOrder", toString(roo))); + inst.addKeyword(PvlKeyword("ReadoutOrder", Isis::toString(roo))); p.EndProcess(); // PROCESS 2 : Do 8 bit to 12 bit conversion for image ==============================================// @@ -291,17 +291,17 @@ namespace Isis{ //Add units of measurement to keywords from translation table double exposureDuration = inst.findKeyword("ExposureDuration"); - inst.findKeyword("ExposureDuration").setValue(toString(exposureDuration), "Milliseconds"); + inst.findKeyword("ExposureDuration").setValue(Isis::toString(exposureDuration), "Milliseconds"); int gainModeId = inst.findKeyword("GainModeId"); - inst.findKeyword("GainModeId").setValue(toString(gainModeId), "ElectronsPerDN"); + inst.findKeyword("GainModeId").setValue(Isis::toString(gainModeId), "ElectronsPerDN"); PvlKeyword opticsTemp = inst.findKeyword("OpticsTemperature"); inst.findKeyword("OpticsTemperature").setValue(opticsTemp[0]); inst.findKeyword("OpticsTemperature").addValue(opticsTemp[1], "DegreesCelcius"); double instDataRate = inst.findKeyword("InstrumentDataRate"); - inst.findKeyword("InstrumentDataRate").setValue(toString(instDataRate), "KilobitsPerSecond"); + inst.findKeyword("InstrumentDataRate").setValue(Isis::toString(instDataRate), "KilobitsPerSecond"); // initialize global variables dataConversionType = QString::fromStdString(inst.findKeyword("DataConversionType")); @@ -365,8 +365,8 @@ namespace Isis{ bandBin += PvlKeyword("OriginalBand", "1"); if(foundfilter) { - bandBin += PvlKeyword("Center", toString(center)); - bandBin += PvlKeyword("Width", toString(width)); + bandBin += PvlKeyword("Center", Isis::toString(center)); + bandBin += PvlKeyword("Width", Isis::toString(width)); } else { PvlGroup msgGrp("Warnings"); diff --git a/isis/src/cassini/apps/cisscal/DarkCurrent.cpp b/isis/src/cassini/apps/cisscal/DarkCurrent.cpp index f8e718072c..1eafe60fa4 100644 --- a/isis/src/cassini/apps/cisscal/DarkCurrent.cpp +++ b/isis/src/cassini/apps/cisscal/DarkCurrent.cpp @@ -1063,7 +1063,7 @@ namespace Isis { if (FileName(fileList[i].toStdString()).baseName().substr(0, 3) != instrument.toStdString()){ continue; } - double currentEpoch = IString::ToDouble(FileName(fileList[i].toStdString()).baseName().substr(10, 6)); + double currentEpoch = Isis::toDouble(FileName(fileList[i].toStdString()).baseName().substr(10, 6)); if (abs(currentEpoch - imgTime) < abs(closestEpochFileNum - imgTime)) { // find closest epoch closestEpochFileNum = currentEpoch; p_hotpixfile = FileName(fileList[i].toStdString()); diff --git a/isis/src/cassini/apps/cisscal/main.cpp b/isis/src/cassini/apps/cisscal/main.cpp index 609aa441e2..ec882e692d 100644 --- a/isis/src/cassini/apps/cisscal/main.cpp +++ b/isis/src/cassini/apps/cisscal/main.cpp @@ -647,7 +647,7 @@ void gbl::ComputeBias() { gbl::bias.resize(1); gbl::bias[0] = gbl::cissLab->BiasStripMean(); } - gbl::calgrp += PvlKeyword("NumberOfOverclocks", toString(gbl::numberOfOverclocks)); + gbl::calgrp += PvlKeyword("NumberOfOverclocks", Isis::toString(gbl::numberOfOverclocks)); return; } @@ -884,14 +884,14 @@ void gbl::FindDustRingParameters() { long largestEpochFileNum = 0; QStringList fileList = QDir(gbl::GetCalibrationDirectory("dustring")).entryList(); for(int i = 0; i < fileList.count(); i++){ - long currentEpoch = IString::ToInteger(FileName(fileList[i].toStdString()).baseName().substr(13, 10)); + long currentEpoch = Isis::toInt(FileName(fileList[i].toStdString()).baseName().substr(13, 10)); if (currentEpoch > largestEpochFileNum && currentEpoch <= imgNumber) { largestEpochFileNum = currentEpoch; } } // get name of dust file - gbl::dustFile = (gbl::GetCalibrationDirectory("dustring").toStdString() + "nac_dustring_" + toString(largestEpochFileNum) + gbl::dustFile = (gbl::GetCalibrationDirectory("dustring").toStdString() + "nac_dustring_" + Isis::toString(largestEpochFileNum) + "." + gbl::cissLab->InstrumentModeId().toStdString() + ".cub"); if(!gbl::dustFile.fileExists()) { // dustring file not found, assume file uses old dustring files gbl::dustFile = (gbl::GetCalibrationDirectory("dustring").toStdString() + "nac_dustring_venus." @@ -982,7 +982,7 @@ void gbl::FindDustRingParameters() { } else { effwl = col5.toDouble(); - gbl::calgrp += PvlKeyword("EffectiveWavelength", toString(effwl)); + gbl::calgrp += PvlKeyword("EffectiveWavelength", Isis::toString(effwl)); gbl::strengthFactor = 1.30280 - 0.000717552 * effwl; } break; @@ -1067,7 +1067,7 @@ void gbl::FindDustRingParameters() { } } } - gbl::calgrp += PvlKeyword("StrengthFactor", toString(gbl::strengthFactor)); + gbl::calgrp += PvlKeyword("StrengthFactor", Isis::toString(gbl::strengthFactor)); return; } @@ -1259,7 +1259,7 @@ void gbl::DNtoElectrons() { _FILEINFO_); } } - gbl::calgrp += PvlKeyword("TrueGain", toString(gbl::trueGain)); + gbl::calgrp += PvlKeyword("TrueGain", Isis::toString(gbl::trueGain)); return; } @@ -1364,9 +1364,9 @@ void gbl::DivideByAreaPixel() { // it was expressed in IDL as the following: // [gbl::sumFactor = (gbl::incube->sampleCount()/1024.0)*(gbl::incube->lineCount()/1024.0);] gbl::sumFactor = 1 / pow(gbl::cissLab->SummingMode(), 2.0); - gbl::calgrp += PvlKeyword("SolidAngle", toString(gbl::solidAngle)); - gbl::calgrp += PvlKeyword("OpticsArea", toString(gbl::opticsArea)); - gbl::calgrp += PvlKeyword("SumFactor", toString(gbl::sumFactor)); + gbl::calgrp += PvlKeyword("SolidAngle", Isis::toString(gbl::solidAngle)); + gbl::calgrp += PvlKeyword("OpticsArea", Isis::toString(gbl::opticsArea)); + gbl::calgrp += PvlKeyword("SumFactor", Isis::toString(gbl::sumFactor)); return; } @@ -1605,7 +1605,7 @@ void gbl::FindEfficiencyFactor(QString fluxunits) { "Unable to calibrate image using I/F. Solar Distance calculated is less than or equal to 0.", _FILEINFO_); } - gbl::calgrp += PvlKeyword("SolarDistance", toString(distFromSun)); + gbl::calgrp += PvlKeyword("SolarDistance", Isis::toString(distFromSun)); // read spectral file to find wavelength and flux CisscalFile *spectral = new CisscalFile(QString::fromStdString(specfile.original())); @@ -1673,8 +1673,8 @@ void gbl::FindEfficiencyFactor(QString fluxunits) { spline2.AddData(lambda, fluxproduct2); gbl::efficiencyFactor = spline1.BoolesRule(spline1.DomainMinimum(), spline1.DomainMaximum()); double efficiency = spline2.BoolesRule(spline2.DomainMinimum(), spline2.DomainMaximum()); - gbl::calgrp += PvlKeyword("EfficiencyFactor", toString(gbl::efficiencyFactor), units.toStdString()); - gbl::calgrp += PvlKeyword("TotalEfficiency", toString(efficiency)); + gbl::calgrp += PvlKeyword("EfficiencyFactor", Isis::toString(gbl::efficiencyFactor), units.toStdString()); + gbl::calgrp += PvlKeyword("TotalEfficiency", Isis::toString(efficiency)); // Cannot divide by 0.0 if(gbl::efficiencyFactor == 0) { @@ -1787,7 +1787,7 @@ void gbl::FindCorrectionFactors() { gbl::calgrp.findKeyword("CorrectionFactorPerformed").addComment("Correction Factor Parameters"); } - gbl::calgrp += PvlKeyword("CorrectionFactor", toString(gbl::correctionFactor)); + gbl::calgrp += PvlKeyword("CorrectionFactor", Isis::toString(gbl::correctionFactor)); return; } @@ -1840,7 +1840,7 @@ void gbl::FindSensitivityCorrection() { gbl::calgrp += PvlKeyword("SensitivityCorrectionPerformed", "Yes"); gbl::calgrp.findKeyword("SensitivityCorrectionPerformed").addComment("Sensitivity vs Time Correction Parameters"); gbl::sensCorrection = true; - gbl::calgrp += PvlKeyword("SensVsTimeCorr", toString(gbl::sensVsTimeCorr)); + gbl::calgrp += PvlKeyword("SensVsTimeCorr", Isis::toString(gbl::sensVsTimeCorr)); } diff --git a/isis/src/cassini/apps/vims2isis/main.cpp b/isis/src/cassini/apps/vims2isis/main.cpp index 7e15931880..2b8e285b7f 100644 --- a/isis/src/cassini/apps/vims2isis/main.cpp +++ b/isis/src/cassini/apps/vims2isis/main.cpp @@ -82,7 +82,7 @@ void IsisMain() { Pvl pdsLab(in.expanded()); // It's VIMS, let's figure out if it has the suffix data or not - if(IString::ToInteger(lab.findObject("QUBE")["SUFFIX_ITEMS"][0]) == 0) { + if(Isis::toInt(lab.findObject("QUBE")["SUFFIX_ITEMS"][0]) == 0) { // No suffix data, we can use processimportpds ProcessImportPds p; @@ -339,10 +339,10 @@ void ReadVimsBIL(QString inFileName, const PvlKeyword &suffixItems, QString outF out.SetBasePosition(1, line + 1, band + 1); outCube.write(out); - if(IString::ToInteger(suffixItems[0]) != 0) { + if(Isis::toInt(suffixItems[0]) != 0) { pos = fin.tellg(); - char *sideplaneData = new char[4*IString::ToInteger(suffixItems[0])]; - fin.read(sideplaneData, 4 * IString::ToInteger(suffixItems[0])); + char *sideplaneData = new char[4*Isis::toInt(suffixItems[0])]; + fin.read(sideplaneData, 4 * Isis::toInt(suffixItems[0])); int suffixData = (int)swapper.Int((int *)sideplaneData); record[0] = line + 1; record[1] = band + 1; @@ -382,7 +382,7 @@ void ReadVimsBIL(QString inFileName, const PvlKeyword &suffixItems, QString outF } } // End band loop - int backplaneSize = IString::ToInteger(suffixItems[1]) * (4 * (ns + IString::ToInteger(suffixItems[0]))); + int backplaneSize = Isis::toInt(suffixItems[1]) * (4 * (ns + Isis::toInt(suffixItems[0]))); fin.seekg(backplaneSize, ios_base::cur); // Check the last io @@ -454,7 +454,7 @@ void ProcessBands(Pvl &pdsLab, Cube *vimsCube, VimsType vtype) { PvlGroup bandbin("BandBin"); PvlKeyword originalBand("OriginalBand"); for(int i = vims.mi32OrigBandStart; i <= vims.mi32OrigBinEnd; i++) { - originalBand.addValue(toString(i)); + originalBand.addValue(Isis::toString(i)); } bandbin += originalBand; PvlKeyword center("Center"); @@ -468,7 +468,7 @@ void ProcessBands(Pvl &pdsLab, Cube *vimsCube, VimsType vtype) { //Create the Kernels Group PvlGroup kern("Kernels"); - kern += PvlKeyword("NaifFrameCode", toString(vims.mi32NaifFrameCode)); + kern += PvlKeyword("NaifFrameCode", Isis::toString(vims.mi32NaifFrameCode)); vimsCube->putGroup(kern); } diff --git a/isis/src/cassini/apps/vimscal/main.cpp b/isis/src/cassini/apps/vimscal/main.cpp index cfbfd5aaa4..ba619a0cd8 100644 --- a/isis/src/cassini/apps/vimscal/main.cpp +++ b/isis/src/cassini/apps/vimscal/main.cpp @@ -436,13 +436,13 @@ void loadCalibrationValues() { calVersion = QString::fromStdString(multipliers["version"]); - g_solar = IString::ToDouble(multipliers["solar"][0]); + g_solar = Isis::toDouble(multipliers["solar"][0]); - g_ir = IString::ToDouble(multipliers["IR"][0]); + g_ir = Isis::toDouble(multipliers["IR"][0]); - g_vis = IString::ToDouble(multipliers["VIS"][0]); + g_vis = Isis::toDouble(multipliers["VIS"][0]); - g_wavecal = IString::ToDouble(multipliers["wave-cal"][0]); + g_wavecal = Isis::toDouble(multipliers["wave-cal"][0]); @@ -571,7 +571,7 @@ void calculateSpecificEnergy(Cube *icube) { } if(g_visBool) { - coefficient /= IString::ToDouble(inst["ExposureDuration"][1]) / 1000.0; + coefficient /= Isis::toDouble(inst["ExposureDuration"][1]) / 1000.0; } else { @@ -608,7 +608,7 @@ void calculateSpecificEnergy(Cube *icube) { */ //USGS - coefficient /= (IString::ToDouble(inst["ExposureDuration"][0]) * 1.01725) / 1000.0 - 0.004; + coefficient /= (Isis::toDouble(inst["ExposureDuration"][0]) * 1.01725) / 1000.0 - 0.004; //University of Arizona @@ -773,7 +773,7 @@ void calculateVisDarkCurrent(Cube *icube) { FILE *calFilePtr = fopen(calFile.toLatin1().data(), "r"); - double visExposure = IString::ToDouble(inst["ExposureDuration"][1]); + double visExposure = Isis::toDouble(inst["ExposureDuration"][1]); int sampleOffset, lineOffset; GetOffsets(*icube->label(), sampleOffset, lineOffset); diff --git a/isis/src/cassini/objs/CissLabels/CissLabels.cpp b/isis/src/cassini/objs/CissLabels/CissLabels.cpp index 147789a923..48220e60d9 100644 --- a/isis/src/cassini/objs/CissLabels/CissLabels.cpp +++ b/isis/src/cassini/objs/CissLabels/CissLabels.cpp @@ -83,7 +83,7 @@ namespace Isis { p_shutterModeId = QString::fromStdString( inst["ShutterModeId"]); //valid values: BothSim, NacOnly, WacOnly p_shutterStateId = QString::fromStdString( inst["ShutterStateId"]); //valid values: Enabled or Disabled p_summingMode = (int) inst["SummingMode"]; //valid values: 1, 2, 4 - p_frontOpticsTemp = IString::ToDouble(inst["OpticsTemperature"][0]); //valid values: real numbers + p_frontOpticsTemp = Isis::toDouble(inst["OpticsTemperature"][0]); //valid values: real numbers p_imageTime = QString::fromStdString( inst["ImageTime"]); p_targetName = QString::fromStdString( inst["TargetName"]); //valid values: may change overtime, any subject of a Cassini image // Get values out of the archive group diff --git a/isis/src/cassini/objs/VimsCamera/VimsGroundMap.cpp b/isis/src/cassini/objs/VimsCamera/VimsGroundMap.cpp index bcce00094c..0a1e2f5cb6 100644 --- a/isis/src/cassini/objs/VimsCamera/VimsGroundMap.cpp +++ b/isis/src/cassini/objs/VimsCamera/VimsGroundMap.cpp @@ -130,9 +130,9 @@ namespace Isis { // Because of inaccuracy with the 15 Mhz clock, the IR exposure and // interline delay need to be adjusted. //---------------------------------------------------------------------- - p_irExp = (IString::ToDouble(inst ["ExposureDuration"][0]) * 1.01725) / 1000.; - p_visExp = (IString::ToDouble(inst ["ExposureDuration"][1])) / 1000.; - p_interlineDelay = (IString::ToDouble(inst ["InterlineDelayDuration"]) * 1.01725) / 1000.; + p_irExp = (Isis::toDouble(inst ["ExposureDuration"][0]) * 1.01725) / 1000.; + p_visExp = (Isis::toDouble(inst ["ExposureDuration"][1])) / 1000.; + p_interlineDelay = (Isis::toDouble(inst ["InterlineDelayDuration"]) * 1.01725) / 1000.; // Get summation mode QString sampMode = QString::fromStdString(inst ["SamplingMode"]).toUpper(); diff --git a/isis/src/cassini/objs/VimsCamera/VimsSkyMap.cpp b/isis/src/cassini/objs/VimsCamera/VimsSkyMap.cpp index a4d8179abd..4e1119a145 100644 --- a/isis/src/cassini/objs/VimsCamera/VimsSkyMap.cpp +++ b/isis/src/cassini/objs/VimsCamera/VimsSkyMap.cpp @@ -72,9 +72,9 @@ namespace Isis { // Because of inaccuracy with the 15 Mhz clock, the IR exposure and // interline delay need to be adjusted. //---------------------------------------------------------------------- - p_irExp = (IString::ToDouble(inst ["ExposureDuration"][0]) * 1.01725) / 1000.; - p_visExp = IString::ToDouble(inst ["ExposureDuration"][1]) / 1000.; - p_interlineDelay = (IString::ToDouble(inst ["InterlineDelayDuration"]) * 1.01725) / 1000.; + p_irExp = (Isis::toDouble(inst ["ExposureDuration"][0]) * 1.01725) / 1000.; + p_visExp = Isis::toDouble(inst ["ExposureDuration"][1]) / 1000.; + p_interlineDelay = (Isis::toDouble(inst ["InterlineDelayDuration"]) * 1.01725) / 1000.; // Get summation mode QString sampMode = QString::fromStdString(inst ["SamplingMode"]).toUpper(); diff --git a/isis/src/chandrayaan1/apps/chan1m32isis/chan1m32isis.cpp b/isis/src/chandrayaan1/apps/chan1m32isis/chan1m32isis.cpp index 866b1d8a55..5007a36f57 100644 --- a/isis/src/chandrayaan1/apps/chan1m32isis/chan1m32isis.cpp +++ b/isis/src/chandrayaan1/apps/chan1m32isis/chan1m32isis.cpp @@ -207,11 +207,11 @@ namespace Isis { } else { importPds.StartProcess(writeCubeWithDroppedLines); - g_results += PvlKeyword("LinesFlipped", toString(linesNeedFlipped)); - g_results += PvlKeyword("SamplesFlipped", toString(samplesNeedFlipped)); - g_results += PvlKeyword("LinesAdded", toString(g_totalLinesAdded)); - g_results += PvlKeyword("OutputLines", toString(outputLines)); - g_results += PvlKeyword("CalculatedOutputLines", toString(calcOutputLines)); + g_results += PvlKeyword("LinesFlipped", Isis::toString(linesNeedFlipped)); + g_results += PvlKeyword("SamplesFlipped", Isis::toString(samplesNeedFlipped)); + g_results += PvlKeyword("LinesAdded", Isis::toString(g_totalLinesAdded)); + g_results += PvlKeyword("OutputLines", Isis::toString(outputLines)); + g_results += PvlKeyword("CalculatedOutputLines", Isis::toString(calcOutputLines)); } delete g_oBuff; @@ -423,7 +423,7 @@ namespace Isis { } PvlKeyword originalBand("OriginalBand"); for (int i = 1; i <= numBands; i++) { - originalBand.addValue(toString(i)); + originalBand.addValue(Isis::toString(i)); } bandGroup += originalBand; ocube->putGroup(bandGroup); @@ -433,8 +433,8 @@ namespace Isis { PvlGroup calib("RadiometricCalibration"); PvlKeyword solar = pdsLabel["SOLAR_DISTANCE"]; calib += PvlKeyword("Units", "W/m2/um/sr"); - calib += PvlKeyword("SolarDistance", toString((double)solar), solar.unit()); - calib += PvlKeyword("DetectorTemperature", toString((double)pdsLabel["DETECTOR_TEMPERATURE"])); + calib += PvlKeyword("SolarDistance", Isis::toString((double)solar), solar.unit()); + calib += PvlKeyword("DetectorTemperature", Isis::toString((double)pdsLabel["DETECTOR_TEMPERATURE"])); calib += PvlKeyword("SpectralCalibrationFileName", pdsLabel["CH1:SPECTRAL_CALIBRATION_FILE_NAME"]); calib += PvlKeyword("RadGainFactorFileName", diff --git a/isis/src/clementine/apps/clem2isis/main.cpp b/isis/src/clementine/apps/clem2isis/main.cpp index 526b07910c..b24facab8b 100755 --- a/isis/src/clementine/apps/clem2isis/main.cpp +++ b/isis/src/clementine/apps/clem2isis/main.cpp @@ -143,11 +143,11 @@ void translateLabels(FileName in, Cube *ocube) { //Band Bin group double center = pdsLab["CenterFilterWavelength"]; center /= 1000.0; - bBin.findKeyword("Center").setValue(toString(center), "micrometers"); + bBin.findKeyword("Center").setValue(Isis::toString(center), "micrometers"); } double width = pdsLab["Bandwidth"]; width /= 1000.0; - bBin.findKeyword("Width").setValue(toString(width), "micrometers"); + bBin.findKeyword("Width").setValue(Isis::toString(width), "micrometers"); ocube->putGroup(bBin); //Kernel group diff --git a/isis/src/clementine/apps/clemnircal/main.cpp b/isis/src/clementine/apps/clemnircal/main.cpp index 48f57372d9..2303cca88e 100644 --- a/isis/src/clementine/apps/clemnircal/main.cpp +++ b/isis/src/clementine/apps/clemnircal/main.cpp @@ -129,7 +129,7 @@ void IsisMain() { if(!gainFactorData.hasGroup(group.toStdString())) { std::string err = "The Gain Factor for Gain Mode ID ["; - err += toString(gainModeID); + err += Isis::toString(gainModeID); err += "] could not be found in clemnircal.def"; throw IException(IException::Programmer, err, _FILEINFO_); } @@ -138,7 +138,7 @@ void IsisMain() { if(abs(gainFactor) < DBL_EPSILON) { std::string err = "The Gain Factor for Gain Mode ID ["; - err += toString(gainModeID); + err += Isis::toString(gainModeID); err += "] can not be zero."; throw IException(IException::Programmer, err, _FILEINFO_); } @@ -250,15 +250,15 @@ void IsisMain() { calgrp += PvlKeyword("ThermalCorrectionTable", thermTbl.toStdString()); calgrp += PvlKeyword("AdditiveFileTable", afFileTableLoc.toStdString()); - calgrp += PvlKeyword("DigitalOffset", toString(digitalOffset)); - calgrp += PvlKeyword("GlobalBias", toString(globalBias)); - calgrp += PvlKeyword("GlobalDarkCoefficient", toString(globalDarkCoefficient)); - calgrp += PvlKeyword("V", toString(vConstant)); + calgrp += PvlKeyword("DigitalOffset", Isis::toString(digitalOffset)); + calgrp += PvlKeyword("GlobalBias", Isis::toString(globalBias)); + calgrp += PvlKeyword("GlobalDarkCoefficient", Isis::toString(globalDarkCoefficient)); + calgrp += PvlKeyword("V", Isis::toString(vConstant)); //Calculated in processing routine - calgrp += PvlKeyword("GainFactor", toString(gainFactor)); - calgrp += PvlKeyword("AbsoluteCoefficient", toString(absoluteCoefficient)); - calgrp += PvlKeyword("CryoNorm", toString(cryonorm)); - calgrp += PvlKeyword("OptimalExposureDuration", toString(optimalExposureDuration)); + calgrp += PvlKeyword("GainFactor", Isis::toString(gainFactor)); + calgrp += PvlKeyword("AbsoluteCoefficient", Isis::toString(absoluteCoefficient)); + calgrp += PvlKeyword("CryoNorm", Isis::toString(cryonorm)); + calgrp += PvlKeyword("OptimalExposureDuration", Isis::toString(optimalExposureDuration)); ocube->putGroup(calgrp); p.EndProcess(); diff --git a/isis/src/clementine/apps/clemuvviscal/main.cpp b/isis/src/clementine/apps/clemuvviscal/main.cpp index 4c4cc3bc6d..3ea8c72bfa 100644 --- a/isis/src/clementine/apps/clemuvviscal/main.cpp +++ b/isis/src/clementine/apps/clemuvviscal/main.cpp @@ -175,25 +175,25 @@ void IsisMain() { calgrp += PvlKeyword("DarkCurrentFile", dccube->fileName().toStdString()); } else { - calgrp += PvlKeyword("DarkCurrentConstant", toString(dcconst)); + calgrp += PvlKeyword("DarkCurrentConstant", Isis::toString(dcconst)); } - calgrp += PvlKeyword("CorrectedFocalPlaneTemp", toString(focalPlaneTemp)); - calgrp += PvlKeyword("C1", toString(avgFF)); - calgrp += PvlKeyword("C2", toString(C2)); - calgrp += PvlKeyword("C3", toString(C3)); - calgrp += PvlKeyword("C4", toString(C4)); - calgrp += PvlKeyword("C5", toString(C5)); - calgrp += PvlKeyword("CR", toString(cr)); - calgrp += PvlKeyword("FrameTransferTimePerRow", toString(cr)); - calgrp += PvlKeyword("Gain", toString(gain)); - calgrp += PvlKeyword("CorrectedExposureDuration", toString(correctedExposureDuration)); - calgrp += PvlKeyword("ConvertToRadiance", toString(conv)); - - calgrp += PvlKeyword("ACO", toString(ACO)); - calgrp += PvlKeyword("BCO", toString(BCO)); - calgrp += PvlKeyword("CCO", toString(CCO)); - calgrp += PvlKeyword("DCO", toString(DCO)); + calgrp += PvlKeyword("CorrectedFocalPlaneTemp", Isis::toString(focalPlaneTemp)); + calgrp += PvlKeyword("C1", Isis::toString(avgFF)); + calgrp += PvlKeyword("C2", Isis::toString(C2)); + calgrp += PvlKeyword("C3", Isis::toString(C3)); + calgrp += PvlKeyword("C4", Isis::toString(C4)); + calgrp += PvlKeyword("C5", Isis::toString(C5)); + calgrp += PvlKeyword("CR", Isis::toString(cr)); + calgrp += PvlKeyword("FrameTransferTimePerRow", Isis::toString(cr)); + calgrp += PvlKeyword("Gain", Isis::toString(gain)); + calgrp += PvlKeyword("CorrectedExposureDuration", Isis::toString(correctedExposureDuration)); + calgrp += PvlKeyword("ConvertToRadiance", Isis::toString(conv)); + + calgrp += PvlKeyword("ACO", Isis::toString(ACO)); + calgrp += PvlKeyword("BCO", Isis::toString(BCO)); + calgrp += PvlKeyword("CCO", Isis::toString(CCO)); + calgrp += PvlKeyword("DCO", Isis::toString(DCO)); ocube->putGroup(calgrp); p.EndProcess(); diff --git a/isis/src/clipper/apps/eis2isis/eis2isis.cpp b/isis/src/clipper/apps/eis2isis/eis2isis.cpp index 324c724747..143c099afc 100644 --- a/isis/src/clipper/apps/eis2isis/eis2isis.cpp +++ b/isis/src/clipper/apps/eis2isis/eis2isis.cpp @@ -97,10 +97,10 @@ namespace Isis { if (instrumentNameString == "EIS-NAC-RS") { // This ID will need to be updated. It is temporarily used for testing but is NOT the actual // NAC ID. - kerns += PvlKeyword("NaifFrameCode", toString(-159101)); + kerns += PvlKeyword("NaifFrameCode", Isis::toString(-159101)); } else if (instrumentNameString == "EIS-WAC-FC") { - kerns += PvlKeyword("NaifFrameCode", toString(-159102)); + kerns += PvlKeyword("NaifFrameCode", Isis::toString(-159102)); } else { std::string msg = "Input file [" + xmlFileName.expanded() + "] has an invalid " + @@ -229,14 +229,14 @@ namespace Isis { // Set a default value for the JitterSampleCoefficients and the JitterLineCoefficient keywords in the Instrument group. // These values are overwritten with a call to the jitterfit application. - PvlKeyword jitterLineCoefficients = PvlKeyword("JitterLineCoefficients", (toString(0.0))); - jitterLineCoefficients += toString(0.0); - jitterLineCoefficients += toString(0.0); + PvlKeyword jitterLineCoefficients = PvlKeyword("JitterLineCoefficients", (Isis::toString(0.0))); + jitterLineCoefficients += Isis::toString(0.0); + jitterLineCoefficients += Isis::toString(0.0); outputLabel->findGroup("Instrument", PvlObject::Traverse).addKeyword(jitterLineCoefficients); - PvlKeyword jitterSampleCoefficients = PvlKeyword("JitterSampleCoefficients", (toString(0.0))); - jitterSampleCoefficients += toString(0.0); - jitterSampleCoefficients += toString(0.0); + PvlKeyword jitterSampleCoefficients = PvlKeyword("JitterSampleCoefficients", (Isis::toString(0.0))); + jitterSampleCoefficients += Isis::toString(0.0); + jitterSampleCoefficients += Isis::toString(0.0); outputLabel->findGroup("Instrument", PvlObject::Traverse).addKeyword(jitterSampleCoefficients); diff --git a/isis/src/clipper/apps/jitterfit/jitterfit.cpp b/isis/src/clipper/apps/jitterfit/jitterfit.cpp index d8e9b49502..a4abd24342 100644 --- a/isis/src/clipper/apps/jitterfit/jitterfit.cpp +++ b/isis/src/clipper/apps/jitterfit/jitterfit.cpp @@ -182,12 +182,12 @@ namespace Isis{ outputCoefficientFile << std::setprecision(14) << lineFunction->Coefficient(i) << "," << std::setprecision(14) << sampleFunction->Coefficient(i) << endl; if (i == 0) { - jitterLineCoefficients.setValue(toString(lineFunction->Coefficient(i))); - jitterSampleCoefficients.setValue(toString(sampleFunction->Coefficient(i))); + jitterLineCoefficients.setValue(Isis::toString(lineFunction->Coefficient(i))); + jitterSampleCoefficients.setValue(Isis::toString(sampleFunction->Coefficient(i))); } else { - jitterLineCoefficients += toString(lineFunction->Coefficient(i)); - jitterSampleCoefficients += toString(sampleFunction->Coefficient(i)); + jitterLineCoefficients += Isis::toString(lineFunction->Coefficient(i)); + jitterSampleCoefficients += Isis::toString(sampleFunction->Coefficient(i)); } } diff --git a/isis/src/clipper/objs/ClipperNacRollingShutterCamera/ClipperNacRollingShutterCamera.cpp b/isis/src/clipper/objs/ClipperNacRollingShutterCamera/ClipperNacRollingShutterCamera.cpp index df3248062c..c4725e09d6 100644 --- a/isis/src/clipper/objs/ClipperNacRollingShutterCamera/ClipperNacRollingShutterCamera.cpp +++ b/isis/src/clipper/objs/ClipperNacRollingShutterCamera/ClipperNacRollingShutterCamera.cpp @@ -67,12 +67,12 @@ namespace Isis { && cube.hasTable("Normalized Main Readout Line Times")) { PvlKeyword sampleCoefficients = inst.findKeyword("JitterSampleCoefficients"); for (int i = 0; i < sampleCoefficients.size(); i++) { - sampleCoeffs.push_back(IString::ToDouble(sampleCoefficients[i])); + sampleCoeffs.push_back(Isis::toDouble(sampleCoefficients[i])); } PvlKeyword lineCoefficients = inst.findKeyword("JitterLineCoefficients"); for (int i = 0; i < lineCoefficients.size(); i++) { - lineCoeffs.push_back(IString::ToDouble(lineCoefficients[i])); + lineCoeffs.push_back(Isis::toDouble(lineCoefficients[i])); } Table normalizedReadoutTimes("Normalized Main Readout Line Times", lab.fileName(), lab); diff --git a/isis/src/clipper/objs/ClipperPushBroomCamera/ClipperPushBroomCamera.cpp b/isis/src/clipper/objs/ClipperPushBroomCamera/ClipperPushBroomCamera.cpp index 70512021b4..7f14a5597c 100644 --- a/isis/src/clipper/objs/ClipperPushBroomCamera/ClipperPushBroomCamera.cpp +++ b/isis/src/clipper/objs/ClipperPushBroomCamera/ClipperPushBroomCamera.cpp @@ -38,7 +38,7 @@ namespace Isis { } else { std::string msg = "Unable to construct Clipper Push Broom camera model. " - "Unrecognized NaifFrameCode [" + toString(frameCode) + "]."; + "Unrecognized NaifFrameCode [" + Isis::toString(frameCode) + "]."; throw IException(IException::User, msg, _FILEINFO_); } diff --git a/isis/src/control/apps/autoseed/autoseed.cpp b/isis/src/control/apps/autoseed/autoseed.cpp index 87b5f30a12..75844262ba 100644 --- a/isis/src/control/apps/autoseed/autoseed.cpp +++ b/isis/src/control/apps/autoseed/autoseed.cpp @@ -484,8 +484,8 @@ namespace Isis { // create SeedDef group and add to print.prt PvlGroup pluginInfo = seeder->PluginParameters("SeedDefinition"); - pluginInfo.addKeyword(PvlKeyword("MaxIncidence", toString(maxIncidence))); - pluginInfo.addKeyword(PvlKeyword("MaxEmission", toString(maxEmission))); + pluginInfo.addKeyword(PvlKeyword("MaxIncidence", Isis::toString(maxIncidence))); + pluginInfo.addKeyword(PvlKeyword("MaxEmission", Isis::toString(maxEmission))); Application::Log(pluginInfo); // inform user of any unused (invalid) keywords found in the def file @@ -503,10 +503,10 @@ namespace Isis { } // create Results group and add to print.prt - PvlKeyword cpCountKeyword("ControlPointCount", toString(cpCount)); - PvlKeyword msCountKeyword("ControlMeasureCount", toString(msCount)); - PvlKeyword cpIgnoredCountKeyword("ControlPointsIgnored", toString(cpIgnoredCount)); - PvlKeyword cmIgnoredCountKeyword("ControlMeasuresIgnored", toString(cmIgnoredCount)); + PvlKeyword cpCountKeyword("ControlPointCount", Isis::toString(cpCount)); + PvlKeyword msCountKeyword("ControlMeasureCount", Isis::toString(msCount)); + PvlKeyword cpIgnoredCountKeyword("ControlPointsIgnored", Isis::toString(cpIgnoredCount)); + PvlKeyword cmIgnoredCountKeyword("ControlMeasuresIgnored", Isis::toString(cmIgnoredCount)); PvlGroup resultsGrp("Results"); resultsGrp.addKeyword(cpCountKeyword); diff --git a/isis/src/control/apps/cnet2dem/main.cpp b/isis/src/control/apps/cnet2dem/main.cpp index b6c3e2426a..5f49245639 100644 --- a/isis/src/control/apps/cnet2dem/main.cpp +++ b/isis/src/control/apps/cnet2dem/main.cpp @@ -381,7 +381,7 @@ void IsisMain() { PvlKeyword cnumber("Number"); for (int i = 0 ; i < functors.size() ; i++) { fname.addValue(functors[i]->name().toStdString()); - cnumber.addValue(toString(i+1)); + cnumber.addValue(Isis::toString(i+1)); } // Create the BandBin group diff --git a/isis/src/control/apps/cnetcheck/cnetcheck.cpp b/isis/src/control/apps/cnetcheck/cnetcheck.cpp index e5f73efd4e..52e71ca243 100644 --- a/isis/src/control/apps/cnetcheck/cnetcheck.cpp +++ b/isis/src/control/apps/cnetcheck/cnetcheck.cpp @@ -232,7 +232,7 @@ namespace Isis { // Islands that have no cubes listed in the input list will // not be shown. for (int i = 0; i < (int)islands.size(); i++) { - QString name(QString::fromStdString(FileName(prefix.toStdString() + "Island." + toString(i + 1)).expanded())); + QString name(QString::fromStdString(FileName(prefix.toStdString() + "Island." + Isis::toString(i + 1)).expanded())); ofstream out_stream; out_stream.open(name.toLatin1().data(), std::ios::out); out_stream.seekp(0, std::ios::beg); //Start writing from beginning of file @@ -262,7 +262,7 @@ namespace Isis { stringstream ss(stringstream::in | stringstream::out); - results.addKeyword(PvlKeyword("Islands", toString((BigInt)islands.size()))); + results.addKeyword(PvlKeyword("Islands", Isis::toString((BigInt)islands.size()))); ss << endl << "----------------------------------------" \ "----------------------------------------" << endl; if (islands.size() == 1) { @@ -279,7 +279,7 @@ namespace Isis { if (ui.GetBoolean("SINGLEMEASURE") && singleMeasureSerialNumbers.size() > 0) { results.addKeyword( - PvlKeyword("SingleMeasure", toString((BigInt)singleMeasureSerialNumbers.size()))); + PvlKeyword("SingleMeasure", Isis::toString((BigInt)singleMeasureSerialNumbers.size()))); std::string name(FileName(prefix.toStdString() + "SinglePointCubes.txt").expanded()); writeOutput(num2cube, QString::fromStdString(name), @@ -297,7 +297,7 @@ namespace Isis { if (ui.GetBoolean("NOLATLON") && noLatLonSerialNumbers.size() > 0) { results.addKeyword( - PvlKeyword("NoLatLonCubes", toString((BigInt)noLatLonSerialNumbers.size()))); + PvlKeyword("NoLatLonCubes", Isis::toString((BigInt)noLatLonSerialNumbers.size()))); std::string name(FileName(prefix.toStdString() + "NoLatLon.txt").expanded()); writeOutput(num2cube, QString::fromStdString(name), @@ -352,14 +352,14 @@ namespace Isis { "coverages, are listed in [" << FileName(name).name() << "]" << endl; results.addKeyword( - PvlKeyword(coverageOp.toStdString(), toString((BigInt) failedCoverageCheck))); + PvlKeyword(coverageOp.toStdString(), Isis::toString((BigInt) failedCoverageCheck))); } } // At this point, inListNums is the list of cubes NOT included in the // ControlNet, and inListNums are their those cube's serial numbers. if (ui.GetBoolean("NOCONTROL") && !inListNums.empty()) { - results.addKeyword(PvlKeyword("NoControl", toString((BigInt)inListNums.size()))); + results.addKeyword(PvlKeyword("NoControl", Isis::toString((BigInt)inListNums.size()))); QString name(QString::fromStdString(FileName(prefix.toStdString() + "NoControl.txt").expanded())); ofstream out_stream; @@ -387,7 +387,7 @@ namespace Isis { // cube in the input list. if (ui.GetBoolean("NOCUBE") && nonListedSerialNumbers.size() > 0) { results.addKeyword( - PvlKeyword("NoCube", toString((BigInt)nonListedSerialNumbers.size()))); + PvlKeyword("NoCube", Isis::toString((BigInt)nonListedSerialNumbers.size()))); QString name(QString::fromStdString(FileName(prefix.toStdString() + "NoCube.txt").expanded())); ofstream out_stream; @@ -428,7 +428,7 @@ namespace Isis { if (singleMeasureCubes.size() > 0) { results.addKeyword( - PvlKeyword("SingleCube", toString((BigInt)singleMeasureCubes.size()))); + PvlKeyword("SingleCube", Isis::toString((BigInt)singleMeasureCubes.size()))); std::string name(FileName(prefix.toStdString() + "SingleCube.txt").expanded()); ofstream out_stream; diff --git a/isis/src/control/apps/cnetcombinept/cnetcombinept.cpp b/isis/src/control/apps/cnetcombinept/cnetcombinept.cpp index f33dd9a3e5..7cd51b470c 100644 --- a/isis/src/control/apps/cnetcombinept/cnetcombinept.cpp +++ b/isis/src/control/apps/cnetcombinept/cnetcombinept.cpp @@ -489,15 +489,15 @@ namespace Isis{ // Write out a report int pMerged = validPoints - vPoints; PvlGroup summary("Summary"); - summary += PvlKeyword("TotalCubes", toString(cube_measures_size)); - summary += PvlKeyword("TotalInputPoints", toString(all_points.size())); - summary += PvlKeyword("TotalOutputPoints", toString(oPoints)); - summary += PvlKeyword("PointsMerged", toString(pMerged)); - summary += PvlKeyword("PointsEvaluated", toString(nfound)); - summary += PvlKeyword("TotalMeasures", toString(allPoints)); - summary += PvlKeyword("MeasuresMerged", toString(nMerged)); - summary += PvlKeyword("MeasuresDeleted", toString(nRemoved)); - summary += PvlKeyword("MinimumMeasures", toString(nMinMeasures)); + summary += PvlKeyword("TotalCubes", Isis::toString(cube_measures_size)); + summary += PvlKeyword("TotalInputPoints", Isis::toString(all_points.size())); + summary += PvlKeyword("TotalOutputPoints", Isis::toString(oPoints)); + summary += PvlKeyword("PointsMerged", Isis::toString(pMerged)); + summary += PvlKeyword("PointsEvaluated", Isis::toString(nfound)); + summary += PvlKeyword("TotalMeasures", Isis::toString(allPoints)); + summary += PvlKeyword("MeasuresMerged", Isis::toString(nMerged)); + summary += PvlKeyword("MeasuresDeleted", Isis::toString(nRemoved)); + summary += PvlKeyword("MinimumMeasures", Isis::toString(nMinMeasures)); Application::Log(summary); pbl.EndProcess(); diff --git a/isis/src/control/apps/cnetdiff/cnetdiff.cpp b/isis/src/control/apps/cnetdiff/cnetdiff.cpp index 7da5948e56..95a0a4dd5a 100644 --- a/isis/src/control/apps/cnetdiff/cnetdiff.cpp +++ b/isis/src/control/apps/cnetdiff/cnetdiff.cpp @@ -347,7 +347,7 @@ namespace Isis { double difference = abs(val1.toDouble() - val2.toDouble()); if (tolerances.hasKeyword(pvl1.name())) { - tolerance = IString::ToDouble((tolerances[pvl1.name()].size() == 1) ? + tolerance = Isis::toDouble((tolerances[pvl1.name()].size() == 1) ? tolerances[pvl1.name()][0] : tolerances[pvl1.name()][i]); } diff --git a/isis/src/control/apps/cnetedit/cnetedit.cpp b/isis/src/control/apps/cnetedit/cnetedit.cpp index 655fb52673..563ce11308 100644 --- a/isis/src/control/apps/cnetedit/cnetedit.cpp +++ b/isis/src/control/apps/cnetedit/cnetedit.cpp @@ -140,7 +140,7 @@ namespace Isis { QString line = in.readLine(); QStringList results = line.split(","); if (results.size() < 2) { - std::string msg = "Line " + toString(lineNumber) + " in the MEASURELIST does " + std::string msg = "Line " + Isis::toString(lineNumber) + " in the MEASURELIST does " "not contain a Point ID and a cube filename separated by a comma"; throw IException(IException::User, msg, _FILEINFO_); } @@ -369,8 +369,8 @@ namespace Isis { if (keepLog) { Pvl outputLog; - outputLog.addKeyword(PvlKeyword("PointsDeleted", toString(numPointsDeleted))); - outputLog.addKeyword(PvlKeyword("MeasuresDeleted", toString(numMeasuresDeleted))); + outputLog.addKeyword(PvlKeyword("PointsDeleted", Isis::toString(numPointsDeleted))); + outputLog.addKeyword(PvlKeyword("MeasuresDeleted", Isis::toString(numMeasuresDeleted))); PvlObject lockedLog = createLog( "EditLocked", editLockedPoints, editLockedMeasures); diff --git a/isis/src/control/apps/cnetextract/cnetextract.cpp b/isis/src/control/apps/cnetextract/cnetextract.cpp index c965dcb74e..41366ba29a 100644 --- a/isis/src/control/apps/cnetextract/cnetextract.cpp +++ b/isis/src/control/apps/cnetextract/cnetextract.cpp @@ -322,10 +322,10 @@ namespace Isis { PvlGroup summary("ResultSummary"); PvlGroup results("Results"); - summary.addKeyword(PvlKeyword("InputPoints", toString(inputPoints))); - summary.addKeyword(PvlKeyword("InputMeasures", toString(inputMeasures))); - summary.addKeyword(PvlKeyword("OutputPoints", toString(outputPoints))); - summary.addKeyword(PvlKeyword("OutputMeasures", toString(outputMeasures))); + summary.addKeyword(PvlKeyword("InputPoints", Isis::toString(inputPoints))); + summary.addKeyword(PvlKeyword("InputMeasures", Isis::toString(inputMeasures))); + summary.addKeyword(PvlKeyword("OutputPoints", Isis::toString(outputPoints))); + summary.addKeyword(PvlKeyword("OutputMeasures", Isis::toString(outputMeasures))); if (outputPoints != 0) { // Write the filenames associated with outNet @@ -357,43 +357,43 @@ namespace Isis { if(noIgnore) { - summary.addKeyword(PvlKeyword("IgnoredPoints", toString((int)ignoredPoints.size()))); - summary.addKeyword(PvlKeyword("IgnoredMeasures", toString((int)ignoredMeasures.size()))); + summary.addKeyword(PvlKeyword("IgnoredPoints", Isis::toString((int)ignoredPoints.size()))); + summary.addKeyword(PvlKeyword("IgnoredMeasures", Isis::toString((int)ignoredMeasures.size()))); } if(noSingleMeasure) { - summary.addKeyword(PvlKeyword("SingleMeasurePoints", toString((int)singleMeasurePoints.size()))); + summary.addKeyword(PvlKeyword("SingleMeasurePoints", Isis::toString((int)singleMeasurePoints.size()))); } if(noMeasureless) { - summary.addKeyword(PvlKeyword("MeasurelessPoints", toString((int)measurelessPoints.size()))); + summary.addKeyword(PvlKeyword("MeasurelessPoints", Isis::toString((int)measurelessPoints.size()))); } if(noTolerancePoints) { - summary.addKeyword(PvlKeyword("TolerancePoints", toString((int)tolerancePoints.size()))); + summary.addKeyword(PvlKeyword("TolerancePoints", Isis::toString((int)tolerancePoints.size()))); } if(reference) { - summary.addKeyword(PvlKeyword("NonReferenceMeasures", toString((int)nonReferenceMeasures.size()))); + summary.addKeyword(PvlKeyword("NonReferenceMeasures", Isis::toString((int)nonReferenceMeasures.size()))); } if(fixed) { - summary.addKeyword(PvlKeyword("NonFixedPoints", toString((int)nonFixedPoints.size()))); + summary.addKeyword(PvlKeyword("NonFixedPoints", Isis::toString((int)nonFixedPoints.size()))); } if(cubePoints) { - summary.addKeyword(PvlKeyword("NonCubePoints", toString((int)nonCubePoints.size()))); + summary.addKeyword(PvlKeyword("NonCubePoints", Isis::toString((int)nonCubePoints.size()))); } // This is commented out since this does not correspond to any filters or the // documentation of this application. I did not delete the code in case we find // that we need it later. J.Backer 2012-06-22 // // if(noMeasurePoints.size() != 0) { - // summary.addKeyword(PvlKeyword("NoCubeMeasure", toString((int)noMeasurePoints.size()))); + // summary.addKeyword(PvlKeyword("NoCubeMeasure", Isis::toString((int)noMeasurePoints.size()))); // } if(cubeMeasures) { - summary.addKeyword(PvlKeyword("NonCubeMeasures", toString((int)noCubeMeasures.size()))); + summary.addKeyword(PvlKeyword("NonCubeMeasures", Isis::toString((int)noCubeMeasures.size()))); } if(pointsEntered) { - summary.addKeyword(PvlKeyword("NonListedPoints", toString((int)nonListedPoints.size()))); + summary.addKeyword(PvlKeyword("NonListedPoints", Isis::toString((int)nonListedPoints.size()))); } if(latLon) { - summary.addKeyword(PvlKeyword("LatLonOutOfRange", toString((int)nonLatLonPoints.size()))); - summary.addKeyword(PvlKeyword("NoLatLonPoints", toString((int)cannotGenerateLatLonPoints.size()))); + summary.addKeyword(PvlKeyword("LatLonOutOfRange", Isis::toString((int)nonLatLonPoints.size()))); + summary.addKeyword(PvlKeyword("NoLatLonPoints", Isis::toString((int)cannotGenerateLatLonPoints.size()))); } outProgress.CheckStatus(); diff --git a/isis/src/control/apps/cnetnewradii/main.cpp b/isis/src/control/apps/cnetnewradii/main.cpp index bb3efa5a29..5376a601ad 100644 --- a/isis/src/control/apps/cnetnewradii/main.cpp +++ b/isis/src/control/apps/cnetnewradii/main.cpp @@ -161,11 +161,11 @@ void IsisMain() { // Write results to Logs // Summary group is created with the counts of successes and failures PvlGroup summaryGroup = PvlGroup("Summary"); - summaryGroup.addKeyword(PvlKeyword("Successes", toString(numSuccesses))); - summaryGroup.addKeyword(PvlKeyword("Failures", toString(numFailures))); + summaryGroup.addKeyword(PvlKeyword("Successes", Isis::toString(numSuccesses))); + summaryGroup.addKeyword(PvlKeyword("Failures", Isis::toString(numFailures))); summaryGroup.addKeyword(PvlKeyword("NumberFixedConstrainedPoints", - toString(numConstrainedFixed))); - summaryGroup.addKeyword(PvlKeyword("NumberEditLockedPoints", toString(numLocked))); + Isis::toString(numConstrainedFixed))); + summaryGroup.addKeyword(PvlKeyword("NumberEditLockedPoints", Isis::toString(numLocked))); bool errorlog; FileName errorlogFile; diff --git a/isis/src/control/apps/cnetref/CnetRefByEmission.cpp b/isis/src/control/apps/cnetref/CnetRefByEmission.cpp index 71f263748e..f2bfe7c2ba 100644 --- a/isis/src/control/apps/cnetref/CnetRefByEmission.cpp +++ b/isis/src/control/apps/cnetref/CnetRefByEmission.cpp @@ -197,24 +197,24 @@ namespace Isis { int iComment = 0; if (numMeasures == 0) { std::string sComment = "Comment"; - sComment += toString(++iComment); + sComment += Isis::toString(++iComment); pvlPointObj += Isis::PvlKeyword(sComment, "No Measures in the Point"); } if (newPnt->IsIgnored()) { std::string sComment = "Comment"; - sComment += toString(++iComment); + sComment += Isis::toString(++iComment); pvlPointObj += Isis::PvlKeyword(sComment, "Point was originally Ignored"); } if (origPnt.GetType() == ControlPoint::Fixed) { std::string sComment = "Comment"; - sComment += toString(++iComment); + sComment += Isis::toString(++iComment); pvlPointObj += Isis::PvlKeyword(sComment, "Fixed Point"); } else if (newPnt->GetType() == ControlPoint::Constrained) { std::string sComment = "Comment"; - sComment += toString(++iComment); + sComment += Isis::toString(++iComment); pvlPointObj += Isis::PvlKeyword(sComment, "Constrained Point"); } @@ -246,7 +246,7 @@ namespace Isis { pvlRefChangeGrp += Isis::PvlKeyword("PrevSerialNumber", origPnt.GetReferenceSN().toStdString()); pvlRefChangeGrp += Isis::PvlKeyword("PrevEmAngle", - toString(bestEmissionAngle[iRefIndex])); + Isis::toString(bestEmissionAngle[iRefIndex])); istrTemp = QString::number((int)origPnt.GetMeasure(iRefIndex)->GetSample()); istrTemp += ","; @@ -260,7 +260,7 @@ namespace Isis { pvlRefChangeGrp += Isis::PvlKeyword("NewSerialNumber", newPnt->GetMeasure(iBestIndex)->GetCubeSerialNumber().toStdString()); pvlRefChangeGrp += Isis::PvlKeyword("NewLeastEmAngle", - toString(bestEmissionAngle[iBestIndex])); + Isis::toString(bestEmissionAngle[iBestIndex])); istrTemp = QString::number((int)newPnt->GetMeasure(iBestIndex)->GetSample()); istrTemp += ","; @@ -278,9 +278,9 @@ namespace Isis { }// end Point // CnetRef Change Statistics - mStatisticsGrp += Isis::PvlKeyword("PointsModified", toString(iPointsModified)); - mStatisticsGrp += Isis::PvlKeyword("ReferenceChanged", toString(iRefChanged)); - mStatisticsGrp += Isis::PvlKeyword("MeasuresModified", toString(iMeasuresModified)); + mStatisticsGrp += Isis::PvlKeyword("PointsModified", Isis::toString(iPointsModified)); + mStatisticsGrp += Isis::PvlKeyword("ReferenceChanged", Isis::toString(iRefChanged)); + mStatisticsGrp += Isis::PvlKeyword("MeasuresModified", Isis::toString(iMeasuresModified)); mPvlLog += mStatisticsGrp; } diff --git a/isis/src/control/apps/cnetref/CnetRefByIncidence.cpp b/isis/src/control/apps/cnetref/CnetRefByIncidence.cpp index ed0a5e7f45..1eb3339f08 100644 --- a/isis/src/control/apps/cnetref/CnetRefByIncidence.cpp +++ b/isis/src/control/apps/cnetref/CnetRefByIncidence.cpp @@ -194,24 +194,24 @@ namespace Isis { int iComment = 0; if (numMeasures == 0) { std::string sComment = "Comment"; - sComment += toString(++iComment); + sComment += Isis::toString(++iComment); pvlPointObj += Isis::PvlKeyword(sComment, "No Measures in the Point"); } if (newPnt->IsIgnored()) { std::string sComment = "Comment"; - sComment += toString(++iComment); + sComment += Isis::toString(++iComment); pvlPointObj += Isis::PvlKeyword(sComment, "Point was originally Ignored"); } if (origPnt.GetType() == ControlPoint::Fixed) { std::string sComment = "Comment"; - sComment += toString(++iComment); + sComment += Isis::toString(++iComment); pvlPointObj += Isis::PvlKeyword(sComment, "Fixed Point"); } else if (newPnt->GetType() == ControlPoint::Constrained) { std::string sComment = "Comment"; - sComment += toString(++iComment); + sComment += Isis::toString(++iComment); pvlPointObj += Isis::PvlKeyword(sComment, "Constrained Point"); } @@ -241,7 +241,7 @@ namespace Isis { if (iRefIndex >= 0) { pvlRefChangeGrp += Isis::PvlKeyword("PrevSerialNumber", origPnt.GetMeasure(iRefIndex)->GetCubeSerialNumber().toStdString()); - pvlRefChangeGrp += Isis::PvlKeyword("PrevIncAngle", toString(bestIncidenceAngle[iRefIndex])); + pvlRefChangeGrp += Isis::PvlKeyword("PrevIncAngle", Isis::toString(bestIncidenceAngle[iRefIndex])); istrTemp = QString::number((int)origPnt.GetMeasure(iRefIndex)->GetSample()); istrTemp += ","; @@ -254,7 +254,7 @@ namespace Isis { pvlRefChangeGrp += Isis::PvlKeyword("NewSerialNumber", newPnt->GetMeasure(iBestIndex)->GetCubeSerialNumber().toStdString()); - pvlRefChangeGrp += Isis::PvlKeyword("NewLeastIncAngle", toString(bestIncidenceAngle[iBestIndex])); + pvlRefChangeGrp += Isis::PvlKeyword("NewLeastIncAngle", Isis::toString(bestIncidenceAngle[iBestIndex])); istrTemp = QString::number((int)newPnt->GetMeasure(iBestIndex)->GetSample()); istrTemp += ","; @@ -272,9 +272,9 @@ namespace Isis { }// end Point // CnetRef Change Statistics - mStatisticsGrp += Isis::PvlKeyword("PointsModified", toString(iPointsModified)); - mStatisticsGrp += Isis::PvlKeyword("ReferenceChanged", toString(iRefChanged)); - mStatisticsGrp += Isis::PvlKeyword("MeasuresModified", toString(iMeasuresModified)); + mStatisticsGrp += Isis::PvlKeyword("PointsModified", Isis::toString(iPointsModified)); + mStatisticsGrp += Isis::PvlKeyword("ReferenceChanged", Isis::toString(iRefChanged)); + mStatisticsGrp += Isis::PvlKeyword("MeasuresModified", Isis::toString(iMeasuresModified)); mPvlLog += mStatisticsGrp; } diff --git a/isis/src/control/apps/cnetref/CnetRefByResolution.cpp b/isis/src/control/apps/cnetref/CnetRefByResolution.cpp index 99708490b6..55635abb66 100644 --- a/isis/src/control/apps/cnetref/CnetRefByResolution.cpp +++ b/isis/src/control/apps/cnetref/CnetRefByResolution.cpp @@ -212,24 +212,24 @@ namespace Isis { int iComment = 0; if (numMeasures == 0) { std::string sComment = "Comment"; - sComment += toString(++iComment); + sComment += Isis::toString(++iComment); pvlPointObj += Isis::PvlKeyword(sComment, "No Measures in the Point"); } if (newPnt->IsIgnored()) { std::string sComment = "Comment"; - sComment += toString(++iComment); + sComment += Isis::toString(++iComment); pvlPointObj += Isis::PvlKeyword(sComment, "Point was originally Ignored"); } if (newPnt->GetType() == ControlPoint::Fixed) { std::string sComment = "Comment"; - sComment += toString(++iComment); + sComment += Isis::toString(++iComment); pvlPointObj += Isis::PvlKeyword(sComment, "Fixed Point"); } else if (newPnt->GetType() == ControlPoint::Constrained) { std::string sComment = "Comment"; - sComment += toString(++iComment); + sComment += Isis::toString(++iComment); pvlPointObj += Isis::PvlKeyword(sComment, "Constrained Point"); } @@ -259,7 +259,7 @@ namespace Isis { if (iRefIndex >= 0) { pvlRefChangeGrp += Isis::PvlKeyword("PrevSerialNumber", origPnt.GetMeasure(iRefIndex)->GetCubeSerialNumber().toStdString()); - pvlRefChangeGrp += Isis::PvlKeyword("PrevResolution", toString(mdResVector[iRefIndex])); + pvlRefChangeGrp += Isis::PvlKeyword("PrevResolution", Isis::toString(mdResVector[iRefIndex])); istrTemp = QString((int)origPnt.GetMeasure(iRefIndex)->GetSample()); istrTemp += ","; @@ -277,7 +277,7 @@ namespace Isis { sKeyName = "NewLeastResolution"; } else if (meType == Mean) { - pvlRefChangeGrp += Isis::PvlKeyword("MeanResolution", toString(GetMeanResolution())); + pvlRefChangeGrp += Isis::PvlKeyword("MeanResolution", Isis::toString(GetMeanResolution())); sKeyName = "NewResolutionNeartoMean"; } else if (meType == Nearest) { @@ -286,7 +286,7 @@ namespace Isis { else if (meType == Range) { sKeyName = "NewResolutionInRange"; } - pvlRefChangeGrp += Isis::PvlKeyword(sKeyName.toStdString(), toString(mdResVector[iBestIndex])); + pvlRefChangeGrp += Isis::PvlKeyword(sKeyName.toStdString(), Isis::toString(mdResVector[iBestIndex])); istrTemp = QString((int)newPnt->GetMeasure(iBestIndex)->GetSample()); istrTemp += ","; @@ -305,9 +305,9 @@ namespace Isis { }// end Point // CnetRef Change Statistics - mStatisticsGrp += Isis::PvlKeyword("PointsModified", toString(iPointsModified)); - mStatisticsGrp += Isis::PvlKeyword("ReferenceChanged", toString(iRefChanged)); - mStatisticsGrp += Isis::PvlKeyword("MeasuresModified", toString(iMeasuresModified)); + mStatisticsGrp += Isis::PvlKeyword("PointsModified", Isis::toString(iPointsModified)); + mStatisticsGrp += Isis::PvlKeyword("ReferenceChanged", Isis::toString(iRefChanged)); + mStatisticsGrp += Isis::PvlKeyword("MeasuresModified", Isis::toString(iMeasuresModified)); mPvlLog += mStatisticsGrp; } diff --git a/isis/src/control/apps/coreg/main.cpp b/isis/src/control/apps/coreg/main.cpp index 462ef55e0c..e7008f0658 100644 --- a/isis/src/control/apps/coreg/main.cpp +++ b/isis/src/control/apps/coreg/main.cpp @@ -201,14 +201,14 @@ void IsisMain() { double lMax = (int)(lStats.Maximum() * 100.0) / 100.0; double lDev = (int)(lStats.StandardDeviation() * 100.0) / 100.0; - results += PvlKeyword("SampleMinimum", toString(sMin)); - results += PvlKeyword("SampleAverage", toString(sTrans)); - results += PvlKeyword("SampleMaximum", toString(sMax)); - results += PvlKeyword("SampleStandardDeviation", toString(sDev)); - results += PvlKeyword("LineMinimum", toString(lMin)); - results += PvlKeyword("LineAverage", toString(lTrans)); - results += PvlKeyword("LineMaximum", toString(lMax)); - results += PvlKeyword("LineStandardDeviation", toString(lDev)); + results += PvlKeyword("SampleMinimum", Isis::toString(sMin)); + results += PvlKeyword("SampleAverage", Isis::toString(sTrans)); + results += PvlKeyword("SampleMaximum", Isis::toString(sMax)); + results += PvlKeyword("SampleStandardDeviation", Isis::toString(sDev)); + results += PvlKeyword("LineMinimum", Isis::toString(lMin)); + results += PvlKeyword("LineAverage", Isis::toString(lTrans)); + results += PvlKeyword("LineMaximum", Isis::toString(lMax)); + results += PvlKeyword("LineStandardDeviation", Isis::toString(lDev)); Application::Log(results); Pvl arPvl = ar->RegistrationStatistics(); diff --git a/isis/src/control/apps/deltack/main.cpp b/isis/src/control/apps/deltack/main.cpp index 8568515219..5a8fc8f50b 100644 --- a/isis/src/control/apps/deltack/main.cpp +++ b/isis/src/control/apps/deltack/main.cpp @@ -94,31 +94,31 @@ void IsisMain() { // Map the latitude/longitude to a line/sample of the desired update // cout << "Input Lat, Lon = " << lat1.degrees() << "," << lon1.degrees() << "\n"; - results += PvlKeyword("Lat1", toString(lat1.degrees()), "degrees"); - results += PvlKeyword("Lon1", toString(lon1.degrees()), "degrees"); + results += PvlKeyword("Lat1", Isis::toString(lat1.degrees()), "degrees"); + results += PvlKeyword("Lon1", Isis::toString(lon1.degrees()), "degrees"); if ( !v_cam->SetUniversalGround(lat1.degrees(), lon1.degrees()) ) { std::string mess = "Geometry coordinate does not map into image at location (" + - toString(lat1.degrees()) + "," + toString(lon1.degrees()) + ")"; + Isis::toString(lat1.degrees()) + "," + Isis::toString(lon1.degrees()) + ")"; throw IException(IException::User, mess, _FILEINFO_); } // Get the surface coordinate in body fixed // cout << "Sample, Line = " << v_cam->Sample() << "," << v_cam->Line() << "\n"; - results += PvlKeyword("Lat1Lon1Sample", toString(v_cam->Sample())); - results += PvlKeyword("Lat1Lon1Line", toString(v_cam->Line())); + results += PvlKeyword("Lat1Lon1Sample", Isis::toString(v_cam->Sample())); + results += PvlKeyword("Lat1Lon1Line", Isis::toString(v_cam->Line())); double pt2[3]; v_cam->Coordinate(pt2); // Retrieve the current geometry of a point to use as reference for the update - results += PvlKeyword("Samp1", toString(samp1)); - results += PvlKeyword("Line1", toString(line1)); + results += PvlKeyword("Samp1", Isis::toString(samp1)); + results += PvlKeyword("Line1", Isis::toString(line1)); if ( !v_cam->SetImage(samp1, line1) ) { // Ignore the SetImage() error as long as the coordinate is a valid // image coordinate. if (!v_cam->InCube() ) { std::string mess = "Image coordinate is outside image coordinates at point (" + - toString(samp1) + "," + toString(line1) + ")"; + Isis::toString(samp1) + "," + Isis::toString(line1) + ")"; throw IException(IException::User, mess, _FILEINFO_); } @@ -130,8 +130,8 @@ void IsisMain() { results += PvlKeyword("Samp1Line1Lon"); } else { - results += PvlKeyword("Samp1Line1Lat", toString(v_cam->GetLatitude().degrees()), "degrees"); - results += PvlKeyword("Samp1Line1Lon", toString(v_cam->GetLongitude().degrees()), "degrees"); + results += PvlKeyword("Samp1Line1Lat", Isis::toString(v_cam->GetLatitude().degrees()), "degrees"); + results += PvlKeyword("Samp1Line1Lon", Isis::toString(v_cam->GetLongitude().degrees()), "degrees"); } // Get vector to surface from S/C and S/C position in body-fixed. @@ -155,7 +155,7 @@ void IsisMain() { // Compute angle difference of update double j2kAngle = vsep_c(&ldir1[0], &ldir2[0]); - results += PvlKeyword("AdjustedAngle", toString(j2kAngle * dpr_c()), "degrees"); + results += PvlKeyword("AdjustedAngle", Isis::toString(j2kAngle * dpr_c()), "degrees"); // Compute rotation of vectors SpiceDouble R[3][3]; @@ -179,7 +179,7 @@ void IsisMain() { // else and we have to abort... if ( o_cmat.Records() != 4 ) { std::string mess = "Expect only 4 records for polynomial cache but got " - + toString(o_cmat.Records()) + " instead!"; + + Isis::toString(o_cmat.Records()) + " instead!"; throw IException(IException::User, mess, _FILEINFO_); } @@ -193,7 +193,7 @@ void IsisMain() { } // Write out a description in the spice table - results += PvlKeyword("RecordsUpdated", toString(o_cmat.Records())); + results += PvlKeyword("RecordsUpdated", Isis::toString(o_cmat.Records())); QString deltackComment = "deltackDirectAdjusted = " + Isis::iTime::CurrentLocalTime(); o_cmat.Label().addComment(deltackComment.toStdString()); @@ -331,7 +331,7 @@ Distance GetRadius(QString filename, Latitude lat, Longitude lon) { Distance radius = sensor->LocalRadius(); if (!radius.isValid()) { std::string msg = "Could not determine radius from DEM at lat/lon ["; - msg += toString(lat.degrees()) + "," + toString(lon.degrees()) + "]"; + msg += Isis::toString(lat.degrees()) + "," + Isis::toString(lon.degrees()) + "]"; throw IException(IException::Unknown, msg, _FILEINFO_); } return radius; @@ -494,7 +494,7 @@ void ApplyRotation(const double R[3][3], Table &table) { // Sanity check... if ( table[0].Fields() < 4 ) { std::string mess = "Expect at least 4 fields for quaternion cache but got " - + toString(table.Records()) + " instead!"; + + Isis::toString(table.Records()) + " instead!"; throw IException(IException::User, mess, _FILEINFO_); } diff --git a/isis/src/control/apps/findfeatures/ImageSource.cpp b/isis/src/control/apps/findfeatures/ImageSource.cpp index 7f11bf215b..8a2ed00eb5 100644 --- a/isis/src/control/apps/findfeatures/ImageSource.cpp +++ b/isis/src/control/apps/findfeatures/ImageSource.cpp @@ -342,7 +342,7 @@ cv::Mat ImageSource::getGeometryMapping(ImageSource &match, // Compute homography if enough point if ( (int) source.size() < v_minpts ) { std::string mess = "Failed to get geometry mapping for " + match.name().toStdString() + - " to " + name().toStdString() + " needing " + std::to_string(v_minpts) + + " to " + name().toStdString() + " needing " + Isis::toString(v_minpts) + " but only could get " + std::to_string(source.size()) +"."; throw IException(IException::Programmer, mess, _FILEINFO_); } diff --git a/isis/src/control/apps/findfeatures/MatchMaker.cpp b/isis/src/control/apps/findfeatures/MatchMaker.cpp index 61b71e71f9..76dd4c6e42 100644 --- a/isis/src/control/apps/findfeatures/MatchMaker.cpp +++ b/isis/src/control/apps/findfeatures/MatchMaker.cpp @@ -158,7 +158,7 @@ MatcherSolutionList MatchMaker::match(const RobustMatcherList &matchers) { logger().flush(); } - cnetinfo += PvlKeyword("SolutionSize", toString(solution.size()) ); + cnetinfo += PvlKeyword("SolutionSize", Isis::toString(solution.size()) ); if ( solution.size() <= 0 ) { cnetinfo += PvlKeyword("Error", "No matches, no network!!"); return (cnetinfo); @@ -217,12 +217,12 @@ MatcherSolutionList MatchMaker::match(const RobustMatcherList &matchers) { } } - cnetinfo += PvlKeyword("ImagesMatched", toString(nImages) ); - cnetinfo += PvlKeyword("ControlPoints", toString(nPoints) ); - cnetinfo += PvlKeyword("ControlMeasures", toString(nMeasures) ); - cnetinfo += PvlKeyword("InvalidIgnoredPoints", toString(nBadPoints) ); - cnetinfo += PvlKeyword("InvalidIgnoredMeasures", toString(nBadMeasures) ); - cnetinfo += PvlKeyword("PreserveIgnoredControl", toString(preserve_ignored) ); + cnetinfo += PvlKeyword("ImagesMatched", Isis::toString(nImages) ); + cnetinfo += PvlKeyword("ControlPoints", Isis::toString(nPoints) ); + cnetinfo += PvlKeyword("ControlMeasures", Isis::toString(nMeasures) ); + cnetinfo += PvlKeyword("InvalidIgnoredPoints", Isis::toString(nBadPoints) ); + cnetinfo += PvlKeyword("InvalidIgnoredMeasures", Isis::toString(nBadMeasures) ); + cnetinfo += PvlKeyword("PreserveIgnoredControl", Isis::toString(preserve_ignored) ); if ( isDebug() ) { logger() << " Images Matched: " << nImages << "\n"; logger() << " ControlPoints created: " << nPoints << "\n"; @@ -234,7 +234,7 @@ MatcherSolutionList MatchMaker::match(const RobustMatcherList &matchers) { } // Report measure statistics - PvlKeyword mkey = PvlKeyword("ValidPoints", toString(pointStats.ValidPixels()) ); + PvlKeyword mkey = PvlKeyword("ValidPoints", Isis::toString(pointStats.ValidPixels()) ); mkey.addComment(" -- Valid Point/Measure Statistics ---"); cnetinfo += mkey; if ( isDebug() ) { @@ -243,11 +243,11 @@ MatcherSolutionList MatchMaker::match(const RobustMatcherList &matchers) { } if ( pointStats.ValidPixels() > 0 ) { - cnetinfo += PvlKeyword("MinimumMeasures", toString(pointStats.Minimum()) ); - cnetinfo += PvlKeyword("MaximumMeasures", toString(pointStats.Maximum()) ); - cnetinfo += PvlKeyword("AverageMeasures", toString(pointStats.Average()) ); - cnetinfo += PvlKeyword("StdDevMeasures", toString(pointStats.StandardDeviation()) ); - cnetinfo += PvlKeyword("TotalMeasures", toString((int) pointStats.Sum()) ); + cnetinfo += PvlKeyword("MinimumMeasures", Isis::toString(pointStats.Minimum()) ); + cnetinfo += PvlKeyword("MaximumMeasures", Isis::toString(pointStats.Maximum()) ); + cnetinfo += PvlKeyword("AverageMeasures", Isis::toString(pointStats.Average()) ); + cnetinfo += PvlKeyword("StdDevMeasures", Isis::toString(pointStats.StandardDeviation()) ); + cnetinfo += PvlKeyword("TotalMeasures", Isis::toString((int) pointStats.Sum()) ); if ( isDebug() ) { logger() << " MinimumMeasures: " << pointStats.Minimum() << "\n"; logger() << " MaximumMeasures: " << pointStats.Maximum() << "\n"; diff --git a/isis/src/control/apps/findfeatures/MatcherAlgorithms.cpp b/isis/src/control/apps/findfeatures/MatcherAlgorithms.cpp index ce5c40c9fa..2744545c6b 100644 --- a/isis/src/control/apps/findfeatures/MatcherAlgorithms.cpp +++ b/isis/src/control/apps/findfeatures/MatcherAlgorithms.cpp @@ -132,7 +132,7 @@ namespace Isis { // Shall we throw an exception to report the issues? if ( (0 < nerrors) && (true == throwOnErrors)) { - std::string mess = "There were " + toString(nerrors) + + std::string mess = "There were " + Isis::toString(nerrors) + " errors found in this matcher algorithm set"; ie.append(IException(IException::Programmer, mess, _FILEINFO_)); throw ie; diff --git a/isis/src/control/apps/findfeatures/findfeatures.cpp b/isis/src/control/apps/findfeatures/findfeatures.cpp index 9e04b0c371..6b03016f6f 100644 --- a/isis/src/control/apps/findfeatures/findfeatures.cpp +++ b/isis/src/control/apps/findfeatures/findfeatures.cpp @@ -396,7 +396,7 @@ namespace Isis { if ( matcher.size() <= 0 ) { logger->dbugout() << "\n\n### No valid files loaded - aborting...\n"; logger->dbugout() << "Time: " << Application::DateTime() << "\n"; - std::string msg = "Input cubes (" + toString(badgeom.size()) + ") failed to load. " + + std::string msg = "Input cubes (" + Isis::toString(badgeom.size()) + ") failed to load. " + "Must provide valid FROM/FROMLIST and MATCH cube or image filenames"; throw IException(IException::User, msg, _FILEINFO_); } @@ -438,7 +438,7 @@ namespace Isis { logger->dbugout() << "Shucks! Insufficient matches were found (" << best->size() << ")\n"; std::string mess = "Shucks! Insufficient matches were found (" + - toString(best->size()) + ")"; + Isis::toString(best->size()) + ")"; throw IException(IException::User, mess, _FILEINFO_); } @@ -446,12 +446,12 @@ namespace Isis { Statistics quality = best->qualityStatistics(); PvlGroup bestinfo("MatchSolution"); bestinfo += PvlKeyword("Matcher", best->matcher()->name().toStdString()); - bestinfo += PvlKeyword("MatchedPairs", toString(best->size())); - bestinfo += PvlKeyword("ValidPairs", toString(quality.ValidPixels())); - bestinfo += PvlKeyword("Efficiency", toString(quality.Average())); + bestinfo += PvlKeyword("MatchedPairs", Isis::toString(best->size())); + bestinfo += PvlKeyword("ValidPairs", Isis::toString(quality.ValidPixels())); + bestinfo += PvlKeyword("Efficiency", Isis::toString(quality.Average())); if ( quality.ValidPixels() > 1 ) { bestinfo += PvlKeyword("StdDevEfficiency", - toString(quality.StandardDeviation())); + Isis::toString(quality.StandardDeviation())); } Application::Log(bestinfo); diff --git a/isis/src/control/apps/fplanemap/main.cpp b/isis/src/control/apps/fplanemap/main.cpp index bc51fd9bcd..e57cbb1eab 100644 --- a/isis/src/control/apps/fplanemap/main.cpp +++ b/isis/src/control/apps/fplanemap/main.cpp @@ -150,14 +150,14 @@ void IsisMain() { } PvlGroup results("Results"); - results += PvlKeyword("PixelPitch", toString(pp), "millimeters"); - results += PvlKeyword("TotalPoints", toString(cn.GetNumPoints())); - results += PvlKeyword("ValidPoints", toString((BigInt) coords.size())); - results += PvlKeyword("InvalidPoints", toString(badPoint)); - if (checkForNulls) results += PvlKeyword("NullDNs", toString(nulls)); - results += PvlKeyword("OldPointNotInImage", toString(oldNotInImage)); - results += PvlKeyword("NewPointNotInImage", toString(newNotInImage)); - results += PvlKeyword("ToleranceExceeded", toString(badTol)); + results += PvlKeyword("PixelPitch", Isis::toString(pp), "millimeters"); + results += PvlKeyword("TotalPoints", Isis::toString(cn.GetNumPoints())); + results += PvlKeyword("ValidPoints", Isis::toString((BigInt) coords.size())); + results += PvlKeyword("InvalidPoints", Isis::toString(badPoint)); + if (checkForNulls) results += PvlKeyword("NullDNs", Isis::toString(nulls)); + results += PvlKeyword("OldPointNotInImage", Isis::toString(oldNotInImage)); + results += PvlKeyword("NewPointNotInImage", Isis::toString(newNotInImage)); + results += PvlKeyword("ToleranceExceeded", Isis::toString(badTol)); // Log it Application::Log(results); diff --git a/isis/src/control/apps/mat2cnet/main.cpp b/isis/src/control/apps/mat2cnet/main.cpp index b52ddbc9cd..dbbd4b49b2 100644 --- a/isis/src/control/apps/mat2cnet/main.cpp +++ b/isis/src/control/apps/mat2cnet/main.cpp @@ -469,7 +469,7 @@ void IsisMain() { // Write results to Logs // Summary group is created with the counts of RAND PPP only points PvlGroup summaryGroup = PvlGroup("Summary"); - summaryGroup.addKeyword(PvlKeyword("RandOnlyPoints", toString(numRandOnly))); + summaryGroup.addKeyword(PvlKeyword("RandOnlyPoints", Isis::toString(numRandOnly))); bool log; FileName logFile; diff --git a/isis/src/control/apps/pointreg/pointreg.cpp b/isis/src/control/apps/pointreg/pointreg.cpp index 70f22c2b6f..b5aee0b5a8 100644 --- a/isis/src/control/apps/pointreg/pointreg.cpp +++ b/isis/src/control/apps/pointreg/pointreg.cpp @@ -467,15 +467,15 @@ namespace Isis { } PvlGroup pLog("Points"); - pLog += PvlKeyword("Total", toString(outNet.GetNumPoints())); - pLog += PvlKeyword("Ignored", toString(ignored)); + pLog += PvlKeyword("Total", Isis::toString(outNet.GetNumPoints())); + pLog += PvlKeyword("Ignored", Isis::toString(ignored)); Application::AppendAndLog(pLog, appLog); PvlGroup mLog("Measures"); - mLog += PvlKeyword("Locked", toString(locked)); - mLog += PvlKeyword("Registered", toString(registered)); - mLog += PvlKeyword("NotIntersected", toString(notintersected)); - mLog += PvlKeyword("Unregistered", toString(unregistered)); + mLog += PvlKeyword("Locked", Isis::toString(locked)); + mLog += PvlKeyword("Registered", Isis::toString(registered)); + mLog += PvlKeyword("NotIntersected", Isis::toString(notintersected)); + mLog += PvlKeyword("Unregistered", Isis::toString(unregistered)); Application::AppendAndLog(mLog, appLog); // Log Registration Statistics diff --git a/isis/src/control/apps/seedgrid/main.cpp b/isis/src/control/apps/seedgrid/main.cpp index 3eaab6e55b..9802c2f4eb 100644 --- a/isis/src/control/apps/seedgrid/main.cpp +++ b/isis/src/control/apps/seedgrid/main.cpp @@ -79,7 +79,7 @@ void IsisMain() { throw IException(e, IException::Unknown, msg, _FILEINFO_); } } - double equatorialRadius = IString::ToDouble(mapGroup.findKeyword("EquatorialRadius")[0]); + double equatorialRadius = Isis::toDouble(mapGroup.findKeyword("EquatorialRadius")[0]); QString networkId; if (ui.WasEntered("NETWORKID")) { @@ -102,7 +102,7 @@ void IsisMain() { checkLatitude(minLat, maxLat); int lonDomain = (mapGroup.hasKeyword("LongitudeDomain") ? - IString::ToInteger(mapGroup.findKeyword("LongitudeDomain")[0]) : + Isis::toInt(mapGroup.findKeyword("LongitudeDomain")[0]) : 360); checkLongitude(minLon, maxLon, lonDomain); @@ -120,10 +120,10 @@ void IsisMain() { mapGroup += PvlKeyword("CenterLongitude", "0.0"); } - mapGroup.addKeyword(PvlKeyword("MinimumLatitude", toString(minLat)), Pvl::Replace); - mapGroup.addKeyword(PvlKeyword("MaximumLatitude", toString(maxLat)), Pvl::Replace); - mapGroup.addKeyword(PvlKeyword("MinimumLongitude", toString(minLon)), Pvl::Replace); - mapGroup.addKeyword(PvlKeyword("MaximumLongitude", toString(maxLon)), Pvl::Replace); + mapGroup.addKeyword(PvlKeyword("MinimumLatitude", Isis::toString(minLat)), Pvl::Replace); + mapGroup.addKeyword(PvlKeyword("MaximumLatitude", Isis::toString(maxLat)), Pvl::Replace); + mapGroup.addKeyword(PvlKeyword("MinimumLongitude", Isis::toString(minLon)), Pvl::Replace); + mapGroup.addKeyword(PvlKeyword("MaximumLongitude", Isis::toString(maxLon)), Pvl::Replace); // create the projection from the editted map TProjection *proj = (TProjection *) ProjectionFactory::Create(userMap); @@ -228,8 +228,8 @@ void IsisMain() { } PvlGroup results("Results"); - results += PvlKeyword("EquatorialRadius", toString(equatorialRadius)); - results += PvlKeyword("NumberControlPoints", toString(cnet.GetNumPoints())); + results += PvlKeyword("EquatorialRadius", Isis::toString(equatorialRadius)); + results += PvlKeyword("NumberControlPoints", Isis::toString(cnet.GetNumPoints())); Application::Log(results); cnet.Write(ui.GetFileName("ONET")); diff --git a/isis/src/control/apps/sumspice/SumFinder.cpp b/isis/src/control/apps/sumspice/SumFinder.cpp index 6c6562c476..1fda4136ad 100644 --- a/isis/src/control/apps/sumspice/SumFinder.cpp +++ b/isis/src/control/apps/sumspice/SumFinder.cpp @@ -341,7 +341,7 @@ namespace Isis { PvlGroup &instGrp = cubeLabels->findGroup("Instrument", Pvl::Traverse); PvlKeyword exptime = instGrp["ExposureDuration"]; QString units = QString::fromStdString(exptime.unit(0)).toLower(); - double etime = IString::ToDouble(exptime[0]); + double etime = Isis::toDouble(exptime[0]); // Convert to seconds if indicated if ( "milliseconds" == units) etime /= 1000.0; diff --git a/isis/src/control/apps/warp/WarpTransform.cpp b/isis/src/control/apps/warp/WarpTransform.cpp index 32b42eb24f..3edd1ed3f5 100644 --- a/isis/src/control/apps/warp/WarpTransform.cpp +++ b/isis/src/control/apps/warp/WarpTransform.cpp @@ -147,9 +147,9 @@ namespace Isis { PvlGroup WarpTransform::Residuals() { PvlGroup errs("Residuals"); for (int i = 0; i < p_lsqInputLine->Knowns(); i++) { - PvlKeyword p("POINT" + toString (i + 1)); - p += toString (p_lsqInputLine->Residual(i)); - p += toString (p_lsqInputSamp->Residual(i)); + PvlKeyword p("POINT" + Isis::toString (i + 1)); + p += Isis::toString (p_lsqInputLine->Residual(i)); + p += Isis::toString (p_lsqInputSamp->Residual(i)); errs += p; } return errs; diff --git a/isis/src/control/objs/BundleAdjust/BundleAdjust.cpp b/isis/src/control/objs/BundleAdjust/BundleAdjust.cpp index 9f3bff9e63..6692eaf732 100644 --- a/isis/src/control/objs/BundleAdjust/BundleAdjust.cpp +++ b/isis/src/control/objs/BundleAdjust/BundleAdjust.cpp @@ -84,8 +84,8 @@ namespace Isis { PvlGroup gp(errlog.toStdString()); gp += PvlKeyword("File",file); - gp += PvlKeyword("Line_Number", toString(nLineNo)); - gp += PvlKeyword("Status", toString(nStatus)); + gp += PvlKeyword("Line_Number", Isis::toString(nLineNo)); + gp += PvlKeyword("Status", Isis::toString(nStatus)); // Application::Log(gp); @@ -1828,7 +1828,7 @@ namespace Isis { // check for "matrix not positive definite" error if (m_cholmodCommon.status == CHOLMOD_NOT_POSDEF) { - std::string msg = "Matrix NOT positive-definite: failure at column " + toString((int) m_L->minor); + std::string msg = "Matrix NOT positive-definite: failure at column " + Isis::toString((int) m_L->minor); // throw IException(IException::User, msg, _FILEINFO_); error(QString::fromStdString(msg)); emit(finished()); @@ -2981,7 +2981,7 @@ namespace Isis { QString BundleAdjust::modelState(int i) { Camera *imageCam = m_controlNet->Camera(i); if (imageCam->GetCameraType() != Camera::Csm) { - std::string msg = "Cannot get model state for image [" + toString(i) + + std::string msg = "Cannot get model state for image [" + Isis::toString(i) + "] because it is not a CSM camera model."; throw IException(IException::Programmer, msg, _FILEINFO_); } @@ -3012,46 +3012,46 @@ namespace Isis { PvlGroup summaryGroup(iterationNumber.toStdString()); summaryGroup += PvlKeyword("Sigma0", - toString( m_bundleResults.sigma0() ) ); + Isis::toString( m_bundleResults.sigma0() ) ); summaryGroup += PvlKeyword("Observations", - toString( m_bundleResults.numberObservations() ) ); + Isis::toString( m_bundleResults.numberObservations() ) ); summaryGroup += PvlKeyword("Constrained_Point_Parameters", - toString( m_bundleResults.numberConstrainedPointParameters() ) ); + Isis::toString( m_bundleResults.numberConstrainedPointParameters() ) ); summaryGroup += PvlKeyword("Constrained_Image_Parameters", - toString( m_bundleResults.numberConstrainedImageParameters() ) ); + Isis::toString( m_bundleResults.numberConstrainedImageParameters() ) ); if (m_bundleSettings->bundleTargetBody()) { summaryGroup += PvlKeyword("Constrained_Target_Parameters", - toString( m_bundleResults.numberConstrainedTargetParameters() ) ); + Isis::toString( m_bundleResults.numberConstrainedTargetParameters() ) ); } summaryGroup += PvlKeyword("Unknown_Parameters", - toString( m_bundleResults.numberUnknownParameters() ) ); + Isis::toString( m_bundleResults.numberUnknownParameters() ) ); summaryGroup += PvlKeyword("Degrees_of_Freedom", - toString( m_bundleResults.degreesOfFreedom() ) ); + Isis::toString( m_bundleResults.degreesOfFreedom() ) ); summaryGroup += PvlKeyword( "Rejected_Measures", - toString( m_bundleResults.numberRejectedObservations()/2) ); + Isis::toString( m_bundleResults.numberRejectedObservations()/2) ); if ( m_bundleResults.numberMaximumLikelihoodModels() > m_bundleResults.maximumLikelihoodModelIndex() ) { // if maximum likelihood estimation is being used summaryGroup += PvlKeyword("Maximum_Likelihood_Tier: ", - toString( m_bundleResults.maximumLikelihoodModelIndex() ) ); + Isis::toString( m_bundleResults.maximumLikelihoodModelIndex() ) ); summaryGroup += PvlKeyword("Median_of_R^2_residuals: ", - toString( m_bundleResults.maximumLikelihoodMedianR2Residuals() ) ); + Isis::toString( m_bundleResults.maximumLikelihoodMedianR2Residuals() ) ); } if ( m_bundleResults.converged() ) { summaryGroup += PvlKeyword("Converged", "TRUE"); - summaryGroup += PvlKeyword("TotalElapsedTime", toString( m_bundleResults.elapsedTime() ) ); + summaryGroup += PvlKeyword("TotalElapsedTime", Isis::toString( m_bundleResults.elapsedTime() ) ); if (m_bundleSettings->errorPropagation()) { summaryGroup += PvlKeyword("ErrorPropagationElapsedTime", - toString( m_bundleResults.elapsedTimeErrorProp() ) ); + Isis::toString( m_bundleResults.elapsedTimeErrorProp() ) ); } } else { summaryGroup += PvlKeyword("Elapsed_Time", - toString( m_iterationTime ) ); + Isis::toString( m_iterationTime ) ); } std::ostringstream ostr; diff --git a/isis/src/control/objs/BundleResults/BundleResults.cpp b/isis/src/control/objs/BundleResults/BundleResults.cpp index 444a1c5f58..a0122493af 100644 --- a/isis/src/control/objs/BundleResults/BundleResults.cpp +++ b/isis/src/control/objs/BundleResults/BundleResults.cpp @@ -1254,7 +1254,7 @@ namespace Isis { m_sigma0 = dvtpv; } else { - std::string msg = "Computed degrees of freedom [" + toString(m_degreesOfFreedom) + std::string msg = "Computed degrees of freedom [" + Isis::toString(m_degreesOfFreedom) + "] is invalid."; throw IException(IException::Io, msg, _FILEINFO_); } diff --git a/isis/src/control/objs/BundleUtilities/BundleObservationSolveSettings.cpp b/isis/src/control/objs/BundleUtilities/BundleObservationSolveSettings.cpp index aa251a4794..7f4d207e6a 100644 --- a/isis/src/control/objs/BundleUtilities/BundleObservationSolveSettings.cpp +++ b/isis/src/control/objs/BundleUtilities/BundleObservationSolveSettings.cpp @@ -202,7 +202,7 @@ namespace Isis { if (scParameterGroup.hasKeyword("ADDITIONAL_CAMERA_POINTING_SIGMAS")) { PvlKeyword additionalSigmas = scParameterGroup.findKeyword("ADDITIONAL_CAMERA_POINTING_SIGMAS"); for (int i = 0; i < additionalSigmas.size(); i++ ) { - m_anglesAprioriSigma.append(IString::ToDouble(additionalSigmas[i])); + m_anglesAprioriSigma.append(Isis::toDouble(additionalSigmas[i])); } } } @@ -229,7 +229,7 @@ namespace Isis { if (scParameterGroup.hasKeyword("ADDITIONAL_SPACECRAFT_POSITION_SIGMAS")) { PvlKeyword additionalSigmas = scParameterGroup.findKeyword("ADDITIONAL_SPACECRAFT_POSITION_SIGMAS"); for (int i = 0; i < additionalSigmas.size(); i++ ) { - m_positionAprioriSigma.append(IString::ToDouble(additionalSigmas[i])); + m_positionAprioriSigma.append(Isis::toDouble(additionalSigmas[i])); } } } diff --git a/isis/src/control/objs/ControlMeasureLogData/ControlMeasureLogData.cpp b/isis/src/control/objs/ControlMeasureLogData/ControlMeasureLogData.cpp index c3ebc91465..e8f9989897 100644 --- a/isis/src/control/objs/ControlMeasureLogData/ControlMeasureLogData.cpp +++ b/isis/src/control/objs/ControlMeasureLogData/ControlMeasureLogData.cpp @@ -60,7 +60,7 @@ namespace Isis { QString name = QString::fromStdString(keywordRep.name()); p_dataType = NameToDataType(name); if (p_dataType != InvalidNumericLogDataType) - p_numericalValue = IString::ToDouble(keywordRep[0]); + p_numericalValue = Isis::toDouble(keywordRep[0]); } /** @@ -165,7 +165,7 @@ namespace Isis { */ PvlKeyword ControlMeasureLogData::ToKeyword() const { if(IsValid()) - return PvlKeyword(DataTypeToName(p_dataType).toStdString(), toString(p_numericalValue)); + return PvlKeyword(DataTypeToName(p_dataType).toStdString(), Isis::toString(p_numericalValue)); else return PvlKeyword(); } @@ -235,7 +235,7 @@ namespace Isis { return "Obsolete_AverageResidual"; } - std::string msg = "Unknown data type [" + toString(type) + "]"; + std::string msg = "Unknown data type [" + Isis::toString(type) + "]"; throw IException(IException::Programmer, msg, _FILEINFO_); } } diff --git a/isis/src/control/objs/ControlMeasureLogData/unitTest.cpp b/isis/src/control/objs/ControlMeasureLogData/unitTest.cpp index fcde04ae2b..313425de9f 100644 --- a/isis/src/control/objs/ControlMeasureLogData/unitTest.cpp +++ b/isis/src/control/objs/ControlMeasureLogData/unitTest.cpp @@ -42,7 +42,7 @@ int main() { cout << "Testing PvlKeyword constructor..." << endl; { - ControlMeasureLogData logData(PvlKeyword("GoodnessOfFit", toString(3.14159))); + ControlMeasureLogData logData(PvlKeyword("GoodnessOfFit", Isis::toString(3.14159))); cout << "Valid? " << logData.IsValid() << "\n" << "Type? " << logData.GetDataType() << "\n" diff --git a/isis/src/control/objs/ControlNet/unitTest.cpp b/isis/src/control/objs/ControlNet/unitTest.cpp index 234b34d71b..b5ae5a1bdb 100644 --- a/isis/src/control/objs/ControlNet/unitTest.cpp +++ b/isis/src/control/objs/ControlNet/unitTest.cpp @@ -486,17 +486,17 @@ int main() { cout << "\nTesting take() functionality to take owernship of the points in a ControlNet:" << endl; - cout << "Original control net number of points: " << toString(net.GetNumPoints()) << endl; + cout << "Original control net number of points: " << Isis::toString(net.GetNumPoints()) << endl; QList points = net.take(); - cout << "Number of points taken out: " << toString(points.length()) << endl; + cout << "Number of points taken out: " << Isis::toString(points.length()) << endl; cout << "Now there should be zero points in the original control net. There are: " - << toString(net.GetNumPoints()) << endl; + << Isis::toString(net.GetNumPoints()) << endl; cout << "And zero pointIDs in the original control net. There are: " - << toString(net.GetPointIds().length()) << endl; + << Isis::toString(net.GetPointIds().length()) << endl; //system("cat unitTest.output | grep -v DateTime > temp.output; mv temp.output unitTest.output"); //system("cat unitTest.output | sed -r s/`date +%Y-%m-%dT`\\[0-9:\\]\\{8\\}/2010-08-27T17:10:06/g > temp.output; mv temp.output unitTest.output"); diff --git a/isis/src/control/objs/ControlNetDiff/ControlNetDiff.cpp b/isis/src/control/objs/ControlNetDiff/ControlNetDiff.cpp index 7362a9aa09..634a4e1a04 100644 --- a/isis/src/control/objs/ControlNetDiff/ControlNetDiff.cpp +++ b/isis/src/control/objs/ControlNetDiff/ControlNetDiff.cpp @@ -68,7 +68,7 @@ namespace Isis { PvlGroup tolerances = diffFile.findGroup("Tolerances"); for (int i = 0; i < tolerances.keywords(); i++) m_tolerances->insert(QString::fromStdString(tolerances[i].name()), - IString::ToDouble(tolerances[i][0])); + Isis::toDouble(tolerances[i][0])); } if (diffFile.hasGroup("IgnoreKeys")) { @@ -264,7 +264,7 @@ namespace Isis { void ControlNetDiff::compare(PvlKeyword &k1, PvlKeyword &k2, PvlContainer &report) { QString name = QString::fromStdString(k1.name()); if (m_tolerances->contains(name)) - diff(name, IString::ToDouble(k1[0]), IString::ToDouble(k2[0]), (*m_tolerances)[name], report); + diff(name, Isis::toDouble(k1[0]), Isis::toDouble(k2[0]), (*m_tolerances)[name], report); else diff(name, QString::fromStdString(k1[0]), QString::fromStdString(k2[0]), report); } @@ -355,10 +355,10 @@ namespace Isis { */ PvlKeyword ControlNetDiff::makeKeyword(QString name, double v1, double v2, double tol) { PvlKeyword keyword(name.toStdString()); - keyword.addValue(toString(v1)); + keyword.addValue(Isis::toString(v1)); if (fabs(v1 - v2) > tol) { - keyword.addValue(toString(v2)); - keyword.addValue(toString(tol)); + keyword.addValue(Isis::toString(v2)); + keyword.addValue(Isis::toString(tol)); } return keyword; } diff --git a/isis/src/control/objs/ControlNetFilter/ControlNetFilter.cpp b/isis/src/control/objs/ControlNetFilter/ControlNetFilter.cpp index afaa3d0635..938ff8f7e9 100644 --- a/isis/src/control/objs/ControlNetFilter/ControlNetFilter.cpp +++ b/isis/src/control/objs/ControlNetFilter/ControlNetFilter.cpp @@ -259,11 +259,11 @@ namespace Isis { int iGreater = 0; if (pvlGrp.hasKeyword("LessThan")) { - iLesser = IString::ToInteger(pvlGrp["LessThan"][0]); + iLesser = Isis::toInt(pvlGrp["LessThan"][0]); } if (pvlGrp.hasKeyword("GreaterThan")) { - iGreater = IString::ToInteger(pvlGrp["GreaterThan"][0]); + iGreater = Isis::toInt(pvlGrp["GreaterThan"][0]); } if (iLesser < 0 || iGreater < 0 || iLesser < iGreater) { @@ -501,13 +501,13 @@ namespace Isis { if (pvlGrp.hasKeyword("LessThan")) { if (pvlGrp["LessThan"][0] != "") { - iLesser = IString::ToInteger(pvlGrp["LessThan"][0]); + iLesser = Isis::toInt(pvlGrp["LessThan"][0]); } } if (pvlGrp.hasKeyword("GreaterThan")) { if (pvlGrp["GreaterThan"][0] != "") { - iGreater = IString::ToInteger(pvlGrp["GreaterThan"][0]); + iGreater = Isis::toInt(pvlGrp["GreaterThan"][0]); } } @@ -1242,12 +1242,12 @@ namespace Isis { int iLessPoints = VALID_MAX2, iGreaterPoints = 0; if (pvlGrp.hasKeyword("LessThan")) { if (pvlGrp["LessThan"][0] != "") { - iLessPoints = IString::ToInteger(pvlGrp["LessThan"][0]); + iLessPoints = Isis::toInt(pvlGrp["LessThan"][0]); } } if (pvlGrp.hasKeyword("GreaterThan")) { if (pvlGrp["GreaterThan"][0] != "") { - iGreaterPoints = IString::ToInteger(pvlGrp["GreaterThan"][0]); + iGreaterPoints = Isis::toInt(pvlGrp["GreaterThan"][0]); } } diff --git a/isis/src/control/objs/ControlNetFilter/unitTest.cpp b/isis/src/control/objs/ControlNetFilter/unitTest.cpp index 1f8567345f..99975a0aa7 100644 --- a/isis/src/control/objs/ControlNetFilter/unitTest.cpp +++ b/isis/src/control/objs/ControlNetFilter/unitTest.cpp @@ -48,7 +48,7 @@ void IsisMain() { // Point ResidualMagnitude Filter cout << "****************** Point_ResidualMagnitude Filter ******************" << endl; filterGrp = PvlGroup("Point_ResidualMagnitude"); - keyword = PvlKeyword("LessThan", toString(1)); + keyword = PvlKeyword("LessThan", Isis::toString(1)); filterGrp += keyword; cnetFilter->PointResMagnitudeFilter(filterGrp, false); cout << filterGrp << endl; @@ -82,7 +82,7 @@ void IsisMain() { cnet = new ControlNet(ui.GetFileName("CNET")); cnetFilter = new ControlNetFilter(cnet, sSerialFile); filterGrp = PvlGroup("Point_NumMeasuresEditLock"); - keyword = PvlKeyword("LessThan", toString(1)); + keyword = PvlKeyword("LessThan", Isis::toString(1)); filterGrp += keyword; cnetFilter->PointNumMeasuresEditLockFilter(filterGrp, false); cout << filterGrp << endl; @@ -99,9 +99,9 @@ void IsisMain() { cnet = new ControlNet(ui.GetFileName("CNET")); cnetFilter = new ControlNetFilter(cnet, sSerialFile); filterGrp = PvlGroup("Point_PixelShift"); - keyword = PvlKeyword("LessThan", toString(10)); + keyword = PvlKeyword("LessThan", Isis::toString(10)); filterGrp += keyword; - keyword = PvlKeyword("GreaterThan", toString(1)); + keyword = PvlKeyword("GreaterThan", Isis::toString(1)); filterGrp += keyword; cnetFilter->PointPixelShiftFilter(filterGrp, false); cout << filterGrp << endl; @@ -135,9 +135,9 @@ void IsisMain() { cnet = new ControlNet(ui.GetFileName("CNET")); cnetFilter = new ControlNetFilter(cnet, sSerialFile); filterGrp = PvlGroup("Point_NumMeasures"); - keyword = PvlKeyword("GreaterThan", toString(2)); + keyword = PvlKeyword("GreaterThan", Isis::toString(2)); filterGrp += keyword; - keyword = PvlKeyword("LessThan", toString(2)); + keyword = PvlKeyword("LessThan", Isis::toString(2)); filterGrp += keyword; cnetFilter->PointMeasuresFilter(filterGrp, false); cout << filterGrp << endl; @@ -173,16 +173,16 @@ void IsisMain() { cnet = new ControlNet(ui.GetFileName("CNET")); cnetFilter = new ControlNetFilter(cnet, sSerialFile); filterGrp = PvlGroup("Point_LatLon"); - PvlKeyword keyword1("MinLat", toString(-100)); + PvlKeyword keyword1("MinLat", Isis::toString(-100)); filterGrp += keyword1; - PvlKeyword keyword2("MaxLat", toString(100)); + PvlKeyword keyword2("MaxLat", Isis::toString(100)); filterGrp += keyword2; - PvlKeyword keyword3("MinLon", toString(0)); + PvlKeyword keyword3("MinLon", Isis::toString(0)); filterGrp += keyword3; - PvlKeyword keyword4("MaxLon", toString(238)); + PvlKeyword keyword4("MaxLon", Isis::toString(238)); filterGrp += keyword4; cnetFilter->PointLatLonFilter(filterGrp, false); @@ -200,7 +200,7 @@ void IsisMain() { cnet = new ControlNet(ui.GetFileName("CNET")); cnetFilter = new ControlNetFilter(cnet, sSerialFile); filterGrp = PvlGroup("Point_Distance"); - keyword = PvlKeyword("MaxDistance", toString(50000)); + keyword = PvlKeyword("MaxDistance", Isis::toString(50000)); filterGrp += keyword; keyword = PvlKeyword("Units", "meters"); filterGrp += keyword; @@ -237,7 +237,7 @@ void IsisMain() { cnet = new ControlNet(ui.GetFileName("CNET")); cnetFilter = new ControlNetFilter(cnet, sSerialFile); filterGrp = PvlGroup("Point_GoodnessOfFit"); - keyword = PvlKeyword("LessThan", toString(0.5)); + keyword = PvlKeyword("LessThan", Isis::toString(0.5)); filterGrp += keyword; cnetFilter->PointGoodnessOfFitFilter(filterGrp, false); cout << filterGrp << endl; @@ -295,9 +295,9 @@ void IsisMain() { cnet = new ControlNet(ui.GetFileName("CNET")); cnetFilter = new ControlNetFilter(cnet, sSerialFile); filterGrp = PvlGroup("Cube_NumPoints"); - keyword = PvlKeyword("GreaterThan", toString(10)); + keyword = PvlKeyword("GreaterThan", Isis::toString(10)); filterGrp += keyword; - keyword = PvlKeyword("LessThan", toString(20)); + keyword = PvlKeyword("LessThan", Isis::toString(20)); filterGrp += keyword; cnetFilter->CubeNumPointsFilter(filterGrp, false); cout << filterGrp << endl; @@ -314,7 +314,7 @@ void IsisMain() { cnet = new ControlNet(ui.GetFileName("CNET")); cnetFilter = new ControlNetFilter(cnet, sSerialFile); filterGrp = PvlGroup("Cube_Distance"); - keyword = PvlKeyword("MaxDistance", toString(100000)); + keyword = PvlKeyword("MaxDistance", Isis::toString(100000)); filterGrp += keyword; keyword = PvlKeyword("Units=", "meters"); filterGrp += keyword; @@ -333,9 +333,9 @@ void IsisMain() { cnet = new ControlNet(ui.GetFileName("CNET")); cnetFilter = new ControlNetFilter(cnet, sSerialFile); filterGrp = PvlGroup("Cube_ConvexHullRatio"); - keyword = PvlKeyword("GreaterThan", toString(0.2)); + keyword = PvlKeyword("GreaterThan", Isis::toString(0.2)); filterGrp += keyword; - keyword = PvlKeyword("LessThan", toString(0.3)); + keyword = PvlKeyword("LessThan", Isis::toString(0.3)); filterGrp += keyword; cnetFilter->CubeConvexHullFilter(filterGrp, false); cout << filterGrp << endl; diff --git a/isis/src/control/objs/ControlNetStatistics/ControlNetStatistics.cpp b/isis/src/control/objs/ControlNetStatistics/ControlNetStatistics.cpp index 48c3ebda1e..9d23822077 100644 --- a/isis/src/control/objs/ControlNetStatistics/ControlNetStatistics.cpp +++ b/isis/src/control/objs/ControlNetStatistics/ControlNetStatistics.cpp @@ -117,94 +117,94 @@ namespace Isis { int numSN = mSerialNumList.size(); if (numSN) { - pStatsGrp += PvlKeyword("TotalImages", toString(numSN)); - pStatsGrp += PvlKeyword("ImagesInControlNet", toString(numCNetImages)); + pStatsGrp += PvlKeyword("TotalImages", Isis::toString(numSN)); + pStatsGrp += PvlKeyword("ImagesInControlNet", Isis::toString(numCNetImages)); } - pStatsGrp += PvlKeyword("TotalPoints", toString(mCNet->GetNumPoints())); - pStatsGrp += PvlKeyword("ValidPoints", toString(NumValidPoints())); - pStatsGrp += PvlKeyword("IgnoredPoints", toString(mCNet->GetNumPoints() - NumValidPoints())); - pStatsGrp += PvlKeyword("FixedPoints", toString(NumFixedPoints())); - pStatsGrp += PvlKeyword("ConstrainedPoints", toString(NumConstrainedPoints())); - pStatsGrp += PvlKeyword("FreePoints", toString(NumFreePoints())); - pStatsGrp += PvlKeyword("EditLockPoints", toString(mCNet->GetNumEditLockPoints())); + pStatsGrp += PvlKeyword("TotalPoints", Isis::toString(mCNet->GetNumPoints())); + pStatsGrp += PvlKeyword("ValidPoints", Isis::toString(NumValidPoints())); + pStatsGrp += PvlKeyword("IgnoredPoints", Isis::toString(mCNet->GetNumPoints() - NumValidPoints())); + pStatsGrp += PvlKeyword("FixedPoints", Isis::toString(NumFixedPoints())); + pStatsGrp += PvlKeyword("ConstrainedPoints", Isis::toString(NumConstrainedPoints())); + pStatsGrp += PvlKeyword("FreePoints", Isis::toString(NumFreePoints())); + pStatsGrp += PvlKeyword("EditLockPoints", Isis::toString(mCNet->GetNumEditLockPoints())); - pStatsGrp += PvlKeyword("TotalMeasures", toString(NumMeasures())); - pStatsGrp += PvlKeyword("ValidMeasures", toString(NumValidMeasures())); - pStatsGrp += PvlKeyword("IgnoredMeasures", toString(NumIgnoredMeasures())); - pStatsGrp += PvlKeyword("EditLockMeasures", toString(mCNet->GetNumEditLockMeasures())); + pStatsGrp += PvlKeyword("TotalMeasures", Isis::toString(NumMeasures())); + pStatsGrp += PvlKeyword("ValidMeasures", Isis::toString(NumValidMeasures())); + pStatsGrp += PvlKeyword("IgnoredMeasures", Isis::toString(NumIgnoredMeasures())); + pStatsGrp += PvlKeyword("EditLockMeasures", Isis::toString(mCNet->GetNumEditLockMeasures())); double dValue = GetAverageResidual(); - pStatsGrp += PvlKeyword("AvgResidual", (dValue == Null ? "Null" : toString(dValue))); + pStatsGrp += PvlKeyword("AvgResidual", (dValue == Null ? "Null" : Isis::toString(dValue))); dValue = GetMinimumResidual(); - pStatsGrp += PvlKeyword("MinResidual", (dValue == Null ? "Null" : toString(dValue))); + pStatsGrp += PvlKeyword("MinResidual", (dValue == Null ? "Null" : Isis::toString(dValue))); dValue = GetMaximumResidual(); - pStatsGrp += PvlKeyword("MaxResidual", (dValue == Null ? "Null" : toString(dValue))); + pStatsGrp += PvlKeyword("MaxResidual", (dValue == Null ? "Null" : Isis::toString(dValue))); dValue = GetMinLineResidual(); - pStatsGrp += PvlKeyword("MinLineResidual", (dValue == Null ? "Null" : toString(dValue))); + pStatsGrp += PvlKeyword("MinLineResidual", (dValue == Null ? "Null" : Isis::toString(dValue))); dValue = GetMaxLineResidual(); - pStatsGrp += PvlKeyword("MaxLineResidual", (dValue == Null ? "Null" : toString(dValue))); + pStatsGrp += PvlKeyword("MaxLineResidual", (dValue == Null ? "Null" : Isis::toString(dValue))); dValue = GetMinSampleResidual(); - pStatsGrp += PvlKeyword("MinSampleResidual", (dValue == Null ? "Null" : toString(dValue))); + pStatsGrp += PvlKeyword("MinSampleResidual", (dValue == Null ? "Null" : Isis::toString(dValue))); dValue = GetMaxSampleResidual(); - pStatsGrp += PvlKeyword("MaxSampleResidual", (dValue == Null ? "Null" : toString(dValue))); + pStatsGrp += PvlKeyword("MaxSampleResidual", (dValue == Null ? "Null" : Isis::toString(dValue))); // Shifts - Line, Sample, Pixel dValue = GetMinLineShift(); - pStatsGrp += PvlKeyword("MinLineShift", (dValue == Null ? "Null" : toString(dValue))); + pStatsGrp += PvlKeyword("MinLineShift", (dValue == Null ? "Null" : Isis::toString(dValue))); dValue = GetMaxLineShift(); - pStatsGrp += PvlKeyword("MaxLineShift", (dValue == Null ? "Null" : toString(dValue))); + pStatsGrp += PvlKeyword("MaxLineShift", (dValue == Null ? "Null" : Isis::toString(dValue))); dValue = GetMinSampleShift(); - pStatsGrp += PvlKeyword("MinSampleShift", (dValue == Null ? "Null" : toString(dValue))); + pStatsGrp += PvlKeyword("MinSampleShift", (dValue == Null ? "Null" : Isis::toString(dValue))); dValue = GetMaxSampleShift(); - pStatsGrp += PvlKeyword("MaxSampleShift", (dValue == Null ? "Null" : toString(dValue))); + pStatsGrp += PvlKeyword("MaxSampleShift", (dValue == Null ? "Null" : Isis::toString(dValue))); dValue = GetAvgPixelShift(); - pStatsGrp += PvlKeyword("AvgPixelShift", (dValue == Null ? "NA" : toString(dValue))); + pStatsGrp += PvlKeyword("AvgPixelShift", (dValue == Null ? "NA" : Isis::toString(dValue))); dValue = GetMinPixelShift(); - pStatsGrp += PvlKeyword("MinPixelShift", (dValue == Null ? "NA" : toString(dValue))); + pStatsGrp += PvlKeyword("MinPixelShift", (dValue == Null ? "NA" : Isis::toString(dValue))); dValue = GetMaxPixelShift(); - pStatsGrp += PvlKeyword("MaxPixelShift", (dValue == Null ? "NA" : toString(dValue))); + pStatsGrp += PvlKeyword("MaxPixelShift", (dValue == Null ? "NA" : Isis::toString(dValue))); dValue = mPointDoubleStats[minGFit]; - pStatsGrp += PvlKeyword("MinGoodnessOfFit", (dValue == Null ? "NA" : toString(dValue))); + pStatsGrp += PvlKeyword("MinGoodnessOfFit", (dValue == Null ? "NA" : Isis::toString(dValue))); dValue = mPointDoubleStats[maxGFit]; - pStatsGrp += PvlKeyword("MaxGoodnessOfFit", (dValue == Null ? "NA" : toString(dValue))); + pStatsGrp += PvlKeyword("MaxGoodnessOfFit", (dValue == Null ? "NA" : Isis::toString(dValue))); dValue = mPointDoubleStats[minEccentricity]; - pStatsGrp += PvlKeyword("MinEccentricity", (dValue == Null ? "NA" : toString(dValue))); + pStatsGrp += PvlKeyword("MinEccentricity", (dValue == Null ? "NA" : Isis::toString(dValue))); dValue = mPointDoubleStats[maxEccentricity]; - pStatsGrp += PvlKeyword("MaxEccentricity", (dValue == Null ? "NA" : toString(dValue))); + pStatsGrp += PvlKeyword("MaxEccentricity", (dValue == Null ? "NA" : Isis::toString(dValue))); dValue = mPointDoubleStats[minPixelZScore]; - pStatsGrp += PvlKeyword("MinPixelZScore", (dValue == Null ? "NA" : toString(dValue))); + pStatsGrp += PvlKeyword("MinPixelZScore", (dValue == Null ? "NA" : Isis::toString(dValue))); dValue = mPointDoubleStats[maxPixelZScore]; - pStatsGrp += PvlKeyword("MaxPixelZScore", (dValue == Null ? "NA" : toString(dValue))); + pStatsGrp += PvlKeyword("MaxPixelZScore", (dValue == Null ? "NA" : Isis::toString(dValue))); // Convex Hull if (mSerialNumList.size()) { dValue = mConvexHullRatioStats.Minimum(); - pStatsGrp += PvlKeyword("MinConvexHullRatio", (dValue == Null ? "Null" : toString(dValue))); + pStatsGrp += PvlKeyword("MinConvexHullRatio", (dValue == Null ? "Null" : Isis::toString(dValue))); dValue = mConvexHullRatioStats.Maximum(); - pStatsGrp += PvlKeyword("MaxConvexHullRatio", (dValue == Null ? "Null" : toString(dValue))); + pStatsGrp += PvlKeyword("MaxConvexHullRatio", (dValue == Null ? "Null" : Isis::toString(dValue))); dValue = mConvexHullRatioStats.Average(); - pStatsGrp += PvlKeyword("AvgConvexHullRatio", (dValue == Null ? "Null" : toString(dValue))); + pStatsGrp += PvlKeyword("AvgConvexHullRatio", (dValue == Null ? "Null" : Isis::toString(dValue))); } } diff --git a/isis/src/control/objs/ControlNetValidMeasure/ControlNetValidMeasure.cpp b/isis/src/control/objs/ControlNetValidMeasure/ControlNetValidMeasure.cpp index cff59f74e5..ea7c5b7117 100644 --- a/isis/src/control/objs/ControlNetValidMeasure/ControlNetValidMeasure.cpp +++ b/isis/src/control/objs/ControlNetValidMeasure/ControlNetValidMeasure.cpp @@ -95,25 +95,25 @@ namespace Isis { void ControlNetValidMeasure::InitStdOptionsGroup(void) { mStdOptionsGrp = PvlGroup("StandardOptions"); - mStdOptionsGrp += Isis::PvlKeyword("MinDN", (mdMinDN == Isis::ValidMinimum ? "NA" : toString(mdMinDN))); - mStdOptionsGrp += Isis::PvlKeyword("MaxDN", (mdMaxDN == Isis::ValidMaximum ? "NA" : toString(mdMaxDN))); - - mStdOptionsGrp += Isis::PvlKeyword("MinEmission", toString(mdMinEmissionAngle)); - mStdOptionsGrp += Isis::PvlKeyword("MaxEmission", toString(mdMaxEmissionAngle)); - mStdOptionsGrp += Isis::PvlKeyword("MinIncidence", toString(mdMinIncidenceAngle)); - mStdOptionsGrp += Isis::PvlKeyword("MaxIncidence", toString(mdMaxIncidenceAngle)); - mStdOptionsGrp += Isis::PvlKeyword("MinResolution", toString(mdMinResolution)); - mStdOptionsGrp += Isis::PvlKeyword("MaxResolution", (mdMaxResolution == DBL_MAX ? "NA" : toString(mdSampleResTolerance))); - mStdOptionsGrp += Isis::PvlKeyword("PixelsFromEdge", toString(miPixelsFromEdge)); - mStdOptionsGrp += Isis::PvlKeyword("MetersFromEdge", toString(mdMetersFromEdge)); - - mStdOptionsGrp += Isis::PvlKeyword("SampleResidual", (mdSampleResTolerance == DBL_MAX ? "NA" : toString(mdSampleResTolerance))); - mStdOptionsGrp += Isis::PvlKeyword("LineResidual", (mdLineResTolerance == DBL_MAX ? "NA" : toString(mdLineResTolerance))); - mStdOptionsGrp += Isis::PvlKeyword("ResidualMagnitude", (mdResidualTolerance == DBL_MAX ? "NA" : toString(mdResidualTolerance))); - - mStdOptionsGrp += Isis::PvlKeyword("SampleShift", (m_sampleShiftTolerance == DBL_MAX ? "NA" : toString(m_sampleShiftTolerance))); - mStdOptionsGrp += Isis::PvlKeyword("LineShift", (m_lineShiftTolerance == DBL_MAX ? "NA" : toString(m_lineShiftTolerance))); - mStdOptionsGrp += Isis::PvlKeyword("PixelShift", (m_pixelShiftTolerance == DBL_MAX ? "NA" : toString(m_pixelShiftTolerance))); + mStdOptionsGrp += Isis::PvlKeyword("MinDN", (mdMinDN == Isis::ValidMinimum ? "NA" : Isis::toString(mdMinDN))); + mStdOptionsGrp += Isis::PvlKeyword("MaxDN", (mdMaxDN == Isis::ValidMaximum ? "NA" : Isis::toString(mdMaxDN))); + + mStdOptionsGrp += Isis::PvlKeyword("MinEmission", Isis::toString(mdMinEmissionAngle)); + mStdOptionsGrp += Isis::PvlKeyword("MaxEmission", Isis::toString(mdMaxEmissionAngle)); + mStdOptionsGrp += Isis::PvlKeyword("MinIncidence", Isis::toString(mdMinIncidenceAngle)); + mStdOptionsGrp += Isis::PvlKeyword("MaxIncidence", Isis::toString(mdMaxIncidenceAngle)); + mStdOptionsGrp += Isis::PvlKeyword("MinResolution", Isis::toString(mdMinResolution)); + mStdOptionsGrp += Isis::PvlKeyword("MaxResolution", (mdMaxResolution == DBL_MAX ? "NA" : Isis::toString(mdSampleResTolerance))); + mStdOptionsGrp += Isis::PvlKeyword("PixelsFromEdge", Isis::toString(miPixelsFromEdge)); + mStdOptionsGrp += Isis::PvlKeyword("MetersFromEdge", Isis::toString(mdMetersFromEdge)); + + mStdOptionsGrp += Isis::PvlKeyword("SampleResidual", (mdSampleResTolerance == DBL_MAX ? "NA" : Isis::toString(mdSampleResTolerance))); + mStdOptionsGrp += Isis::PvlKeyword("LineResidual", (mdLineResTolerance == DBL_MAX ? "NA" : Isis::toString(mdLineResTolerance))); + mStdOptionsGrp += Isis::PvlKeyword("ResidualMagnitude", (mdResidualTolerance == DBL_MAX ? "NA" : Isis::toString(mdResidualTolerance))); + + mStdOptionsGrp += Isis::PvlKeyword("SampleShift", (m_sampleShiftTolerance == DBL_MAX ? "NA" : Isis::toString(m_sampleShiftTolerance))); + mStdOptionsGrp += Isis::PvlKeyword("LineShift", (m_lineShiftTolerance == DBL_MAX ? "NA" : Isis::toString(m_lineShiftTolerance))); + mStdOptionsGrp += Isis::PvlKeyword("PixelShift", (m_pixelShiftTolerance == DBL_MAX ? "NA" : Isis::toString(m_pixelShiftTolerance))); } /** @@ -262,9 +262,9 @@ namespace Isis { if(pMeasureGrp != NULL) { if(mbCameraRequired && (mdEmissionAngle != Null || mdIncidenceAngle != Null || mdResolution != Null)) { - *pMeasureGrp += Isis::PvlKeyword("EmissionAngle", toString(mdEmissionAngle)); - *pMeasureGrp += Isis::PvlKeyword("IncidenceAngle", toString(mdIncidenceAngle)); - *pMeasureGrp += Isis::PvlKeyword("Resolution", toString(mdResolution)); + *pMeasureGrp += Isis::PvlKeyword("EmissionAngle", Isis::toString(mdEmissionAngle)); + *pMeasureGrp += Isis::PvlKeyword("IncidenceAngle", Isis::toString(mdIncidenceAngle)); + *pMeasureGrp += Isis::PvlKeyword("Resolution", Isis::toString(mdResolution)); } else { *pMeasureGrp += Isis::PvlKeyword("EmissionAngle", "Invalid Emission Angle"); @@ -272,15 +272,15 @@ namespace Isis { *pMeasureGrp += Isis::PvlKeyword("Resolution", "Invalid Resolution"); } if(mbValidateDN) { - *pMeasureGrp += Isis::PvlKeyword("DNValue", toString(mdDnValue)); + *pMeasureGrp += Isis::PvlKeyword("DNValue", Isis::toString(mdDnValue)); } - *pMeasureGrp += Isis::PvlKeyword("SampleResidual", toString(mdSampleResidual)); - *pMeasureGrp += Isis::PvlKeyword("LineResidual", toString(mdLineResidual)); - *pMeasureGrp += Isis::PvlKeyword("ResidualMagnitude", toString(mdResidualMagnitude)); + *pMeasureGrp += Isis::PvlKeyword("SampleResidual", Isis::toString(mdSampleResidual)); + *pMeasureGrp += Isis::PvlKeyword("LineResidual", Isis::toString(mdLineResidual)); + *pMeasureGrp += Isis::PvlKeyword("ResidualMagnitude", Isis::toString(mdResidualMagnitude)); - *pMeasureGrp += Isis::PvlKeyword("SampleShift", toString(m_sampleShift)); - *pMeasureGrp += Isis::PvlKeyword("LineShift", toString(m_lineShift)); - *pMeasureGrp += Isis::PvlKeyword("PixelShift", toString(m_pixelShift)); + *pMeasureGrp += Isis::PvlKeyword("SampleShift", Isis::toString(m_sampleShift)); + *pMeasureGrp += Isis::PvlKeyword("LineShift", Isis::toString(m_lineShift)); + *pMeasureGrp += Isis::PvlKeyword("PixelShift", Isis::toString(m_pixelShift)); } MeasureValidationResults results; @@ -401,7 +401,7 @@ namespace Isis { else { mbValidateFromEdge = true; } - mStdOptionsGrp += Isis::PvlKeyword("PixelsFromEdge", toString(miPixelsFromEdge)); + mStdOptionsGrp += Isis::PvlKeyword("PixelsFromEdge", Isis::toString(miPixelsFromEdge)); } // Parse the Meters from edge if(mPvlOpGrp.hasKeyword("MetersFromEdge")) { @@ -412,7 +412,7 @@ namespace Isis { else { mbValidateFromEdge = true; } - mStdOptionsGrp += Isis::PvlKeyword("MetersFromEdge", toString(mdMetersFromEdge)); + mStdOptionsGrp += Isis::PvlKeyword("MetersFromEdge", Isis::toString(mdMetersFromEdge)); } } @@ -431,7 +431,7 @@ namespace Isis { else { mdMinResolution = 0; } - mStdOptionsGrp += Isis::PvlKeyword("MinResolution", toString(mdMinResolution)); + mStdOptionsGrp += Isis::PvlKeyword("MinResolution", Isis::toString(mdMinResolution)); if(mPvlOpGrp.hasKeyword("MaxResolution")){ mdMaxResolution = mPvlOpGrp["MaxResolution"]; @@ -440,7 +440,7 @@ namespace Isis { else { mdMaxResolution = DBL_MAX; } - mStdOptionsGrp += Isis::PvlKeyword("MaxResolution", (mdMaxResolution == DBL_MAX ? "NA" : toString(mdMaxResolution))); + mStdOptionsGrp += Isis::PvlKeyword("MaxResolution", (mdMaxResolution == DBL_MAX ? "NA" : Isis::toString(mdMaxResolution))); if(mdMinResolution < 0 || mdMaxResolution < 0) { std::string msg = "Invalid Resolution value(s), Resolution must be greater than zero"; @@ -469,7 +469,7 @@ namespace Isis { else { mdMinDN = Isis::ValidMinimum; } - mStdOptionsGrp += Isis::PvlKeyword("MinDN", (mdMinDN == Isis::ValidMinimum ? "NA" : toString(mdMinDN))); + mStdOptionsGrp += Isis::PvlKeyword("MinDN", (mdMinDN == Isis::ValidMinimum ? "NA" : Isis::toString(mdMinDN))); if(mPvlOpGrp.hasKeyword("MaxDN")) { mdMaxDN = mPvlOpGrp["MaxDN"]; @@ -478,7 +478,7 @@ namespace Isis { else { mdMaxDN = Isis::ValidMaximum; } - mStdOptionsGrp += Isis::PvlKeyword("MaxDN", (mdMaxDN == Isis::ValidMaximum ? "NA" : toString(mdMaxDN))); + mStdOptionsGrp += Isis::PvlKeyword("MaxDN", (mdMaxDN == Isis::ValidMaximum ? "NA" : Isis::toString(mdMaxDN))); if(mdMaxDN < mdMinDN) { std::string msg = "MinDN must be less than MaxDN"; @@ -503,7 +503,7 @@ namespace Isis { throw IException(IException::User, msg, _FILEINFO_); } } - mStdOptionsGrp += Isis::PvlKeyword("MinEmission", toString(mdMinEmissionAngle)); + mStdOptionsGrp += Isis::PvlKeyword("MinEmission", Isis::toString(mdMinEmissionAngle)); if(mPvlOpGrp.hasKeyword("MaxEmission")) { mdMaxEmissionAngle = mPvlOpGrp["MaxEmission"]; @@ -513,7 +513,7 @@ namespace Isis { throw IException(IException::User, msg, _FILEINFO_); } } - mStdOptionsGrp += Isis::PvlKeyword("MaxEmission", toString(mdMaxEmissionAngle)); + mStdOptionsGrp += Isis::PvlKeyword("MaxEmission", Isis::toString(mdMaxEmissionAngle)); if(mdMaxEmissionAngle < mdMinEmissionAngle) { std::string msg = "Min EmissionAngle must be less than Max EmissionAngle"; @@ -539,7 +539,7 @@ namespace Isis { throw IException(IException::User, msg, _FILEINFO_); } } - mStdOptionsGrp += Isis::PvlKeyword("MinIncidence", toString(mdMinIncidenceAngle)); + mStdOptionsGrp += Isis::PvlKeyword("MinIncidence", Isis::toString(mdMinIncidenceAngle)); if(mPvlOpGrp.hasKeyword("MaxIncidence")) { mdMaxIncidenceAngle = mPvlOpGrp["MaxIncidence"]; @@ -549,7 +549,7 @@ namespace Isis { throw IException(IException::User, msg, _FILEINFO_); } } - mStdOptionsGrp += Isis::PvlKeyword("MaxIncidence", toString(mdMaxIncidenceAngle)); + mStdOptionsGrp += Isis::PvlKeyword("MaxIncidence", Isis::toString(mdMaxIncidenceAngle)); if(mdMaxIncidenceAngle < mdMinIncidenceAngle) { std::string msg = "Min IncidenceAngle must be less than Max IncidenceAngle"; @@ -573,7 +573,7 @@ namespace Isis { } bRes = true; } - mStdOptionsGrp += Isis::PvlKeyword("SampleResidual", (mdSampleResTolerance == DBL_MAX ? "NA" : toString(mdSampleResTolerance))); + mStdOptionsGrp += Isis::PvlKeyword("SampleResidual", (mdSampleResTolerance == DBL_MAX ? "NA" : Isis::toString(mdSampleResTolerance))); if(mPvlOpGrp.hasKeyword("LineResidual")) { mdLineResTolerance = mPvlOpGrp["LineResidual"]; @@ -583,7 +583,7 @@ namespace Isis { } bRes = true; } - mStdOptionsGrp += Isis::PvlKeyword("LineResidual", (mdLineResTolerance == DBL_MAX ? "NA" : toString(mdLineResTolerance))); + mStdOptionsGrp += Isis::PvlKeyword("LineResidual", (mdLineResTolerance == DBL_MAX ? "NA" : Isis::toString(mdLineResTolerance))); if(mPvlOpGrp.hasKeyword("ResidualMagnitude")) { mdResidualTolerance = mPvlOpGrp["ResidualMagnitude"]; @@ -593,7 +593,7 @@ namespace Isis { } bResMag = true; } - mStdOptionsGrp += Isis::PvlKeyword("ResidualMagnitude", (mdResidualTolerance == DBL_MAX ? "NA" : toString(mdResidualTolerance))); + mStdOptionsGrp += Isis::PvlKeyword("ResidualMagnitude", (mdResidualTolerance == DBL_MAX ? "NA" : Isis::toString(mdResidualTolerance))); if(bRes && bResMag) { std::string msg = "Cannot have both Sample/Line Residuals and Residual Magnitude."; @@ -618,7 +618,7 @@ namespace Isis { } hasSampleLineShift = true; } - mStdOptionsGrp += Isis::PvlKeyword("SampleShift", (m_sampleShiftTolerance == DBL_MAX ? "NA" : toString(m_sampleShiftTolerance))); + mStdOptionsGrp += Isis::PvlKeyword("SampleShift", (m_sampleShiftTolerance == DBL_MAX ? "NA" : Isis::toString(m_sampleShiftTolerance))); if (mPvlOpGrp.hasKeyword("LineShift")) { m_lineShiftTolerance = mPvlOpGrp["LineShift"]; @@ -629,7 +629,7 @@ namespace Isis { } hasSampleLineShift = true; } - mStdOptionsGrp += Isis::PvlKeyword("LineShift", (m_lineShiftTolerance == DBL_MAX ? "NA" : toString(m_lineShiftTolerance))); + mStdOptionsGrp += Isis::PvlKeyword("LineShift", (m_lineShiftTolerance == DBL_MAX ? "NA" : Isis::toString(m_lineShiftTolerance))); bool hasPixelShift = false; if (mPvlOpGrp.hasKeyword("PixelShift")) { @@ -641,7 +641,7 @@ namespace Isis { } hasPixelShift = true; } - mStdOptionsGrp += Isis::PvlKeyword("PixelShift", (m_pixelShiftTolerance == DBL_MAX ? "NA" : toString(m_pixelShiftTolerance))); + mStdOptionsGrp += Isis::PvlKeyword("PixelShift", (m_pixelShiftTolerance == DBL_MAX ? "NA" : Isis::toString(m_pixelShiftTolerance))); if (hasSampleLineShift && hasPixelShift) { std::string msg = "Cannot have both Sample/Line Shift and Pixel Shift"; diff --git a/isis/src/control/objs/ControlNetValidMeasure/unitTest.cpp b/isis/src/control/objs/ControlNetValidMeasure/unitTest.cpp index 595deacf96..e4e8f94fce 100644 --- a/isis/src/control/objs/ControlNetValidMeasure/unitTest.cpp +++ b/isis/src/control/objs/ControlNetValidMeasure/unitTest.cpp @@ -20,17 +20,17 @@ int main(void) { Pvl pvlLog; PvlGroup op("ValidMeasure"); op += PvlKeyword("Name", "StandardDeviation"); - op += PvlKeyword("DeltaLine", toString(100)); - op += PvlKeyword("DeltaSamp", toString(100)); - op += PvlKeyword("Samples", toString(15)); - op += PvlKeyword("Lines", toString(15)); - op += PvlKeyword("MinimumInterest", toString(0.01)); - op += PvlKeyword("MinDN", toString(1.0)); - op += PvlKeyword("MaxDN", toString(-1.0)); - op += PvlKeyword("MinEmission", toString(15.0)); - op += PvlKeyword("MaxEmission", toString(25.0)); - op += PvlKeyword("MinIncidence", toString(0.0)); - op += PvlKeyword("MaxIncidence", toString(135.0)); + op += PvlKeyword("DeltaLine", Isis::toString(100)); + op += PvlKeyword("DeltaSamp", Isis::toString(100)); + op += PvlKeyword("Samples", Isis::toString(15)); + op += PvlKeyword("Lines", Isis::toString(15)); + op += PvlKeyword("MinimumInterest", Isis::toString(0.01)); + op += PvlKeyword("MinDN", Isis::toString(1.0)); + op += PvlKeyword("MaxDN", Isis::toString(-1.0)); + op += PvlKeyword("MinEmission", Isis::toString(15.0)); + op += PvlKeyword("MaxEmission", Isis::toString(25.0)); + op += PvlKeyword("MinIncidence", Isis::toString(0.0)); + op += PvlKeyword("MaxIncidence", Isis::toString(135.0)); pvlLog += op; @@ -45,12 +45,12 @@ int main(void) { Pvl pvlLog; PvlGroup op("ValidMeasure"); op += PvlKeyword("Name", "None"); - op += PvlKeyword("MinDN", toString(-1.0)); - op += PvlKeyword("MaxDN", toString(1.0)); - op += PvlKeyword("MinEmission", toString(25.0)); - op += PvlKeyword("MaxEmission", toString(15.0)); - op += PvlKeyword("MinIncidence", toString(0.0)); - op += PvlKeyword("MaxIncidence", toString(135.0)); + op += PvlKeyword("MinDN", Isis::toString(-1.0)); + op += PvlKeyword("MaxDN", Isis::toString(1.0)); + op += PvlKeyword("MinEmission", Isis::toString(25.0)); + op += PvlKeyword("MaxEmission", Isis::toString(15.0)); + op += PvlKeyword("MinIncidence", Isis::toString(0.0)); + op += PvlKeyword("MaxIncidence", Isis::toString(135.0)); pvlLog += op; @@ -65,17 +65,17 @@ int main(void) { Pvl pvlLog; PvlGroup op("ValidMeasure"); op += PvlKeyword("Name", "StandardDeviation"); - op += PvlKeyword("DeltaLine", toString(100)); - op += PvlKeyword("DeltaSamp", toString(100)); - op += PvlKeyword("Samples", toString(15)); - op += PvlKeyword("Lines", toString(15)); - op += PvlKeyword("MinimumInterest", toString(0.01)); - op += PvlKeyword("MinDN", toString(-1.0)); - op += PvlKeyword("MaxDN", toString(1.0)); - op += PvlKeyword("MinEmission", toString(0.0)); - op += PvlKeyword("MaxEmission", toString(135.0)); - op += PvlKeyword("MinIncidence", toString(0.0)); - op += PvlKeyword("MaxIncidence", toString(150.0)); + op += PvlKeyword("DeltaLine", Isis::toString(100)); + op += PvlKeyword("DeltaSamp", Isis::toString(100)); + op += PvlKeyword("Samples", Isis::toString(15)); + op += PvlKeyword("Lines", Isis::toString(15)); + op += PvlKeyword("MinimumInterest", Isis::toString(0.01)); + op += PvlKeyword("MinDN", Isis::toString(-1.0)); + op += PvlKeyword("MaxDN", Isis::toString(1.0)); + op += PvlKeyword("MinEmission", Isis::toString(0.0)); + op += PvlKeyword("MaxEmission", Isis::toString(135.0)); + op += PvlKeyword("MinIncidence", Isis::toString(0.0)); + op += PvlKeyword("MaxIncidence", Isis::toString(150.0)); pvlLog += op; @@ -90,14 +90,14 @@ int main(void) { Pvl pvlLog; PvlGroup op("ValidMeasure"); op += PvlKeyword("Name", "None"); - op += PvlKeyword("MinDN", toString(-1.0)); - op += PvlKeyword("MaxDN", toString(1.0)); - op += PvlKeyword("MinEmission", toString(0.0)); - op += PvlKeyword("MaxEmission", toString(135.0)); - op += PvlKeyword("MinIncidence", toString(0.0)); - op += PvlKeyword("MaxIncidence", toString(135.0)); - op += PvlKeyword("MinResolution", toString(100.0)); - op += PvlKeyword("MaxResolution", toString(-1.0)); + op += PvlKeyword("MinDN", Isis::toString(-1.0)); + op += PvlKeyword("MaxDN", Isis::toString(1.0)); + op += PvlKeyword("MinEmission", Isis::toString(0.0)); + op += PvlKeyword("MaxEmission", Isis::toString(135.0)); + op += PvlKeyword("MinIncidence", Isis::toString(0.0)); + op += PvlKeyword("MaxIncidence", Isis::toString(135.0)); + op += PvlKeyword("MinResolution", Isis::toString(100.0)); + op += PvlKeyword("MaxResolution", Isis::toString(-1.0)); pvlLog += op; @@ -112,19 +112,19 @@ int main(void) { Pvl pvlLog; PvlGroup op("ValidMeasure"); op += PvlKeyword("Name", "None"); - op += PvlKeyword("MinDN", toString(-1.0)); - op += PvlKeyword("MaxDN", toString(1.0)); - op += PvlKeyword("MinEmission", toString(0.0)); - op += PvlKeyword("MaxEmission", toString(135.0)); - op += PvlKeyword("MinIncidence", toString(0.0)); - op += PvlKeyword("MaxIncidence", toString(135.0)); - op += PvlKeyword("MinResolution", toString(100.0)); - op += PvlKeyword("MaxResolution", toString(500.0)); - op += PvlKeyword("SampleResidual", toString(5.0)); - op += PvlKeyword("LineResidual", toString(5.0)); - op += PvlKeyword("ResidualMagnitude", toString(10.0)); - op += PvlKeyword("SampleShift", toString(5.0)); - op += PvlKeyword("LineShift", toString(5.0)); + op += PvlKeyword("MinDN", Isis::toString(-1.0)); + op += PvlKeyword("MaxDN", Isis::toString(1.0)); + op += PvlKeyword("MinEmission", Isis::toString(0.0)); + op += PvlKeyword("MaxEmission", Isis::toString(135.0)); + op += PvlKeyword("MinIncidence", Isis::toString(0.0)); + op += PvlKeyword("MaxIncidence", Isis::toString(135.0)); + op += PvlKeyword("MinResolution", Isis::toString(100.0)); + op += PvlKeyword("MaxResolution", Isis::toString(500.0)); + op += PvlKeyword("SampleResidual", Isis::toString(5.0)); + op += PvlKeyword("LineResidual", Isis::toString(5.0)); + op += PvlKeyword("ResidualMagnitude", Isis::toString(10.0)); + op += PvlKeyword("SampleShift", Isis::toString(5.0)); + op += PvlKeyword("LineShift", Isis::toString(5.0)); pvlLog += op; @@ -139,19 +139,19 @@ int main(void) { Pvl pvlLog; PvlGroup op("ValidMeasure"); op += PvlKeyword("Name", "None"); - op += PvlKeyword("MinDN", toString(-1.0)); - op += PvlKeyword("MaxDN", toString(1.0)); - op += PvlKeyword("MinEmission", toString(0.0)); - op += PvlKeyword("MaxEmission", toString(135.0)); - op += PvlKeyword("MinIncidence", toString(0.0)); - op += PvlKeyword("MaxIncidence", toString(135.0)); - op += PvlKeyword("MinResolution", toString(100.0)); - op += PvlKeyword("MaxResolution", toString(500.0)); - op += PvlKeyword("SampleResidual", toString(5.0)); - op += PvlKeyword("LineResidual", toString(5.0)); - op += PvlKeyword("SampleShift", toString(5.0)); - op += PvlKeyword("LineShift", toString(5.0)); - op += PvlKeyword("PixelShift", toString(10.0)); + op += PvlKeyword("MinDN", Isis::toString(-1.0)); + op += PvlKeyword("MaxDN", Isis::toString(1.0)); + op += PvlKeyword("MinEmission", Isis::toString(0.0)); + op += PvlKeyword("MaxEmission", Isis::toString(135.0)); + op += PvlKeyword("MinIncidence", Isis::toString(0.0)); + op += PvlKeyword("MaxIncidence", Isis::toString(135.0)); + op += PvlKeyword("MinResolution", Isis::toString(100.0)); + op += PvlKeyword("MaxResolution", Isis::toString(500.0)); + op += PvlKeyword("SampleResidual", Isis::toString(5.0)); + op += PvlKeyword("LineResidual", Isis::toString(5.0)); + op += PvlKeyword("SampleShift", Isis::toString(5.0)); + op += PvlKeyword("LineShift", Isis::toString(5.0)); + op += PvlKeyword("PixelShift", Isis::toString(10.0)); pvlLog += op; @@ -166,18 +166,18 @@ int main(void) { Pvl pvlLog; PvlGroup op("ValidMeasure"); op += PvlKeyword("Name", "None"); - op += PvlKeyword("MinDN", toString(-1.0)); - op += PvlKeyword("MaxDN", toString(1.0)); - op += PvlKeyword("MinEmission", toString(0.0)); - op += PvlKeyword("MaxEmission", toString(135.0)); - op += PvlKeyword("MinIncidence", toString(0.0)); - op += PvlKeyword("MaxIncidence", toString(135.0)); - op += PvlKeyword("MinResolution", toString(100.0)); - op += PvlKeyword("MaxResolution", toString(500.0)); - op += PvlKeyword("SampleResidual", toString(5.0)); - op += PvlKeyword("LineResidual", toString(5.0)); - op += PvlKeyword("SampleShift", toString(5.0)); - op += PvlKeyword("LineShift", toString(5.0)); + op += PvlKeyword("MinDN", Isis::toString(-1.0)); + op += PvlKeyword("MaxDN", Isis::toString(1.0)); + op += PvlKeyword("MinEmission", Isis::toString(0.0)); + op += PvlKeyword("MaxEmission", Isis::toString(135.0)); + op += PvlKeyword("MinIncidence", Isis::toString(0.0)); + op += PvlKeyword("MaxIncidence", Isis::toString(135.0)); + op += PvlKeyword("MinResolution", Isis::toString(100.0)); + op += PvlKeyword("MaxResolution", Isis::toString(500.0)); + op += PvlKeyword("SampleResidual", Isis::toString(5.0)); + op += PvlKeyword("LineResidual", Isis::toString(5.0)); + op += PvlKeyword("SampleShift", Isis::toString(5.0)); + op += PvlKeyword("LineShift", Isis::toString(5.0)); pvlLog += op; diff --git a/isis/src/control/objs/ControlNetVersioner/ControlNetVersioner.cpp b/isis/src/control/objs/ControlNetVersioner/ControlNetVersioner.cpp index 8bbe90954a..1543fe2357 100644 --- a/isis/src/control/objs/ControlNetVersioner/ControlNetVersioner.cpp +++ b/isis/src/control/objs/ControlNetVersioner/ControlNetVersioner.cpp @@ -305,19 +305,19 @@ namespace Isis { // add surface point x/y/z, convert to lat,lon,radius and output as comment SurfacePoint aprioriSurfacePoint = controlPoint->GetAprioriSurfacePoint(); if ( aprioriSurfacePoint.Valid() ) { - PvlKeyword aprioriX("AprioriX", toString(aprioriSurfacePoint.GetX().meters()), "meters"); - PvlKeyword aprioriY("AprioriY", toString(aprioriSurfacePoint.GetY().meters()), "meters"); - PvlKeyword aprioriZ("AprioriZ", toString(aprioriSurfacePoint.GetZ().meters()), "meters"); + PvlKeyword aprioriX("AprioriX", Isis::toString(aprioriSurfacePoint.GetX().meters()), "meters"); + PvlKeyword aprioriY("AprioriY", Isis::toString(aprioriSurfacePoint.GetY().meters()), "meters"); + PvlKeyword aprioriZ("AprioriZ", Isis::toString(aprioriSurfacePoint.GetZ().meters()), "meters"); aprioriX.addComment("AprioriLatitude = " - + toString(aprioriSurfacePoint.GetLatitude().degrees()) + + Isis::toString(aprioriSurfacePoint.GetLatitude().degrees()) + " "); aprioriY.addComment("AprioriLongitude = " - + toString(aprioriSurfacePoint.GetLongitude().degrees()) + + Isis::toString(aprioriSurfacePoint.GetLongitude().degrees()) + " "); aprioriZ.addComment("AprioriRadius = " - + toString(aprioriSurfacePoint.GetLocalRadius().meters()) + + Isis::toString(aprioriSurfacePoint.GetLocalRadius().meters()) + " "); pvlPoint += aprioriX; @@ -331,12 +331,12 @@ namespace Isis { // Matrix units are meters squared PvlKeyword matrix("AprioriCovarianceMatrix"); - matrix += toString(aprioriCovarianceMatrix(0, 0)); - matrix += toString(aprioriCovarianceMatrix(0, 1)); - matrix += toString(aprioriCovarianceMatrix(0, 2)); - matrix += toString(aprioriCovarianceMatrix(1, 1)); - matrix += toString(aprioriCovarianceMatrix(1, 2)); - matrix += toString(aprioriCovarianceMatrix(2, 2)); + matrix += Isis::toString(aprioriCovarianceMatrix(0, 0)); + matrix += Isis::toString(aprioriCovarianceMatrix(0, 1)); + matrix += Isis::toString(aprioriCovarianceMatrix(0, 2)); + matrix += Isis::toString(aprioriCovarianceMatrix(1, 1)); + matrix += Isis::toString(aprioriCovarianceMatrix(1, 2)); + matrix += Isis::toString(aprioriCovarianceMatrix(2, 2)); // *** TODO *** What do we do in the case of bundled in rectangular coordinates? // For now we do nothing. @@ -385,20 +385,20 @@ namespace Isis { SurfacePoint adjustedSurfacePoint = controlPoint->GetAdjustedSurfacePoint(); if ( adjustedSurfacePoint.Valid() ) { PvlKeyword adjustedX("AdjustedX", - toString(adjustedSurfacePoint.GetX().meters()), "meters"); + Isis::toString(adjustedSurfacePoint.GetX().meters()), "meters"); PvlKeyword adjustedY("AdjustedY", - toString(adjustedSurfacePoint.GetY().meters()), "meters"); + Isis::toString(adjustedSurfacePoint.GetY().meters()), "meters"); PvlKeyword adjustedZ("AdjustedZ", - toString(adjustedSurfacePoint.GetZ().meters()), "meters"); + Isis::toString(adjustedSurfacePoint.GetZ().meters()), "meters"); adjustedX.addComment("AdjustedLatitude = " - + toString(adjustedSurfacePoint.GetLatitude().degrees()) + + Isis::toString(adjustedSurfacePoint.GetLatitude().degrees()) + " "); adjustedY.addComment("AdjustedLongitude = " - + toString(adjustedSurfacePoint.GetLongitude().degrees()) + + Isis::toString(adjustedSurfacePoint.GetLongitude().degrees()) + " "); adjustedZ.addComment("AdjustedRadius = " - + toString(adjustedSurfacePoint.GetLocalRadius().meters()) + + Isis::toString(adjustedSurfacePoint.GetLocalRadius().meters()) + " "); pvlPoint += adjustedX; @@ -411,12 +411,12 @@ namespace Isis { if ( adjustedCovarianceMatrix.size1() > 0 ) { PvlKeyword matrix("AdjustedCovarianceMatrix"); - matrix += toString(adjustedCovarianceMatrix(0, 0)); - matrix += toString(adjustedCovarianceMatrix(0, 1)); - matrix += toString(adjustedCovarianceMatrix(0, 2)); - matrix += toString(adjustedCovarianceMatrix(1, 1)); - matrix += toString(adjustedCovarianceMatrix(1, 2)); - matrix += toString(adjustedCovarianceMatrix(2, 2)); + matrix += Isis::toString(adjustedCovarianceMatrix(0, 0)); + matrix += Isis::toString(adjustedCovarianceMatrix(0, 1)); + matrix += Isis::toString(adjustedCovarianceMatrix(0, 2)); + matrix += Isis::toString(adjustedCovarianceMatrix(1, 1)); + matrix += Isis::toString(adjustedCovarianceMatrix(1, 2)); + matrix += Isis::toString(adjustedCovarianceMatrix(2, 2)); if ( adjustedSurfacePoint.GetLatSigmaDistance().meters() != Isis::Null && adjustedSurfacePoint.GetLonSigmaDistance().meters() != Isis::Null @@ -480,50 +480,50 @@ namespace Isis { } if ( controlMeasure.GetSample() != Isis::Null) { - pvlMeasure += PvlKeyword("Sample", toString(controlMeasure.GetSample())); + pvlMeasure += PvlKeyword("Sample", Isis::toString(controlMeasure.GetSample())); } if ( controlMeasure.GetLine() != Isis::Null ) { - pvlMeasure += PvlKeyword("Line", toString(controlMeasure.GetLine())); + pvlMeasure += PvlKeyword("Line", Isis::toString(controlMeasure.GetLine())); } if ( controlMeasure.GetDiameter() != Isis::Null && controlMeasure.GetDiameter() != 0. ) { - pvlMeasure += PvlKeyword("Diameter", toString(controlMeasure.GetDiameter())); + pvlMeasure += PvlKeyword("Diameter", Isis::toString(controlMeasure.GetDiameter())); } if ( controlMeasure.GetAprioriSample() != Isis::Null ) { - pvlMeasure += PvlKeyword("AprioriSample", toString(controlMeasure.GetAprioriSample())); + pvlMeasure += PvlKeyword("AprioriSample", Isis::toString(controlMeasure.GetAprioriSample())); } if ( controlMeasure.GetAprioriLine() != Isis::Null ) { - pvlMeasure += PvlKeyword("AprioriLine", toString(controlMeasure.GetAprioriLine())); + pvlMeasure += PvlKeyword("AprioriLine", Isis::toString(controlMeasure.GetAprioriLine())); } if ( controlMeasure.GetSampleSigma() != Isis::Null ) { - pvlMeasure += PvlKeyword("SampleSigma", toString(controlMeasure.GetSampleSigma()), + pvlMeasure += PvlKeyword("SampleSigma", Isis::toString(controlMeasure.GetSampleSigma()), "pixels"); } if ( controlMeasure.GetLineSigma() != Isis::Null ) { - pvlMeasure += PvlKeyword("LineSigma", toString(controlMeasure.GetLineSigma()), + pvlMeasure += PvlKeyword("LineSigma", Isis::toString(controlMeasure.GetLineSigma()), "pixels"); } if ( controlMeasure.GetSampleResidual() != Isis::Null ) { pvlMeasure += PvlKeyword("SampleResidual", - toString(controlMeasure.GetSampleResidual()), + Isis::toString(controlMeasure.GetSampleResidual()), "pixels"); } if ( controlMeasure.GetLineResidual() != Isis::Null ) { - pvlMeasure += PvlKeyword("LineResidual", toString(controlMeasure.GetLineResidual()), + pvlMeasure += PvlKeyword("LineResidual", Isis::toString(controlMeasure.GetLineResidual()), "pixels"); } if ( controlMeasure.IsRejected() ) { - pvlMeasure += PvlKeyword("JigsawRejected", toString(controlMeasure.IsRejected())); + pvlMeasure += PvlKeyword("JigsawRejected", Isis::toString(controlMeasure.IsRejected())); } foreach (ControlMeasureLogData log, controlMeasure.GetLogDataEntries()) { @@ -587,7 +587,7 @@ namespace Isis { int version = 1; if ( controlNetwork.hasKeyword("Version") ) { - version = IString::ToInteger(controlNetwork["Version"][0]); + version = Isis::toInt(controlNetwork["Version"][0]); } switch ( version ) { @@ -607,7 +607,7 @@ namespace Isis { readPvlV0005(controlNetwork, progress); break; default: - std::string msg = "The Pvl file version [" + toString(version) + std::string msg = "The Pvl file version [" + Isis::toString(version) + "] is not supported"; throw IException(IException::Unknown, msg, _FILEINFO_); } @@ -660,7 +660,7 @@ namespace Isis { } catch (IException &e) { std::string msg = "Failed to initialize control point at index [" - + toString(objectIndex) + "]."; + + Isis::toString(objectIndex) + "]."; throw IException(e, IException::Io, msg, _FILEINFO_); } } @@ -711,7 +711,7 @@ namespace Isis { } catch (IException &e) { std::string msg = "Failed to initialize control point at index [" - + toString(objectIndex) + "]."; + + Isis::toString(objectIndex) + "]."; throw IException(e, IException::Io, msg, _FILEINFO_); } } @@ -761,7 +761,7 @@ namespace Isis { } catch (IException &e) { std::string msg = "Failed to initialize control point at index [" - + toString(objectIndex) + "]."; + + Isis::toString(objectIndex) + "]."; throw IException(e, IException::Io, msg, _FILEINFO_); } } @@ -810,7 +810,7 @@ namespace Isis { } catch (IException &e) { std::string msg = "Failed to initialize control point at index [" - + toString(objectIndex) + "]."; + + Isis::toString(objectIndex) + "]."; throw IException(e, IException::Io, msg, _FILEINFO_); } } @@ -859,7 +859,7 @@ namespace Isis { } catch (IException &e) { std::string msg = "Failed to initialize control point at index [" - + toString(objectIndex) + "]."; + + Isis::toString(objectIndex) + "]."; throw IException(e, IException::Io, msg, _FILEINFO_); } } @@ -883,7 +883,7 @@ namespace Isis { const PvlGroup &netInfo = protoBuf.findGroup("ControlNetworkInfo"); if ( netInfo.hasKeyword("Version") ) { - version = IString::ToInteger(netInfo["Version"][0]); + version = Isis::toInt(netInfo["Version"][0]); } switch ( version ) { case 1: @@ -896,7 +896,7 @@ namespace Isis { readProtobufV0005(header, netFile, progress); break; default: - std::string msg = "The Protobuf file version [" + toString(version) + std::string msg = "The Protobuf file version [" + Isis::toString(version) + "] is not supported"; throw IException(IException::Io, msg, _FILEINFO_); } @@ -1019,7 +1019,7 @@ namespace Isis { } catch (IException &e) { std::string msg = "Failed to convert version 1 protobuf control point at index [" - + toString(i) + "] into a ControlPoint."; + + Isis::toString(i) + "] into a ControlPoint."; throw IException(e, IException::User, msg, _FILEINFO_); } } @@ -1121,7 +1121,7 @@ namespace Isis { } catch (...) { std::string msg = "Failed to read protobuf version 2 control point at index [" - + toString(pointIndex) + "]."; + + Isis::toString(pointIndex) + "]."; throw IException(IException::Io, msg, _FILEINFO_); } @@ -1136,7 +1136,7 @@ namespace Isis { } catch (IException &e) { std::string msg = "Failed to convert protobuf version 2 control point at index [" - + toString(pointIndex) + "] into a ControlPoint."; + + Isis::toString(pointIndex) + "] into a ControlPoint."; throw IException(e, IException::Io, msg, _FILEINFO_); } } @@ -1270,7 +1270,7 @@ namespace Isis { } catch (...) { std::string msg = "Failed to read protobuf version 2 control point at index [" - + toString(pointIndex) + "]."; + + Isis::toString(pointIndex) + "]."; throw IException(IException::Io, msg, _FILEINFO_); } @@ -1285,7 +1285,7 @@ namespace Isis { } catch (IException &e) { std::string msg = "Failed to convert protobuf version 2 control point at index [" - + toString(pointIndex) + "] into a ControlPoint."; + + Isis::toString(pointIndex) + "] into a ControlPoint."; throw IException(e, IException::Io, msg, _FILEINFO_); } } @@ -1367,7 +1367,7 @@ namespace Isis { break; default: std::string msg = "Unable to create ControlPoint [" + protoPoint.id() - + "] from file. Type enumeration [" + toString((int)(protoPoint.type())) + + "] from file. Type enumeration [" + Isis::toString((int)(protoPoint.type())) + "] is invalid."; throw IException(IException::Programmer, msg, _FILEINFO_); break; @@ -1697,15 +1697,15 @@ namespace Isis { PvlObject protoCore("Core"); protoCore.addKeyword(PvlKeyword("HeaderStartByte", - toString(((BigInt) startCoreHeaderPos)))); - protoCore.addKeyword(PvlKeyword("HeaderBytes", toString(((BigInt) coreHeaderSize)))); + Isis::toString(((BigInt) startCoreHeaderPos)))); + protoCore.addKeyword(PvlKeyword("HeaderBytes", Isis::toString(((BigInt) coreHeaderSize)))); BigInt pointsStartByte = (BigInt) (startCoreHeaderPos + coreHeaderSize); - protoCore.addKeyword(PvlKeyword("PointsStartByte", toString((pointsStartByte)))); + protoCore.addKeyword(PvlKeyword("PointsStartByte", Isis::toString((pointsStartByte)))); protoCore.addKeyword(PvlKeyword("PointsBytes", - toString(pointByteTotal))); + Isis::toString(pointByteTotal))); protoObj.addObject(protoCore); PvlGroup netInfo("ControlNetworkInfo"); @@ -1716,8 +1716,8 @@ namespace Isis { netInfo += PvlKeyword("Created", protobufHeader.created()); netInfo += PvlKeyword("LastModified", protobufHeader.lastmodified()); netInfo += PvlKeyword("Description", protobufHeader.description()); - netInfo += PvlKeyword("NumberOfPoints", toString(numPoints)); - netInfo += PvlKeyword("NumberOfMeasures", toString(numMeasures)); + netInfo += PvlKeyword("NumberOfPoints", Isis::toString(numPoints)); + netInfo += PvlKeyword("NumberOfMeasures", Isis::toString(numMeasures)); netInfo += PvlKeyword("Version", "5"); protoObj.addGroup(netInfo); diff --git a/isis/src/control/objs/ControlNetVersioner/ControlPointV0001.cpp b/isis/src/control/objs/ControlNetVersioner/ControlPointV0001.cpp index 235ee98c6d..b2bf24277b 100644 --- a/isis/src/control/objs/ControlNetVersioner/ControlPointV0001.cpp +++ b/isis/src/control/objs/ControlNetVersioner/ControlPointV0001.cpp @@ -87,9 +87,9 @@ namespace Isis { && pointObject.hasKeyword("Longitude") && pointObject.hasKeyword("Radius") ) { SurfacePoint adjustedPoint( - Latitude(IString::ToDouble(pointObject["Latitude"][0]), Angle::Degrees), - Longitude(IString::ToDouble(pointObject["Longitude"][0]), Angle::Degrees), - Distance(IString::ToDouble(pointObject["Radius"][0]), Distance::Meters)); + Latitude(Isis::toDouble(pointObject["Latitude"][0]), Angle::Degrees), + Longitude(Isis::toDouble(pointObject["Longitude"][0]), Angle::Degrees), + Distance(Isis::toDouble(pointObject["Radius"][0]), Distance::Meters)); m_pointData->set_adjustedx( adjustedPoint.GetX().meters() ); m_pointData->set_adjustedy( adjustedPoint.GetY().meters() ); @@ -98,9 +98,9 @@ namespace Isis { else if ( pointObject.hasKeyword("X") && pointObject.hasKeyword("Y") && pointObject.hasKeyword("Z") ) { - m_pointData->set_adjustedx( IString::ToDouble(pointObject["X"][0]) ); - m_pointData->set_adjustedy( IString::ToDouble(pointObject["Y"][0]) ); - m_pointData->set_adjustedz( IString::ToDouble(pointObject["Z"][0]) ); + m_pointData->set_adjustedx( Isis::toDouble(pointObject["X"][0]) ); + m_pointData->set_adjustedy( Isis::toDouble(pointObject["Y"][0]) ); + m_pointData->set_adjustedz( Isis::toDouble(pointObject["Z"][0]) ); } // copy over the apriori surface point @@ -108,9 +108,9 @@ namespace Isis { && pointObject.hasKeyword("AprioriLongitude") && pointObject.hasKeyword("AprioriRadius") ) { SurfacePoint aprioriPoint( - Latitude(IString::ToDouble(pointObject["AprioriLatitude"][0]), Angle::Degrees), - Longitude(IString::ToDouble(pointObject["AprioriLongitude"][0]), Angle::Degrees), - Distance(IString::ToDouble(pointObject["AprioriRadius"][0]), Distance::Meters)); + Latitude(Isis::toDouble(pointObject["AprioriLatitude"][0]), Angle::Degrees), + Longitude(Isis::toDouble(pointObject["AprioriLongitude"][0]), Angle::Degrees), + Distance(Isis::toDouble(pointObject["AprioriRadius"][0]), Distance::Meters)); m_pointData->set_apriorix( aprioriPoint.GetX().meters() ); m_pointData->set_aprioriy( aprioriPoint.GetY().meters() ); @@ -119,9 +119,9 @@ namespace Isis { else if ( pointObject.hasKeyword("AprioriX") && pointObject.hasKeyword("AprioriY") && pointObject.hasKeyword("AprioriZ") ) { - m_pointData->set_apriorix( IString::ToDouble(pointObject["AprioriX"][0]) ); - m_pointData->set_aprioriy( IString::ToDouble(pointObject["AprioriY"][0]) ); - m_pointData->set_aprioriz( IString::ToDouble(pointObject["AprioriZ"][0]) ); + m_pointData->set_apriorix( Isis::toDouble(pointObject["AprioriX"][0]) ); + m_pointData->set_aprioriy( Isis::toDouble(pointObject["AprioriY"][0]) ); + m_pointData->set_aprioriz( Isis::toDouble(pointObject["AprioriZ"][0]) ); } // If the apriori values are missing, copy them from the adjusted. else if ( m_pointData->has_adjustedx() @@ -242,12 +242,12 @@ namespace Isis { if ( pointObject.hasKeyword("AprioriCovarianceMatrix") ) { PvlKeyword &matrix = pointObject["AprioriCovarianceMatrix"]; - m_pointData->add_aprioricovar(IString::ToDouble(matrix[0])); - m_pointData->add_aprioricovar(IString::ToDouble(matrix[1])); - m_pointData->add_aprioricovar(IString::ToDouble(matrix[2])); - m_pointData->add_aprioricovar(IString::ToDouble(matrix[3])); - m_pointData->add_aprioricovar(IString::ToDouble(matrix[4])); - m_pointData->add_aprioricovar(IString::ToDouble(matrix[5])); + m_pointData->add_aprioricovar(Isis::toDouble(matrix[0])); + m_pointData->add_aprioricovar(Isis::toDouble(matrix[1])); + m_pointData->add_aprioricovar(Isis::toDouble(matrix[2])); + m_pointData->add_aprioricovar(Isis::toDouble(matrix[3])); + m_pointData->add_aprioricovar(Isis::toDouble(matrix[4])); + m_pointData->add_aprioricovar(Isis::toDouble(matrix[5])); m_pointData->set_latitudeconstrained(true); m_pointData->set_longitudeconstrained(true); @@ -262,25 +262,25 @@ namespace Isis { double sigmaRad = 10000.0; if ( pointObject.hasKeyword("AprioriSigmaLatitude") ) { - if (IString::ToDouble(pointObject["AprioriSigmaLatitude"][0]) > 0 - && IString::ToDouble(pointObject["AprioriSigmaLatitude"][0]) < sigmaLat) { - sigmaLat = IString::ToDouble(pointObject["AprioriSigmaLatitude"][0]); + if (Isis::toDouble(pointObject["AprioriSigmaLatitude"][0]) > 0 + && Isis::toDouble(pointObject["AprioriSigmaLatitude"][0]) < sigmaLat) { + sigmaLat = Isis::toDouble(pointObject["AprioriSigmaLatitude"][0]); } m_pointData->set_latitudeconstrained(true); } if ( pointObject.hasKeyword("AprioriSigmaLongitude") ) { - if (IString::ToDouble(pointObject["AprioriSigmaLongitude"][0]) > 0 - && IString::ToDouble(pointObject["AprioriSigmaLongitude"][0]) < sigmaLon) { - sigmaLon = IString::ToDouble(pointObject["AprioriSigmaLongitude"][0]); + if (Isis::toDouble(pointObject["AprioriSigmaLongitude"][0]) > 0 + && Isis::toDouble(pointObject["AprioriSigmaLongitude"][0]) < sigmaLon) { + sigmaLon = Isis::toDouble(pointObject["AprioriSigmaLongitude"][0]); } m_pointData->set_longitudeconstrained(true); } if ( pointObject.hasKeyword("AprioriSigmaRadius") ) { - if (IString::ToDouble(pointObject["AprioriSigmaRadius"][0]) > 0 - && IString::ToDouble(pointObject["AprioriSigmaRadius"][0]) < sigmaRad) { - sigmaRad = IString::ToDouble(pointObject["AprioriSigmaRadius"][0]); + if (Isis::toDouble(pointObject["AprioriSigmaRadius"][0]) > 0 + && Isis::toDouble(pointObject["AprioriSigmaRadius"][0]) < sigmaRad) { + sigmaRad = Isis::toDouble(pointObject["AprioriSigmaRadius"][0]); } m_pointData->set_radiusconstrained(true); } @@ -304,12 +304,12 @@ namespace Isis { if ( pointObject.hasKeyword("ApostCovarianceMatrix") ) { PvlKeyword &matrix = pointObject["ApostCovarianceMatrix"]; - m_pointData->add_adjustedcovar(IString::ToDouble(matrix[0])); - m_pointData->add_adjustedcovar(IString::ToDouble(matrix[1])); - m_pointData->add_adjustedcovar(IString::ToDouble(matrix[2])); - m_pointData->add_adjustedcovar(IString::ToDouble(matrix[3])); - m_pointData->add_adjustedcovar(IString::ToDouble(matrix[4])); - m_pointData->add_adjustedcovar(IString::ToDouble(matrix[5])); + m_pointData->add_adjustedcovar(Isis::toDouble(matrix[0])); + m_pointData->add_adjustedcovar(Isis::toDouble(matrix[1])); + m_pointData->add_adjustedcovar(Isis::toDouble(matrix[2])); + m_pointData->add_adjustedcovar(Isis::toDouble(matrix[3])); + m_pointData->add_adjustedcovar(Isis::toDouble(matrix[4])); + m_pointData->add_adjustedcovar(Isis::toDouble(matrix[5])); m_pointData->set_latitudeconstrained(true); m_pointData->set_longitudeconstrained(true); @@ -324,23 +324,23 @@ namespace Isis { double sigmaRad = 10000.0; if ( pointObject.hasKeyword("AdjustedSigmaLatitude") ) { - if (IString::ToDouble(pointObject["AdjustedSigmaLatitude"][0]) > 0 - && IString::ToDouble(pointObject["AdjustedSigmaLatitude"][0]) < sigmaLat) { - sigmaLat = IString::ToDouble(pointObject["AdjustedSigmaLatitude"][0]); + if (Isis::toDouble(pointObject["AdjustedSigmaLatitude"][0]) > 0 + && Isis::toDouble(pointObject["AdjustedSigmaLatitude"][0]) < sigmaLat) { + sigmaLat = Isis::toDouble(pointObject["AdjustedSigmaLatitude"][0]); } } if ( pointObject.hasKeyword("AdjustedSigmaLongitude") ) { - if (IString::ToDouble(pointObject["AdjustedSigmaLongitude"][0]) > 0 - && IString::ToDouble(pointObject["AdjustedSigmaLongitude"][0]) < sigmaLon) { - sigmaLon = IString::ToDouble(pointObject["AdjustedSigmaLongitude"][0]); + if (Isis::toDouble(pointObject["AdjustedSigmaLongitude"][0]) > 0 + && Isis::toDouble(pointObject["AdjustedSigmaLongitude"][0]) < sigmaLon) { + sigmaLon = Isis::toDouble(pointObject["AdjustedSigmaLongitude"][0]); } } if ( pointObject.hasKeyword("AdjustedSigmaRadius") ) { - if (IString::ToDouble(pointObject["AdjustedSigmaRadius"][0]) > 0 - && IString::ToDouble(pointObject["AdjustedSigmaRadius"][0]) < sigmaRad) { - sigmaRad = IString::ToDouble(pointObject["AdjustedSigmaRadius"][0]); + if (Isis::toDouble(pointObject["AdjustedSigmaRadius"][0]) > 0 + && Isis::toDouble(pointObject["AdjustedSigmaRadius"][0]) < sigmaRad) { + sigmaRad = Isis::toDouble(pointObject["AdjustedSigmaRadius"][0]); } } @@ -395,7 +395,7 @@ namespace Isis { // in this case set it to 0 and ignore the measure double value; try { - value = IString::ToDouble(group["Sample"][0]); + value = Isis::toDouble(group["Sample"][0]); } catch (...) { value = 0; @@ -409,7 +409,7 @@ namespace Isis { // in this case set it to 0 and ignore the measure double value; try { - value = IString::ToDouble(group["Line"][0]); + value = Isis::toDouble(group["Line"][0]); } catch (...) { value = 0; @@ -422,24 +422,24 @@ namespace Isis { // Some old networks use ErrorSample and ErrorLine, // others use SampleResidual and LineResidual so check for both if (group.hasKeyword("ErrorSample")) { - double value = IString::ToDouble(group["ErrorSample"][0]); + double value = Isis::toDouble(group["ErrorSample"][0]); measure.mutable_measurement()->set_sampleresidual(value); group.deleteKeyword("ErrorSample"); } if (group.hasKeyword("ErrorLine")) { - double value = IString::ToDouble(group["ErrorLine"][0]); + double value = Isis::toDouble(group["ErrorLine"][0]); measure.mutable_measurement()->set_lineresidual(value); group.deleteKeyword("ErrorLine"); } if (group.hasKeyword("SampleResidual")) { - double value = IString::ToDouble(group["SampleResidual"][0]); + double value = Isis::toDouble(group["SampleResidual"][0]); measure.mutable_measurement()->set_sampleresidual(value); group.deleteKeyword("SampleResidual"); } if (group.hasKeyword("LineResidual")) { - double value = IString::ToDouble(group["LineResidual"][0]); + double value = Isis::toDouble(group["LineResidual"][0]); measure.mutable_measurement()->set_lineresidual(value); group.deleteKeyword("LineResidual"); } @@ -528,7 +528,7 @@ namespace Isis { } try { - value = IString::ToDouble(dataKeyword[0]); + value = Isis::toDouble(dataKeyword[0]); } catch (IException &e) { std::string msg = "Invalid control measure log data value [" + dataKeyword[0] + "]"; @@ -633,7 +633,7 @@ namespace Isis { return; } - double value = IString::ToDouble(container[keyName.toStdString()][0]); + double value = Isis::toDouble(container[keyName.toStdString()][0]); container.deleteKeyword(keyName.toStdString()); (point.data()->*setter)(value); } @@ -726,7 +726,7 @@ namespace Isis { double value = Isis::Null; if ( container.hasKeyword(keyName.toStdString()) ) { - value = IString::ToDouble(container[keyName.toStdString()][0]); + value = Isis::toDouble(container[keyName.toStdString()][0]); container.deleteKeyword(keyName.toStdString()); } diff --git a/isis/src/control/objs/ControlNetVersioner/ControlPointV0002.cpp b/isis/src/control/objs/ControlNetVersioner/ControlPointV0002.cpp index 4e0e27e554..f92b030799 100644 --- a/isis/src/control/objs/ControlNetVersioner/ControlPointV0002.cpp +++ b/isis/src/control/objs/ControlNetVersioner/ControlPointV0002.cpp @@ -154,23 +154,23 @@ namespace Isis { if (pointObject.hasKeyword("AprioriCovarianceMatrix")) { PvlKeyword &matrix = pointObject["AprioriCovarianceMatrix"]; - m_pointData->add_aprioricovar(IString::ToDouble(matrix[0])); - m_pointData->add_aprioricovar(IString::ToDouble(matrix[1])); - m_pointData->add_aprioricovar(IString::ToDouble(matrix[2])); - m_pointData->add_aprioricovar(IString::ToDouble(matrix[3])); - m_pointData->add_aprioricovar(IString::ToDouble(matrix[4])); - m_pointData->add_aprioricovar(IString::ToDouble(matrix[5])); + m_pointData->add_aprioricovar(Isis::toDouble(matrix[0])); + m_pointData->add_aprioricovar(Isis::toDouble(matrix[1])); + m_pointData->add_aprioricovar(Isis::toDouble(matrix[2])); + m_pointData->add_aprioricovar(Isis::toDouble(matrix[3])); + m_pointData->add_aprioricovar(Isis::toDouble(matrix[4])); + m_pointData->add_aprioricovar(Isis::toDouble(matrix[5])); } if (pointObject.hasKeyword("AdjustedCovarianceMatrix")) { PvlKeyword &matrix = pointObject["AdjustedCovarianceMatrix"]; - m_pointData->add_adjustedcovar(IString::ToDouble(matrix[0])); - m_pointData->add_adjustedcovar(IString::ToDouble(matrix[1])); - m_pointData->add_adjustedcovar(IString::ToDouble(matrix[2])); - m_pointData->add_adjustedcovar(IString::ToDouble(matrix[3])); - m_pointData->add_adjustedcovar(IString::ToDouble(matrix[4])); - m_pointData->add_adjustedcovar(IString::ToDouble(matrix[5])); + m_pointData->add_adjustedcovar(Isis::toDouble(matrix[0])); + m_pointData->add_adjustedcovar(Isis::toDouble(matrix[1])); + m_pointData->add_adjustedcovar(Isis::toDouble(matrix[2])); + m_pointData->add_adjustedcovar(Isis::toDouble(matrix[3])); + m_pointData->add_adjustedcovar(Isis::toDouble(matrix[4])); + m_pointData->add_adjustedcovar(Isis::toDouble(matrix[5])); } // Process Measures @@ -205,22 +205,22 @@ namespace Isis { // The sample, line, sample residual, and line residual are nested in another structure // inside the measure, so they cannot be copied with the conenience methods. if (group.hasKeyword("Sample")) { - double value = IString::ToDouble(group["Sample"][0]); + double value = Isis::toDouble(group["Sample"][0]); measure.mutable_measurement()->set_sample(value); group.deleteKeyword("Sample"); } if (group.hasKeyword("Line")) { - double value = IString::ToDouble(group["Line"][0]); + double value = Isis::toDouble(group["Line"][0]); measure.mutable_measurement()->set_line(value); group.deleteKeyword("Line"); } if (group.hasKeyword("SampleResidual")) { - double value = IString::ToDouble(group["SampleResidual"][0]); + double value = Isis::toDouble(group["SampleResidual"][0]); measure.mutable_measurement()->set_sampleresidual(value); group.deleteKeyword("SampleResidual"); } if (group.hasKeyword("LineResidual")) { - double value = IString::ToDouble(group["LineResidual"][0]); + double value = Isis::toDouble(group["LineResidual"][0]); measure.mutable_measurement()->set_lineresidual(value); group.deleteKeyword("LineResidual"); } @@ -302,7 +302,7 @@ namespace Isis { } try { - value = IString::ToDouble(dataKeyword[0]); + value = Isis::toDouble(dataKeyword[0]); } catch (IException &e) { std::string msg = "Invalid control measure log data value [" + dataKeyword[0] + "]"; @@ -422,7 +422,7 @@ namespace Isis { return; } - double value = IString::ToDouble(container[keyName.toStdString()][0]); + double value = Isis::toDouble(container[keyName.toStdString()][0]); container.deleteKeyword(keyName.toStdString()); (point.data()->*setter)(value); } @@ -513,7 +513,7 @@ namespace Isis { return; } - double value = IString::ToDouble(container[keyName.toStdString()][0]); + double value = Isis::toDouble(container[keyName.toStdString()][0]); container.deleteKeyword(keyName.toStdString()); (measure.*setter)(value); } diff --git a/isis/src/control/objs/ControlNetVersioner/ControlPointV0003.cpp b/isis/src/control/objs/ControlNetVersioner/ControlPointV0003.cpp index f13336d5a6..47171ce304 100644 --- a/isis/src/control/objs/ControlNetVersioner/ControlPointV0003.cpp +++ b/isis/src/control/objs/ControlNetVersioner/ControlPointV0003.cpp @@ -157,23 +157,23 @@ namespace Isis { if (pointObject.hasKeyword("AprioriCovarianceMatrix")) { PvlKeyword &matrix = pointObject["AprioriCovarianceMatrix"]; - m_pointData->add_aprioricovar(IString::ToDouble(matrix[0])); - m_pointData->add_aprioricovar(IString::ToDouble(matrix[1])); - m_pointData->add_aprioricovar(IString::ToDouble(matrix[2])); - m_pointData->add_aprioricovar(IString::ToDouble(matrix[3])); - m_pointData->add_aprioricovar(IString::ToDouble(matrix[4])); - m_pointData->add_aprioricovar(IString::ToDouble(matrix[5])); + m_pointData->add_aprioricovar(Isis::toDouble(matrix[0])); + m_pointData->add_aprioricovar(Isis::toDouble(matrix[1])); + m_pointData->add_aprioricovar(Isis::toDouble(matrix[2])); + m_pointData->add_aprioricovar(Isis::toDouble(matrix[3])); + m_pointData->add_aprioricovar(Isis::toDouble(matrix[4])); + m_pointData->add_aprioricovar(Isis::toDouble(matrix[5])); } if (pointObject.hasKeyword("AdjustedCovarianceMatrix")) { PvlKeyword &matrix = pointObject["AdjustedCovarianceMatrix"]; - m_pointData->add_adjustedcovar(IString::ToDouble(matrix[0])); - m_pointData->add_adjustedcovar(IString::ToDouble(matrix[1])); - m_pointData->add_adjustedcovar(IString::ToDouble(matrix[2])); - m_pointData->add_adjustedcovar(IString::ToDouble(matrix[3])); - m_pointData->add_adjustedcovar(IString::ToDouble(matrix[4])); - m_pointData->add_adjustedcovar(IString::ToDouble(matrix[5])); + m_pointData->add_adjustedcovar(Isis::toDouble(matrix[0])); + m_pointData->add_adjustedcovar(Isis::toDouble(matrix[1])); + m_pointData->add_adjustedcovar(Isis::toDouble(matrix[2])); + m_pointData->add_adjustedcovar(Isis::toDouble(matrix[3])); + m_pointData->add_adjustedcovar(Isis::toDouble(matrix[4])); + m_pointData->add_adjustedcovar(Isis::toDouble(matrix[5])); } // Process Measures @@ -623,7 +623,7 @@ namespace Isis { return; } - double value = IString::ToDouble(container[keyName.toStdString()][0]); + double value = Isis::toDouble(container[keyName.toStdString()][0]); container.deleteKeyword(keyName.toStdString()); (point.data()->*setter)(value); } @@ -714,7 +714,7 @@ namespace Isis { return; } - double value = IString::ToDouble(container[keyName.toStdString()][0]); + double value = Isis::toDouble(container[keyName.toStdString()][0]); container.deleteKeyword(keyName.toStdString()); (measure.*setter)(value); } diff --git a/isis/src/control/objs/ControlPoint/ControlPoint.cpp b/isis/src/control/objs/ControlPoint/ControlPoint.cpp index 2af76fb775..0a05ee26ee 100644 --- a/isis/src/control/objs/ControlPoint/ControlPoint.cpp +++ b/isis/src/control/objs/ControlPoint/ControlPoint.cpp @@ -362,7 +362,7 @@ namespace Isis { */ int ControlPoint::Delete(int index) { if (index < 0 || index >= cubeSerials->size()) { - std::string msg = "index [" + toString(index) + "] out of bounds"; + std::string msg = "index [" + Isis::toString(index) + "] out of bounds"; throw IException(IException::Programmer, msg, _FILEINFO_); } @@ -704,7 +704,7 @@ namespace Isis { */ ControlPoint::Status ControlPoint::SetType(PointType newType) { if (type != Fixed && type != Free && type != Constrained) { - std::string msg = "Invalid Point Enumeration, [" + toString(type) + "], for " + std::string msg = "Invalid Point Enumeration, [" + Isis::toString(type) + "], for " "Control Point [" + GetId().toStdString() + "]"; throw IException(IException::Programmer, msg, _FILEINFO_); } diff --git a/isis/src/control/objs/ControlPointList/ControlPointList.cpp b/isis/src/control/objs/ControlPointList/ControlPointList.cpp index 3fdd24f8b1..e532fec497 100644 --- a/isis/src/control/objs/ControlPointList/ControlPointList.cpp +++ b/isis/src/control/objs/ControlPointList/ControlPointList.cpp @@ -136,9 +136,9 @@ namespace Isis { } } - pcPvlLog += Isis::PvlKeyword("TotalPoints", toString(size)); - pcPvlLog += Isis::PvlKeyword("ValidPoints", toString(size - iNotFound)); - pcPvlLog += Isis::PvlKeyword("InvalidPoints", toString(iNotFound)); + pcPvlLog += Isis::PvlKeyword("TotalPoints", Isis::toString(size)); + pcPvlLog += Isis::PvlKeyword("ValidPoints", Isis::toString(size - iNotFound)); + pcPvlLog += Isis::PvlKeyword("InvalidPoints", Isis::toString(iNotFound)); pcPvlLog += Isis::PvlKeyword("InvalidPointIds", sPointsNotFound.toStdString()); } } diff --git a/isis/src/control/objs/InterestOperator/InterestOperator.cpp b/isis/src/control/objs/InterestOperator/InterestOperator.cpp index 7b97ebdb17..a04ec9b643 100644 --- a/isis/src/control/objs/InterestOperator/InterestOperator.cpp +++ b/isis/src/control/objs/InterestOperator/InterestOperator.cpp @@ -97,19 +97,19 @@ namespace Isis { mOperatorGrp += Isis::PvlKeyword(op["Name"]); p_samples = op["Samples"]; - mOperatorGrp += Isis::PvlKeyword("Samples", toString(p_samples)); + mOperatorGrp += Isis::PvlKeyword("Samples", Isis::toString(p_samples)); p_lines = op["Lines"]; - mOperatorGrp += Isis::PvlKeyword("Lines", toString(p_lines)); + mOperatorGrp += Isis::PvlKeyword("Lines", Isis::toString(p_lines)); p_deltaLine = op["DeltaLine"]; - mOperatorGrp += Isis::PvlKeyword("DeltaLine", toString(p_deltaLine)); + mOperatorGrp += Isis::PvlKeyword("DeltaLine", Isis::toString(p_deltaLine)); p_deltaSamp = op["DeltaSamp"]; - mOperatorGrp += Isis::PvlKeyword("DeltaSamp", toString(p_deltaSamp)); + mOperatorGrp += Isis::PvlKeyword("DeltaSamp", Isis::toString(p_deltaSamp)); p_minimumInterest = op["MinimumInterest"]; - mOperatorGrp += Isis::PvlKeyword("MinimumInterest", toString(p_minimumInterest)); + mOperatorGrp += Isis::PvlKeyword("MinimumInterest", Isis::toString(p_minimumInterest)); } catch (IException &e) { @@ -497,8 +497,8 @@ namespace Isis { pvlMeasureGrp += Isis::PvlKeyword("NewLocation", LocationString(mtInterestResults[measure].mdBestSample, mtInterestResults[measure].mdBestLine).toStdString()); - pvlMeasureGrp += Isis::PvlKeyword("DeltaSample", toString(mtInterestResults[measure].miDeltaSample)); - pvlMeasureGrp += Isis::PvlKeyword("DeltaLine", toString(mtInterestResults[measure].miDeltaLine)); + pvlMeasureGrp += Isis::PvlKeyword("DeltaSample", Isis::toString(mtInterestResults[measure].miDeltaSample)); + pvlMeasureGrp += Isis::PvlKeyword("DeltaLine", Isis::toString(mtInterestResults[measure].miDeltaLine)); pvlMeasureGrp += Isis::PvlKeyword("Reference", "true"); } else { @@ -518,8 +518,8 @@ namespace Isis { newMeasure->SetIgnored(true); } pvlMeasureGrp += Isis::PvlKeyword("NewLocation", LocationString(dSample, dLine).toStdString()); - pvlMeasureGrp += Isis::PvlKeyword("DeltaSample", toString((int)abs((int)dSample - (int)origSample))); - pvlMeasureGrp += Isis::PvlKeyword("DeltaLine", toString((int)abs((int)dLine - (int)origLine))); + pvlMeasureGrp += Isis::PvlKeyword("DeltaSample", Isis::toString((int)abs((int)dSample - (int)origSample))); + pvlMeasureGrp += Isis::PvlKeyword("DeltaLine", Isis::toString((int)abs((int)dLine - (int)origLine))); pvlMeasureGrp += Isis::PvlKeyword("Reference", "false"); } } @@ -543,11 +543,11 @@ namespace Isis { iMeasuresModified ++; } - pvlMeasureGrp += Isis::PvlKeyword("BestInterest", toString(mtInterestResults[measure].mdInterest)); - pvlMeasureGrp += Isis::PvlKeyword("EmissionAngle", toString(mtInterestResults[measure].mdEmission)); - pvlMeasureGrp += Isis::PvlKeyword("IncidenceAngle", toString(mtInterestResults[measure].mdIncidence)); - pvlMeasureGrp += Isis::PvlKeyword("Resolution", toString(mtInterestResults[measure].mdResolution)); - pvlMeasureGrp += Isis::PvlKeyword("DNValue", toString(mtInterestResults[measure].mdDn)); + pvlMeasureGrp += Isis::PvlKeyword("BestInterest", Isis::toString(mtInterestResults[measure].mdInterest)); + pvlMeasureGrp += Isis::PvlKeyword("EmissionAngle", Isis::toString(mtInterestResults[measure].mdEmission)); + pvlMeasureGrp += Isis::PvlKeyword("IncidenceAngle", Isis::toString(mtInterestResults[measure].mdIncidence)); + pvlMeasureGrp += Isis::PvlKeyword("Resolution", Isis::toString(mtInterestResults[measure].mdResolution)); + pvlMeasureGrp += Isis::PvlKeyword("DNValue", Isis::toString(mtInterestResults[measure].mdDn)); pvlPointObj += pvlMeasureGrp; } // Measures Loop @@ -568,7 +568,7 @@ namespace Isis { PvlGroup pvlRefChangeGrp("ReferenceChangeDetails"); if (iOrigRefIndex >= 0) { pvlRefChangeGrp += Isis::PvlKeyword("PrevSerialNumber", mtInterestResults[iOrigRefIndex].msSerialNum.toStdString()); - pvlRefChangeGrp += Isis::PvlKeyword("PrevBestInterest", toString(mtInterestResults[iOrigRefIndex].mdInterest)); + pvlRefChangeGrp += Isis::PvlKeyword("PrevBestInterest", Isis::toString(mtInterestResults[iOrigRefIndex].mdInterest)); pvlRefChangeGrp += Isis::PvlKeyword("PrevLocation", LocationString(mtInterestResults[iOrigRefIndex].mdOrigSample, mtInterestResults[iOrigRefIndex].mdOrigLine).toStdString()); } @@ -576,7 +576,7 @@ namespace Isis { pvlRefChangeGrp += Isis::PvlKeyword("PrevReference", "Not Set"); } pvlRefChangeGrp += Isis::PvlKeyword("NewSerialNumber", mtInterestResults[iBestMeasureIndex].msSerialNum.toStdString()); - pvlRefChangeGrp += Isis::PvlKeyword("NewBestInterest", toString(mtInterestResults[iBestMeasureIndex].mdInterest)); + pvlRefChangeGrp += Isis::PvlKeyword("NewBestInterest", Isis::toString(mtInterestResults[iBestMeasureIndex].mdInterest)); pvlRefChangeGrp += Isis::PvlKeyword("NewLocation", LocationString(mtInterestResults[iBestMeasureIndex].mdBestSample, mtInterestResults[iBestMeasureIndex].mdBestLine).toStdString()); @@ -599,24 +599,24 @@ namespace Isis { if (numMeasures == 0) { std::string sComment = "Comment"; - sComment += toString(++iComment); + sComment += Isis::toString(++iComment); pvlPointObj += Isis::PvlKeyword(sComment, "No Measures in the Point"); } if (newPnt->IsIgnored()) { std::string sComment = "Comment"; - sComment += toString(++iComment); + sComment += Isis::toString(++iComment); pvlPointObj += Isis::PvlKeyword(sComment, "Point was originally Ignored"); } if (newPnt->GetType() == ControlPoint::Fixed) { std::string sComment = "Comment"; - sComment += toString(++iComment); + sComment += Isis::toString(++iComment); pvlPointObj += Isis::PvlKeyword(sComment, "Fixed Point"); } else if (newPnt->GetType() == ControlPoint::Constrained) { std::string sComment = "Comment"; - sComment += toString(++iComment); + sComment += Isis::toString(++iComment); pvlPointObj += Isis::PvlKeyword(sComment, "Constrained Point"); } @@ -639,9 +639,9 @@ namespace Isis { } // Point loop // CnetRef Change Statistics - mStatisticsGrp += Isis::PvlKeyword("PointsModified", toString(iPointsModified)); - mStatisticsGrp += Isis::PvlKeyword("ReferenceChanged", toString(iRefChanged)); - mStatisticsGrp += Isis::PvlKeyword("MeasuresModified", toString(iMeasuresModified)); + mStatisticsGrp += Isis::PvlKeyword("PointsModified", Isis::toString(iPointsModified)); + mStatisticsGrp += Isis::PvlKeyword("ReferenceChanged", Isis::toString(iRefChanged)); + mStatisticsGrp += Isis::PvlKeyword("MeasuresModified", Isis::toString(iMeasuresModified)); mPvlLog += mStatisticsGrp; } diff --git a/isis/src/control/objs/InterestOperator/unitTest.cpp b/isis/src/control/objs/InterestOperator/unitTest.cpp index 0d6c39e2d4..5e11953fc4 100644 --- a/isis/src/control/objs/InterestOperator/unitTest.cpp +++ b/isis/src/control/objs/InterestOperator/unitTest.cpp @@ -26,19 +26,19 @@ int main() { try { PvlGroup op("Operator"); op += PvlKeyword("Name", "StandardDeviation"); - op += PvlKeyword("DeltaLine", toString(100)); - op += PvlKeyword("DeltaSamp", toString(100)); - op += PvlKeyword("Samples", toString(15)); - op += PvlKeyword("Lines", toString(15)); - op += PvlKeyword("MinimumInterest", toString(0.01)); + op += PvlKeyword("DeltaLine", Isis::toString(100)); + op += PvlKeyword("DeltaSamp", Isis::toString(100)); + op += PvlKeyword("Samples", Isis::toString(15)); + op += PvlKeyword("Lines", Isis::toString(15)); + op += PvlKeyword("MinimumInterest", Isis::toString(0.01)); PvlGroup opv("ValidMeasure"); - opv += PvlKeyword("MinDN", toString(0.0)); - opv += PvlKeyword("MaxDN", toString(1.0)); - opv += PvlKeyword("MinEmission", toString(15.0)); - opv += PvlKeyword("MaxEmission", toString(25.0)); - opv += PvlKeyword("MinIncidence", toString(0.0)); - opv += PvlKeyword("MaxIncidence", toString(135.0)); + opv += PvlKeyword("MinDN", Isis::toString(0.0)); + opv += PvlKeyword("MaxDN", Isis::toString(1.0)); + opv += PvlKeyword("MinEmission", Isis::toString(15.0)); + opv += PvlKeyword("MaxEmission", Isis::toString(25.0)); + opv += PvlKeyword("MinIncidence", Isis::toString(0.0)); + opv += PvlKeyword("MaxIncidence", Isis::toString(135.0)); //op += PvlKeyword("MinResolution", 100); //op += PvlKeyword("MaxResolution", 300); diff --git a/isis/src/core/src/Blob.cpp b/isis/src/core/src/Blob.cpp index 53d968d585..5bcfef6f07 100644 --- a/isis/src/core/src/Blob.cpp +++ b/isis/src/core/src/Blob.cpp @@ -424,8 +424,8 @@ namespace Isis { os.seekp(0, std::ios::end); BigInt nbytes = (BigInt) os.tellp() + (BigInt) 64; p_startByte = nbytes + 1 + 1; // 1-based; - pvl.findObject(p_type)["StartByte"] = std::to_string(p_startByte); - pvl.findObject(p_type)["Bytes"] = std::to_string(p_nbytes); + pvl.findObject(p_type)["StartByte"] = Isis::toString(p_startByte); + pvl.findObject(p_type)["Bytes"] = Isis::toString(p_nbytes); pvl.write(file); // Prepare and write the binary data @@ -482,8 +482,8 @@ namespace Isis { } - p_blobPvl["StartByte"] = std::to_string((BigInt)sbyte); - p_blobPvl["Bytes"] = std::to_string(p_nbytes); + p_blobPvl["StartByte"] = Isis::toString((BigInt)sbyte); + p_blobPvl["Bytes"] = Isis::toString(p_nbytes); // See if the blob is already in the file diff --git a/isis/src/core/src/FileName.cpp b/isis/src/core/src/FileName.cpp index 07e63e0f25..94a3b20469 100644 --- a/isis/src/core/src/FileName.cpp +++ b/isis/src/core/src/FileName.cpp @@ -410,12 +410,12 @@ namespace Isis { int width = std::count(file.begin(), file.end(), '?'); if (versionNumber < 0) { - std::string msg = "FileName does not support negative version numbers in the file name, tried to get version [" + std::to_string(versionNumber) + "] in file named " + originalPath() + "/" + file; + std::string msg = "FileName does not support negative version numbers in the file name, tried to get version [" + Isis::toString(versionNumber) + "] in file named " + originalPath() + "/" + file; throw IException(IException::Unknown, msg, _FILEINFO_); } if (versionNumber >= pow(10.0, width)) { - std::string msg = "FileName does not support version numbers greater than what would fit in the file name, tried to get version [" + std::to_string(versionNumber) + "] in file named [" + originalPath() + "/" + file + "]"; + std::string msg = "FileName does not support version numbers greater than what would fit in the file name, tried to get version [" + Isis::toString(versionNumber) + "] in file named [" + originalPath() + "/" + file + "]"; throw IException(IException::Unknown, msg, _FILEINFO_); } @@ -746,7 +746,7 @@ namespace Isis { for (std::string foundFile : files) { try { - foundValue = IString::ToInteger(foundFile.substr(before.length(), width)); + foundValue = Isis::toInt(foundFile.substr(before.length(), width)); success = true; } catch (...) { diff --git a/isis/src/core/src/IException.cpp b/isis/src/core/src/IException.cpp index 6d08d67c41..6828d976e9 100644 --- a/isis/src/core/src/IException.cpp +++ b/isis/src/core/src/IException.cpp @@ -422,7 +422,7 @@ namespace Isis { errGroup += PvlKeyword("File", *exception.m_fileName); if (exception.m_lineNumber != -1) - errGroup += PvlKeyword("Line", std::to_string(exception.m_lineNumber)); + errGroup += PvlKeyword("Line", Isis::toString(exception.m_lineNumber)); } if (!exceptionIsBlank) diff --git a/isis/src/core/src/Preference.cpp b/isis/src/core/src/Preference.cpp index 033e2f34f4..359e516335 100644 --- a/isis/src/core/src/Preference.cpp +++ b/isis/src/core/src/Preference.cpp @@ -65,7 +65,7 @@ namespace Isis { if (threadsPreference != "optimized") { // We need a no-iException conversion here - int threads = IString::ToInteger(threadsPreference); + int threads = Isis::toInt(threadsPreference); if (threads > 0) { QThreadPool::globalInstance()->setMaxThreadCount(threads); diff --git a/isis/src/core/src/PvlKeyword.cpp b/isis/src/core/src/PvlKeyword.cpp index 4650facb55..b1e78f4d6e 100644 --- a/isis/src/core/src/PvlKeyword.cpp +++ b/isis/src/core/src/PvlKeyword.cpp @@ -550,7 +550,7 @@ namespace Isis { upcase = true; } else if (upcase) { - std::string valueUpper = std::to_string(value[i]); + std::string valueUpper = Isis::toString(value[i]); std::transform(valueUpper.begin(), valueUpper.end(), valueUpper.begin(), ::toupper); out += valueUpper; lastlower = false; @@ -582,7 +582,7 @@ namespace Isis { lastlower = false; } else { - std::string valueUpper = std::to_string(value[i]); + std::string valueUpper = Isis::toString(value[i]); std::transform(valueUpper.begin(), valueUpper.end(), valueUpper.begin(), ::toupper); out += valueUpper; if (islower(value[i])) lastlower = true; @@ -1987,8 +1987,8 @@ namespace Isis { // Check for Range if (sValueName.find("__Range") != std::string::npos) { - dRangeMin = IString::ToDouble((*pvlKwrdValue)[0]); - dRangeMax = IString::ToDouble((*pvlKwrdValue)[1]); + dRangeMin = Isis::toDouble((*pvlKwrdValue)[0]); + dRangeMax = Isis::toDouble((*pvlKwrdValue)[1]); bRange = true; } else if (sValueName.find("__Value") != std::string::npos) { @@ -2004,7 +2004,7 @@ namespace Isis { if (sValue != "null"){ int iValue=0; try { - iValue = IString::ToInteger(sValue); + iValue = Isis::toInt(sValue); } catch (IException & e) { std::string sErrMsg = "\"" +pvlKwrd.name() +"\" expects an Integer value"; throw IException(e, IException::User, sErrMsg, _FILEINFO_); @@ -2016,7 +2016,7 @@ namespace Isis { if (bValue) { bool bFound = false; for (int j=0; jsize(); j++) { - if (iValue == IString::ToInteger((*pvlKwrdValue)[j])) { + if (iValue == Isis::toInt((*pvlKwrdValue)[j])) { bFound = true; break; } @@ -2044,7 +2044,7 @@ namespace Isis { std::string sValue = pvlKwrd[i]; std::transform(sValue.begin(), sValue.end(), sValue.begin(), ::tolower); if (sValue != "null"){ - double dValue = IString::ToDouble(sValue); + double dValue = Isis::toDouble(sValue); if (bRange && (dValue < dRangeMin || dValue > dRangeMax)) { std::string sErrMsg = "\"" +pvlKwrd.name() +"\" is not in the specified Range"; throw IException(IException::User, sErrMsg, _FILEINFO_); @@ -2052,7 +2052,7 @@ namespace Isis { if (bValue) { bool bFound = false; for (int j=0; jsize(); j++) { - if (dValue == IString::ToDouble((*pvlKwrdValue)[j])) { + if (dValue == Isis::toDouble((*pvlKwrdValue)[j])) { bFound = true; break; } diff --git a/isis/src/core/src/Table.cpp b/isis/src/core/src/Table.cpp index 2874c79434..a7fa64fab0 100644 --- a/isis/src/core/src/Table.cpp +++ b/isis/src/core/src/Table.cpp @@ -420,9 +420,9 @@ namespace Isis { if (RecordSize() != rec.RecordSize()) { std::string msg = "Unable to add the given record with size = [" - + std::to_string(rec.RecordSize()) + " bytes] to to Isis Table [" + + Isis::toString(rec.RecordSize()) + " bytes] to to Isis Table [" + p_name + "] with record size = [" - + std::to_string(RecordSize()) + " bytes]. Record sizes must match."; + + Isis::toString(RecordSize()) + " bytes]. Record sizes must match."; throw IException(IException::Unknown, msg, _FILEINFO_); } char *newbuf = new char[RecordSize()]; @@ -474,7 +474,7 @@ namespace Isis { PvlObject &blobLabel = tableBlob.Label(); // Label setup - blobLabel += PvlKeyword("Records", std::to_string(Records())); + blobLabel += PvlKeyword("Records", Isis::toString(Records())); int nbytes = Records() * RecordSize(); if (Isis::IsLsb()) { diff --git a/isis/src/core/src/TableField.cpp b/isis/src/core/src/TableField.cpp index ac81b9d180..7cf7b06bae 100644 --- a/isis/src/core/src/TableField.cpp +++ b/isis/src/core/src/TableField.cpp @@ -356,7 +356,7 @@ namespace Isis { } if (m_size > 1) { std::string msg = "Unable to set field to the given int value. " - "Field [" + m_name + "] has [" + std::to_string(m_size) + "] " + "Field [" + m_name + "] has [" + Isis::toString(m_size) + "] " "Integer values. Use operator=(vector)."; throw IException(IException::Programmer, msg, _FILEINFO_); } @@ -380,7 +380,7 @@ namespace Isis { } if (m_size > 1) { std::string msg = "Unable to set field to the given double value. " - "Field [" + m_name + "] has [" + std::to_string(m_size) + "] " + "Field [" + m_name + "] has [" + Isis::toString(m_size) + "] " "Double values. Use operator=(vector)."; throw IException(IException::Programmer, msg, _FILEINFO_); } @@ -404,7 +404,7 @@ namespace Isis { } if (m_size > 1) { std::string msg = "Unable to set field to the given float value. " - "Field [" + m_name + "] has [" + std::to_string(m_size) + "] " + "Field [" + m_name + "] has [" + Isis::toString(m_size) + "] " "Real values. Use operator=(vector)."; throw IException(IException::Programmer, msg, _FILEINFO_); } @@ -431,7 +431,7 @@ namespace Isis { if (val[i] != ' ' && val[i] != '\0') { std::string msg = "Unable to set the Text TableField to the given string. " "The number of bytes allowed for this field value [" - + std::to_string(m_size) + "] is less than the length of the " + + Isis::toString(m_size) + "] is less than the length of the " "given string [" + value + "]."; throw IException(IException::Unknown, msg, _FILEINFO_); } @@ -460,7 +460,7 @@ namespace Isis { else if ((int) values.size() != m_size) { std::string msg = "Unable to set field to the given vector of int values. " "Field [" + m_name + "] values has size [" - + std::to_string(m_size) + "]."; + + Isis::toString(m_size) + "]."; throw IException(IException::Programmer, msg, _FILEINFO_); } m_ivalues = values; @@ -484,7 +484,7 @@ namespace Isis { else if ((int) values.size() != m_size) { std::string msg = "Unable to set field to the given vector of double values. " "Field [" + m_name + "] values has size [" - + std::to_string(m_size) + "]."; + + Isis::toString(m_size) + "]."; throw IException(IException::Programmer, msg, _FILEINFO_); } m_dvalues = values; @@ -509,7 +509,7 @@ namespace Isis { else if ((int) values.size() != m_size) { std::string msg = "Unable to set field to the given vector of float values. " "Field [" + m_name + "] values has size [" - + std::to_string(m_size) + "]."; + + Isis::toString(m_size) + "]."; throw IException(IException::Programmer, msg, _FILEINFO_); } m_rvalues = values; @@ -602,7 +602,7 @@ namespace Isis { else if (m_type == TableField::Real) { group += PvlKeyword("Type", "Real"); } - group += PvlKeyword("Size", std::to_string(m_size)); + group += PvlKeyword("Size", Isis::toString(m_size)); return group; } @@ -632,7 +632,7 @@ namespace Isis { else if (field.isInteger()){ vector< int > currField = field; for (int i = 0;i <(int)currField.size();i++){ - fieldValues += std::to_string(currField[i]); + fieldValues += Isis::toString(currField[i]); if (i <(int)currField.size()- 1){ // add delimiter for all but the last element of the field fieldValues += delimiter; @@ -642,7 +642,7 @@ namespace Isis { else if (field.isDouble()){ vector< double > currField = field; for (int i = 0;i <(int)currField.size();i++){ - fieldValues += std::to_string(currField[i]); + fieldValues += Isis::toString(currField[i]); if (i <(int)currField.size()- 1){ fieldValues += delimiter; } @@ -651,7 +651,7 @@ namespace Isis { else { //if (field.isReal()) { vector< float > currField = field; for (int i = 0;i <(int)currField.size();i++){ - fieldValues += std::to_string(currField[i]); + fieldValues += Isis::toString(currField[i]); if (i <(int)currField.size()- 1){ fieldValues += delimiter; } diff --git a/isis/src/core/tests/PvlKeywordTests.cpp b/isis/src/core/tests/PvlKeywordTests.cpp index d6a38b5e22..6bca6bfc6f 100644 --- a/isis/src/core/tests/PvlKeywordTests.cpp +++ b/isis/src/core/tests/PvlKeywordTests.cpp @@ -224,7 +224,11 @@ TEST(PvlKeyword, IndexSetValue) key.addValue("3.3", "feet"); key.addValue("Hello World!"); +<<<<<<< HEAD key[1] = toString(88); +======= + key[1] = Isis::toString(88); +>>>>>>> e6eff8ddd (Update std::tostring, stoi, stod to IString functions) EXPECT_EQ(key[1], "88"); } @@ -322,7 +326,11 @@ TEST(PvlKeyword, KeywordValidationNull) TEST(PvlKeyword, KeywordValidationFail) { try { PvlKeyword pvlTmplKwrd("KeyName", "integer"); +<<<<<<< HEAD PvlKeyword pvlKwrd("KeyName", toString(3.5)); +======= + PvlKeyword pvlKwrd("KeyName", Isis::toString(3.5)); +>>>>>>> e6eff8ddd (Update std::tostring, stoi, stod to IString functions) pvlTmplKwrd.validateKeyword(pvlKwrd); } catch(Isis::IException &e) { @@ -333,7 +341,11 @@ TEST(PvlKeyword, KeywordValidationFail) { TEST(PvlKeyword, KeywordValidationPositive) { try { PvlKeyword pvlTmplKwrd("KeyName", "integer"); +<<<<<<< HEAD PvlKeyword pvlKwrd("KeyName", toString(-3)); +======= + PvlKeyword pvlKwrd("KeyName", Isis::toString(-3)); +>>>>>>> e6eff8ddd (Update std::tostring, stoi, stod to IString functions) pvlTmplKwrd.validateKeyword(pvlKwrd, "positive"); } catch(Isis::IException &e) { @@ -344,9 +356,15 @@ TEST(PvlKeyword, KeywordValidationPositive) { TEST(PvlKeyword, KeywordValidationRange) { try { PvlKeyword pvlTmplKwrd("KeyName", "integer"); +<<<<<<< HEAD PvlKeyword pvlTmplKwrdRange("KeyName__Range", toString(0)); pvlTmplKwrdRange.addValue(toString(10)); PvlKeyword pvlKwrd("KeyName", toString(11)); +======= + PvlKeyword pvlTmplKwrdRange("KeyName__Range", Isis::toString(0)); + pvlTmplKwrdRange.addValue(Isis::toString(10)); + PvlKeyword pvlKwrd("KeyName", Isis::toString(11)); +>>>>>>> e6eff8ddd (Update std::tostring, stoi, stod to IString functions) pvlTmplKwrd.validateKeyword(pvlKwrd, "", &pvlTmplKwrdRange); } catch(Isis::IException &e) { diff --git a/isis/src/dawn/apps/dawnfc2isis/dawnfc2isis.cpp b/isis/src/dawn/apps/dawnfc2isis/dawnfc2isis.cpp index 07235b709f..623ee6dcc4 100644 --- a/isis/src/dawn/apps/dawnfc2isis/dawnfc2isis.cpp +++ b/isis/src/dawn/apps/dawnfc2isis/dawnfc2isis.cpp @@ -158,17 +158,17 @@ namespace Isis { "FilterNumber. The FilterNumber must fall in the range 1 to 8."; throw IException(IException::Io, msg, _FILEINFO_); } - bbGrp.addKeyword(PvlKeyword("Center", toString(center))); - bbGrp.addKeyword(PvlKeyword("Width", toString(width))); + bbGrp.addKeyword(PvlKeyword("Center", Isis::toString(center))); + bbGrp.addKeyword(PvlKeyword("Width", Isis::toString(width))); bbGrp.addKeyword(PvlKeyword("FilterName", filtname.toStdString())); outcube->putGroup(bbGrp); PvlGroup kerns("Kernels"); if(instid == "FC1") { - kerns += PvlKeyword("NaifFrameCode", toString(-203110-filtno)); + kerns += PvlKeyword("NaifFrameCode", Isis::toString(-203110-filtno)); } else if(instid == "FC2") { - kerns += PvlKeyword("NaifFrameCode", toString(-203120-filtno)); + kerns += PvlKeyword("NaifFrameCode", Isis::toString(-203120-filtno)); } else { std::string msg = "Input file [" + inFile.expanded() + "] has an invalid " + diff --git a/isis/src/dawn/objs/DawnFcCamera/DawnFcCamera.cpp b/isis/src/dawn/objs/DawnFcCamera/DawnFcCamera.cpp index 8f2b2b0d18..3779e7c77d 100644 --- a/isis/src/dawn/objs/DawnFcCamera/DawnFcCamera.cpp +++ b/isis/src/dawn/objs/DawnFcCamera/DawnFcCamera.cpp @@ -55,7 +55,7 @@ namespace Isis { } else { std::string msg = "File does not appear to be a Dawn Framing Camera image. "; - msg += "(" + toString(ikCode) + " is not a Dawn FC instrument code)"; + msg += "(" + Isis::toString(ikCode) + " is not a Dawn FC instrument code)"; throw IException(IException::Programmer, msg, _FILEINFO_); } diff --git a/isis/src/dawn/objs/DawnVirCamera/DawnVirCamera.cpp b/isis/src/dawn/objs/DawnVirCamera/DawnVirCamera.cpp index 2cd85751bd..8fd1e9eb47 100644 --- a/isis/src/dawn/objs/DawnVirCamera/DawnVirCamera.cpp +++ b/isis/src/dawn/objs/DawnVirCamera/DawnVirCamera.cpp @@ -88,9 +88,9 @@ namespace Isis { // Get other info from labels PvlKeyword &frameParam = inst["FrameParameter"]; - m_exposureTime = IString::ToDouble(frameParam[0]); - m_summing = IString::ToDouble(frameParam[1]); - m_scanRate = IString::ToDouble(frameParam[2]); + m_exposureTime = Isis::toDouble(frameParam[0]); + m_summing = Isis::toDouble(frameParam[1]); + m_scanRate = Isis::toDouble(frameParam[2]); // Setup detector map // Get the line scan rates/times @@ -480,21 +480,21 @@ namespace Isis { } // Add some necessary keywords - quats.Label() += PvlKeyword("CkTableStartTime", toString(startTime())); - quats.Label() += PvlKeyword("CkTableEndTime", toString(endTime())); - quats.Label() += PvlKeyword("CkTableOriginalSize", toString(quats.Records())); + quats.Label() += PvlKeyword("CkTableStartTime", Isis::toString(startTime())); + quats.Label() += PvlKeyword("CkTableEndTime", Isis::toString(endTime())); + quats.Label() += PvlKeyword("CkTableOriginalSize", Isis::toString(quats.Records())); // Create the time dependant frames keyword int virZeroId = getInteger("FRAME_" + virZero); - PvlKeyword tdf("TimeDependentFrames", toString(virZeroId)); // DAWN_VIR_{ID}_ZERO + PvlKeyword tdf("TimeDependentFrames", Isis::toString(virZeroId)); // DAWN_VIR_{ID}_ZERO tdf.addValue("-203200"); // DAWN_VIR tdf.addValue("-203000"); // DAWN_SPACECRAFT tdf.addValue("1"); // J2000 quats.Label() += tdf; // Create constant rotation frames - PvlKeyword cf("ConstantFrames", toString(virZeroId)); - cf.addValue(toString(virZeroId)); + PvlKeyword cf("ConstantFrames", Isis::toString(virZeroId)); + cf.addValue(Isis::toString(virZeroId)); quats.Label() += cf; SpiceDouble identity[3][3]; @@ -504,7 +504,7 @@ namespace Isis { PvlKeyword crot("ConstantRotation"); for (int i = 0 ; i < 3 ; i++) { for (int j = 0 ; j < 3 ; j++) { - crot.addValue(toString(identity[i][j])); + crot.addValue(Isis::toString(identity[i][j])); } } diff --git a/isis/src/dev/apps/camcoeffs/main.cpp b/isis/src/dev/apps/camcoeffs/main.cpp index 03329d454e..771f1f259a 100644 --- a/isis/src/dev/apps/camcoeffs/main.cpp +++ b/isis/src/dev/apps/camcoeffs/main.cpp @@ -161,21 +161,21 @@ void IsisMain() { if(ui.WasEntered("IAKCODE")) { PvlKeyword naifFormatX("INS" + ui.GetString("IAKCODE").toStdString() + "_TRANSX"); - naifFormatX += toString(eq1[0]); - naifFormatX += toString(eq1[1]); - naifFormatX += toString(eq1[2]); + naifFormatX += Isis::toString(eq1[0]); + naifFormatX += Isis::toString(eq1[1]); + naifFormatX += Isis::toString(eq1[2]); PvlKeyword naifFormatY("INS" + ui.GetString("IAKCODE").toStdString() + "_TRANSY"); - naifFormatY += toString(eq2[0]); - naifFormatY += toString(eq2[1]); - naifFormatY += toString(eq2[2]); + naifFormatY += Isis::toString(eq2[0]); + naifFormatY += Isis::toString(eq2[1]); + naifFormatY += Isis::toString(eq2[2]); PvlKeyword naifFormatS("INS" + ui.GetString("IAKCODE").toStdString() + "_ITRANSS"); - naifFormatS += toString(res1[0]); - naifFormatS += toString(res1[1]); - naifFormatS += toString(res1[2]); + naifFormatS += Isis::toString(res1[0]); + naifFormatS += Isis::toString(res1[1]); + naifFormatS += Isis::toString(res1[2]); PvlKeyword naifFormatL("INS" + ui.GetString("IAKCODE").toStdString() + "_ITRANSL"); - naifFormatL += toString(res2[0]); - naifFormatL += toString(res2[1]); - naifFormatL += toString(res2[2]); + naifFormatL += Isis::toString(res2[0]); + naifFormatL += Isis::toString(res2[1]); + naifFormatL += Isis::toString(res2[2]); res += naifFormatX; res += naifFormatY; diff --git a/isis/src/dev/apps/camtest/main.cpp b/isis/src/dev/apps/camtest/main.cpp index a510b4e10c..ad6ec12e37 100644 --- a/isis/src/dev/apps/camtest/main.cpp +++ b/isis/src/dev/apps/camtest/main.cpp @@ -92,14 +92,14 @@ void IsisMain() { // Collect results PvlGroup results = PvlGroup("CamTestResults"); - results += PvlKeyword("FailedConversionsToLatLong", toString(resultsStats.LrsPixels())); - results += PvlKeyword("FailedConversionsToSampleLine", toString(resultsStats.HrsPixels())); - results += PvlKeyword("SuccessfulConversions", toString(resultsStats.ValidPixels())); + results += PvlKeyword("FailedConversionsToLatLong", Isis::toString(resultsStats.LrsPixels())); + results += PvlKeyword("FailedConversionsToSampleLine", Isis::toString(resultsStats.HrsPixels())); + results += PvlKeyword("SuccessfulConversions", Isis::toString(resultsStats.ValidPixels())); if (outFormat == Err) { - results += PvlKeyword("Average", toString(resultsStats.Average())); - results += PvlKeyword("StandardDeviation", toString(resultsStats.StandardDeviation())); - results += PvlKeyword("Minimum", toString(resultsStats.Minimum())); - results += PvlKeyword("Maximum", toString(resultsStats.Maximum())); + results += PvlKeyword("Average", Isis::toString(resultsStats.Average())); + results += PvlKeyword("StandardDeviation", Isis::toString(resultsStats.StandardDeviation())); + results += PvlKeyword("Minimum", Isis::toString(resultsStats.Minimum())); + results += PvlKeyword("Maximum", Isis::toString(resultsStats.Maximum())); } // Log output results diff --git a/isis/src/galileo/apps/gllnims2isis/main.cpp b/isis/src/galileo/apps/gllnims2isis/main.cpp index 7e2b837d4f..72cfcb48df 100644 --- a/isis/src/galileo/apps/gllnims2isis/main.cpp +++ b/isis/src/galileo/apps/gllnims2isis/main.cpp @@ -368,8 +368,8 @@ PvlGroup originalMappingGroup = qube.findGroup("IMAGE_MAP_PROJECTION", Pvl::Trav double lineOffset = -(double)(importPds.Lines()+1) / 2; double sampleOffset = -(double)(importPds.Samples()+1) / 2; double resolution = mappingGroup["PixelResolution"][0].toDouble(); - mappingGroup["UpperLeftCornerY"] = toString(-lineOffset * resolution); - mappingGroup["UpperLeftCornerX"] = toString(sampleOffset * resolution); + mappingGroup["UpperLeftCornerY"] = Isis::toString(-lineOffset * resolution); + mappingGroup["UpperLeftCornerX"] = Isis::toString(sampleOffset * resolution); if (originalMappingGroup["COORDINATE_SYSTEM_NAME"][0] == "PLANETOCENTRIC") { mappingGroup["LatitudeType"] = "Planetocentric"; } @@ -387,11 +387,11 @@ PvlGroup originalMappingGroup = qube.findGroup("IMAGE_MAP_PROJECTION", Pvl::Trav } else { if (mappingGroup.hasKeyword("CenterLatitude")) { - mappingGroup["CenterLatitude"].setValue(toString(centerLatitude), + mappingGroup["CenterLatitude"].setValue(Isis::toString(centerLatitude), "degrees"); } else { - PvlKeyword clat("CenterLatitude", toString(centerLatitude), "degrees" ); + PvlKeyword clat("CenterLatitude", Isis::toString(centerLatitude), "degrees" ); mappingGroup.addKeyword(clat); } } @@ -400,7 +400,7 @@ PvlGroup originalMappingGroup = qube.findGroup("IMAGE_MAP_PROJECTION", Pvl::Trav "degrees"); } else { - mappingGroup["CenterLongitude"].setValue(toString(centerLongitude), + mappingGroup["CenterLongitude"].setValue(Isis::toString(centerLongitude), "degrees"); } mappingGroup["LongitudeDomain"].setUnits("degrees"); diff --git a/isis/src/galileo/apps/gllssi2isis/main.cpp b/isis/src/galileo/apps/gllssi2isis/main.cpp index 3de0834a66..8d801a0d4d 100644 --- a/isis/src/galileo/apps/gllssi2isis/main.cpp +++ b/isis/src/galileo/apps/gllssi2isis/main.cpp @@ -195,7 +195,7 @@ void translateLabels(Pvl &pdsLabel, Cube *ocube) { //change exposure duration to seconds double expDur = inst.findKeyword("exposureDuration"); double expDurOut = expDur / 1000.0; - inst.findKeyword("exposureDuration").setValue(toString(expDurOut), "seconds"); + inst.findKeyword("exposureDuration").setValue(Isis::toString(expDurOut), "seconds"); inst.addKeyword(PvlKeyword("FrameDuration", pdsLabel["frameDuration"], "seconds")); //Calculate the Frame_Rate_Id keyword @@ -207,7 +207,7 @@ void translateLabels(Pvl &pdsLabel, Cube *ocube) { summingMode = 2; } - inst.addKeyword(PvlKeyword("Summing", toString(summingMode))); + inst.addKeyword(PvlKeyword("Summing", Isis::toString(summingMode))); inst.addKeyword(PvlKeyword("FrameModeId", frameModeId.toStdString())); // Create the Band bin Group diff --git a/isis/src/galileo/apps/gllssical/gllssical.cpp b/isis/src/galileo/apps/gllssical/gllssical.cpp index d04436c3e3..cefe699cfa 100644 --- a/isis/src/galileo/apps/gllssical/gllssical.cpp +++ b/isis/src/galileo/apps/gllssical/gllssical.cpp @@ -82,7 +82,7 @@ namespace Isis { Isis::CubeAttributeInput inAtt1; FileName darkFileName = FindDarkFile(icube); Cube *darkcube = p.SetInputCube(QString::fromStdString(darkFileName.expanded()), inAtt1); - dcScaleFactor = IString::ToDouble(darkcube->group("Instrument")["PicScale"][0]); + dcScaleFactor = Isis::toDouble(darkcube->group("Instrument")["PicScale"][0]); Isis::CubeAttributeInput inAtt2; FileName gainFileName = FindGainFile(icube); @@ -107,7 +107,7 @@ namespace Isis { calculateScaleFactor0(icube, gaincube); - exposureDuration = IString::ToDouble(icube->group("Instrument")["ExposureDuration"][0]) * 1000; + exposureDuration = Isis::toDouble(icube->group("Instrument")["ExposureDuration"][0]) * 1000; if(darkcube->pixelType() == Isis::UnsignedByte) { eightBitDarkCube = true; @@ -126,23 +126,23 @@ namespace Isis { gainFileName.name())); calibrationLog.addKeyword(PvlKeyword("ShutterFile", shutterFileName.originalPath() + "/" + shutterFileName.name())); - calibrationLog.addKeyword(PvlKeyword("ScaleFactor", toString(scaleFactor))); + calibrationLog.addKeyword(PvlKeyword("ScaleFactor", Isis::toString(scaleFactor))); calibrationLog.addKeyword(PvlKeyword("OutputUnits", iof ? "I/F" : "Radiance")); if (iof) { - calibrationLog.addKeyword(PvlKeyword("S1", toString(s1), "I/F per Ft-Lambert")); - calibrationLog.addKeyword(PvlKeyword("RSUN", toString(rsun), "(Planet-Sun range)/5.2 A.U.")); - calibrationLog.addKeyword(PvlKeyword("Scale", toString(scaleFactor), "I/F units per DN")); - calibrationLog.addKeyword(PvlKeyword("GC", toString(cubeConversion), "Cube gain conversion")); - calibrationLog.addKeyword(PvlKeyword("GG", toString(gainConversion), "Gain file gain conversion")); - calibrationLog.addKeyword(PvlKeyword("IOF-SCALE0", toString(scaleFactor0), "(S1/Scale)*(GC/GG)/RSUN**2")); + calibrationLog.addKeyword(PvlKeyword("S1", Isis::toString(s1), "I/F per Ft-Lambert")); + calibrationLog.addKeyword(PvlKeyword("RSUN", Isis::toString(rsun), "(Planet-Sun range)/5.2 A.U.")); + calibrationLog.addKeyword(PvlKeyword("Scale", Isis::toString(scaleFactor), "I/F units per DN")); + calibrationLog.addKeyword(PvlKeyword("GC", Isis::toString(cubeConversion), "Cube gain conversion")); + calibrationLog.addKeyword(PvlKeyword("GG", Isis::toString(gainConversion), "Gain file gain conversion")); + calibrationLog.addKeyword(PvlKeyword("IOF-SCALE0", Isis::toString(scaleFactor0), "(S1/Scale)*(GC/GG)/RSUN**2")); } else { - calibrationLog.addKeyword(PvlKeyword("S2", toString(s2), "Nanowatts per Ft-Lambert")); - calibrationLog.addKeyword(PvlKeyword("Scale", toString(scaleFactor), + calibrationLog.addKeyword(PvlKeyword("S2", Isis::toString(s2), "Nanowatts per Ft-Lambert")); + calibrationLog.addKeyword(PvlKeyword("Scale", Isis::toString(scaleFactor), "Nanowatts/cm**2/steradian/nanometer/DN")); - calibrationLog.addKeyword(PvlKeyword("GC", toString(cubeConversion), "Cube gain conversion")); - calibrationLog.addKeyword(PvlKeyword("GG", toString(gainConversion), "Gain file gain conversion")); - calibrationLog.addKeyword(PvlKeyword("Radiance-SCALE0", toString(scaleFactor0), "(S2/Scale)*(GC/GG)")); + calibrationLog.addKeyword(PvlKeyword("GC", Isis::toString(cubeConversion), "Cube gain conversion")); + calibrationLog.addKeyword(PvlKeyword("GG", Isis::toString(gainConversion), "Gain file gain conversion")); + calibrationLog.addKeyword(PvlKeyword("Radiance-SCALE0", Isis::toString(scaleFactor0), "(S2/Scale)*(GC/GG)")); } ocube->putGroup(calibrationLog); @@ -235,11 +235,11 @@ namespace Isis { * 4 = 60 2/3 * 5 = 15 1/6 */ - if((int)(IString::ToDouble(icube->group("Instrument")["FrameDuration"][0])) == 2) frameRateId = 1; - if((int)(IString::ToDouble(icube->group("Instrument")["FrameDuration"][0])) == 8) frameRateId = 2; - if((int)(IString::ToDouble(icube->group("Instrument")["FrameDuration"][0])) == 30) frameRateId = 3; - if((int)(IString::ToDouble(icube->group("Instrument")["FrameDuration"][0])) == 60) frameRateId = 4; - if((int)(IString::ToDouble(icube->group("Instrument")["FrameDuration"][0])) == 15) frameRateId = 5; + if((int)(Isis::toDouble(icube->group("Instrument")["FrameDuration"][0])) == 2) frameRateId = 1; + if((int)(Isis::toDouble(icube->group("Instrument")["FrameDuration"][0])) == 8) frameRateId = 2; + if((int)(Isis::toDouble(icube->group("Instrument")["FrameDuration"][0])) == 30) frameRateId = 3; + if((int)(Isis::toDouble(icube->group("Instrument")["FrameDuration"][0])) == 60) frameRateId = 4; + if((int)(Isis::toDouble(icube->group("Instrument")["FrameDuration"][0])) == 15) frameRateId = 5; int exposureTypeId = (icube->group("Instrument")["ExposureType"][0] == "NORMAL") ? 0 : 1; @@ -282,7 +282,7 @@ namespace Isis { int minImageNum = tokens.takeFirst().toInt(); int maxImageNum = tokens.takeFirst().toInt(); - int imageNumber = (int)(IString::ToDouble(icube->group("Instrument")["SpacecraftClockStartCount"]) * 100 + 0.5); + int imageNumber = (int)(Isis::toDouble(icube->group("Instrument")["SpacecraftClockStartCount"]) * 100 + 0.5); QString telemetry = QString::fromStdString(icube->group("Instrument")["TelemetryFormat"][0]); if(imageNumber > 99757701 && imageNumber < 159999999) { if((telemetry == "AI8" && (gainState == "1" || gainState == "2")) || @@ -361,7 +361,7 @@ namespace Isis { QString keyword = QString("GainState") + ((getGainModeID(icube) < 3) ? QString("12") : QString("34")); for(int i = 0; i < frameGrp[keyword.toStdString()].size(); i++) { - weight.push_back(IString::ToDouble(frameGrp[keyword.toStdString()][i])); + weight.push_back(Isis::toDouble(frameGrp[keyword.toStdString()][i])); } return weightFile; @@ -376,16 +376,16 @@ namespace Isis { * 3 = 40,000 * 4 = 10,000 */ - if((int)IString::ToDouble(icube->group("Instrument")["GainModeId"][0]) == 4E5) { + if((int)Isis::toDouble(icube->group("Instrument")["GainModeId"][0]) == 4E5) { gainModeId = 1; } - else if((int)IString::ToDouble(icube->group("Instrument")["GainModeId"][0]) == 1E5) { + else if((int)Isis::toDouble(icube->group("Instrument")["GainModeId"][0]) == 1E5) { gainModeId = 2; } - else if((int)IString::ToDouble(icube->group("Instrument")["GainModeId"][0]) == 4E4) { + else if((int)Isis::toDouble(icube->group("Instrument")["GainModeId"][0]) == 4E4) { gainModeId = 3; } - else if((int)IString::ToDouble(icube->group("Instrument")["GainModeId"][0]) == 1E4) { + else if((int)Isis::toDouble(icube->group("Instrument")["GainModeId"][0]) == 1E4) { gainModeId = 4; } else { @@ -431,7 +431,7 @@ namespace Isis { if(currGrp.hasKeyword("MinimumTargetName")) { try { if((int)currGrp["MinimumTargetName"] > - (int)IString::ToInteger(icube->group("Archive")["CalTargetCode"][0].substr(0, 2))) { + (int)Isis::toInt(icube->group("Archive")["CalTargetCode"][0].substr(0, 2))) { continue; } } @@ -444,7 +444,7 @@ namespace Isis { fltToRad = currGrp["FloatToRad"]; } - int filterNumber = IString::ToInteger(icube->group("BandBin")["FilterNumber"][0]); + int filterNumber = Isis::toInt(icube->group("BandBin")["FilterNumber"][0]); if(fltToRef.size() == 0) { throw IException(IException::Unknown, @@ -454,10 +454,10 @@ namespace Isis { _FILEINFO_); } - s1 = IString::ToDouble(fltToRef[filterNumber]); - s2 = IString::ToDouble(fltToRad[filterNumber]); - cubeConversion = IString::ToDouble( conversionFactors["GainRatios"][getGainModeID(icube)-1]); - gainConversion = IString::ToDouble(conversionFactors["GainRatios"][getGainModeID(gaincube)-1]); + s1 = Isis::toDouble(fltToRef[filterNumber]); + s2 = Isis::toDouble(fltToRad[filterNumber]); + cubeConversion = Isis::toDouble( conversionFactors["GainRatios"][getGainModeID(icube)-1]); + gainConversion = Isis::toDouble(conversionFactors["GainRatios"][getGainModeID(gaincube)-1]); if (iof) { try { diff --git a/isis/src/hayabusa/apps/amica2isis/AmicaImportFits.cpp b/isis/src/hayabusa/apps/amica2isis/AmicaImportFits.cpp index fb2419918c..68bcfaf14e 100644 --- a/isis/src/hayabusa/apps/amica2isis/AmicaImportFits.cpp +++ b/isis/src/hayabusa/apps/amica2isis/AmicaImportFits.cpp @@ -129,16 +129,16 @@ namespace Isis { m_label = parseLabel(input, fitsLabelName); // Get data dimensions - int naxis = IString::ToInteger(m_label["NAXIS"][0]); + int naxis = Isis::toInt(m_label["NAXIS"][0]); if (naxis == 2) { - m_samples = IString::ToInteger(m_label["NAXIS1"][0]); - m_lines = IString::ToInteger(m_label["NAXIS2"][0]); + m_samples = Isis::toInt(m_label["NAXIS1"][0]); + m_lines = Isis::toInt(m_label["NAXIS2"][0]); m_bands = 1; } else if (naxis == 3) { - m_samples = IString::ToInteger(m_label["NAXIS1"][0]); - m_lines = IString::ToInteger(m_label["NAXIS2"][0]); - m_bands = IString::ToInteger(m_label["NAXIS3"][0]); + m_samples = Isis::toInt(m_label["NAXIS1"][0]); + m_lines = Isis::toInt(m_label["NAXIS2"][0]); + m_bands = Isis::toInt(m_label["NAXIS3"][0]); } else { std::string msg = "NAXIS count of [" + m_label["NAXIS"][0] + diff --git a/isis/src/hayabusa/apps/amica2isis/main.cpp b/isis/src/hayabusa/apps/amica2isis/main.cpp index af7f62e81a..c27878c737 100644 --- a/isis/src/hayabusa/apps/amica2isis/main.cpp +++ b/isis/src/hayabusa/apps/amica2isis/main.cpp @@ -132,7 +132,7 @@ void IsisMain () // Create YearDoy keyword in Archive group iTime stime(QString::fromStdString(outLabel.findGroup("Instrument", Pvl::Traverse)["StartTime"][0])); - PvlKeyword yeardoy("YearDoy", toString(stime.Year()*1000 + stime.DayOfYear())); + PvlKeyword yeardoy("YearDoy", Isis::toString(stime.Year()*1000 + stime.DayOfYear())); outLabel.findGroup("Archive", Pvl::Traverse).addKeyword(yeardoy); diff --git a/isis/src/hayabusa/apps/amicacal/main.cpp b/isis/src/hayabusa/apps/amicacal/main.cpp index 4481aba80c..6cc5c58156 100644 --- a/isis/src/hayabusa/apps/amicacal/main.cpp +++ b/isis/src/hayabusa/apps/amicacal/main.cpp @@ -461,21 +461,21 @@ void IsisMain() { // Add PSF parameter to the calibration reporting key = PvlKeyword("PSF_KernelSize"); - key.addValue(toString(g_size)); - key.addValue(toString(g_size)); + key.addValue(Isis::toString(g_size)); + key.addValue(Isis::toString(g_size)); calibrationLog.addKeyword(key); - calibrationLog.addKeyword(PvlKeyword("PSF_Focused", toString(g_alpha, 6))); + calibrationLog.addKeyword(PvlKeyword("PSF_Focused", Isis::toString(g_alpha, 6))); key = PvlKeyword("PSF_Sigma"); for (int i = 0 ; i < g_N ; i++ ) { - key.addValue(toString(g_sigma[i])); + key.addValue(Isis::toString(g_sigma[i])); } calibrationLog.addKeyword(key); key = PvlKeyword("PSF_Diffuse"); for (int i = 0 ; i < g_N ; i++ ) { - key.addValue(toString(g_A[i])); + key.addValue(Isis::toString(g_A[i])); } } @@ -629,8 +629,8 @@ QString loadCalibrationVariables(const QString &config, Cube *iCube) { // Load the hot pixels into a vector for (int i = 0; i< hotPixelsGroup.keywords(); i++ ){ - int samp(IString::ToInteger(hotPixelsGroup[i][0])); - int line (IString::ToInteger(hotPixelsGroup[i][1])); + int samp(Isis::toInt(hotPixelsGroup[i][0])); + int line (Isis::toInt(hotPixelsGroup[i][1])); hotPixelVector.append( Pixel(alpha->BetaSample(samp), alpha->BetaLine(line), 1, 0)); } @@ -639,20 +639,20 @@ QString loadCalibrationVariables(const QString &config, Cube *iCube) { g_gamma = linearityGroup["Gamma"]; g_gamma = 1.0 - g_gamma; - g_L0 = IString::ToDouble(linearityGroup["L"][0]); - g_L1 = IString::ToDouble(linearityGroup["L"][1]); + g_L0 = Isis::toDouble(linearityGroup["L"][0]); + g_L1 = Isis::toDouble(linearityGroup["L"][1]); // Load Smear Removal Variables g_tvct = smearGroup["tvct"]; // Load DarkCurrent variables - g_d0 = IString::ToDouble(darkCurrentGroup["D"][0]); - g_d1 = IString::ToDouble(darkCurrentGroup["D"][1]); + g_d0 = Isis::toDouble(darkCurrentGroup["D"][0]); + g_d1 = Isis::toDouble(darkCurrentGroup["D"][1]); // Load Bias variables - g_b0 = IString::ToDouble(biasGroup["B"][0]); - g_b1 = IString::ToDouble(biasGroup["B"][1]); - g_b2 = IString::ToDouble(biasGroup["B"][2]); + g_b0 = Isis::toDouble(biasGroup["B"][0]); + g_b1 = Isis::toDouble(biasGroup["B"][1]); + g_b2 = Isis::toDouble(biasGroup["B"][2]); g_launchTimeStr = QString::fromStdString(biasGroup["launchTime"]); diff --git a/isis/src/hayabusa/apps/nirs2isis/NirsImportFits.cpp b/isis/src/hayabusa/apps/nirs2isis/NirsImportFits.cpp index f726c83ec6..c89adefa81 100644 --- a/isis/src/hayabusa/apps/nirs2isis/NirsImportFits.cpp +++ b/isis/src/hayabusa/apps/nirs2isis/NirsImportFits.cpp @@ -129,16 +129,16 @@ namespace Isis { m_label = parseLabel(input, fitsLabelName); // Get data dimensions - int naxis = IString::ToInteger(m_label["NAXIS"][0]); + int naxis = Isis::toInt(m_label["NAXIS"][0]); if (naxis == 2) { - m_samples = IString::ToInteger(m_label["NAXIS1"][0]); - m_lines = IString::ToInteger(m_label["NAXIS2"][0]); + m_samples = Isis::toInt(m_label["NAXIS1"][0]); + m_lines = Isis::toInt(m_label["NAXIS2"][0]); m_bands = 1; } else if (naxis == 3) { - m_samples = IString::ToInteger(m_label["NAXIS1"][0]); - m_lines = IString::ToInteger(m_label["NAXIS2"][0]); - m_bands = IString::ToInteger(m_label["NAXIS3"][0]); + m_samples = Isis::toInt(m_label["NAXIS1"][0]); + m_lines = Isis::toInt(m_label["NAXIS2"][0]); + m_bands = Isis::toInt(m_label["NAXIS3"][0]); } else { std::string msg = "NAXIS count of [" + m_label["NAXIS"][0] + diff --git a/isis/src/hayabusa/apps/nirs2isis/main.cpp b/isis/src/hayabusa/apps/nirs2isis/main.cpp index 66728c877c..58457ec68d 100644 --- a/isis/src/hayabusa/apps/nirs2isis/main.cpp +++ b/isis/src/hayabusa/apps/nirs2isis/main.cpp @@ -156,8 +156,8 @@ void IsisMain() { PvlKeyword filterNumber("FilterNumber"); PvlKeyword center("Center"); for (int channelNumber = 1; channelNumber <= 64; channelNumber++) { - filterNumber += toString( channelNumber ); - center += toString( 2.27144 - 0.02356 * (65 - channelNumber) ); + filterNumber += Isis::toString( channelNumber ); + center += Isis::toString( 2.27144 - 0.02356 * (65 - channelNumber) ); } newLabel.findGroup("BandBin", Pvl::Traverse).addKeyword(filterNumber); newLabel.findGroup("BandBin", Pvl::Traverse).addKeyword(center); @@ -165,7 +165,7 @@ void IsisMain() { // Create YearDoy keyword in Archive group iTime stime(QString::fromStdString(newLabel.findGroup("Instrument", Pvl::Traverse)["StartTime"][0])); - PvlKeyword yeardoy("YearDoy", toString(stime.Year()*1000 + stime.DayOfYear())); + PvlKeyword yeardoy("YearDoy", Isis::toString(stime.Year()*1000 + stime.DayOfYear())); newLabel.findGroup("Archive", Pvl::Traverse).addKeyword(yeardoy); // Add the instrument, band bin, archive, mission data, and kernels diff --git a/isis/src/hayabusa2/apps/hyb2onc2isis/hyb2onc2isis.cpp b/isis/src/hayabusa2/apps/hyb2onc2isis/hyb2onc2isis.cpp index 7abb4ca8cb..107db069f1 100644 --- a/isis/src/hayabusa2/apps/hyb2onc2isis/hyb2onc2isis.cpp +++ b/isis/src/hayabusa2/apps/hyb2onc2isis/hyb2onc2isis.cpp @@ -112,7 +112,7 @@ namespace Isis { // Create YearDoy keyword in Archive group iTime stime(QString::fromStdString(outputLabel.findGroup("Instrument", Pvl::Traverse)["StartTime"][0])); - PvlKeyword yeardoy("YearDoy", toString(stime.Year()*1000 + stime.DayOfYear())); + PvlKeyword yeardoy("YearDoy", Isis::toString(stime.Year()*1000 + stime.DayOfYear())); archGrp.addKeyword(yeardoy); outputCube->putGroup(archGrp); diff --git a/isis/src/hayabusa2/apps/hyb2onccal/main.cpp b/isis/src/hayabusa2/apps/hyb2onccal/main.cpp index 746a3d28c2..9b974fcd2a 100644 --- a/isis/src/hayabusa2/apps/hyb2onccal/main.cpp +++ b/isis/src/hayabusa2/apps/hyb2onccal/main.cpp @@ -373,13 +373,13 @@ QString loadCalibrationVariables(const QString &config) { // g_Tvct = Smear["Tvct"]; // Load DarkCurrent variables - g_d0 = IString::ToDouble(DarkCurrent["D"][0]); - g_d1 = IString::ToDouble(DarkCurrent["D"][1]); + g_d0 = Isis::toDouble(DarkCurrent["D"][0]); + g_d1 = Isis::toDouble(DarkCurrent["D"][1]); // Load Bias variables - g_b0 = IString::ToDouble(Bias["B"][0]); - g_b1 = IString::ToDouble(Bias["B"][1]); - g_b2 = IString::ToDouble(Bias["B"][2]); + g_b0 = Isis::toDouble(Bias["B"][0]); + g_b1 = Isis::toDouble(Bias["B"][1]); + g_b2 = Isis::toDouble(Bias["B"][2]); // Compute BIAS correction factor (it's a constant so do it once!) g_bias = g_b0 + g_b1 * g_AEtemperature + g_b2 * (g_AEtemperature * g_AEtemperature); diff --git a/isis/src/juno/apps/junocam2isis/main.cpp b/isis/src/juno/apps/junocam2isis/main.cpp index a0ffa0f93d..8b2043ceec 100644 --- a/isis/src/juno/apps/junocam2isis/main.cpp +++ b/isis/src/juno/apps/junocam2isis/main.cpp @@ -161,14 +161,14 @@ void IsisMain() { // Update the labels Pvl *fullFrameLabel = g_outputCubes[i]->label(); fullFrameLabel->findGroup("Instrument", PvlObject::Traverse) - .addKeyword(PvlKeyword("FrameNumber", toString(i+1))); + .addKeyword(PvlKeyword("FrameNumber", Isis::toString(i+1))); PvlGroup &bandBin = fullFrameLabel->findGroup("BandBin", PvlObject::Traverse); bandBin.addKeyword(PvlKeyword("FilterName", "FULLCCD"), PvlObject::Replace); // Add filter-specific code to band bin Group - bandBin.addKeyword(PvlKeyword("NaifIkCode", toString(spacecraftCode))); + bandBin.addKeyword(PvlKeyword("NaifIkCode", Isis::toString(spacecraftCode))); importPds.WriteHistory(*g_outputCubes[i]); g_outputCubes[i]->write(origLabels); @@ -182,7 +182,7 @@ void IsisMain() { int numSubimages = importPds.Lines() / g_frameletLines; int frameletsPerFilter = numSubimages / g_filterList.size(); outputLabel.findGroup("Instrument", PvlObject::Traverse) - .addKeyword(PvlKeyword("NumberFramelets", toString(frameletsPerFilter))); + .addKeyword(PvlKeyword("NumberFramelets", Isis::toString(frameletsPerFilter))); // get output file name and remove cube extension, if entered FileName outputFileName(ui.GetCubeName("TO").toStdString()); @@ -255,7 +255,7 @@ void IsisMain() { int frameNumber = (i / g_filterList.size()) + 1; Pvl *frameletLabel = g_outputCubes[i]->label(); frameletLabel->findGroup("Instrument", PvlObject::Traverse) - .addKeyword(PvlKeyword("FrameNumber", toString(frameNumber))); + .addKeyword(PvlKeyword("FrameNumber", Isis::toString(frameNumber))); int filterIndex = i % g_filterList.size(); QString filterName = g_filterList[filterIndex]; @@ -276,7 +276,7 @@ void IsisMain() { spacecraftCode = -61504; } // Add filter-specific code to band bin Group - bandBin.addKeyword(PvlKeyword("NaifIkCode", toString(spacecraftCode))); + bandBin.addKeyword(PvlKeyword("NaifIkCode", Isis::toString(spacecraftCode))); importPds.WriteHistory(*g_outputCubes[i]); g_outputCubes[i]->write(origLabels); @@ -353,7 +353,7 @@ void translateLabel(Pvl &inputLabel, Pvl &outputLabel) { archiveXlater.Auto(outputLabel); PvlGroup &archive = outputLabel.findGroup("Archive", PvlObject::Traverse); iTime startTime(QString::fromStdString(inst["StartTime"][0])); - PvlKeyword yeardoy("YearDoy", toString(startTime.Year()*1000 + startTime.DayOfYear())); + PvlKeyword yeardoy("YearDoy", Isis::toString(startTime.Year()*1000 + startTime.DayOfYear())); archive.addKeyword(yeardoy); UserInterface &ui = Application::GetUserInterface(); @@ -366,7 +366,7 @@ void translateLabel(Pvl &inputLabel, Pvl &outputLabel) { // Setup the kernel group PvlGroup kern("Kernels"); int spacecraftCode = -61500; - kern += PvlKeyword("NaifFrameCode", toString(spacecraftCode)); + kern += PvlKeyword("NaifFrameCode", Isis::toString(spacecraftCode)); outputLabel.findObject("IsisCube").addGroup(kern); } diff --git a/isis/src/juno/objs/JunoCamera/unitTest.cpp b/isis/src/juno/objs/JunoCamera/unitTest.cpp index 13c3747741..2c51d1c6a4 100644 --- a/isis/src/juno/objs/JunoCamera/unitTest.cpp +++ b/isis/src/juno/objs/JunoCamera/unitTest.cpp @@ -61,7 +61,7 @@ int main(void) { // Test Shutter Open/Close const PvlGroup &inst = c.label()->findGroup("Instrument", Pvl::Traverse); - double exposureDuration = IString::ToDouble( inst["ExposureDuration"][0] ); + double exposureDuration = Isis::toDouble( inst["ExposureDuration"][0] ); QString stime = QString::fromStdString(inst["StartTime"]); double et; str2et_c(stime.toLatin1().data(), &et); diff --git a/isis/src/kaguya/apps/kaguyami2isis/kaguyami2isis.cpp b/isis/src/kaguya/apps/kaguyami2isis/kaguyami2isis.cpp index ca7b1b2491..59c5a267b8 100644 --- a/isis/src/kaguya/apps/kaguyami2isis/kaguyami2isis.cpp +++ b/isis/src/kaguya/apps/kaguyami2isis/kaguyami2isis.cpp @@ -120,7 +120,7 @@ namespace Isis { if (baseBand.contains("MV")) { kern += PvlKeyword("NaifFrameCode", (toString(-13133) + QString(baseBand[2]).toStdString())); } - kern += PvlKeyword("NaifCkCode", toString(-131330)); + kern += PvlKeyword("NaifCkCode", Isis::toString(-131330)); } else if (lab.findKeyword("INSTRUMENT_ID")[0] == "MI-NIR") { if (baseBand.contains("MN")) { diff --git a/isis/src/kaguya/apps/kaguyasp2ascii/main.cpp b/isis/src/kaguya/apps/kaguyasp2ascii/main.cpp index 429e269a03..3280274124 100644 --- a/isis/src/kaguya/apps/kaguyasp2ascii/main.cpp +++ b/isis/src/kaguya/apps/kaguyasp2ascii/main.cpp @@ -79,27 +79,27 @@ void IsisMain() { int qaptr = 0; if (lab.hasKeyword("^SP_SPECTRUM_WAV")) { - wavptr = IString::ToInteger(lab.findKeyword("^SP_SPECTRUM_WAV")[keywordIndex]) - 1; + wavptr = Isis::toInt(lab.findKeyword("^SP_SPECTRUM_WAV")[keywordIndex]) - 1; } if (lab.hasKeyword("^SP_SPECTRUM_RAW")) { - rawptr = IString::ToInteger(lab.findKeyword("^SP_SPECTRUM_RAW")[keywordIndex]) - 1; + rawptr = Isis::toInt(lab.findKeyword("^SP_SPECTRUM_RAW")[keywordIndex]) - 1; } if (lab.hasKeyword("^SP_SPECTRUM_RAD")) { - radptr = IString::ToInteger(lab.findKeyword("^SP_SPECTRUM_RAD")[keywordIndex]) - 1; + radptr = Isis::toInt(lab.findKeyword("^SP_SPECTRUM_RAD")[keywordIndex]) - 1; } //older-format file without calibrated NIR2 data if (lab.hasKeyword("^SP_SPECTRUM_REF")) { - refptr1 = IString::ToInteger(lab.findKeyword("^SP_SPECTRUM_REF")[keywordIndex]) - 1; + refptr1 = Isis::toInt(lab.findKeyword("^SP_SPECTRUM_REF")[keywordIndex]) - 1; } //newer-format file with calibrated NIR2 data and 2 different Reflectances if (lab.hasKeyword("^SP_SPECTRUM_REF1")) { - refptr1 = IString::ToInteger(lab.findKeyword("^SP_SPECTRUM_REF1")[keywordIndex]) - 1; + refptr1 = Isis::toInt(lab.findKeyword("^SP_SPECTRUM_REF1")[keywordIndex]) - 1; } if (lab.hasKeyword("^SP_SPECTRUM_REF2")) { - refptr2 = IString::ToInteger(lab.findKeyword("^SP_SPECTRUM_REF2")[keywordIndex]) - 1; + refptr2 = Isis::toInt(lab.findKeyword("^SP_SPECTRUM_REF2")[keywordIndex]) - 1; } if (lab.hasKeyword("^SP_SPECTRUM_QA")) { - qaptr = IString::ToInteger(lab.findKeyword("^SP_SPECTRUM_QA")[keywordIndex]) - 1; + qaptr = Isis::toInt(lab.findKeyword("^SP_SPECTRUM_QA")[keywordIndex]) - 1; } FILE *spcptr; @@ -127,10 +127,10 @@ void IsisMain() { } PvlObject wavobj = lab.findObject("SP_SPECTRUM_WAV"); - int wavlines = IString::ToInteger(wavobj.findKeyword("LINES")[0]); - int wavsamps = IString::ToInteger(wavobj.findKeyword("LINE_SAMPLES")[0]); + int wavlines = Isis::toInt(wavobj.findKeyword("LINES")[0]); + int wavsamps = Isis::toInt(wavobj.findKeyword("LINE_SAMPLES")[0]); QString wavtype = QString::fromStdString(wavobj.findKeyword("SAMPLE_TYPE")); - int wavbits = IString::ToInteger(wavobj.findKeyword("SAMPLE_BITS")[0]); + int wavbits = Isis::toInt(wavobj.findKeyword("SAMPLE_BITS")[0]); if (wavlines != 1 || wavsamps != 296 || wavtype != "MSB_UNSIGNED_INTEGER" || wavbits != 16) { std::string msg = "Wavelength data in input file does not meet the following "; @@ -166,10 +166,10 @@ void IsisMain() { } PvlObject rawobj = lab.findObject("SP_SPECTRUM_RAW"); - int rawlines = IString::ToInteger(rawobj.findKeyword("LINES")[0]); - int rawsamps = IString::ToInteger(rawobj.findKeyword("LINE_SAMPLES")[0]); + int rawlines = Isis::toInt(rawobj.findKeyword("LINES")[0]); + int rawsamps = Isis::toInt(rawobj.findKeyword("LINE_SAMPLES")[0]); QString rawtype = QString::fromStdString(rawobj.findKeyword("SAMPLE_TYPE")); - int rawbits = IString::ToInteger(rawobj.findKeyword("SAMPLE_BITS")[0]); + int rawbits = Isis::toInt(rawobj.findKeyword("SAMPLE_BITS")[0]); if (rawsamps != 296 || rawtype != "MSB_UNSIGNED_INTEGER" || rawbits != 16) { std::string msg = "Raw data in input file does not meet the following "; @@ -204,10 +204,10 @@ void IsisMain() { } PvlObject qaobj = lab.findObject("SP_SPECTRUM_QA"); - int qalines = IString::ToInteger(qaobj.findKeyword("LINES")[0]); - int qasamps = IString::ToInteger(qaobj.findKeyword("LINE_SAMPLES")[0]); + int qalines = Isis::toInt(qaobj.findKeyword("LINES")[0]); + int qasamps = Isis::toInt(qaobj.findKeyword("LINE_SAMPLES")[0]); QString qatype = QString::fromStdString(qaobj.findKeyword("SAMPLE_TYPE")); - int qabits = IString::ToInteger(qaobj.findKeyword("SAMPLE_BITS")[0]); + int qabits = Isis::toInt(qaobj.findKeyword("SAMPLE_BITS")[0]); if (qalines != rawlines || qasamps != 296 || qatype != "MSB_UNSIGNED_INTEGER" || qabits != 16) { std::string msg = "Quality Assessment data in input file does not meet the "; @@ -242,10 +242,10 @@ void IsisMain() { } PvlObject radobj = lab.findObject("SP_SPECTRUM_RAD"); - int radlines = IString::ToInteger(radobj.findKeyword("LINES")[0]); - int radsamps = IString::ToInteger(radobj.findKeyword("LINE_SAMPLES")[0]); + int radlines = Isis::toInt(radobj.findKeyword("LINES")[0]); + int radsamps = Isis::toInt(radobj.findKeyword("LINE_SAMPLES")[0]); QString radtype = QString::fromStdString(radobj.findKeyword("SAMPLE_TYPE")); - int radbits = IString::ToInteger(radobj.findKeyword("SAMPLE_BITS")[0]); + int radbits = Isis::toInt(radobj.findKeyword("SAMPLE_BITS")[0]); if (radlines != qalines || radsamps != 296 || radtype != "MSB_UNSIGNED_INTEGER" || radbits != 16) { std::string msg = "Radiance data in input file does not meet the following "; @@ -290,10 +290,10 @@ void IsisMain() { refobj2 = lab.findObject("SP_SPECTRUM_REF2"); } - int reflines = IString::ToInteger(refobj.findKeyword("LINES")[0]); - int refsamps = IString::ToInteger(refobj.findKeyword("LINE_SAMPLES")[0]); + int reflines = Isis::toInt(refobj.findKeyword("LINES")[0]); + int refsamps = Isis::toInt(refobj.findKeyword("LINE_SAMPLES")[0]); QString reftype = QString::fromStdString(refobj.findKeyword("SAMPLE_TYPE")); - int refbits = IString::ToInteger(refobj.findKeyword("SAMPLE_BITS")[0]); + int refbits = Isis::toInt(refobj.findKeyword("SAMPLE_BITS")[0]); if (reflines != radlines || refsamps != 296 || reftype != "MSB_UNSIGNED_INTEGER" || refbits != 16) { std::string msg = "Reflectance data in input file does not meet the following "; @@ -331,10 +331,10 @@ void IsisMain() { //import reflectance 2 if it exists double *ref2 = NULL; if (lab.hasKeyword("^SP_SPECTRUM_REF2")) { - int reflines2 = IString::ToInteger(refobj2.findKeyword("LINES")[0]); - int refsamps2 = IString::ToInteger(refobj2.findKeyword("LINE_SAMPLES")[0]); + int reflines2 = Isis::toInt(refobj2.findKeyword("LINES")[0]); + int refsamps2 = Isis::toInt(refobj2.findKeyword("LINE_SAMPLES")[0]); QString reftype2 = QString::fromStdString(refobj2.findKeyword("SAMPLE_TYPE")); - int refbits2 = IString::ToInteger(refobj2.findKeyword("SAMPLE_BITS")[0]); + int refbits2 = Isis::toInt(refobj2.findKeyword("SAMPLE_BITS")[0]); if (reflines2 != radlines || refsamps2 != 296 || reftype2 != "MSB_UNSIGNED_INTEGER" || refbits2 != 16) { std::string msg = "Reflectance #2 data in input file does not meet the following "; diff --git a/isis/src/kaguya/apps/kaguyasp2isis/main.cpp b/isis/src/kaguya/apps/kaguyasp2isis/main.cpp index 99a67b6321..5607dd6bdc 100644 --- a/isis/src/kaguya/apps/kaguyasp2isis/main.cpp +++ b/isis/src/kaguya/apps/kaguyasp2isis/main.cpp @@ -58,19 +58,19 @@ void IsisMain() { int qaptr = 0; if (lab.hasKeyword("^SP_SPECTRUM_WAV")) { - wavptr = IString::ToInteger(lab.findKeyword("^SP_SPECTRUM_WAV")[0]) - 1; + wavptr = Isis::toInt(lab.findKeyword("^SP_SPECTRUM_WAV")[0]) - 1; } if (lab.hasKeyword("^SP_SPECTRUM_RAW")) { - rawptr = IString::ToInteger(lab.findKeyword("^SP_SPECTRUM_RAW")[0]) - 1; + rawptr = Isis::toInt(lab.findKeyword("^SP_SPECTRUM_RAW")[0]) - 1; } if (lab.hasKeyword("^SP_SPECTRUM_RAD")) { - radptr = IString::ToInteger(lab.findKeyword("^SP_SPECTRUM_RAD")[0]) - 1; + radptr = Isis::toInt(lab.findKeyword("^SP_SPECTRUM_RAD")[0]) - 1; } if (lab.hasKeyword("^SP_SPECTRUM_REF")) { - refptr = IString::ToInteger(lab.findKeyword("^SP_SPECTRUM_REF")[0]) - 1; + refptr = Isis::toInt(lab.findKeyword("^SP_SPECTRUM_REF")[0]) - 1; } if (lab.hasKeyword("^SP_SPECTRUM_QA")) { - qaptr = IString::ToInteger(lab.findKeyword("^SP_SPECTRUM_REF")[0]) - 1; + qaptr = Isis::toInt(lab.findKeyword("^SP_SPECTRUM_REF")[0]) - 1; } FILE *spcptr; @@ -97,10 +97,10 @@ void IsisMain() { } PvlObject wavobj = lab.findObject("SP_SPECTRUM_WAV"); - int wavlines = IString::ToInteger(wavobj.findKeyword("LINES")[0]); - int wavsamps = IString::ToInteger(wavobj.findKeyword("LINE_SAMPLES")[0]); + int wavlines = Isis::toInt(wavobj.findKeyword("LINES")[0]); + int wavsamps = Isis::toInt(wavobj.findKeyword("LINE_SAMPLES")[0]); QString wavtype = QString::fromStdString(wavobj.findKeyword("SAMPLE_TYPE")); - int wavbits = IString::ToInteger(wavobj.findKeyword("SAMPLE_BITS")[0]); + int wavbits = Isis::toInt(wavobj.findKeyword("SAMPLE_BITS")[0]); if (wavlines != 1 || wavsamps != 296 || wavtype != "MSB_UNSIGNED_INTEGER" || wavbits != 16) { std::string msg = "Wavelength data in input file does not meet the following "; @@ -136,10 +136,10 @@ void IsisMain() { } PvlObject rawobj = lab.findObject("SP_SPECTRUM_RAW"); - int rawlines = IString::ToInteger(rawobj.findKeyword("LINES")[0]); - int rawsamps = IString::ToInteger(rawobj.findKeyword("LINE_SAMPLES")[0]); + int rawlines = Isis::toInt(rawobj.findKeyword("LINES")[0]); + int rawsamps = Isis::toInt(rawobj.findKeyword("LINE_SAMPLES")[0]); QString rawtype = QString::fromStdString(rawobj.findKeyword("SAMPLE_TYPE")); - int rawbits = IString::ToInteger(rawobj.findKeyword("SAMPLE_BITS")[0]); + int rawbits = Isis::toInt(rawobj.findKeyword("SAMPLE_BITS")[0]); if (rawsamps != 296 || rawtype != "MSB_UNSIGNED_INTEGER" || rawbits != 16) { std::string msg = "Raw data in input file does not meet the following "; @@ -174,10 +174,10 @@ void IsisMain() { } PvlObject qaobj = lab.findObject("SP_SPECTRUM_QA"); - int qalines = IString::ToInteger(qaobj.findKeyword("LINES")[0]); - int qasamps = IString::ToInteger(qaobj.findKeyword("LINE_SAMPLES")[0]); + int qalines = Isis::toInt(qaobj.findKeyword("LINES")[0]); + int qasamps = Isis::toInt(qaobj.findKeyword("LINE_SAMPLES")[0]); QString qatype = QString::fromStdString(qaobj.findKeyword("SAMPLE_TYPE")); - int qabits = IString::ToInteger(qaobj.findKeyword("SAMPLE_BITS")[0]); + int qabits = Isis::toInt(qaobj.findKeyword("SAMPLE_BITS")[0]); if (qalines != rawlines || qasamps != 296 || qatype != "MSB_UNSIGNED_INTEGER" || qabits != 16) { std::string msg = "Quality Assessment data in input file does not meet the "; @@ -212,10 +212,10 @@ void IsisMain() { } PvlObject radobj = lab.findObject("SP_SPECTRUM_RAD"); - int radlines = IString::ToInteger(radobj.findKeyword("LINES")[0]); - int radsamps = IString::ToInteger(radobj.findKeyword("LINE_SAMPLES")[0]); + int radlines = Isis::toInt(radobj.findKeyword("LINES")[0]); + int radsamps = Isis::toInt(radobj.findKeyword("LINE_SAMPLES")[0]); QString radtype = QString::fromStdString(radobj.findKeyword("SAMPLE_TYPE")); - int radbits = IString::ToInteger(radobj.findKeyword("SAMPLE_BITS")[0]); + int radbits = Isis::toInt(radobj.findKeyword("SAMPLE_BITS")[0]); if (radlines != qalines || radsamps != 296 || radtype != "MSB_UNSIGNED_INTEGER" || radbits != 16) { std::string msg = "Radiance data in input file does not meet the following "; @@ -250,10 +250,10 @@ void IsisMain() { } PvlObject refobj = lab.findObject("SP_SPECTRUM_REF"); - int reflines = IString::ToInteger(refobj.findKeyword("LINES")[0]); - int refsamps = IString::ToInteger(refobj.findKeyword("LINE_SAMPLES")[0]); + int reflines = Isis::toInt(refobj.findKeyword("LINES")[0]); + int refsamps = Isis::toInt(refobj.findKeyword("LINE_SAMPLES")[0]); QString reftype = QString::fromStdString(refobj.findKeyword("SAMPLE_TYPE")); - int refbits = IString::ToInteger(refobj.findKeyword("SAMPLE_BITS")[0]); + int refbits = Isis::toInt(refobj.findKeyword("SAMPLE_BITS")[0]); if (reflines != radlines || refsamps != 296 || reftype != "MSB_UNSIGNED_INTEGER" || refbits != 16) { std::string msg = "Reflectance data in input file does not meet the following "; diff --git a/isis/src/kaguya/apps/mimap2isis/mimap2isis.cpp b/isis/src/kaguya/apps/mimap2isis/mimap2isis.cpp index 7a36db0d63..922b972527 100644 --- a/isis/src/kaguya/apps/mimap2isis/mimap2isis.cpp +++ b/isis/src/kaguya/apps/mimap2isis/mimap2isis.cpp @@ -28,9 +28,9 @@ namespace Isis { // keyword value in their labels. The following code creates a temporary // detached PDS label with the correct (negated) keyword value. PvlObject obj = label.findObject("IMAGE_MAP_PROJECTION"); - double soff = IString::ToDouble(obj.findKeyword("SAMPLE_PROJECTION_OFFSET")[0]); + double soff = Isis::toDouble(obj.findKeyword("SAMPLE_PROJECTION_OFFSET")[0]); soff = -soff; - label.findObject("IMAGE_MAP_PROJECTION").addKeyword(PvlKeyword("SAMPLE_PROJECTION_OFFSET",toString(soff)),Pvl::Replace); + label.findObject("IMAGE_MAP_PROJECTION").addKeyword(PvlKeyword("SAMPLE_PROJECTION_OFFSET",Isis::toString(soff)),Pvl::Replace); FileName tempFileName = FileName::createTempFile("TEMPORARYlabel.pvl").name(); QString fn(QString::fromStdString(tempFileName.expanded())); label.write(fn.toStdString()); diff --git a/isis/src/lo/apps/lo2isis/lo2isis.cpp b/isis/src/lo/apps/lo2isis/lo2isis.cpp index 281d83a5ce..18b0bff214 100644 --- a/isis/src/lo/apps/lo2isis/lo2isis.cpp +++ b/isis/src/lo/apps/lo2isis/lo2isis.cpp @@ -170,7 +170,7 @@ namespace Isis{ QString imgNumber = QString::fromStdString(inst.findKeyword("ImageNumber")); int subFrame = imgNumber.mid(5).toInt(); - inst.addKeyword(PvlKeyword("SubFrame", toString(subFrame))); + inst.addKeyword(PvlKeyword("SubFrame", Isis::toString(subFrame))); //ImageNumber is auto translated, and no longer needed inst.deleteKeyword("ImageNumber"); diff --git a/isis/src/lo/apps/lopdsgen/main.cpp b/isis/src/lo/apps/lopdsgen/main.cpp index b6da46e6e3..12bec41462 100644 --- a/isis/src/lo/apps/lopdsgen/main.cpp +++ b/isis/src/lo/apps/lopdsgen/main.cpp @@ -151,8 +151,8 @@ void IsisMain() { // Calculate statistics on the cube to be processed and place // its MINIMUM and MAXIMUM into the output label p.CalculateStatistics(); - pdsLabel.findObject("IMAGE").addKeyword(PvlKeyword("MINIMUM", toString(p.CubeStatistics(0)->Minimum())), Pvl::Replace); - pdsLabel.findObject("IMAGE").addKeyword(PvlKeyword("MAXIMUM", toString(p.CubeStatistics(0)->Maximum())), Pvl::Replace); + pdsLabel.findObject("IMAGE").addKeyword(PvlKeyword("MINIMUM", Isis::toString(p.CubeStatistics(0)->Minimum())), Pvl::Replace); + pdsLabel.findObject("IMAGE").addKeyword(PvlKeyword("MAXIMUM", Isis::toString(p.CubeStatistics(0)->Maximum())), Pvl::Replace); } else { FileName inputFile(ui.GetCubeName("FROM").toStdString()); diff --git a/isis/src/lo/objs/LoCameraFiducialMap/LoCameraFiducialMap.cpp b/isis/src/lo/objs/LoCameraFiducialMap/LoCameraFiducialMap.cpp index 5f8b8f70b3..57dc273126 100644 --- a/isis/src/lo/objs/LoCameraFiducialMap/LoCameraFiducialMap.cpp +++ b/isis/src/lo/objs/LoCameraFiducialMap/LoCameraFiducialMap.cpp @@ -61,10 +61,10 @@ namespace Isis { PvlKeyword &fYs = inst["FiducialYCoordinates"]; for(int i = 0; i < fSamps.size(); i++) { - p_fidSamples.push_back(IString::ToDouble(fSamps[i])); - p_fidLines.push_back(IString::ToDouble(fLines[i])); - p_fidXCoords.push_back(IString::ToDouble(fXs[i])); - p_fidYCoords.push_back(IString::ToDouble(fYs[i])); + p_fidSamples.push_back(Isis::toDouble(fSamps[i])); + p_fidLines.push_back(Isis::toDouble(fLines[i])); + p_fidXCoords.push_back(Isis::toDouble(fXs[i])); + p_fidYCoords.push_back(Isis::toDouble(fYs[i])); } } catch(IException &e) { diff --git a/isis/src/lro/apps/lromakeflat/main.cpp b/isis/src/lro/apps/lromakeflat/main.cpp index d8f30736d4..819c300a80 100644 --- a/isis/src/lro/apps/lromakeflat/main.cpp +++ b/isis/src/lro/apps/lromakeflat/main.cpp @@ -361,8 +361,8 @@ void getCubeListNormalization(Matrix2d &matrix, int cubeWidth, int frameHeight, double normalizationAverage = hist.Average(); matrix[listIndex][frame] = normalizationAverage; normResults += PvlKeyword("FileName", g_list[listIndex].toString()); - normResults += PvlKeyword("Frame", toString(frame)); - normResults += PvlKeyword("Frame_MeanAverage", toString(normalizationAverage)); + normResults += PvlKeyword("Frame", Isis::toString(frame)); + normResults += PvlKeyword("Frame_MeanAverage", Isis::toString(normalizationAverage)); Application::Log(normResults); } tmp.close(); @@ -504,7 +504,7 @@ void exclude(int listIndex, int frame, string reason){ PvlObject exclusion("Excluded_Items"); PvlGroup excludedFiles("Excluded_Frames"); excludedFiles += PvlKeyword("Frame_from_cube", g_list[listIndex].toString()); - excludedFiles += PvlKeyword("Frame_number", toString(frame)); + excludedFiles += PvlKeyword("Frame_number", Isis::toString(frame)); excludedFiles += PvlKeyword("Exclusion_reason", reason); Application::Log(excludedFiles); exclusion.addGroup(excludedFiles); diff --git a/isis/src/lro/apps/lronac2isis/lronac2isis.cpp b/isis/src/lro/apps/lronac2isis/lronac2isis.cpp index e0a9ee8f2e..6b92d66dd5 100644 --- a/isis/src/lro/apps/lronac2isis/lronac2isis.cpp +++ b/isis/src/lro/apps/lronac2isis/lronac2isis.cpp @@ -70,9 +70,9 @@ namespace Isis { } for(int i = 0; i < xtermKeyword.size(); i++) { - g_xterm.push_back(IString::ToDouble(xtermKeyword[i])); - g_mterm.push_back(IString::ToDouble(mtermKeyword[i])); - g_bterm.push_back(IString::ToDouble(btermKeyword[i])); + g_xterm.push_back(Isis::toDouble(xtermKeyword[i])); + g_mterm.push_back(Isis::toDouble(mtermKeyword[i])); + g_bterm.push_back(Isis::toDouble(btermKeyword[i])); } double versionId = QString::fromStdString(lab.findKeyword("PRODUCT_VERSION_ID")[0]).remove(QRegExp("^v")).toDouble(); diff --git a/isis/src/lro/apps/lronac2pds/lronac2pds.cpp b/isis/src/lro/apps/lronac2pds/lronac2pds.cpp index f7be2d7021..d2c7d3cd1f 100644 --- a/isis/src/lro/apps/lronac2pds/lronac2pds.cpp +++ b/isis/src/lro/apps/lronac2pds/lronac2pds.cpp @@ -201,18 +201,18 @@ namespace Isis { // Update the "IMAGE" Object PvlObject &imageObject = labelPvl.findObject("IMAGE"); imageObject.clear(); - imageObject += PvlKeyword("LINES", toString(cube->lineCount())); - imageObject += PvlKeyword("LINE_SAMPLES", toString(cube->sampleCount())); + imageObject += PvlKeyword("LINES", Isis::toString(cube->lineCount())); + imageObject += PvlKeyword("LINE_SAMPLES", Isis::toString(cube->sampleCount())); if (g_isIof) { - imageObject += PvlKeyword("SAMPLE_BITS", toString(16)); + imageObject += PvlKeyword("SAMPLE_BITS", Isis::toString(16)); imageObject += PvlKeyword("SAMPLE_TYPE", "LSB_INTEGER"); - imageObject += PvlKeyword("SCALING_FACTOR", toString(1.0 / SCALING_FACTOR)); - imageObject += PvlKeyword("VALID_MINIMUM", toString(Isis::VALID_MIN2)); - imageObject += PvlKeyword("NULL", toString(Isis::NULL2)); - imageObject += PvlKeyword("LOW_REPR_SATURATION", toString(Isis::LOW_REPR_SAT2)); - imageObject += PvlKeyword("LOW_INSTR_SATURATION", toString(Isis::LOW_INSTR_SAT2)); - imageObject += PvlKeyword("HIGH_INSTR_SATURATION", toString(Isis::HIGH_INSTR_SAT2)); - imageObject += PvlKeyword("HIGH_REPR_SATURATION", toString(Isis::HIGH_REPR_SAT2)); + imageObject += PvlKeyword("SCALING_FACTOR", Isis::toString(1.0 / SCALING_FACTOR)); + imageObject += PvlKeyword("VALID_MINIMUM", Isis::toString(Isis::VALID_MIN2)); + imageObject += PvlKeyword("NULL", Isis::toString(Isis::NULL2)); + imageObject += PvlKeyword("LOW_REPR_SATURATION", Isis::toString(Isis::LOW_REPR_SAT2)); + imageObject += PvlKeyword("LOW_INSTR_SATURATION", Isis::toString(Isis::LOW_INSTR_SAT2)); + imageObject += PvlKeyword("HIGH_INSTR_SATURATION", Isis::toString(Isis::HIGH_INSTR_SAT2)); + imageObject += PvlKeyword("HIGH_REPR_SATURATION", Isis::toString(Isis::HIGH_REPR_SAT2)); imageObject += PvlKeyword("UNIT", "Scaled I/F"); } else { @@ -233,13 +233,13 @@ namespace Isis { int recordBytes = cube->sampleCount(); int labelRecords = (int) ((stream.str().length()) / recordBytes) + 1; - labelPvl["RECORD_BYTES"] = toString(recordBytes); + labelPvl["RECORD_BYTES"] = Isis::toString(recordBytes); if (g_isIof) - labelPvl["FILE_RECORDS"] = toString((int) (cube->lineCount() * 2 + labelRecords)); + labelPvl["FILE_RECORDS"] = Isis::toString((int) (cube->lineCount() * 2 + labelRecords)); else - labelPvl["FILE_RECORDS"] = toString((int) (cube->lineCount() * 4 + labelRecords)); - labelPvl["LABEL_RECORDS"] = toString(labelRecords); - labelPvl["^IMAGE"] = toString((int) (labelRecords + 1)); + labelPvl["FILE_RECORDS"] = Isis::toString((int) (cube->lineCount() * 4 + labelRecords)); + labelPvl["LABEL_RECORDS"] = Isis::toString(labelRecords); + labelPvl["^IMAGE"] = Isis::toString((int) (labelRecords + 1)); stream.str(std::string()); @@ -251,9 +251,9 @@ namespace Isis { while ((int)pdsLabel.length() + 2 > (int)(labelRecords * recordBytes)) { labelRecords++; // Refresh the label content - labelPvl["FILE_RECORDS"] = toString((int) (cube->lineCount() * 4 + labelRecords)); - labelPvl["LABEL_RECORDS"] = toString(labelRecords); - labelPvl["^IMAGE"] = toString((int) (labelRecords + 1)); + labelPvl["FILE_RECORDS"] = Isis::toString((int) (cube->lineCount() * 4 + labelRecords)); + labelPvl["LABEL_RECORDS"] = Isis::toString(labelRecords); + labelPvl["^IMAGE"] = Isis::toString((int) (labelRecords + 1)); stream.str(std::string()); stream << labelPvl; pdsLabel = stream.str().c_str(); diff --git a/isis/src/lro/apps/lronaccal/lronaccal.cpp b/isis/src/lro/apps/lronaccal/lronaccal.cpp index 0719c82040..f8008e6355 100644 --- a/isis/src/lro/apps/lronaccal/lronaccal.cpp +++ b/isis/src/lro/apps/lronaccal/lronaccal.cpp @@ -192,10 +192,10 @@ namespace Isis { } for(int i = 0; i < maskedPixels.size(); i++) - if((g_isLeftNac && IString::ToInteger(maskedPixels[i]) < cutoff) || (!g_isLeftNac && IString::ToInteger(maskedPixels[i]) > cutoff)) - g_maskedPixelsLeft.push_back(IString::ToInteger(maskedPixels[i])); + if((g_isLeftNac && Isis::toInt(maskedPixels[i]) < cutoff) || (!g_isLeftNac && Isis::toInt(maskedPixels[i]) > cutoff)) + g_maskedPixelsLeft.push_back(Isis::toInt(maskedPixels[i])); else - g_maskedPixelsRight.push_back(IString::ToInteger(maskedPixels[i])); + g_maskedPixelsRight.push_back(Isis::toInt(maskedPixels[i])); } vector darkFiles; @@ -363,9 +363,9 @@ namespace Isis { if(g_masked) { PvlKeyword darkColumns("DarkColumns"); for(unsigned int i = 0; i < g_maskedPixelsLeft.size(); i++) - darkColumns += toString(g_maskedPixelsLeft[i]); + darkColumns += Isis::toString(g_maskedPixelsLeft[i]); for(unsigned int i = 0; i < g_maskedPixelsRight.size(); i++) - darkColumns += toString(g_maskedPixelsRight[i]); + darkColumns += Isis::toString(g_maskedPixelsRight[i]); calgrp += darkColumns; } @@ -395,18 +395,18 @@ namespace Isis { if(g_iof) { calgrp += PvlKeyword("RadiometricType", "IOF"); if(g_isLeftNac) - calgrp += PvlKeyword("ResponsivityValue", toString(g_iofLeft)); + calgrp += PvlKeyword("ResponsivityValue", Isis::toString(g_iofLeft)); else - calgrp += PvlKeyword("ResponsivityValue", toString(g_iofRight)); + calgrp += PvlKeyword("ResponsivityValue", Isis::toString(g_iofRight)); } else { calgrp += PvlKeyword("RadiometricType", "AbsoluteRadiance"); if(g_isLeftNac) - calgrp += PvlKeyword("ResponsivityValue", toString(g_radianceLeft)); + calgrp += PvlKeyword("ResponsivityValue", Isis::toString(g_radianceLeft)); else - calgrp += PvlKeyword("ResponsivityValue", toString(g_radianceRight)); + calgrp += PvlKeyword("ResponsivityValue", Isis::toString(g_radianceRight)); } - calgrp += PvlKeyword("SolarDistance", toString(g_solarDistance)); + calgrp += PvlKeyword("SolarDistance", Isis::toString(g_solarDistance)); } oCube->putGroup(calgrp); diff --git a/isis/src/lro/apps/lronacpho/LROCEmpirical.cpp b/isis/src/lro/apps/lronacpho/LROCEmpirical.cpp index 6eca37e3f1..bb8c0c8c6f 100644 --- a/isis/src/lro/apps/lronacpho/LROCEmpirical.cpp +++ b/isis/src/lro/apps/lronacpho/LROCEmpirical.cpp @@ -93,7 +93,7 @@ namespace Isis { std::string errs(""); for (int i = 0; i < cube.bandCount(); i++) { - Parameters parms = findParameters(IString::ToDouble(center[i])); + Parameters parms = findParameters(Isis::toDouble(center[i])); if (parms.IsValid()) { parms.band = i + 1; parms.phoStd = photometry(parms, m_iRef, m_eRef, m_gRef); @@ -236,10 +236,10 @@ namespace Isis { } pvl += PvlKeyword("Algorithm", "LROC_Empirical"); - pvl += PvlKeyword("AlgorithmVersion", toString(m_bandpho[0].algoVersion), "" ); - pvl += PvlKeyword("IncRef", toString(m_iRef), "degrees"); - pvl += PvlKeyword("EmaRef", toString(m_eRef), "degrees"); - pvl += PvlKeyword("PhaRef", toString(m_gRef), "degrees"); + pvl += PvlKeyword("AlgorithmVersion", Isis::toString(m_bandpho[0].algoVersion), "" ); + pvl += PvlKeyword("IncRef", Isis::toString(m_iRef), "degrees"); + pvl += PvlKeyword("EmaRef", Isis::toString(m_eRef), "degrees"); + pvl += PvlKeyword("PhaRef", Isis::toString(m_gRef), "degrees"); PvlKeyword units("FunctionUnits"); PvlKeyword phostd("PhotometricStandard"); @@ -250,21 +250,21 @@ namespace Isis { std::vector aTermKeywords; std::vector bTermKeywords; for (unsigned int i = 0; i < m_bandpho[0].aTerms.size(); i++) - aTermKeywords.push_back(PvlKeyword("A" + toString((int) i))); + aTermKeywords.push_back(PvlKeyword("A" + Isis::toString((int) i))); for (unsigned int i = 0; i < m_bandpho[0].bTerms.size(); i++) - bTermKeywords.push_back(PvlKeyword("B" + toString((int) i))); + bTermKeywords.push_back(PvlKeyword("B" + Isis::toString((int) i))); for (unsigned int i = 0; i < m_bandpho.size(); i++) { Parameters &p = m_bandpho[i]; units.addValue(p.units.toStdString()); - phostd.addValue(toString(p.phoStd)); - bbc.addValue(toString(p.wavelength)); - bbct.addValue(toString(p.tolerance)); - bbn.addValue(toString(p.band)); + phostd.addValue(Isis::toString(p.phoStd)); + bbc.addValue(Isis::toString(p.wavelength)); + bbct.addValue(Isis::toString(p.tolerance)); + bbn.addValue(Isis::toString(p.band)); for (unsigned int j = 0; j < aTermKeywords.size(); j++) - aTermKeywords[j].addValue(toString(p.aTerms[j])); + aTermKeywords[j].addValue(Isis::toString(p.aTerms[j])); for (unsigned int j = 0; j < bTermKeywords.size(); j++) - bTermKeywords[j].addValue(toString(p.bTerms[j])); + bTermKeywords[j].addValue(Isis::toString(p.bTerms[j])); } pvl += units; diff --git a/isis/src/lro/apps/lrowac2isis/lrowac2isis.cpp b/isis/src/lro/apps/lrowac2isis/lrowac2isis.cpp index 115caf0164..3ae57c0af7 100644 --- a/isis/src/lro/apps/lrowac2isis/lrowac2isis.cpp +++ b/isis/src/lro/apps/lrowac2isis/lrowac2isis.cpp @@ -222,7 +222,7 @@ namespace Isis { OriginalLabel origLabel(pdsLab); int numFramelets = padding.size(); - PvlKeyword numFrameletsKeyword("NumFramelets", toString(numFramelets)); + PvlKeyword numFrameletsKeyword("NumFramelets", Isis::toString(numFramelets)); if(uveven) { for(int grp = 0; grp < isis3UvEvenLab.groups(); grp++) { @@ -495,10 +495,10 @@ namespace Isis { // color offset doesn't apply to BW mode (single band cubes) if(colorOffset && viseven && viseven->bandCount() == 1) { - genericInstrument.push_back(PvlKeyword("ColorOffset", toString(0))); + genericInstrument.push_back(PvlKeyword("ColorOffset", Isis::toString(0))); } else { - genericInstrument.push_back(PvlKeyword("ColorOffset", toString(colorOffset))); + genericInstrument.push_back(PvlKeyword("ColorOffset", Isis::toString(colorOffset))); } genericInstrument.push_back(PvlKeyword("Decompanded", (ui.GetBoolean("UNLUT") ? "Yes" : "No"))); @@ -520,14 +520,14 @@ namespace Isis { // add labels unique to particular files if(viseven) { visEvenInst.addKeyword(PvlKeyword("Framelets", "Even")); - visEvenInst.addKeyword(PvlKeyword("NumFramelets", toString(viseven->lineCount() / 14))); + visEvenInst.addKeyword(PvlKeyword("NumFramelets", Isis::toString(viseven->lineCount() / 14))); visEvenInst.addKeyword(PvlKeyword("InstrumentId", "WAC-VIS"), Pvl::Replace); visEvenInst.addKeyword(PvlKeyword("InstrumentModeId", pdsLab["INSTRUMENT_MODE_ID"])); } if(visodd) { visOddInst.addKeyword(PvlKeyword("Framelets", "Odd")); - visOddInst.addKeyword(PvlKeyword("NumFramelets", toString(visodd->lineCount() / 14))); + visOddInst.addKeyword(PvlKeyword("NumFramelets", Isis::toString(visodd->lineCount() / 14))); visOddInst.addKeyword(PvlKeyword("InstrumentId", "WAC-VIS"), Pvl::Replace); visOddInst.addKeyword(PvlKeyword("InstrumentModeId", pdsLab["INSTRUMENT_MODE_ID"])); } @@ -549,7 +549,7 @@ namespace Isis { } else { for(int i = 0; i < pdsLab["FILTER_NUMBER"].size(); i++) { - if(IString::ToInteger(pdsLab["FILTER_NUMBER"][i]) > 2) { + if(Isis::toInt(pdsLab["FILTER_NUMBER"][i]) > 2) { visWavelength += pdsLab["CENTER_FILTER_WAVELENGTH"][i]; visFilterNum += pdsLab["FILTER_NUMBER"][i]; @@ -577,14 +577,14 @@ namespace Isis { if(uveven) { uvEvenInst.addKeyword(PvlKeyword("Framelets", "Even")); - uvEvenInst.addKeyword(PvlKeyword("NumFramelets", toString(uveven->lineCount() / 4))); + uvEvenInst.addKeyword(PvlKeyword("NumFramelets", Isis::toString(uveven->lineCount() / 4))); uvEvenInst.addKeyword(PvlKeyword("InstrumentId", "WAC-UV"), Pvl::Replace); uvEvenInst.addKeyword(PvlKeyword("InstrumentModeId", pdsLab["INSTRUMENT_MODE_ID"])); } if(uvodd) { uvOddInst.addKeyword(PvlKeyword("Framelets", "Odd")); - uvOddInst.addKeyword(PvlKeyword("NumFramelets", toString(uvodd->lineCount() / 4))); + uvOddInst.addKeyword(PvlKeyword("NumFramelets", Isis::toString(uvodd->lineCount() / 4))); uvOddInst.addKeyword(PvlKeyword("InstrumentId", "WAC-UV"), Pvl::Replace); uvOddInst.addKeyword(PvlKeyword("InstrumentModeId", pdsLab["INSTRUMENT_MODE_ID"])); } @@ -596,7 +596,7 @@ namespace Isis { PvlKeyword uvBandwidth("Width"); for(int i = 0; i < pdsLab["FILTER_NUMBER"].size(); i++) { - if(IString::ToInteger(pdsLab["FILTER_NUMBER"][i]) <= 2) { + if(Isis::toInt(pdsLab["FILTER_NUMBER"][i]) <= 2) { uvWavelength += pdsLab["CENTER_FILTER_WAVELENGTH"][i]; uvFilterNum += pdsLab["FILTER_NUMBER"][i]; @@ -742,7 +742,7 @@ namespace Isis { bool found = false; bool match = false; for(int j = 0; !found && j < (int) filters.size(); j++) { - if(IString::ToInteger(pdsLab["FILTER_NUMBER"][i]) == filters[j].first) { + if(Isis::toInt(pdsLab["FILTER_NUMBER"][i]) == filters[j].first) { found = true; match = (pdsLab["CENTER_FILTER_WAVELENGTH"][i] == filters[j].second.toStdString()); diff --git a/isis/src/lro/apps/lrowac2pds/lrowac2pds.cpp b/isis/src/lro/apps/lrowac2pds/lrowac2pds.cpp index a04ad309b7..875e9c7efe 100644 --- a/isis/src/lro/apps/lrowac2pds/lrowac2pds.cpp +++ b/isis/src/lro/apps/lrowac2pds/lrowac2pds.cpp @@ -418,9 +418,9 @@ namespace Isis { // Update the "IMAGE" Object PvlObject &imageObject = labelPvl.findObject("IMAGE"); imageObject.clear(); - imageObject += PvlKeyword("LINES", toString(cube->lineCount())); - imageObject += PvlKeyword("LINE_SAMPLES", toString(cube->sampleCount())); - imageObject += PvlKeyword("SAMPLE_BITS", toString(32)); + imageObject += PvlKeyword("LINES", Isis::toString(cube->lineCount())); + imageObject += PvlKeyword("LINE_SAMPLES", Isis::toString(cube->sampleCount())); + imageObject += PvlKeyword("SAMPLE_BITS", Isis::toString(32)); imageObject += PvlKeyword("SAMPLE_TYPE", "PC_REAL"); imageObject += PvlKeyword("VALID_MINIMUM", "16#FF7FFFFA#"); imageObject += PvlKeyword("NULL", "16#FF7FFFFB#"); @@ -439,10 +439,10 @@ namespace Isis { int recordBytes = cube->sampleCount(); int labelRecords = (int) ((stream.str().length()) / recordBytes) + 1; - labelPvl["RECORD_BYTES"] = toString(recordBytes); - labelPvl["FILE_RECORDS"] = toString((int) (cube->lineCount() * 4 + labelRecords)); - labelPvl["LABEL_RECORDS"] = toString(labelRecords); - labelPvl["^IMAGE"] = toString((int) (labelRecords + 1)); + labelPvl["RECORD_BYTES"] = Isis::toString(recordBytes); + labelPvl["FILE_RECORDS"] = Isis::toString((int) (cube->lineCount() * 4 + labelRecords)); + labelPvl["LABEL_RECORDS"] = Isis::toString(labelRecords); + labelPvl["^IMAGE"] = Isis::toString((int) (labelRecords + 1)); stream.str(std::string()); @@ -455,9 +455,9 @@ namespace Isis { while ((int)pdsLabel.length() + 2 > (int)(labelRecords * recordBytes)) { labelRecords++; // Refresh the label content - labelPvl["FILE_RECORDS"] = toString((int) (cube->lineCount() * 4 + labelRecords)); - labelPvl["LABEL_RECORDS"] = toString(labelRecords); - labelPvl["^IMAGE"] = toString((int) (labelRecords + 1)); + labelPvl["FILE_RECORDS"] = Isis::toString((int) (cube->lineCount() * 4 + labelRecords)); + labelPvl["LABEL_RECORDS"] = Isis::toString(labelRecords); + labelPvl["^IMAGE"] = Isis::toString((int) (labelRecords + 1)); stream.str(std::string()); stream << labelPvl; pdsLabel = stream.str().c_str(); diff --git a/isis/src/lro/apps/lrowaccal/lrowaccal.cpp b/isis/src/lro/apps/lrowaccal/lrowaccal.cpp index 76d9ba537f..10f90f8987 100644 --- a/isis/src/lro/apps/lrowaccal/lrowaccal.cpp +++ b/isis/src/lro/apps/lrowaccal/lrowaccal.cpp @@ -653,7 +653,7 @@ namespace Isis { responsivity = radPvl["IOF"]; for (int i = 0; i < bands.size(); i++) { - g_iofResponsivity.push_back(IString::ToDouble(responsivity[IString::ToInteger(bands[i]) - 1])); + g_iofResponsivity.push_back(Isis::toDouble(responsivity[Isis::toInt(bands[i]) - 1])); } try { @@ -704,7 +704,7 @@ namespace Isis { else { responsivity = radPvl["Radiance"]; for (int i = 0; i < bands.size(); i++) - g_radianceResponsivity.push_back(IString::ToDouble(responsivity[IString::ToInteger(bands[i]) - 1])); + g_radianceResponsivity.push_back(Isis::toDouble(responsivity[Isis::toInt(bands[i]) - 1])); } } @@ -738,8 +738,8 @@ namespace Isis { Pvl tempPvl(tempFileName.expanded()); temperaturePvl.addValue(tempFileName.expanded()); for (int b = 0; b < bands.size(); b++){ - g_TempratureConstants[g_bands[b]][0]=IString::ToDouble(tempPvl[bands[b]][0]); - g_TempratureConstants[g_bands[b]][1]=IString::ToDouble(tempPvl[bands[b]][1]); + g_TempratureConstants[g_bands[b]][0]=Isis::toDouble(tempPvl[bands[b]][0]); + g_TempratureConstants[g_bands[b]][1]=Isis::toDouble(tempPvl[bands[b]][1]); } } @@ -781,15 +781,15 @@ namespace Isis { if (g_iof) { calgrp += PvlKeyword("RadiometricType", "IOF"); for (unsigned int i=0; i< g_iofResponsivity.size(); i++) - vals.addValue(toString(g_iofResponsivity[i])); + vals.addValue(Isis::toString(g_iofResponsivity[i])); } else { calgrp += PvlKeyword("RadiometricType", "AbsoluteRadiance", "W/m2/sr/um"); for (unsigned int i=0; i< g_radianceResponsivity.size(); i++) - vals.addValue(toString(g_radianceResponsivity[i])); + vals.addValue(Isis::toString(g_radianceResponsivity[i])); } calgrp += vals; - calgrp += PvlKeyword("SolarDistance", toString(g_solarDistance)); + calgrp += PvlKeyword("SolarDistance", Isis::toString(g_solarDistance)); } if (g_specpix) calgrp += PvlKeyword("SpecialPixelsFile", specpixFile.toStdString()); diff --git a/isis/src/lro/apps/lrowacpho/Exponential.cpp b/isis/src/lro/apps/lrowacpho/Exponential.cpp index d8dea2bcd6..2838c17ea0 100644 --- a/isis/src/lro/apps/lrowacpho/Exponential.cpp +++ b/isis/src/lro/apps/lrowacpho/Exponential.cpp @@ -116,9 +116,9 @@ namespace Isis { pvl.addComment(" F(phase) = A0*exp(B0*phase) + A1*exp(B1*phase) + ... + An*exp(Bn*phase)"); pvl += PvlKeyword("Algorithm", "Exponential"); - pvl += PvlKeyword("IncRef", toString(m_iRef), "degrees"); - pvl += PvlKeyword("EmaRef", toString(m_eRef), "degrees"); - pvl += PvlKeyword("PhaRef", toString(m_gRef), "degrees"); + pvl += PvlKeyword("IncRef", Isis::toString(m_iRef), "degrees"); + pvl += PvlKeyword("EmaRef", Isis::toString(m_eRef), "degrees"); + pvl += PvlKeyword("PhaRef", Isis::toString(m_gRef), "degrees"); PvlKeyword units("ExponentialUnits"); PvlKeyword phostd("PhotometricStandard"); PvlKeyword bbc("BandBinCenter"); @@ -128,21 +128,21 @@ namespace Isis { std::vector < PvlKeyword > aTermKeywords; std::vector < PvlKeyword > bTermKeywords; for (unsigned int i = 0; i < m_bandpho[0].aTerms.size(); i++) - aTermKeywords.push_back(PvlKeyword("A" + toString((int) i))); + aTermKeywords.push_back(PvlKeyword("A" + Isis::toString((int) i))); for (unsigned int i = 0; i < m_bandpho[0].bTerms.size(); i++) - bTermKeywords.push_back(PvlKeyword("B" + toString((int) i))); + bTermKeywords.push_back(PvlKeyword("B" + Isis::toString((int) i))); for (unsigned int i = 0; i < m_bandpho.size(); i++) { Parameters &p = m_bandpho[i]; units.addValue(p.units.toStdString()); - phostd.addValue(toString(p.phoStd)); - bbc.addValue(toString(p.wavelength)); - bbct.addValue(toString(p.tolerance)); - bbn.addValue(toString(p.band)); + phostd.addValue(Isis::toString(p.phoStd)); + bbc.addValue(Isis::toString(p.wavelength)); + bbct.addValue(Isis::toString(p.tolerance)); + bbn.addValue(Isis::toString(p.band)); for (unsigned int j = 0; j < aTermKeywords.size(); j++) - aTermKeywords[j].addValue(toString(p.aTerms[j])); + aTermKeywords[j].addValue(Isis::toString(p.aTerms[j])); for (unsigned int j = 0; j < bTermKeywords.size(); j++) - bTermKeywords[j].addValue(toString(p.bTerms[j])); + bTermKeywords[j].addValue(Isis::toString(p.bTerms[j])); } pvl += units; pvl += phostd; @@ -268,7 +268,7 @@ namespace Isis { PvlKeyword center = label->findGroup("BandBin", Pvl::Traverse)["Center"]; std::string errs(""); for (int i = 0; i < cube.bandCount(); i++) { - Parameters parms = findParameters(IString::ToDouble(center[i])); + Parameters parms = findParameters(Isis::toDouble(center[i])); if (parms.IsValid()) { parms.band = i + 1; //_camera->SetBand(i + 1); diff --git a/isis/src/lro/apps/lrowacpho/HapkeExponential.cpp b/isis/src/lro/apps/lrowacpho/HapkeExponential.cpp index 02c223eed2..abae7957af 100644 --- a/isis/src/lro/apps/lrowacpho/HapkeExponential.cpp +++ b/isis/src/lro/apps/lrowacpho/HapkeExponential.cpp @@ -121,9 +121,9 @@ namespace Isis { pvl.addComment(" F(mu,mu0,phase) = A1*exp(B1*phase) + A2*( mu0 + mu )exp(B2*phase) + A3*( mu0 + mu ) + A4"); pvl += PvlKeyword("Algorithm", "HapkeExponential"); - pvl += PvlKeyword("IncRef", toString(m_iRef), "degrees"); - pvl += PvlKeyword("EmaRef", toString(m_eRef), "degrees"); - pvl += PvlKeyword("PhaRef", toString(m_gRef), "degrees"); + pvl += PvlKeyword("IncRef", Isis::toString(m_iRef), "degrees"); + pvl += PvlKeyword("EmaRef", Isis::toString(m_eRef), "degrees"); + pvl += PvlKeyword("PhaRef", Isis::toString(m_gRef), "degrees"); PvlKeyword units("HapkeExponentialUnits"); PvlKeyword phostd("PhotometricStandard"); PvlKeyword bbc("BandBinCenter"); @@ -133,21 +133,21 @@ namespace Isis { std::vector aTermKeywords; std::vector bTermKeywords; for (unsigned int i = 0; i < m_bandpho[0].aTerms.size(); i++) - aTermKeywords.push_back(PvlKeyword("A" + toString((int) i+1))); + aTermKeywords.push_back(PvlKeyword("A" + Isis::toString((int) i+1))); for (unsigned int i = 0; i < m_bandpho[0].bTerms.size(); i++) - bTermKeywords.push_back(PvlKeyword("B" + toString((int) i+1))); + bTermKeywords.push_back(PvlKeyword("B" + Isis::toString((int) i+1))); for (unsigned int i = 0; i < m_bandpho.size(); i++) { Parameters &p = m_bandpho[i]; units.addValue(p.units.toStdString()); - phostd.addValue(toString(p.phoStd)); - bbc.addValue(toString(p.wavelength)); - bbct.addValue(toString(p.tolerance)); - bbn.addValue(toString(p.band)); + phostd.addValue(Isis::toString(p.phoStd)); + bbc.addValue(Isis::toString(p.wavelength)); + bbct.addValue(Isis::toString(p.tolerance)); + bbn.addValue(Isis::toString(p.band)); for (unsigned int j = 0; j < aTermKeywords.size(); j++) - aTermKeywords[j].addValue(toString(p.aTerms[j])); + aTermKeywords[j].addValue(Isis::toString(p.aTerms[j])); for (unsigned int j = 0; j < bTermKeywords.size(); j++) - bTermKeywords[j].addValue(toString(p.bTerms[j])); + bTermKeywords[j].addValue(Isis::toString(p.bTerms[j])); } pvl += units; pvl += phostd; @@ -271,7 +271,7 @@ namespace Isis { PvlKeyword center = label->findGroup("BandBin", Pvl::Traverse)["Center"]; std::string errs(""); for (int i = 0; i < cube.bandCount(); i++) { - Parameters parms = findParameters(IString::ToDouble(center[i])); + Parameters parms = findParameters(Isis::toDouble(center[i])); if (parms.IsValid()) { parms.band = i + 1; //_camera->SetBand(i + 1); diff --git a/isis/src/lro/apps/lrowacpho/Hillier.cpp b/isis/src/lro/apps/lrowacpho/Hillier.cpp index 6ccab202d0..4e1b8262f4 100644 --- a/isis/src/lro/apps/lrowacpho/Hillier.cpp +++ b/isis/src/lro/apps/lrowacpho/Hillier.cpp @@ -114,9 +114,9 @@ namespace Isis { pvl.addComment(" F(phase) = B0*exp(-B1*phase) + A0 + A1*phase + A2*phase^2 + A3*phase^3 + A4*phase^4"); pvl += PvlKeyword("Algorithm", "Hillier"); - pvl += PvlKeyword("IncRef", toString(m_iRef), "degrees"); - pvl += PvlKeyword("EmaRef", toString(m_eRef), "degrees"); - pvl += PvlKeyword("PhaRef", toString(m_gRef), "degrees"); + pvl += PvlKeyword("IncRef", Isis::toString(m_iRef), "degrees"); + pvl += PvlKeyword("EmaRef", Isis::toString(m_eRef), "degrees"); + pvl += PvlKeyword("PhaRef", Isis::toString(m_gRef), "degrees"); PvlKeyword units("HillierUnits"); PvlKeyword phostd("PhotometricStandard"); PvlKeyword bbc("BandBinCenter"); @@ -132,17 +132,17 @@ namespace Isis { for (unsigned int i = 0; i < m_bandpho.size(); i++) { Parameters &p = m_bandpho[i]; units.addValue(p.units.toStdString()); - phostd.addValue(toString(p.phoStd)); - bbc.addValue(toString(p.wavelength)); - bbct.addValue(toString(p.tolerance)); - bbn.addValue(toString(p.band)); - b0.addValue(toString(p.b0)); - b1.addValue(toString(p.b1)); - a0.addValue(toString(p.a0)); - a1.addValue(toString(p.a1)); - a2.addValue(toString(p.a2)); - a3.addValue(toString(p.a3)); - a4.addValue(toString(p.a4)); + phostd.addValue(Isis::toString(p.phoStd)); + bbc.addValue(Isis::toString(p.wavelength)); + bbct.addValue(Isis::toString(p.tolerance)); + bbn.addValue(Isis::toString(p.band)); + b0.addValue(Isis::toString(p.b0)); + b1.addValue(Isis::toString(p.b1)); + a0.addValue(Isis::toString(p.a0)); + a1.addValue(Isis::toString(p.a1)); + a2.addValue(Isis::toString(p.a2)); + a3.addValue(Isis::toString(p.a3)); + a4.addValue(Isis::toString(p.a4)); } pvl += units; pvl += phostd; @@ -267,7 +267,7 @@ namespace Isis { PvlKeyword center = label->findGroup("BandBin", Pvl::Traverse)["Center"]; std::string errs(""); for (int i = 0; i < cube.bandCount(); i++) { - Parameters parms = findParameters(IString::ToDouble(center[i])); + Parameters parms = findParameters(Isis::toDouble(center[i])); if (parms.IsValid()) { parms.band = i + 1; //_camera->SetBand(i + 1); diff --git a/isis/src/lro/apps/lrowacphomap/HapkeLRO.cpp b/isis/src/lro/apps/lrowacphomap/HapkeLRO.cpp index 364aa16990..7742f44c7b 100644 --- a/isis/src/lro/apps/lrowacphomap/HapkeLRO.cpp +++ b/isis/src/lro/apps/lrowacphomap/HapkeLRO.cpp @@ -65,9 +65,9 @@ namespace Isis { m_currentMapIndex = 0; PvlObject phoModel = pvl.findObject("PhotometricModel"); - m_iRef = IString::ToDouble(phoModel.findKeyword("Incref")[0]); // Incidence refernce angle - m_eRef = IString::ToDouble(phoModel.findKeyword("EmiRef")[0]); // Emission reference angle - m_gRef = IString::ToDouble(phoModel.findKeyword("Pharef")[0]); // Phase reference angle + m_iRef = Isis::toDouble(phoModel.findKeyword("Incref")[0]); // Incidence refernce angle + m_eRef = Isis::toDouble(phoModel.findKeyword("EmiRef")[0]); // Emission reference angle + m_gRef = Isis::toDouble(phoModel.findKeyword("Pharef")[0]); // Phase reference angle if (QString::fromStdString(phoModel.findKeyword("Units")[0]).toUpper() == "DEGREES") { m_isDegrees = true; } @@ -85,7 +85,7 @@ namespace Isis { PvlGroup paramGroup = phoModel.group(i); HapkeLRO::Parameters parms; - parms.bandBinCenter = IString::ToDouble(paramGroup.findKeyword("BandBinCenter")[0]); + parms.bandBinCenter = Isis::toDouble(paramGroup.findKeyword("BandBinCenter")[0]); for (int j = 0; j < center.size(); j++) { if (center[j] == paramGroup.findKeyword("BandBinCenter")[0]) { parms.band = j + 1; @@ -94,8 +94,8 @@ namespace Isis { PvlKeyword bands = paramGroup.findKeyword("Bands"); for (int j = 0; j < bands.size(); j++) { - parms.mapBands.push_back(IString::ToInteger(bands[j]) - 1); - parms.names.push_back(QString::fromStdString(paramBandNames[IString::ToInteger(bands[j]) - 1]).toUpper()); + parms.mapBands.push_back(Isis::toInt(bands[j]) - 1); + parms.names.push_back(QString::fromStdString(paramBandNames[Isis::toInt(bands[j]) - 1]).toUpper()); parms.values.push_back(0.0); } @@ -329,9 +329,9 @@ namespace Isis { pvl += PvlKeyword("Algorithm", "HapkeLRO"); pvl += PvlKeyword("ParameterMapCube", m_paramMap->fileName().toStdString()); - pvl += PvlKeyword("IncRef", toString(m_iRef), "degrees"); - pvl += PvlKeyword("EmiRef", toString(m_eRef), "degrees"); - pvl += PvlKeyword("PhaRef", toString(m_gRef), "degrees"); + pvl += PvlKeyword("IncRef", Isis::toString(m_iRef), "degrees"); + pvl += PvlKeyword("EmiRef", Isis::toString(m_eRef), "degrees"); + pvl += PvlKeyword("PhaRef", Isis::toString(m_gRef), "degrees"); PvlKeyword units("Units"); if (m_isDegrees) { diff --git a/isis/src/lro/apps/lrowacphomap/HapkeLROC.cpp b/isis/src/lro/apps/lrowacphomap/HapkeLROC.cpp index 1f5cedad3c..d7a5302f73 100644 --- a/isis/src/lro/apps/lrowacphomap/HapkeLROC.cpp +++ b/isis/src/lro/apps/lrowacphomap/HapkeLROC.cpp @@ -57,9 +57,9 @@ namespace Isis { m_currentMapIndex = 0; PvlObject phoModel = pvl.findObject("PhotometricModel"); - m_iRef = IString::ToDouble(phoModel.findKeyword("Incref")[0]); // Incidence refernce angle - m_eRef = IString::ToDouble(phoModel.findKeyword("EmiRef")[0]); // Emission reference angle - m_gRef = IString::ToDouble(phoModel.findKeyword("Pharef")[0]); // Phase reference angle + m_iRef = Isis::toDouble(phoModel.findKeyword("Incref")[0]); // Incidence refernce angle + m_eRef = Isis::toDouble(phoModel.findKeyword("EmiRef")[0]); // Emission reference angle + m_gRef = Isis::toDouble(phoModel.findKeyword("Pharef")[0]); // Phase reference angle if (QString::fromStdString(phoModel.findKeyword("Units")[0]).toUpper() == "DEGREES") { m_isDegrees = true; @@ -78,7 +78,7 @@ namespace Isis { PvlGroup paramGroup = phoModel.group(i); HapkeLROC::Parameters parms; - parms.bandBinCenter = IString::ToDouble(paramGroup.findKeyword("BandBinCenter")[0]); + parms.bandBinCenter = Isis::toDouble(paramGroup.findKeyword("BandBinCenter")[0]); for (int j = 0; j < center.size(); j++) { if (center[j] == paramGroup.findKeyword("BandBinCenter")[0]) { parms.band = j + 1; @@ -87,8 +87,8 @@ namespace Isis { PvlKeyword bands = paramGroup.findKeyword("Bands"); for (int j = 0; j < bands.size(); j++) { - parms.mapBands.push_back(IString::ToInteger(bands[j]) - 1); - parms.names.push_back(QString::fromStdString(paramBandNames[IString::ToInteger(bands[j]) - 1]).toUpper()); + parms.mapBands.push_back(Isis::toInt(bands[j]) - 1); + parms.names.push_back(QString::fromStdString(paramBandNames[Isis::toInt(bands[j]) - 1]).toUpper()); parms.values.push_back(0.0); } @@ -616,9 +616,9 @@ namespace Isis { void HapkeLROC::report(PvlContainer &pvl) { pvl += PvlKeyword("Algorithm", "HapkeLROC"); pvl += PvlKeyword("ParameterMapCube", m_paramMap->fileName().toStdString()); - pvl += PvlKeyword("IncRef", toString(m_iRef), "degrees"); - pvl += PvlKeyword("EmiRef", toString(m_eRef), "degrees"); - pvl += PvlKeyword("PhaRef", toString(m_gRef), "degrees"); + pvl += PvlKeyword("IncRef", Isis::toString(m_iRef), "degrees"); + pvl += PvlKeyword("EmiRef", Isis::toString(m_eRef), "degrees"); + pvl += PvlKeyword("PhaRef", Isis::toString(m_gRef), "degrees"); PvlKeyword units("Units"); if (m_isDegrees) { diff --git a/isis/src/lro/apps/mrf2isis/main.cpp b/isis/src/lro/apps/mrf2isis/main.cpp index 0f46450303..8f783636d0 100644 --- a/isis/src/lro/apps/mrf2isis/main.cpp +++ b/isis/src/lro/apps/mrf2isis/main.cpp @@ -149,15 +149,15 @@ void IsisMain() { else { // BASELINE_X or ZOOM_X frequency = 7140000000.0; } - instGrp.addKeyword(PvlKeyword("Frequency", toString(frequency))); + instGrp.addKeyword(PvlKeyword("Frequency", Isis::toString(frequency))); outcube->putGroup(instGrp); } PvlGroup kerns("Kernels"); if(id.startsWith("CHAN1") || id.startsWith("CH1")) { - kerns += PvlKeyword("NaifFrameCode", toString(-86001)); + kerns += PvlKeyword("NaifFrameCode", Isis::toString(-86001)); } else { // LRO - kerns += PvlKeyword("NaifFrameCode", toString(-85700)); + kerns += PvlKeyword("NaifFrameCode", Isis::toString(-85700)); } outcube->putGroup(kerns); } diff --git a/isis/src/lro/objs/LroWideAngleCamera/LroWideAngleCamera.cpp b/isis/src/lro/objs/LroWideAngleCamera/LroWideAngleCamera.cpp index 87d15b0d34..6345ea7ce4 100644 --- a/isis/src/lro/objs/LroWideAngleCamera/LroWideAngleCamera.cpp +++ b/isis/src/lro/objs/LroWideAngleCamera/LroWideAngleCamera.cpp @@ -59,7 +59,7 @@ namespace Isis { QString stime = QString::fromStdString(inst["SpacecraftClockStartCount"]); et = getClockTime(stime).Et(); - p_exposureDur = IString::ToDouble(inst["ExposureDuration"]); + p_exposureDur = Isis::toDouble(inst["ExposureDuration"]); // TODO: Changed et - exposure to et + exposure. // Think about if this is correct p_etStart = et + ((p_exposureDur / 1000.0) / 2.0); @@ -148,15 +148,15 @@ namespace Isis { // Now map the actual filters that exist in cube to camera components or // storage vectors for later band selection (see SetBand(vband)) for (int i = 0; i < filtNames.size(); i++) { - if (!filterToDetectorOffset.exists(IString::ToInteger(filtNames[i]))) { + if (!filterToDetectorOffset.exists(Isis::toInt(filtNames[i]))) { std::string msg = "Unrecognized filter name [" + filtNames[i] + "]"; throw IException(IException::Programmer, msg, _FILEINFO_); } - p_detectorStartLines.push_back(filterToDetectorOffset.get(IString::ToInteger(filtNames[i]))); - p_frameletOffsets.push_back(filterToFrameletOffset.get(IString::ToInteger(filtNames[i]))); + p_detectorStartLines.push_back(filterToDetectorOffset.get(Isis::toInt(filtNames[i]))); + p_frameletOffsets.push_back(filterToFrameletOffset.get(Isis::toInt(filtNames[i]))); - QString kBase = "INS" + QString::number(filterIKCode.get(IString::ToInteger(filtNames[i]))); + QString kBase = "INS" + QString::number(filterIKCode.get(Isis::toInt(filtNames[i]))); p_focalLength.push_back(getDouble(kBase+"_FOCAL_LENGTH")); p_boreSightSample.push_back(getDouble(kBase+"_BORESIGHT_SAMPLE")); p_boreSightLine.push_back(getDouble(kBase+"_BORESIGHT_LINE")); @@ -194,8 +194,8 @@ namespace Isis { LroWideAngleCameraDistortionMap *distort = new LroWideAngleCameraDistortionMap(this, naifIkCode()); for ( int i = 0 ; i < filtNames.size() ; i++ ) { - fplane->addFilter(filterIKCode.get(IString::ToInteger(filtNames[i]))); - distort->addFilter(filterIKCode.get(IString::ToInteger(filtNames[i]))); + fplane->addFilter(filterIKCode.get(Isis::toInt(filtNames[i]))); + distort->addFilter(filterIKCode.get(Isis::toInt(filtNames[i]))); } // Setup the ground and sky map @@ -307,7 +307,7 @@ namespace Isis { PvlKeyword kw = NaifKeywords[key.toStdString()]; IntParameterList parms; for (int i = 0; ifileName().toStdString()); } calgrp += PvlKeyword("CoefficientCube", coCube.fileName().toStdString()); - calgrp += PvlKeyword("AbsoluteCoefficient", toString(absCoef)); + calgrp += PvlKeyword("AbsoluteCoefficient", Isis::toString(absCoef)); ocube->putGroup(calgrp); diff --git a/isis/src/mer/apps/mical/MiCalibration.cpp b/isis/src/mer/apps/mical/MiCalibration.cpp index 2bfdab52f6..fd49c004d9 100644 --- a/isis/src/mer/apps/mical/MiCalibration.cpp +++ b/isis/src/mer/apps/mical/MiCalibration.cpp @@ -36,8 +36,8 @@ namespace Isis { image.label()->findGroup("Instrument", Pvl::Traverse); p_exposureDuration = labelgrp["ExposureDuration"]; p_instrumentSerialNumber = labelgrp["InstrumentSerialNumber"]; - p_CCDTemperature = IString::ToDouble(labelgrp["InstrumentTemperature"][6]); - p_PCBTemperature = IString::ToDouble(labelgrp["InstrumentTemperature"][7]); + p_CCDTemperature = Isis::toDouble(labelgrp["InstrumentTemperature"][6]); + p_PCBTemperature = Isis::toDouble(labelgrp["InstrumentTemperature"][7]); p_OffsetModeId = labelgrp["OffsetModeID"]; p_shuttereffectcorrectionflag = QString::fromStdString(labelgrp["ShutterEffectCorrectionFlag"]); p_filterName = QString::fromStdString(labelgrp["FilterName"]); diff --git a/isis/src/mer/apps/mical/main.cpp b/isis/src/mer/apps/mical/main.cpp index 51e9f7403a..44b9165983 100644 --- a/isis/src/mer/apps/mical/main.cpp +++ b/isis/src/mer/apps/mical/main.cpp @@ -144,12 +144,12 @@ void IsisMain() { calgrp += PvlKeyword("ReferencePixelValueSource", "ERPImage"); calgrp += PvlKeyword("ReferencePixelValueImage", ui.GetCubeName("REFPIXIMAGE").toStdString()); - calgrp += PvlKeyword("ReferencePixelValue", toString(gbl::ReferencePixelValue)); + calgrp += PvlKeyword("ReferencePixelValue", Isis::toString(gbl::ReferencePixelValue)); } else { gbl::ReferencePixelValue = gbl::mi->ReferencePixelModel(); calgrp += PvlKeyword("ReferencePixelValueSource", "ERPModel"); - calgrp += PvlKeyword("ReferenceModel", toString(gbl::ReferencePixelValue)); + calgrp += PvlKeyword("ReferenceModel", Isis::toString(gbl::ReferencePixelValue)); } // if user wants NO zero exposure or if shutter effect correction is true // set the user value to zero and set label output to reflect no correction @@ -159,7 +159,7 @@ void IsisMain() { calgrp += PvlKeyword("ZeroExposureImage", "NoCorrection"); } else { - calgrp += PvlKeyword("ZeroExposureValue", toString(gbl::mi->ZeroExposureValue())); + calgrp += PvlKeyword("ZeroExposureValue", Isis::toString(gbl::mi->ZeroExposureValue())); calgrp += PvlKeyword("ZeroExposureImage", gbl::mi->ZeroExposureImage().toStdString()); } // If user wants NO active area set user value to zero and set the label @@ -170,7 +170,7 @@ void IsisMain() { calgrp += PvlKeyword("ActiveAreaImage", "NoCorrection"); } else { - calgrp += PvlKeyword("ActiveAreaValue", toString(gbl::mi->ActiveAreaValue())); + calgrp += PvlKeyword("ActiveAreaValue", Isis::toString(gbl::mi->ActiveAreaValue())); calgrp += PvlKeyword("ActiveAreaImage", gbl::mi->ActiveAreaImage().toStdString()); } @@ -211,14 +211,14 @@ void IsisMain() { double fullModel = gbl::mi->ReferencePixelModel() + gbl::mi->ZeroExposureValue() + gbl::mi->ActiveAreaValue(); - calgrp += PvlKeyword("DarkCurrentFullModel", toString(fullModel)); + calgrp += PvlKeyword("DarkCurrentFullModel", Isis::toString(fullModel)); //Add temperature values to the radiometry group - calgrp += PvlKeyword("CCDTemperture", toString(gbl::mi->CCDTemperatureCorrect())); - calgrp += PvlKeyword("PCBTemperature", toString(gbl::mi->PCBTemperature())); + calgrp += PvlKeyword("CCDTemperture", Isis::toString(gbl::mi->CCDTemperatureCorrect())); + calgrp += PvlKeyword("PCBTemperature", Isis::toString(gbl::mi->PCBTemperature())); if(stagestop == "IOF") { - calgrp += PvlKeyword("OmegaNaught", toString(gbl::mi->OmegaNaught())); - calgrp += PvlKeyword("SunAU", toString(gbl::sunAU)); + calgrp += PvlKeyword("OmegaNaught", Isis::toString(gbl::mi->OmegaNaught())); + calgrp += PvlKeyword("SunAU", Isis::toString(gbl::sunAU)); } //write Radiometry group to the output cube. diff --git a/isis/src/messenger/apps/mdis2isis/main.cpp b/isis/src/messenger/apps/mdis2isis/main.cpp index 63e49ad472..d3d2788396 100644 --- a/isis/src/messenger/apps/mdis2isis/main.cpp +++ b/isis/src/messenger/apps/mdis2isis/main.cpp @@ -121,7 +121,7 @@ void IsisMain() { // Create YearDoy keyword in Archive group iTime stime( QString::fromStdString(outLabel.findGroup("Instrument", Pvl::Traverse)["StartTime"][0])); - PvlKeyword yeardoy("YearDoy", toString(stime.Year()*1000 + stime.DayOfYear())); + PvlKeyword yeardoy("YearDoy", Isis::toString(stime.Year()*1000 + stime.DayOfYear())); (void) outLabel.findGroup("Archive", Pvl::Traverse).addKeyword(yeardoy); if(ui.GetBoolean("UNLUT") == false || !needsUnlut) { @@ -133,7 +133,7 @@ void IsisMain() { // Write the Instrument, BandBin, Archive, and Kernels groups to the output // cube label PvlGroup &group = outLabel.findGroup("Instrument", Pvl::Traverse); - group.addKeyword(PvlKeyword("Unlutted", toString((int)!needsUnlut))); + group.addKeyword(PvlKeyword("Unlutted", Isis::toString((int)!needsUnlut))); outCube->putGroup(group); outCube->putGroup(outLabel.findGroup("BandBin", Pvl::Traverse)); @@ -162,7 +162,7 @@ void IsisMain() { outCube->create(ui.GetCubeName("TO")); PvlGroup &group = outLabel.findGroup("Instrument", Pvl::Traverse); - group.addKeyword(PvlKeyword("Unlutted", toString((int)true))); + group.addKeyword(PvlKeyword("Unlutted", Isis::toString((int)true))); group.addKeyword(PvlKeyword("LutInversionTable", lutfile.toStdString())); outCube->label()->findObject("IsisCube").addGroup(group); @@ -237,7 +237,7 @@ Pvl TranslateMdisEdrLabels(FileName &labelFile, const QString &target) { // Compute the gimble pivot angle and write to the label double pivotCounter = (double) instGrp["PivotPosition"]; double pivotAngle = pivotCounter / ((double)(2 << 15)) * 180.0; - instGrp += PvlKeyword("PivotAngle", toString(pivotAngle), "Degrees"); + instGrp += PvlKeyword("PivotAngle", Isis::toString(pivotAngle), "Degrees"); return outLabel; } @@ -304,7 +304,7 @@ int CreateFilterSpecs(const QString &instId, int filter_code, naifCode = "-236800"; for(int filterTry = 1; filterTry <= 12 ; filterTry++) { - int idealPosition = confgrp["EncoderPosition" + toString(filterTry)]; + int idealPosition = confgrp["EncoderPosition" + Isis::toString(filterTry)]; if((filter_code <= (idealPosition + tolerance)) && (filter_code >= (idealPosition - tolerance))) { int fno = filterTry - 1; @@ -324,7 +324,7 @@ int CreateFilterSpecs(const QString &instId, int filter_code, } if(!name.isEmpty()) { - bandbin.addKeyword(PvlKeyword("Number", toString(filter)), PvlContainer::Replace); + bandbin.addKeyword(PvlKeyword("Number", Isis::toString(filter)), PvlContainer::Replace); bandbin.addKeyword(PvlKeyword("Name", name.toStdString()), PvlContainer::Replace); bandbin.addKeyword(PvlKeyword("Center", center.toStdString(), "NM"), PvlContainer::Replace); bandbin.addKeyword(PvlKeyword("Width", width.toStdString(), "NM"), PvlContainer::Replace); diff --git a/isis/src/messenger/apps/mdis2pds/main.cpp b/isis/src/messenger/apps/mdis2pds/main.cpp index 44a11d5c6e..a648d88b2c 100644 --- a/isis/src/messenger/apps/mdis2pds/main.cpp +++ b/isis/src/messenger/apps/mdis2pds/main.cpp @@ -47,7 +47,7 @@ inline void validateUnit(PvlKeyword &key, const QString &kunit) { for (int i = 0; i < temp.size(); i++) { try { // If this works, check unit, otherwise an exception is thrown - IString::ToDouble(temp[i]); + Isis::toDouble(temp[i]); QString unit = QString::fromStdString(temp.unit(i)); if (unit.isEmpty()) unit = kunit; key.addValue(temp[i], unit.toStdString()); @@ -230,12 +230,12 @@ void IsisMain() { p.CheckStatus(); // Creates keywords from the input's hist above - PvlKeyword minDn("MINIMUM", toString(setRound(hist->Minimum(), 16))); - PvlKeyword maxDn("MAXIMUM", toString(setRound(hist->Maximum(), 16))); - PvlKeyword meanDn("MEAN", toString(setRound(hist->Average(), 16))); - PvlKeyword stddev("STANDARD_DEVIATION", toString(setRound(hist->StandardDeviation(), 16))); + PvlKeyword minDn("MINIMUM", Isis::toString(setRound(hist->Minimum(), 16))); + PvlKeyword maxDn("MAXIMUM", Isis::toString(setRound(hist->Maximum(), 16))); + PvlKeyword meanDn("MEAN", Isis::toString(setRound(hist->Average(), 16))); + PvlKeyword stddev("STANDARD_DEVIATION", Isis::toString(setRound(hist->StandardDeviation(), 16))); - PvlKeyword saturated("SATURATED_PIXEL_COUNT", toString(hist->HisPixels())); + PvlKeyword saturated("SATURATED_PIXEL_COUNT", Isis::toString(hist->HisPixels())); PvlObject &imageObj = pdsLabel.findObject("IMAGE"); @@ -252,7 +252,7 @@ void IsisMain() { PvlKeyword &darkStripMean = imageObj.findKeyword("DARK_STRIP_MEAN"); try { - darkStripMean[0] = toString(setRound(IString::ToDouble(darkStripMean[0]), 16)); + darkStripMean[0] = Isis::toString(setRound(Isis::toDouble(darkStripMean[0]), 16)); } catch (IException &) { // If we fail to convert this keyword to a number, then preserve diff --git a/isis/src/messenger/apps/mdiscal/main.cpp b/isis/src/messenger/apps/mdiscal/main.cpp index a280f5d4f9..1c57b5a210 100644 --- a/isis/src/messenger/apps/mdiscal/main.cpp +++ b/isis/src/messenger/apps/mdiscal/main.cpp @@ -410,8 +410,8 @@ void IsisMain() { calibrationLog.addKeyword(PvlKeyword("DarkCurrentFile", darkCurrentFile.toStdString())); } - calibrationLog.addKeyword(PvlKeyword("BinnedImage", toString((int)g_isBinnedData))); - calibrationLog.addKeyword(PvlKeyword("FilterNumber", toString(g_filterNumber + 1))); + calibrationLog.addKeyword(PvlKeyword("BinnedImage", Isis::toString((int)g_isBinnedData))); + calibrationLog.addKeyword(PvlKeyword("FilterNumber", Isis::toString(g_filterNumber + 1))); if (g_applyFlatfield) { calibrationLog.addKeyword(PvlKeyword("FlatFieldFile", flatfield.originalPath() + "/" + flatfield.name())); @@ -423,20 +423,20 @@ void IsisMain() { calibFile.originalPath() + "/" + calibFile.name())); calibrationLog.addKeyword(PvlKeyword("ResponsivityFile", respfile.toStdString())); calibrationLog.addKeyword(PvlKeyword("SmearCompFile", smearfile.toStdString())); - PvlKeyword rspKey("Response", toString(rsp[0])); + PvlKeyword rspKey("Response", Isis::toString(rsp[0])); for (unsigned int i = 1; i < rsp.size(); i++) { - rspKey.addValue(toString(rsp[i])); + rspKey.addValue(Isis::toString(rsp[i])); } calibrationLog.addKeyword(rspKey); - calibrationLog.addKeyword(PvlKeyword("SmearComponent", toString(g_smearComponent))); + calibrationLog.addKeyword(PvlKeyword("SmearComponent", Isis::toString(g_smearComponent))); QString calibType; if (applyIOF && validIOF) { calibrationLog.addKeyword(PvlKeyword("Units", "I over F")); - calibrationLog.addKeyword(PvlKeyword("SolarDistance", toString(g_solarDist), "AU")); + calibrationLog.addKeyword(PvlKeyword("SolarDistance", Isis::toString(g_solarDist), "AU")); calibrationLog.addKeyword(PvlKeyword("SolarIrrFile", solirrfile.toStdString())); - calibrationLog.addKeyword(PvlKeyword("FilterIrradianceFactor", toString(g_Ff))); - calibrationLog.addKeyword(PvlKeyword("IOFFactor", toString(g_iof))); + calibrationLog.addKeyword(PvlKeyword("FilterIrradianceFactor", Isis::toString(g_Ff))); + calibrationLog.addKeyword(PvlKeyword("IOFFactor", Isis::toString(g_iof))); calibType = "IF"; } else if (g_applyRadiometric) { @@ -453,18 +453,18 @@ void IsisMain() { calibrationLog.addKeyword(PvlKeyword("EmpiricalCorrectionFactor", empiricalCorrectionFactor.toStdString())); - calibrationLog.addKeyword(PvlKeyword("DarkStripColumns", toString(g_nDarkColumns)), + calibrationLog.addKeyword(PvlKeyword("DarkStripColumns", Isis::toString(g_nDarkColumns)), Pvl::Replace); - calibrationLog.addKeyword(PvlKeyword("ValidDarkColumns", toString(g_nValidDark)), + calibrationLog.addKeyword(PvlKeyword("ValidDarkColumns", Isis::toString(g_nValidDark)), Pvl::Replace); if (g_darkStrip.TotalPixels() > 0) { double avgDark = (g_darkStrip.ValidPixels() > 0) ? g_darkStrip.Average() : 0.0; - calibrationLog.addKeyword(PvlKeyword("DarkStripMean", toString(avgDark)), + calibrationLog.addKeyword(PvlKeyword("DarkStripMean", Isis::toString(avgDark)), Pvl::Replace); } // Report nulled sample count - calibrationLog.addKeyword(PvlKeyword("LeftSamplesNulled", toString(g_nSampsToNull))); + calibrationLog.addKeyword(PvlKeyword("LeftSamplesNulled", Isis::toString(g_nSampsToNull))); // Handle updates of ProductId and SourceProduct Id keywords PvlGroup& archive = ocube->group("Archive"); diff --git a/isis/src/messenger/apps/mdisddr/main.cpp b/isis/src/messenger/apps/mdisddr/main.cpp index 09766e2c12..e261820f54 100644 --- a/isis/src/messenger/apps/mdisddr/main.cpp +++ b/isis/src/messenger/apps/mdisddr/main.cpp @@ -53,7 +53,7 @@ inline void validateUnit(PvlKeyword &key, const QString &kunit) { for (int i = 0; i < temp.size(); i++) { try { // If this works, check unit, otherwise an exception is thrown - (void)IString::ToDouble(temp[i]); + (void) Isis::toDouble(temp[i]); QString unit = QString::fromStdString(temp.unit(i)); if (unit.isEmpty()) unit = kunit; key.addValue(temp[i], unit.toStdString()); diff --git a/isis/src/mgs/apps/moc2isis/main.cpp b/isis/src/mgs/apps/moc2isis/main.cpp index 6a17efb8ec..dab461338f 100644 --- a/isis/src/mgs/apps/moc2isis/main.cpp +++ b/isis/src/mgs/apps/moc2isis/main.cpp @@ -195,7 +195,7 @@ void TranslateMocEdrLabels(FileName &labelFile, Cube *ocube) { QString str = instrumentXlater.Translate("FirstLineSample"); int num = str.toInt(); num++; - inst += PvlKeyword("FirstLineSample", toString(num)); + inst += PvlKeyword("FirstLineSample", Isis::toString(num)); } // Add the instrument specific info to the output file @@ -288,16 +288,16 @@ void TranslateMocEdrLabels(FileName &labelFile, Cube *ocube) { if(str == "BLUE") { bandBin += PvlKeyword("FilterName", str.toStdString()); - bandBin += PvlKeyword("OriginalBand", toString(1)); - bandBin += PvlKeyword("Center", toString(0.4346), "micrometers"); - bandBin += PvlKeyword("Width", toString(0.050), "micrometers"); + bandBin += PvlKeyword("OriginalBand", Isis::toString(1)); + bandBin += PvlKeyword("Center", Isis::toString(0.4346), "micrometers"); + bandBin += PvlKeyword("Width", Isis::toString(0.050), "micrometers"); frameCode = "-94033"; } else if(str == "RED") { bandBin += PvlKeyword("FilterName", str.toStdString()); - bandBin += PvlKeyword("OriginalBand", toString(1)); - bandBin += PvlKeyword("Center", toString(0.6134), "micrometers"); - bandBin += PvlKeyword("Width", toString(0.050), "micrometers"); + bandBin += PvlKeyword("OriginalBand", Isis::toString(1)); + bandBin += PvlKeyword("Center", Isis::toString(0.6134), "micrometers"); + bandBin += PvlKeyword("Width", Isis::toString(0.050), "micrometers"); frameCode = "-94032"; } else { @@ -306,9 +306,9 @@ void TranslateMocEdrLabels(FileName &labelFile, Cube *ocube) { } else { bandBin += PvlKeyword("FilterName", "BROAD_BAND"); - bandBin += PvlKeyword("OriginalBand", toString(1)); - bandBin += PvlKeyword("Center", toString(0.700), "micrometers"); - bandBin += PvlKeyword("Width", toString(0.400), "micrometers"); + bandBin += PvlKeyword("OriginalBand", Isis::toString(1)); + bandBin += PvlKeyword("Center", Isis::toString(0.700), "micrometers"); + bandBin += PvlKeyword("Width", Isis::toString(0.400), "micrometers"); frameCode = "-94031"; } diff --git a/isis/src/mgs/apps/moccal/moccal.cpp b/isis/src/mgs/apps/moccal/moccal.cpp index 91785bbe42..0588128fd2 100644 --- a/isis/src/mgs/apps/moccal/moccal.cpp +++ b/isis/src/mgs/apps/moccal/moccal.cpp @@ -179,19 +179,19 @@ namespace Isis { calgrp += PvlKeyword("CalibrationKernel", calKernelFile.toStdString()); calgrp += PvlKeyword("CoefficientFile", coefFile.toStdString()); - calgrp += PvlKeyword("a", toString(gbl::a)); + calgrp += PvlKeyword("a", Isis::toString(gbl::a)); calgrp["a"].addComment("Radiometric equation in moccal"); calgrp["a"].addComment("r = (pixel - z + off) / a - g / ex - dc"); - calgrp += PvlKeyword("off", toString(gbl::off)); - calgrp += PvlKeyword("ex", toString(gbl::ex)); - calgrp += PvlKeyword("z", toString(gbl::z)); - calgrp += PvlKeyword("dc", toString(gbl::dc)); - calgrp += PvlKeyword("g", toString(gbl::g)); + calgrp += PvlKeyword("off", Isis::toString(gbl::off)); + calgrp += PvlKeyword("ex", Isis::toString(gbl::ex)); + calgrp += PvlKeyword("z", Isis::toString(gbl::z)); + calgrp += PvlKeyword("dc", Isis::toString(gbl::dc)); + calgrp += PvlKeyword("g", Isis::toString(gbl::g)); - calgrp += PvlKeyword("w0", toString(gbl::w0)); + calgrp += PvlKeyword("w0", Isis::toString(gbl::w0)); calgrp["w0"].addComment("Reflectance = r * iof, where iof = (s * s) / w0"); - calgrp += PvlKeyword("s", toString(sunAU)); - calgrp += PvlKeyword("iof", toString(gbl::iof)); + calgrp += PvlKeyword("s", Isis::toString(sunAU)); + calgrp += PvlKeyword("iof", Isis::toString(gbl::iof)); ocube->putGroup(calgrp); diff --git a/isis/src/mgs/apps/mocnoise50/main.cpp b/isis/src/mgs/apps/mocnoise50/main.cpp index 409f411575..6241a2da1c 100644 --- a/isis/src/mgs/apps/mocnoise50/main.cpp +++ b/isis/src/mgs/apps/mocnoise50/main.cpp @@ -142,11 +142,11 @@ void IsisMain() { p.SetOutputCube("TO"); PvlGroup results("Results"); - results += PvlKeyword("DeltaSample", toString(gbl::delta)); - results += PvlKeyword("StartingSample", toString(gbl::ssFirst)); - results += PvlKeyword("Coefficient1", toString(gbl::avg1)); - results += PvlKeyword("Coefficient2", toString(gbl::avg2)); - results += PvlKeyword("Coefficient3", toString(gbl::avg3)); + results += PvlKeyword("DeltaSample", Isis::toString(gbl::delta)); + results += PvlKeyword("StartingSample", Isis::toString(gbl::ssFirst)); + results += PvlKeyword("Coefficient1", Isis::toString(gbl::avg1)); + results += PvlKeyword("Coefficient2", Isis::toString(gbl::avg2)); + results += PvlKeyword("Coefficient3", Isis::toString(gbl::avg3)); // If less than 50% of the lines do not agree on a delta then // we will assume no noise so just make a copy diff --git a/isis/src/mro/apps/crism2isis/crism2isis.cpp b/isis/src/mro/apps/crism2isis/crism2isis.cpp index 92bb2dbd59..e1d9c56575 100644 --- a/isis/src/mro/apps/crism2isis/crism2isis.cpp +++ b/isis/src/mro/apps/crism2isis/crism2isis.cpp @@ -85,7 +85,7 @@ namespace Isis{ st = st.simplified().trimmed(); QStringList cols = st.split(","); - origBand += toString(band); + origBand += Isis::toString(band); widths += cols[2].toStdString(); band++; } @@ -111,7 +111,7 @@ namespace Isis{ PvlKeyword bandName = PvlKeyword("BandName"); PvlKeyword bandNames = labelPvl.findObject("IMAGE").findKeyword("BAND_NAME"); for (int i = 0; i < bandNames.size(); i++) { - origBand += toString(i + 1); + origBand += Isis::toString(i + 1); bandName += bandNames[i]; } bandBin.addKeyword(origBand); @@ -139,7 +139,7 @@ namespace Isis{ PvlKeyword bandName = PvlKeyword("BandName"); PvlKeyword bandNames = labelPvl.findObject("FILE").findObject("IMAGE").findKeyword("BAND_NAME"); for (int i = 0; i < bandNames.size(); i++) { - origBand += toString(i + 1); + origBand += Isis::toString(i + 1); bandName += bandNames[i]; } bandBin.addKeyword(origBand); diff --git a/isis/src/mro/apps/ctxcal/ctxcal.cpp b/isis/src/mro/apps/ctxcal/ctxcal.cpp index 066171fad8..3785bfc2a8 100644 --- a/isis/src/mro/apps/ctxcal/ctxcal.cpp +++ b/isis/src/mro/apps/ctxcal/ctxcal.cpp @@ -210,7 +210,7 @@ namespace Isis { PvlGroup calgrp("Radiometry"); calgrp += PvlKeyword("FlatFile", flatFile.fileName().toStdString()); - calgrp += PvlKeyword("iof", toString(iof)); + calgrp += PvlKeyword("iof", Isis::toString(iof)); ocube->putGroup(calgrp); diff --git a/isis/src/mro/apps/hi2isis/hi2isis.cpp b/isis/src/mro/apps/hi2isis/hi2isis.cpp index 8f502b01d5..faaf16c92a 100644 --- a/isis/src/mro/apps/hi2isis/hi2isis.cpp +++ b/isis/src/mro/apps/hi2isis/hi2isis.cpp @@ -144,7 +144,7 @@ namespace Isis { // The user wants it unlutted else if(ui.GetBoolean("UNLUT")) { for(int i = 0; i < lutSeq.Size(); i++) { - stretch.AddPair(i, ((IString::ToDouble(lutSeq[i][0]) +IString::ToDouble(lutSeq[i][1])) / 2.0)); + stretch.AddPair(i, ((Isis::toDouble(lutSeq[i][0]) + Isis::toDouble(lutSeq[i][1])) / 2.0)); } instgrp.addKeyword(PvlKeyword("Unlutted", "TRUE")); instgrp.deleteKeyword("LookupTable"); @@ -187,47 +187,47 @@ namespace Isis { PvlGroup results("Results"); results += PvlKeyword("From", inFile.expanded()); - results += PvlKeyword("CalibrationBufferGaps", toString(gapCount[0])); - results += PvlKeyword("CalibrationBufferLIS", toString(lisCount[0])); - results += PvlKeyword("CalibrationBufferHIS", toString(hisCount[0])); - results += PvlKeyword("CalibrationBufferPossibleGaps", toString(suspectGapCount[0])); - results += PvlKeyword("CalibrationBufferInvalid", toString(invalidCount[0])); - results += PvlKeyword("CalibrationBufferValid", toString(validCount[0])); - - results += PvlKeyword("CalibrationImageGaps", toString(gapCount[1])); - results += PvlKeyword("CalibrationImageLIS", toString(lisCount[1])); - results += PvlKeyword("CalibrationImageHIS", toString(hisCount[1])); - results += PvlKeyword("CalibrationImagePossibleGaps", toString(suspectGapCount[1])); - results += PvlKeyword("CalibrationImageInvalid", toString(invalidCount[1])); - results += PvlKeyword("CalibrationImageValid", toString(validCount[1])); - - results += PvlKeyword("CalibrationDarkGaps", toString(gapCount[2])); - results += PvlKeyword("CalibrationDarkLIS", toString(lisCount[2])); - results += PvlKeyword("CalibrationDarkHIS", toString(hisCount[2])); - results += PvlKeyword("CalibrationDarkPossibleGaps", toString(suspectGapCount[2])); - results += PvlKeyword("CalibrationDarkInvalid", toString(invalidCount[2])); - results += PvlKeyword("CalibrationDarkValid", toString(validCount[2])); - - results += PvlKeyword("ObservationBufferGaps", toString(gapCount[3])); - results += PvlKeyword("ObservationBufferLIS", toString(lisCount[3])); - results += PvlKeyword("ObservationBufferHIS", toString(hisCount[3])); - results += PvlKeyword("ObservationBufferPossibleGaps", toString(suspectGapCount[3])); - results += PvlKeyword("ObservationBufferInvalid", toString(invalidCount[3])); - results += PvlKeyword("ObservationBufferValid", toString(validCount[3])); - - results += PvlKeyword("ObservationImageGaps", toString(gapCount[4])); - results += PvlKeyword("ObservationImageLIS", toString(lisCount[4])); - results += PvlKeyword("ObservationImageHIS", toString(hisCount[4])); - results += PvlKeyword("ObservationImagePossibleGaps", toString(suspectGapCount[4])); - results += PvlKeyword("ObservationImageInvalid", toString(invalidCount[4])); - results += PvlKeyword("ObservationImageValid", toString(validCount[4])); - - results += PvlKeyword("ObservationDarkGaps", toString(gapCount[5])); - results += PvlKeyword("ObservationDarkLIS", toString(lisCount[5])); - results += PvlKeyword("ObservationDarkHIS", toString(hisCount[5])); - results += PvlKeyword("ObservationDarkPossibleGaps", toString(suspectGapCount[5])); - results += PvlKeyword("ObservationDarkInvalid", toString(invalidCount[5])); - results += PvlKeyword("ObservationDarkValid", toString(validCount[5])); + results += PvlKeyword("CalibrationBufferGaps", Isis::toString(gapCount[0])); + results += PvlKeyword("CalibrationBufferLIS", Isis::toString(lisCount[0])); + results += PvlKeyword("CalibrationBufferHIS", Isis::toString(hisCount[0])); + results += PvlKeyword("CalibrationBufferPossibleGaps", Isis::toString(suspectGapCount[0])); + results += PvlKeyword("CalibrationBufferInvalid", Isis::toString(invalidCount[0])); + results += PvlKeyword("CalibrationBufferValid", Isis::toString(validCount[0])); + + results += PvlKeyword("CalibrationImageGaps", Isis::toString(gapCount[1])); + results += PvlKeyword("CalibrationImageLIS", Isis::toString(lisCount[1])); + results += PvlKeyword("CalibrationImageHIS", Isis::toString(hisCount[1])); + results += PvlKeyword("CalibrationImagePossibleGaps", Isis::toString(suspectGapCount[1])); + results += PvlKeyword("CalibrationImageInvalid", Isis::toString(invalidCount[1])); + results += PvlKeyword("CalibrationImageValid", Isis::toString(validCount[1])); + + results += PvlKeyword("CalibrationDarkGaps", Isis::toString(gapCount[2])); + results += PvlKeyword("CalibrationDarkLIS", Isis::toString(lisCount[2])); + results += PvlKeyword("CalibrationDarkHIS", Isis::toString(hisCount[2])); + results += PvlKeyword("CalibrationDarkPossibleGaps", Isis::toString(suspectGapCount[2])); + results += PvlKeyword("CalibrationDarkInvalid", Isis::toString(invalidCount[2])); + results += PvlKeyword("CalibrationDarkValid", Isis::toString(validCount[2])); + + results += PvlKeyword("ObservationBufferGaps", Isis::toString(gapCount[3])); + results += PvlKeyword("ObservationBufferLIS", Isis::toString(lisCount[3])); + results += PvlKeyword("ObservationBufferHIS", Isis::toString(hisCount[3])); + results += PvlKeyword("ObservationBufferPossibleGaps", Isis::toString(suspectGapCount[3])); + results += PvlKeyword("ObservationBufferInvalid", Isis::toString(invalidCount[3])); + results += PvlKeyword("ObservationBufferValid", Isis::toString(validCount[3])); + + results += PvlKeyword("ObservationImageGaps", Isis::toString(gapCount[4])); + results += PvlKeyword("ObservationImageLIS", Isis::toString(lisCount[4])); + results += PvlKeyword("ObservationImageHIS", Isis::toString(hisCount[4])); + results += PvlKeyword("ObservationImagePossibleGaps", Isis::toString(suspectGapCount[4])); + results += PvlKeyword("ObservationImageInvalid", Isis::toString(invalidCount[4])); + results += PvlKeyword("ObservationImageValid", Isis::toString(validCount[4])); + + results += PvlKeyword("ObservationDarkGaps", Isis::toString(gapCount[5])); + results += PvlKeyword("ObservationDarkLIS", Isis::toString(lisCount[5])); + results += PvlKeyword("ObservationDarkHIS", Isis::toString(hisCount[5])); + results += PvlKeyword("ObservationDarkPossibleGaps", Isis::toString(suspectGapCount[5])); + results += PvlKeyword("ObservationDarkInvalid", Isis::toString(invalidCount[5])); + results += PvlKeyword("ObservationDarkValid", Isis::toString(validCount[5])); // Write the results to the log Application::Log(results); diff --git a/isis/src/mro/apps/hicalproc/main.cpp b/isis/src/mro/apps/hicalproc/main.cpp index f33c75352c..aa1f0b390c 100644 --- a/isis/src/mro/apps/hicalproc/main.cpp +++ b/isis/src/mro/apps/hicalproc/main.cpp @@ -61,7 +61,7 @@ void IsisMain() { cubeLabel = Pvl(inFile.toStdString()); } // Get the Summing from the label - int iSumming = IString::ToInteger(cubeLabel.findObject("IsisCube").findGroup("Instrument").findKeyword("Summing")[0]); + int iSumming = Isis::toInt(cubeLabel.findObject("IsisCube").findGroup("Instrument").findKeyword("Summing")[0]); Pipeline p1("hicalproc1"); p1.SetInputFile("FROM"); @@ -456,7 +456,7 @@ void GetCCD_Channel_Coefficients(Pvl & pCubeLabel) } else { PvlKeyword binKey = instrGrp.findKeyword("Summing"); - iSumming = IString::ToInteger(binKey[0]); + iSumming = Isis::toInt(binKey[0]); if (iSumming != 1 && iSumming != 2 && iSumming != 4) { std::string sMsg = "Invalid Summing value in input file, must be 1,2,or 4"; throw IException(IException::User, sMsg, _FILEINFO_); @@ -480,7 +480,7 @@ void GetCCD_Channel_Coefficients(Pvl & pCubeLabel) } else { PvlKeyword channelKey = instrGrp.findKeyword("ChannelNumber"); - iChannel = IString::ToInteger(channelKey[0]); + iChannel = Isis::toInt(channelKey[0]); } // Get the coefficient file name diff --git a/isis/src/mro/apps/hiccdstitch/main.cpp b/isis/src/mro/apps/hiccdstitch/main.cpp index d744e76b5e..498baf73e3 100644 --- a/isis/src/mro/apps/hiccdstitch/main.cpp +++ b/isis/src/mro/apps/hiccdstitch/main.cpp @@ -377,14 +377,14 @@ void IsisMain() { PvlGroup ccdGroup(CCDlist[CCDindex].ccdName.toStdString()); ccdGroup += PvlKeyword("File", CCDlist[CCDindex].filename.toStdString()); - ccdGroup += PvlKeyword("FocalPlaneSample", toString(CCDlist[CCDindex].fpsamp)); - ccdGroup += PvlKeyword("FocalPlaneLine", toString(CCDlist[CCDindex].fpline)); - ccdGroup += PvlKeyword("ImageSample", toString(CCDlist[CCDindex].outss)); - ccdGroup += PvlKeyword("ImageLine", toString(CCDlist[CCDindex].outsl)); + ccdGroup += PvlKeyword("FocalPlaneSample", Isis::toString(CCDlist[CCDindex].fpsamp)); + ccdGroup += PvlKeyword("FocalPlaneLine", Isis::toString(CCDlist[CCDindex].fpline)); + ccdGroup += PvlKeyword("ImageSample", Isis::toString(CCDlist[CCDindex].outss)); + ccdGroup += PvlKeyword("ImageLine", Isis::toString(CCDlist[CCDindex].outsl)); int ccd = CCDlist[CCDindex].ccdNumber; - ccdGroup += PvlKeyword("SampleOffset", toString(CCDlist[CCDindex].fpsamp - xoffset[ccd])); - ccdGroup += PvlKeyword("LineOffset", toString(CCDlist[CCDindex].fpline - yoffset[ccd])); + ccdGroup += PvlKeyword("SampleOffset", Isis::toString(CCDlist[CCDindex].fpsamp - xoffset[ccd])); + ccdGroup += PvlKeyword("LineOffset", Isis::toString(CCDlist[CCDindex].fpline - yoffset[ccd])); results.addGroup(ccdGroup); } diff --git a/isis/src/mro/apps/hicolormos/hicolormos.cpp b/isis/src/mro/apps/hicolormos/hicolormos.cpp index 4ff063e8aa..7dc38194f2 100644 --- a/isis/src/mro/apps/hicolormos/hicolormos.cpp +++ b/isis/src/mro/apps/hicolormos/hicolormos.cpp @@ -258,13 +258,13 @@ void hicolormos(Cube *from1, Cube* from2, UserInterface &ui) { mos += PvlKeyword("SpacecraftClockStartCount ", startClk.toStdString()); mos += PvlKeyword("StopTime ", stopTime.toStdString()); mos += PvlKeyword("SpacecraftClockStopCount ", stopClk.toStdString()); - mos += PvlKeyword("IncidenceAngle ", toString(Cincid), "DEG"); - mos += PvlKeyword("EmissionAngle ", toString(Cemiss), "DEG"); - mos += PvlKeyword("PhaseAngle ", toString(Cphase), "DEG"); - mos += PvlKeyword("LocalTime ", toString(ClocalSolTime), "LOCALDAY/24"); - mos += PvlKeyword("SolarLongitude ", toString(CsolarLong), "DEG"); - mos += PvlKeyword("SubSolarAzimuth ", toString(CsunAzimuth), "DEG"); - mos += PvlKeyword("NorthAzimuth ", toString(CnorthAzimuth), "DEG"); + mos += PvlKeyword("IncidenceAngle ", Isis::toString(Cincid), "DEG"); + mos += PvlKeyword("EmissionAngle ", Isis::toString(Cemiss), "DEG"); + mos += PvlKeyword("PhaseAngle ", Isis::toString(Cphase), "DEG"); + mos += PvlKeyword("LocalTime ", Isis::toString(ClocalSolTime), "LOCALDAY/24"); + mos += PvlKeyword("SolarLongitude ", Isis::toString(CsolarLong), "DEG"); + mos += PvlKeyword("SubSolarAzimuth ", Isis::toString(CsunAzimuth), "DEG"); + mos += PvlKeyword("NorthAzimuth ", Isis::toString(CnorthAzimuth), "DEG"); mos += cpmmTdiFlag; mos += cpmmSummingFlag; mos += specialProcessingFlag; diff --git a/isis/src/mro/apps/hicrop/hicrop.cpp b/isis/src/mro/apps/hicrop/hicrop.cpp index 9cc65475e7..b84240293d 100644 --- a/isis/src/mro/apps/hicrop/hicrop.cpp +++ b/isis/src/mro/apps/hicrop/hicrop.cpp @@ -355,11 +355,11 @@ namespace Isis { // Construct a label with the results PvlGroup results("Results"); - results += PvlKeyword("InputLines", toString(inputLineCount)); - results += PvlKeyword("NumberOfLinesCropped", toString(inputLineCount-g_cropLineCount)); - results += PvlKeyword("OututStartingLine", toString(g_cropStartLine)); - results += PvlKeyword("OututEndingLine", toString(g_cropEndLine)); - results += PvlKeyword("OututLineCount", toString(g_cropLineCount)); + results += PvlKeyword("InputLines", Isis::toString(inputLineCount)); + results += PvlKeyword("NumberOfLinesCropped", Isis::toString(inputLineCount-g_cropLineCount)); + results += PvlKeyword("OututStartingLine", Isis::toString(g_cropStartLine)); + results += PvlKeyword("OututEndingLine", Isis::toString(g_cropEndLine)); + results += PvlKeyword("OututLineCount", Isis::toString(g_cropLineCount)); results += PvlKeyword("OututStartTime", cropStartTime.UTC().toStdString()); results += PvlKeyword("OututStopTime", cropStopTime.UTC().toStdString()); //??? adjustedCropStopTime results += PvlKeyword("OututStartClock", adjustedCropStartClockCount.toStdString()); diff --git a/isis/src/mro/apps/hicubenorm/hicubenorm.cpp b/isis/src/mro/apps/hicubenorm/hicubenorm.cpp index b102d16410..c06e8d342b 100644 --- a/isis/src/mro/apps/hicubenorm/hicubenorm.cpp +++ b/isis/src/mro/apps/hicubenorm/hicubenorm.cpp @@ -254,22 +254,22 @@ namespace Isis { void pvlOut(const QString &StatFile) { PvlGroup results("Results"); for(unsigned int i = 0; i < band.size(); i++) { - results += PvlKeyword("Band", toString(band[i])); - results += PvlKeyword("RowCol", toString(element[i])); - results += PvlKeyword("ValidPixels", toString(validpixels[i])); + results += PvlKeyword("Band", Isis::toString(band[i])); + results += PvlKeyword("RowCol", Isis::toString(element[i])); + results += PvlKeyword("ValidPixels", Isis::toString(validpixels[i])); if(validpixels[i] > 0) { - results += PvlKeyword("Mean", toString(average[i])); - results += PvlKeyword("Median", toString(median[i])); - results += PvlKeyword("Std", toString(stddev[i])); - results += PvlKeyword("Minimum", toString(minimum[i])); - results += PvlKeyword("Maximum", toString(maximum[i])); + results += PvlKeyword("Mean", Isis::toString(average[i])); + results += PvlKeyword("Median", Isis::toString(median[i])); + results += PvlKeyword("Std", Isis::toString(stddev[i])); + results += PvlKeyword("Minimum", Isis::toString(minimum[i])); + results += PvlKeyword("Maximum", Isis::toString(maximum[i])); } else { - results += PvlKeyword("Mean", toString(0.0)); - results += PvlKeyword("Median", toString(0.0)); - results += PvlKeyword("Std", toString(0.0)); - results += PvlKeyword("Minimum", toString(0.0)); - results += PvlKeyword("Maximum", toString(0.0)); + results += PvlKeyword("Mean", Isis::toString(0.0)); + results += PvlKeyword("Median", Isis::toString(0.0)); + results += PvlKeyword("Std", Isis::toString(0.0)); + results += PvlKeyword("Minimum", Isis::toString(0.0)); + results += PvlKeyword("Maximum", Isis::toString(0.0)); } } @@ -338,21 +338,21 @@ namespace Isis { PvlObject::PvlKeywordIterator itr = results.begin(); while(itr != results.end()) { - band.push_back(IString::ToInteger((*itr)[0])); + band.push_back(Isis::toInt((*itr)[0])); itr++; - element.push_back(IString::ToInteger((*itr)[0])); + element.push_back(Isis::toInt((*itr)[0])); itr++; - validpixels.push_back(IString::ToInteger((*itr)[0])); + validpixels.push_back(Isis::toInt((*itr)[0])); itr++; - average.push_back(IString::ToDouble((*itr)[0])); + average.push_back(Isis::toDouble((*itr)[0])); itr++; - median.push_back(IString::ToDouble((*itr)[0])); + median.push_back(Isis::toDouble((*itr)[0])); itr++; - stddev.push_back(IString::ToDouble((*itr)[0])); + stddev.push_back(Isis::toDouble((*itr)[0])); itr++; - minimum.push_back(IString::ToDouble((*itr)[0])); + minimum.push_back(Isis::toDouble((*itr)[0])); itr++; - maximum.push_back(IString::ToDouble((*itr)[0])); + maximum.push_back(Isis::toDouble((*itr)[0])); itr++; } } diff --git a/isis/src/mro/apps/hideal2pds/main.cpp b/isis/src/mro/apps/hideal2pds/main.cpp index 5a0e77af14..f60506d655 100644 --- a/isis/src/mro/apps/hideal2pds/main.cpp +++ b/isis/src/mro/apps/hideal2pds/main.cpp @@ -194,7 +194,7 @@ void IsisMain() { // change SAMPLE_BIT_MASK value according to BITS input PvlObject &image = pdsLabel.findObject("IMAGE"); - image.addKeyword(PvlKeyword("SAMPLE_BIT_MASK", toString((int)pow(2.0, (double)nbits) - 1)), + image.addKeyword(PvlKeyword("SAMPLE_BIT_MASK", Isis::toString((int)pow(2.0, (double)nbits) - 1)), Pvl::Replace); Camera *cam = inputCube->camera(); @@ -273,7 +273,7 @@ void IsisMain() { } else { tableKeyword = PvlKeyword("SOLAR_LONGITUDE", - toString(cam->solarLongitude().force360Domain() + Isis::toString(cam->solarLongitude().force360Domain() .positiveEast(Angle::Degrees)), "DEGREES"); } @@ -419,10 +419,10 @@ void updatePdsLabelImageObject(PvlObject *isisCubeLab, Pvl &pdsLabel) { firstSample = alphaStartingSample; firstLine = alphaStartingLine; } - image += PvlKeyword("SOURCE_LINE_SAMPLES", toString(sourceSamples)); - image += PvlKeyword("SOURCE_LINES", toString(sourceLines)); - image += PvlKeyword("FIRST_LINE_SAMPLE", toString(firstSample)); - image += PvlKeyword("FIRST_LINE", toString(firstLine)); + image += PvlKeyword("SOURCE_LINE_SAMPLES", Isis::toString(sourceSamples)); + image += PvlKeyword("SOURCE_LINES", Isis::toString(sourceLines)); + image += PvlKeyword("FIRST_LINE_SAMPLE", Isis::toString(firstSample)); + image += PvlKeyword("FIRST_LINE", Isis::toString(firstLine)); // Add center wavelength and bandwidth with correct units to the IMAGE object @@ -503,7 +503,7 @@ void updatePdsLabelRootObject(PvlObject *isisCubeLab, Pvl &pdsLabel, pdsLabel += PvlKeyword("PRODUCT_VERSION_ID", ui.GetString("VERSION").toStdString()); // Add the N/A constant keyword to the ROOT object - pdsLabel += PvlKeyword("NOT_APPLICABLE_CONSTANT", toString(-9998)); + pdsLabel += PvlKeyword("NOT_APPLICABLE_CONSTANT", Isis::toString(-9998)); // Compute and add SOFTWARE_NAME to the ROOT object QString sfname; @@ -520,9 +520,9 @@ void updatePdsLabelRootObject(PvlObject *isisCubeLab, Pvl &pdsLabel, bool jitter = false; if (isisCubeLab->findObject("IsisCube").findGroup("Instrument") .hasKeyword("ImageJitterCorrected")) { - jitter = IString::ToInteger(isisCubeLab->findObject("IsisCube") + jitter = Isis::toInt(isisCubeLab->findObject("IsisCube") .findGroup("Instrument")["ImageJitterCorrected"][0]); - pdsLabel += PvlKeyword("IMAGE_JITTER_CORRECTED", toString((int)jitter)); + pdsLabel += PvlKeyword("IMAGE_JITTER_CORRECTED", Isis::toString((int)jitter)); } else { pdsLabel += PvlKeyword("IMAGE_JITTER_CORRECTED", "UNK"); @@ -550,30 +550,30 @@ void updatePdsLabelRootObject(PvlObject *isisCubeLab, Pvl &pdsLabel, else { Distance naifBodyRadii[3]; cam->radii(naifBodyRadii); - pdsLabel += PvlKeyword("A_AXIS_RADIUS", toString(naifBodyRadii[0].kilometers()), "KILOMETERS"); - pdsLabel += PvlKeyword("B_AXIS_RADIUS", toString(naifBodyRadii[1].kilometers()), "KILOMETERS"); - pdsLabel += PvlKeyword("C_AXIS_RADIUS", toString(naifBodyRadii[2].kilometers()), "KILOMETERS"); + pdsLabel += PvlKeyword("A_AXIS_RADIUS", Isis::toString(naifBodyRadii[0].kilometers()), "KILOMETERS"); + pdsLabel += PvlKeyword("B_AXIS_RADIUS", Isis::toString(naifBodyRadii[1].kilometers()), "KILOMETERS"); + pdsLabel += PvlKeyword("C_AXIS_RADIUS", Isis::toString(naifBodyRadii[2].kilometers()), "KILOMETERS"); } if (naifKeywordGroup.hasKeyword("BODY_FRAME_CODE")) { pdsLabel += naifKeywordGroup.findKeyword("BODY_FRAME_CODE"); } else { - pdsLabel += PvlKeyword("BODY_FRAME_CODE", toString(cam->naifBodyFrameCode())); + pdsLabel += PvlKeyword("BODY_FRAME_CODE", Isis::toString(cam->naifBodyFrameCode())); } if (naifKeywordGroup.hasKeyword("IDEAL_FOCAL_LENGTH")) { pdsLabel += naifKeywordGroup.findKeyword("IDEAL_FOCAL_LENGTH"); } else { - pdsLabel += PvlKeyword("IDEAL_FOCAL_LENGTH", toString(cam->FocalLength())); + pdsLabel += PvlKeyword("IDEAL_FOCAL_LENGTH", Isis::toString(cam->FocalLength())); } if (naifKeywordGroup.hasKeyword("IDEAL_PIXEL_PITCH")) { pdsLabel += naifKeywordGroup.findKeyword("IDEAL_PIXEL_PITCH"); } else { - pdsLabel += PvlKeyword("IDEAL_PIXEL_PITCH", toString(cam->PixelPitch())); + pdsLabel += PvlKeyword("IDEAL_PIXEL_PITCH", Isis::toString(cam->PixelPitch())); } if (naifKeywordGroup.hasKeyword("IDEAL_TRANSX")) { @@ -583,7 +583,7 @@ void updatePdsLabelRootObject(PvlObject *isisCubeLab, Pvl &pdsLabel, const double *transXValues = cam->FocalPlaneMap()->TransX(); PvlKeyword transX("IDEAL_TRANSX"); for (int i = 0; i < 3; i++) { - transX += toString(transXValues[i]); + transX += Isis::toString(transXValues[i]); } pdsLabel += transX; } @@ -595,7 +595,7 @@ void updatePdsLabelRootObject(PvlObject *isisCubeLab, Pvl &pdsLabel, const double *transYValues = cam->FocalPlaneMap()->TransY(); PvlKeyword transY("IDEAL_TRANSY"); for (int i = 0; i < 3; i++) { - transY += toString(transYValues[i]); + transY += Isis::toString(transYValues[i]); } pdsLabel += transY; } @@ -607,7 +607,7 @@ void updatePdsLabelRootObject(PvlObject *isisCubeLab, Pvl &pdsLabel, const double *transSValues = cam->FocalPlaneMap()->TransS(); PvlKeyword transS("IDEAL_TRANSS"); for (int i = 0; i < 3; i++) { - transS += toString(transSValues[i]); + transS += Isis::toString(transSValues[i]); } pdsLabel += transS; } @@ -619,7 +619,7 @@ void updatePdsLabelRootObject(PvlObject *isisCubeLab, Pvl &pdsLabel, const double *transLValues = cam->FocalPlaneMap()->TransL(); PvlKeyword transL("IDEAL_TRANSL"); for (int i = 0; i < 3; i++) { - transL += toString(transLValues[i]); + transL += Isis::toString(transLValues[i]); } pdsLabel += transL; } diff --git a/isis/src/mro/apps/hidtmgen/hidtmgen.cpp b/isis/src/mro/apps/hidtmgen/hidtmgen.cpp index f1d5beece7..e5f07ba36d 100644 --- a/isis/src/mro/apps/hidtmgen/hidtmgen.cpp +++ b/isis/src/mro/apps/hidtmgen/hidtmgen.cpp @@ -499,7 +499,7 @@ namespace Isis{ PvlObject viewingParameters("VIEWING_PARAMETERS"); if (northAzimuth != Isis::Null) { - viewingParameters.addKeyword(PvlKeyword("NORTH_AZIMUTH", toString(northAzimuth), "DEG")); + viewingParameters.addKeyword(PvlKeyword("NORTH_AZIMUTH", Isis::toString(northAzimuth), "DEG")); } else { viewingParameters.addKeyword(PvlKeyword("NORTH_AZIMUTH", "N/A")); @@ -513,11 +513,11 @@ namespace Isis{ TProjection *proj = (TProjection *) ProjectionFactory::CreateFromCube(*inCube); double newRadius = proj->LocalRadius((double)mappingObject["CENTER_LATITUDE"]); newRadius /= 1000; - mappingObject.findKeyword("A_AXIS_RADIUS").setValue(toString(newRadius)); + mappingObject.findKeyword("A_AXIS_RADIUS").setValue(Isis::toString(newRadius)); mappingObject.findKeyword("A_AXIS_RADIUS").setUnits("KM"); - mappingObject.findKeyword("B_AXIS_RADIUS").setValue(toString(newRadius)); + mappingObject.findKeyword("B_AXIS_RADIUS").setValue(Isis::toString(newRadius)); mappingObject.findKeyword("B_AXIS_RADIUS").setUnits("KM"); - mappingObject.findKeyword("C_AXIS_RADIUS").setValue(toString(newRadius)); + mappingObject.findKeyword("C_AXIS_RADIUS").setValue(Isis::toString(newRadius)); mappingObject.findKeyword("C_AXIS_RADIUS").setUnits("KM"); } @@ -532,14 +532,14 @@ namespace Isis{ // find the center latitude of this set of images // (not the same as the center lat for the projection) - double clat = ((IString::ToDouble(mappingObject["MAXIMUM_LATITUDE"][0]) - - IString::ToDouble(mappingObject["MINIMUM_LATITUDE"][0])) / 2) + - IString::ToDouble(mappingObject["MINIMUM_LATITUDE"][0]); + double clat = ((Isis::toDouble(mappingObject["MAXIMUM_LATITUDE"][0]) - + Isis::toDouble(mappingObject["MINIMUM_LATITUDE"][0])) / 2) + + Isis::toDouble(mappingObject["MINIMUM_LATITUDE"][0]); // find the center longitude of this set of images // (not the same as the center lon for the projection) - double clon = ((IString::ToDouble(mappingObject["EASTERNMOST_LONGITUDE"][0]) - - IString::ToDouble(mappingObject["WESTERNMOST_LONGITUDE"][0])) / 2) + - IString::ToDouble(mappingObject["WESTERNMOST_LONGITUDE"][0]); + double clon = ((Isis::toDouble(mappingObject["EASTERNMOST_LONGITUDE"][0]) - + Isis::toDouble(mappingObject["WESTERNMOST_LONGITUDE"][0])) / 2) + + Isis::toDouble(mappingObject["WESTERNMOST_LONGITUDE"][0]); if (clat > 0.0 && clon < 270.0) { // Northern Hemisphere, 0 to 270 lon northAzimuth = 270.00 - clon; @@ -603,7 +603,7 @@ namespace Isis{ QString versionNumber(const Pvl ¶msPvl, const UserInterface &ui) { - double version = IString::ToDouble(paramsPvl["PRODUCT_VERSION_ID"]); + double version = Isis::toDouble(paramsPvl["PRODUCT_VERSION_ID"]); // Format the version for the output name: // Only important thing to note is that a #.0 number is converted to 0# @@ -777,8 +777,8 @@ namespace Isis{ // Create statistics and add to image group Statistics *stat = inCube->statistics(); - image.addKeyword(PvlKeyword("VALID_MINIMUM", toString(stat->Minimum()))); - image.addKeyword(PvlKeyword("VALID_MAXIMUM", toString(stat->Maximum()))); + image.addKeyword(PvlKeyword("VALID_MINIMUM", Isis::toString(stat->Minimum()))); + image.addKeyword(PvlKeyword("VALID_MAXIMUM", Isis::toString(stat->Maximum()))); // delete unneeded keywords in map object mappingObject.deleteKeyword("FIRST_STANDARD_PARALLEL"); diff --git a/isis/src/mro/apps/hifringe/main.cpp b/isis/src/mro/apps/hifringe/main.cpp index d637b3e62b..dbe67871e6 100644 --- a/isis/src/mro/apps/hifringe/main.cpp +++ b/isis/src/mro/apps/hifringe/main.cpp @@ -199,28 +199,28 @@ void IsisMain() { void pvlOut(Statistics stats1, Statistics stats2, QString name, int start, int end, PvlObject *one, PvlObject *two) { PvlGroup left(name.toStdString()); - left += PvlKeyword("StartLine", toString(start + 1)); - left += PvlKeyword("EndLine", toString(end)); - left += PvlKeyword("TotalPixels", toString(stats1.TotalPixels())); - left += PvlKeyword("ValidPixels", toString(stats1.ValidPixels())); + left += PvlKeyword("StartLine", Isis::toString(start + 1)); + left += PvlKeyword("EndLine", Isis::toString(end)); + left += PvlKeyword("TotalPixels", Isis::toString(stats1.TotalPixels())); + left += PvlKeyword("ValidPixels", Isis::toString(stats1.ValidPixels())); if(stats1.ValidPixels() > 0) { - left += PvlKeyword("Mean", toString(stats1.Average())); - left += PvlKeyword("StandardDeviation", toString(stats1.StandardDeviation())); - left += PvlKeyword("Minimum", toString(stats1.Minimum())); - left += PvlKeyword("Maximum", toString(stats1.Maximum())); + left += PvlKeyword("Mean", Isis::toString(stats1.Average())); + left += PvlKeyword("StandardDeviation", Isis::toString(stats1.StandardDeviation())); + left += PvlKeyword("Minimum", Isis::toString(stats1.Minimum())); + left += PvlKeyword("Maximum", Isis::toString(stats1.Maximum())); } one->addGroup(left); PvlGroup right(name.toStdString()); - right += PvlKeyword("StartLine", toString(start + 1)); - right += PvlKeyword("EndLine", toString(end)); - right += PvlKeyword("TotalPixels", toString(stats2.TotalPixels())); - right += PvlKeyword("ValidPixels", toString(stats2.ValidPixels())); + right += PvlKeyword("StartLine", Isis::toString(start + 1)); + right += PvlKeyword("EndLine", Isis::toString(end)); + right += PvlKeyword("TotalPixels", Isis::toString(stats2.TotalPixels())); + right += PvlKeyword("ValidPixels", Isis::toString(stats2.ValidPixels())); if(stats2.ValidPixels() > 0) { - right += PvlKeyword("Mean", toString(stats2.Average())); - right += PvlKeyword("StandardDeviation", toString(stats2.StandardDeviation())); - right += PvlKeyword("Minimum", toString(stats2.Minimum())); - right += PvlKeyword("Maximum", toString(stats2.Maximum())); + right += PvlKeyword("Mean", Isis::toString(stats2.Average())); + right += PvlKeyword("StandardDeviation", Isis::toString(stats2.StandardDeviation())); + right += PvlKeyword("Minimum", Isis::toString(stats2.Minimum())); + right += PvlKeyword("Maximum", Isis::toString(stats2.Maximum())); } two->addGroup(right); } diff --git a/isis/src/mro/apps/hifurrows/main.cpp b/isis/src/mro/apps/hifurrows/main.cpp index 72b5a53732..bc912a27c3 100644 --- a/isis/src/mro/apps/hifurrows/main.cpp +++ b/isis/src/mro/apps/hifurrows/main.cpp @@ -133,7 +133,7 @@ void IsisMain() { ss >> finish; } label += "Column" + begin + "to" + finish; - stats += PvlKeyword(label.c_str(), toString(furrows[i].mvstats[j].Correlation())); + stats += PvlKeyword(label.c_str(), Isis::toString(furrows[i].mvstats[j].Correlation())); } } Application::Log(stats); diff --git a/isis/src/mro/apps/hijitreg/main.cpp b/isis/src/mro/apps/hijitreg/main.cpp index e604f32059..99360b55dd 100644 --- a/isis/src/mro/apps/hijitreg/main.cpp +++ b/isis/src/mro/apps/hijitreg/main.cpp @@ -355,9 +355,9 @@ void IsisMain() { if (jparms.sStats.ValidPixels() > 0) { double sTrans = (int)(jparms.sStats.Average() * 100.0) / 100.0; double lTrans = (int)(jparms.lStats.Average() * 100.0) / 100.0; - results += PvlKeyword("Sample", toString(sTrans)); - results += PvlKeyword("Line", toString(lTrans)); - results += PvlKeyword("NSuspects", toString(jparms.nSuspects)); + results += PvlKeyword("Sample", Isis::toString(sTrans)); + results += PvlKeyword("Line", Isis::toString(lTrans)); + results += PvlKeyword("NSuspects", Isis::toString(jparms.nSuspects)); } else { results += PvlKeyword("Sample", "NULL"); diff --git a/isis/src/mro/apps/himos/himos.cpp b/isis/src/mro/apps/himos/himos.cpp index 7c2088a117..6a7917769f 100644 --- a/isis/src/mro/apps/himos/himos.cpp +++ b/isis/src/mro/apps/himos/himos.cpp @@ -259,13 +259,13 @@ namespace Isis { mos += PvlKeyword("SpacecraftClockStartCount ", startClock.toStdString()); mos += PvlKeyword("StopTime ", stopTime.toStdString()); mos += PvlKeyword("SpacecraftClockStopCount ", stopClock.toStdString()); - mos += PvlKeyword("IncidenceAngle ", toString(Cincid), "DEG"); - mos += PvlKeyword("EmissionAngle ", toString(Cemiss), "DEG"); - mos += PvlKeyword("PhaseAngle ", toString(Cphase), "DEG"); - mos += PvlKeyword("LocalTime ", toString(ClocalSolTime), "LOCALDAY/24"); - mos += PvlKeyword("SolarLongitude ", toString(CsolarLong), "DEG"); - mos += PvlKeyword("SubSolarAzimuth ", toString(CsunAzimuth), "DEG"); - mos += PvlKeyword("NorthAzimuth ", toString(CnorthAzimuth), "DEG"); + mos += PvlKeyword("IncidenceAngle ", Isis::toString(Cincid), "DEG"); + mos += PvlKeyword("EmissionAngle ", Isis::toString(Cemiss), "DEG"); + mos += PvlKeyword("PhaseAngle ", Isis::toString(Cphase), "DEG"); + mos += PvlKeyword("LocalTime ", Isis::toString(ClocalSolTime), "LOCALDAY/24"); + mos += PvlKeyword("SolarLongitude ", Isis::toString(CsolarLong), "DEG"); + mos += PvlKeyword("SubSolarAzimuth ", Isis::toString(CsunAzimuth), "DEG"); + mos += PvlKeyword("NorthAzimuth ", Isis::toString(CnorthAzimuth), "DEG"); mos += cpmmTdiFlag; mos += cpmmSummingFlag; mos += specialProcessingFlag; diff --git a/isis/src/mro/apps/hinoise/main.cpp b/isis/src/mro/apps/hinoise/main.cpp index 35da55263f..0829a31a99 100644 --- a/isis/src/mro/apps/hinoise/main.cpp +++ b/isis/src/mro/apps/hinoise/main.cpp @@ -87,8 +87,8 @@ void IsisMain() { // Get Summing, CcdId and Channel Number from the cube label Pvl cubeLabel = Pvl(sInputFile.toStdString()); - int iSumming = IString::ToInteger(cubeLabel.findObject("IsisCube").findGroup("Instrument").findKeyword("Summing")[0]); - int iChannel = IString::ToInteger(cubeLabel.findObject("IsisCube").findGroup("Instrument").findKeyword("ChannelNumber")[0]); + int iSumming = Isis::toInt(cubeLabel.findObject("IsisCube").findGroup("Instrument").findKeyword("Summing")[0]); + int iChannel = Isis::toInt(cubeLabel.findObject("IsisCube").findGroup("Instrument").findKeyword("ChannelNumber")[0]); QString sCcdId = QString::fromStdString(cubeLabel.findObject("IsisCube").findGroup("Instrument").findKeyword("CcdId")); // Get the image histogram diff --git a/isis/src/mro/apps/hirdrgen/main.cpp b/isis/src/mro/apps/hirdrgen/main.cpp index c3a46f5351..f48dbd22f7 100644 --- a/isis/src/mro/apps/hirdrgen/main.cpp +++ b/isis/src/mro/apps/hirdrgen/main.cpp @@ -210,7 +210,7 @@ void IsisMain() { timeParam += PvlKeyword("PRODUCT_CREATION_TIME", tmpDateTime.UTC().toStdString()); // Add the N/A constant keyword to the ROOT - pdsLabel += PvlKeyword("NOT_APPLICABLE_CONSTANT", toString(-9998)); + pdsLabel += PvlKeyword("NOT_APPLICABLE_CONSTANT", Isis::toString(-9998)); // Add SOFTWARE_NAME to the ROOT QString sfname; @@ -306,9 +306,9 @@ void IsisMain() { TProjection *proj = (TProjection *) ProjectionFactory::CreateFromCube(*icube2); PvlGroup &mapping = icube2->label()->findGroup("MAPPING", Pvl::Traverse); double radius = proj->LocalRadius((double)mapping["CenterLatitude"]) / 1000.0; - mapObject["A_AXIS_RADIUS"].setValue(toString(radius), "KM"); - mapObject["B_AXIS_RADIUS"].setValue(toString(radius), "KM"); - mapObject["C_AXIS_RADIUS"].setValue(toString(radius), "KM"); + mapObject["A_AXIS_RADIUS"].setValue(Isis::toString(radius), "KM"); + mapObject["B_AXIS_RADIUS"].setValue(Isis::toString(radius), "KM"); + mapObject["C_AXIS_RADIUS"].setValue(Isis::toString(radius), "KM"); } projName = QString::fromStdString(mapObject["MAP_PROJECTION_TYPE"][0]); @@ -319,11 +319,11 @@ void IsisMain() { // The input to output mapping is opposite from the one above double slope = (p.GetOutputMaximum() - p.GetOutputMinimum()) / (maxmax - minmin); double intercept = p.GetOutputMaximum() - slope * maxmax; - PvlKeyword minimum("MRO:MINIMUM_STRETCH", toString(slope * g_min[0] + intercept)); - PvlKeyword maximum("MRO:MAXIMUM_STRETCH", toString(slope * g_max[0] + intercept)); + PvlKeyword minimum("MRO:MINIMUM_STRETCH", Isis::toString(slope * g_min[0] + intercept)); + PvlKeyword maximum("MRO:MAXIMUM_STRETCH", Isis::toString(slope * g_max[0] + intercept)); for (int band = 1; band < icube2->bandCount(); ++band) { - minimum += toString(slope * g_min[band] + intercept); - maximum += toString(slope * g_max[band] + intercept); + minimum += Isis::toString(slope * g_min[band] + intercept); + maximum += Isis::toString(slope * g_max[band] + intercept); } if (enctype.Equal("jp2")) { @@ -334,8 +334,8 @@ void IsisMain() { imagejp2 += PvlKeyword("DESCRIPTION", "HiRISE projected and mosaicked product"); // Add the SCALLING_FACTOR and OFFSET keywords - imagejp2.addKeyword(PvlKeyword("SCALING_FACTOR", toString(slope)), Pvl::Replace); - imagejp2.addKeyword(PvlKeyword("OFFSET", toString(intercept)), Pvl::Replace); + imagejp2.addKeyword(PvlKeyword("SCALING_FACTOR", Isis::toString(slope)), Pvl::Replace); + imagejp2.addKeyword(PvlKeyword("OFFSET", Isis::toString(intercept)), Pvl::Replace); // Reformat some keyword units in the image object // This is lame, but PDS units are difficult to work with, so for now??? @@ -381,7 +381,7 @@ void IsisMain() { // ProcessExportPds if (nbits != 8 && nbits != 16) { imagejp2.addKeyword(PvlKeyword("SAMPLE_BIT_MASK", - toString((int)pow(2.0, (double)ui.GetInteger("BITS")) - 1)), + Isis::toString((int)pow(2.0, (double)ui.GetInteger("BITS")) - 1)), Pvl::Replace); } } @@ -402,8 +402,8 @@ void IsisMain() { // ??? unneccessary calculation - this is done by ProcessExportPds class. double slope = (maxmax - minmin) / (p.GetOutputMaximum() - p.GetOutputMinimum()); double intercept = maxmax - slope * p.GetOutputMaximum(); - image.addKeyword(PvlKeyword("SCALING_FACTOR", toString(slope)), Pvl::Replace); - image.addKeyword(PvlKeyword("OFFSET", toString(intercept)), Pvl::Replace); + image.addKeyword(PvlKeyword("SCALING_FACTOR", Isis::toString(slope)), Pvl::Replace); + image.addKeyword(PvlKeyword("OFFSET", Isis::toString(intercept)), Pvl::Replace); // Reformat some keyword units in the image object // This is lame, but PDS units are difficult to work with, so for now @@ -449,7 +449,7 @@ void IsisMain() { // ProcessExportPds if (nbits != 8 && nbits != 16) { image.addKeyword(PvlKeyword("SAMPLE_BIT_MASK", - toString((int)pow(2.0, (double)ui.GetInteger("BITS")) - 1)), + Isis::toString((int)pow(2.0, (double)ui.GetInteger("BITS")) - 1)), Pvl::Replace); } } diff --git a/isis/src/mro/apps/histat/main.cpp b/isis/src/mro/apps/histat/main.cpp index 6ecd2818a7..ee25f03854 100644 --- a/isis/src/mro/apps/histat/main.cpp +++ b/isis/src/mro/apps/histat/main.cpp @@ -314,19 +314,19 @@ PvlGroup PvlStats(Statistics &stats, const QString &name) { // Construct a label with the results PvlGroup results(name.toStdString()); if(stats.ValidPixels() != 0) { - results += PvlKeyword("Average", toString(stats.Average())); - results += PvlKeyword("StandardDeviation", toString(stats.StandardDeviation())); - results += PvlKeyword("Variance", toString(stats.Variance())); - results += PvlKeyword("Minimum", toString(stats.Minimum())); - results += PvlKeyword("Maximum", toString(stats.Maximum())); + results += PvlKeyword("Average", Isis::toString(stats.Average())); + results += PvlKeyword("StandardDeviation", Isis::toString(stats.StandardDeviation())); + results += PvlKeyword("Variance", Isis::toString(stats.Variance())); + results += PvlKeyword("Minimum", Isis::toString(stats.Minimum())); + results += PvlKeyword("Maximum", Isis::toString(stats.Maximum())); } - results += PvlKeyword("TotalPixels", toString(stats.TotalPixels())); - results += PvlKeyword("ValidPixels", toString(stats.ValidPixels())); - results += PvlKeyword("NullPixels", toString(stats.NullPixels())); - results += PvlKeyword("LisPixels", toString(stats.LisPixels())); - results += PvlKeyword("LrsPixels", toString(stats.LrsPixels())); - results += PvlKeyword("HisPixels", toString(stats.HisPixels())); - results += PvlKeyword("HrsPixels", toString(stats.HrsPixels())); + results += PvlKeyword("TotalPixels", Isis::toString(stats.TotalPixels())); + results += PvlKeyword("ValidPixels", Isis::toString(stats.ValidPixels())); + results += PvlKeyword("NullPixels", Isis::toString(stats.NullPixels())); + results += PvlKeyword("LisPixels", Isis::toString(stats.LisPixels())); + results += PvlKeyword("LrsPixels", Isis::toString(stats.LrsPixels())); + results += PvlKeyword("HisPixels", Isis::toString(stats.HisPixels())); + results += PvlKeyword("HrsPixels", Isis::toString(stats.HrsPixels())); return results; } diff --git a/isis/src/mro/apps/histitch/main.cpp b/isis/src/mro/apps/histitch/main.cpp index 1a13aaa792..25d69d1c8a 100644 --- a/isis/src/mro/apps/histitch/main.cpp +++ b/isis/src/mro/apps/histitch/main.cpp @@ -245,7 +245,7 @@ void IsisMain() { InstrumentOut += PvlKeyword("StitchedProductIds", stitchedProductIds.toStdString()); } else { - InstrumentOut += PvlKeyword("StitchedChannels", toString(fromData[0].ChnNumber)); + InstrumentOut += PvlKeyword("StitchedChannels", Isis::toString(fromData[0].ChnNumber)); InstrumentOut += PvlKeyword("StitchedProductIds", stitchedProductIds.toStdString()); } @@ -293,15 +293,15 @@ void IsisMain() { fromData[ch0Index].mult = coeff; } } - results += PvlKeyword("TruthChannel", toString(hiChannel)); - results += PvlKeyword("BalanceRatio", toString(coeff)); + results += PvlKeyword("TruthChannel", Isis::toString(hiChannel)); + results += PvlKeyword("BalanceRatio", Isis::toString(coeff)); } else { // Store off original averages for table HiVector ch0_org = f0LineAvg; HiVector ch1_org = f1LineAvg; - results += PvlKeyword("FilterWidth", toString(filterWidth)); + results += PvlKeyword("FilterWidth", Isis::toString(filterWidth)); if(filterWidth > 0) { f0LineAvg = filter(f0LineAvg, filterWidth); f1LineAvg = filter(f1LineAvg, filterWidth); @@ -311,12 +311,12 @@ void IsisMain() { if(fillNull) { int nfilled; f0LineAvg = filler(f0LineAvg, nfilled); - results += PvlKeyword("Channel0Filled", toString(nfilled)); + results += PvlKeyword("Channel0Filled", Isis::toString(nfilled)); f1LineAvg = filler(f1LineAvg, nfilled); - results += PvlKeyword("Channel1Filled", toString(nfilled)); + results += PvlKeyword("Channel1Filled", Isis::toString(nfilled)); } - results += PvlKeyword("TruthChannel", toString(hiChannel)); + results += PvlKeyword("TruthChannel", Isis::toString(hiChannel)); results += PvlKeyword("Operator", fixop.toStdString()); int nunfilled(0); HiVector ch0_fixed(icube1->lineCount(), 1.0); @@ -343,7 +343,7 @@ void IsisMain() { ch1_fixed = 0.0; } } - results += PvlKeyword("UnFilled", toString(nunfilled)); + results += PvlKeyword("UnFilled", Isis::toString(nunfilled)); // Add a table to the output file of the data values TableField f1("Channel1Original", Isis::TableField::Double); diff --git a/isis/src/mro/apps/marci2isis/marci2isis.cpp b/isis/src/mro/apps/marci2isis/marci2isis.cpp index 8d829014f2..93db1bff6f 100644 --- a/isis/src/mro/apps/marci2isis/marci2isis.cpp +++ b/isis/src/mro/apps/marci2isis/marci2isis.cpp @@ -173,7 +173,7 @@ namespace Isis{ // Populate with first values Pvl *isisLabelInitial = outputCubes[0]->label(); PvlGroup &instInitial = isisLabelInitial->findGroup("Instrument", Pvl::Traverse); - double exposure = IString::ToDouble(instInitial["ExposureDuration"][0]) * 1000.0; + double exposure = Isis::toDouble(instInitial["ExposureDuration"][0]) * 1000.0; frameseq.push_back(0); exptime.push_back(exposure); @@ -240,8 +240,8 @@ namespace Isis{ PvlKeyword frameNumber("FrameNumber"); for (unsigned int i=0; i < exptime.size(); i++) { - varExposure.addValue(toString(exptime[i]), "ms" ); - frameNumber.addValue(toString(frameseq[i])); + varExposure.addValue(Isis::toString(exptime[i]), "ms" ); + frameNumber.addValue(Isis::toString(frameseq[i])); } inst.addKeyword(frameNumber); inst.addKeyword(varExposure); @@ -395,17 +395,17 @@ namespace Isis{ inst += PvlKeyword("StartTime", pdsLabel["START_TIME"]); inst += PvlKeyword("StopTime", pdsLabel["STOP_TIME"]); inst += PvlKeyword("SpacecraftClockCount", pdsLabel["SPACECRAFT_CLOCK_START_COUNT"]); - inst += PvlKeyword("DataFlipped", toString((int)(flip == 1))); - inst += PvlKeyword("ColorOffset", toString(colorOffset)); - inst += PvlKeyword("InterframeDelay", toString((double)pdsLabel["INTERFRAME_DELAY"]), "seconds"); - inst += PvlKeyword("ExposureDuration", toString((double)pdsLabel["LINE_EXPOSURE_DURATION"] / 1000.0), "seconds"); + inst += PvlKeyword("DataFlipped", Isis::toString((int)(flip == 1))); + inst += PvlKeyword("ColorOffset", Isis::toString(colorOffset)); + inst += PvlKeyword("InterframeDelay", Isis::toString((double)pdsLabel["INTERFRAME_DELAY"]), "seconds"); + inst += PvlKeyword("ExposureDuration", Isis::toString((double)pdsLabel["LINE_EXPOSURE_DURATION"] / 1000.0), "seconds"); PvlGroup bandBin("BandBin"); PvlKeyword filterName("FilterName"); PvlKeyword origBands("OriginalBand"); for(int filter = 0; filter < pdsLabel["FILTER_NAME"].size(); filter++) { filterName += pdsLabel["FILTER_NAME"][filter]; - origBands += toString(filter + 1); + origBands += Isis::toString(filter + 1); } bandBin += filterName; @@ -435,7 +435,7 @@ namespace Isis{ PvlGroup kerns("Kernels"); QString uvvis = bandUvVis.find(QString::fromStdString(bandBin["FilterName"][0]))->second; int iakCode = naifIkCodes.find(uvvis)->second; - kerns += PvlKeyword("NaifIkCode", toString(iakCode)); + kerns += PvlKeyword("NaifIkCode", Isis::toString(iakCode)); isisCube.addGroup(kerns); } diff --git a/isis/src/mro/apps/marcical/marcical.cpp b/isis/src/mro/apps/marcical/marcical.cpp index 5754083ea6..6784e4d188 100644 --- a/isis/src/mro/apps/marcical/marcical.cpp +++ b/isis/src/mro/apps/marcical/marcical.cpp @@ -256,9 +256,9 @@ namespace Isis { vector flatcubes; vector fcubeMgrs; - int summing = IString::ToInteger(icube.group("Instrument")["SummingMode"][0]); - double ifdelay = IString::ToDouble(icube.group("Instrument")["InterframeDelay"][0]) * 1000.0; - int flipped = IString::ToInteger(icube.group("Instrument")["DataFlipped"][0]); + int summing = Isis::toInt(icube.group("Instrument")["SummingMode"][0]); + double ifdelay = Isis::toDouble(icube.group("Instrument")["InterframeDelay"][0]) * 1000.0; + int flipped = Isis::toInt(icube.group("Instrument")["DataFlipped"][0]); // Read in the flat files for (int band = 0; band < 7; band++) { @@ -330,12 +330,12 @@ namespace Isis { } PvlKeyword &sumMode = icube.label()->findGroup("Instrument", Pvl::Traverse)["SummingMode"]; - int summingMode = IString::ToInteger(sumMode[0]); + int summingMode = Isis::toInt(sumMode[0]); int filterHeight = 16 / summingMode; std::vector padding; padding.resize(numFilters); PvlKeyword &colOff = icube.label()->findGroup("Instrument", Pvl::Traverse)["ColorOffset"]; - int colorOffset = IString::ToInteger(colOff[0]); + int colorOffset = Isis::toInt(colOff[0]); for (int i = 0; i < numFilters; i++) { if (colorOffset > 0) { @@ -377,9 +377,9 @@ namespace Isis { PvlKeyword expTimesKey = inst["VariableExposureDuration"]; PvlKeyword frameNumbersKey = inst["FrameNumber"]; for (int i=0; igroup("Instrument"); // change flipped keyword - inst["DataFlipped"] = toString(((int)inst["DataFlipped"] + 1) % 2); + inst["DataFlipped"] = Isis::toString(((int)inst["DataFlipped"] + 1) % 2); outputCube->label()->findObject("IsisCube").addGroup(inst); } diff --git a/isis/src/mro/apps/mroctx2isis/main.cpp b/isis/src/mro/apps/mroctx2isis/main.cpp index 1922ce98ca..4b7cd8a7c1 100644 --- a/isis/src/mro/apps/mroctx2isis/main.cpp +++ b/isis/src/mro/apps/mroctx2isis/main.cpp @@ -244,12 +244,12 @@ void TranslateMroCtxLabels(FileName &labelFile, Cube *ocube) { // Set up the BandBin groups PvlGroup bbin("BandBin"); bbin += PvlKeyword("FilterName", "BroadBand"); - bbin += PvlKeyword("Center", toString(0.650), "micrometers"); - bbin += PvlKeyword("Width", toString(0.150), "micrometers"); + bbin += PvlKeyword("Center", Isis::toString(0.650), "micrometers"); + bbin += PvlKeyword("Width", Isis::toString(0.150), "micrometers"); //Set up the Kernels group PvlGroup kern("Kernels"); - kern += PvlKeyword("NaifFrameCode", toString(-74021)); + kern += PvlKeyword("NaifFrameCode", Isis::toString(-74021)); Pvl lab(labelFile.expanded()); int sumMode, startSamp; @@ -266,8 +266,8 @@ void TranslateMroCtxLabels(FileName &labelFile, Cube *ocube) { startSamp = (int)lab.findKeyword("SAMPLE_FIRST_PIXEL"); } PvlGroup inst = outLabel.findGroup("Instrument", Pvl::Traverse); - inst += PvlKeyword("SpatialSumming", toString(sumMode)); - inst += PvlKeyword("SampleFirstPixel", toString(startSamp)); + inst += PvlKeyword("SpatialSumming", Isis::toString(sumMode)); + inst += PvlKeyword("SampleFirstPixel", Isis::toString(startSamp)); //Add all groups to the output cube ocube->putGroup(inst); diff --git a/isis/src/mro/apps/pds2hideal/main.cpp b/isis/src/mro/apps/pds2hideal/main.cpp index aecde341fb..604d3c01db 100644 --- a/isis/src/mro/apps/pds2hideal/main.cpp +++ b/isis/src/mro/apps/pds2hideal/main.cpp @@ -59,7 +59,7 @@ void IsisMain() { outputCube->putGroup(otherGroups.findGroup("Archive")); PvlGroup kernelGroup("Kernels"); - kernelGroup += PvlKeyword("NaifIkCode", toString(-74699)); + kernelGroup += PvlKeyword("NaifIkCode", Isis::toString(-74699)); kernelGroup += PvlKeyword("TargetPosition", "Table"); kernelGroup += PvlKeyword("InstrumentPointing", "Table"); kernelGroup += PvlKeyword("InstrumentPosition", "Table"); @@ -101,14 +101,14 @@ void IsisMain() { if (sourceLines != lines) { // this image is cropped, create an AlphaCube group PvlGroup alphaCube("AlphaCube"); - alphaCube += PvlKeyword("AlphaSamples", toString(sourceSamps)); - alphaCube += PvlKeyword("AlphaLines", toString(sourceLines)); - alphaCube += PvlKeyword("AlphaStartingSample", toString(firstSamp)); - alphaCube += PvlKeyword("AlphaEndingSample", toString((double) firstSamp + samples)); - alphaCube += PvlKeyword("AlphaStartingLine", toString(firstLine)); - alphaCube += PvlKeyword("AlphaEndingLine", toString((double) firstLine + lines)); - alphaCube += PvlKeyword("BetaSamples", toString(samples)); - alphaCube += PvlKeyword("BetaLines", toString(lines)); + alphaCube += PvlKeyword("AlphaSamples", Isis::toString(sourceSamps)); + alphaCube += PvlKeyword("AlphaLines", Isis::toString(sourceLines)); + alphaCube += PvlKeyword("AlphaStartingSample", Isis::toString(firstSamp)); + alphaCube += PvlKeyword("AlphaEndingSample", Isis::toString((double) firstSamp + samples)); + alphaCube += PvlKeyword("AlphaStartingLine", Isis::toString(firstLine)); + alphaCube += PvlKeyword("AlphaEndingLine", Isis::toString((double) firstLine + lines)); + alphaCube += PvlKeyword("BetaSamples", Isis::toString(samples)); + alphaCube += PvlKeyword("BetaLines", Isis::toString(lines)); isisCubeObject += alphaCube; } diff --git a/isis/src/near/apps/msi2isis/msi2isis.cpp b/isis/src/near/apps/msi2isis/msi2isis.cpp index 3c94348b9e..6c56c0bb44 100644 --- a/isis/src/near/apps/msi2isis/msi2isis.cpp +++ b/isis/src/near/apps/msi2isis/msi2isis.cpp @@ -75,8 +75,8 @@ namespace Isis { + "]. The msi2isis program requires INSTRUMENT_ID = [MSI].", _FILEINFO_); } - int lines = IString::ToInteger(inputLabelPvl.findObject("IMAGE")["LINES"][0]); - int samples = IString::ToInteger(inputLabelPvl.findObject("IMAGE")["LINE_SAMPLES"][0]); + int lines = Isis::toInt(inputLabelPvl.findObject("IMAGE")["LINES"][0]); + int samples = Isis::toInt(inputLabelPvl.findObject("IMAGE")["LINE_SAMPLES"][0]); if ( ( (lines != 244) && (lines != 412) ) || samples != 537) { std::string msg = "The given file [" + from.expanded() + "] does not contain " "a full MSI image. Full NEAR Shoemaker MSI images have " diff --git a/isis/src/newhorizons/apps/leisa2isis/leisa2isis.cpp b/isis/src/newhorizons/apps/leisa2isis/leisa2isis.cpp index af494799d5..03c03b41c5 100644 --- a/isis/src/newhorizons/apps/leisa2isis/leisa2isis.cpp +++ b/isis/src/newhorizons/apps/leisa2isis/leisa2isis.cpp @@ -204,7 +204,7 @@ namespace Isis { QString exposureTime = QString::fromStdString(inst["ExposureDuration"]); double frameRate = 1.0/exposureTime.toDouble(); - inst.addKeyword(PvlKeyword("FrameRate", toString(frameRate)), PvlGroup::Replace); + inst.addKeyword(PvlKeyword("FrameRate", Isis::toString(frameRate)), PvlGroup::Replace); inst.findKeyword("FrameRate").setUnits("Hz"); // Save the input FITS label in the Cube original labels diff --git a/isis/src/newhorizons/apps/mvic2isis/mvic2isis.cpp b/isis/src/newhorizons/apps/mvic2isis/mvic2isis.cpp index c2f10ba8c7..708351642b 100644 --- a/isis/src/newhorizons/apps/mvic2isis/mvic2isis.cpp +++ b/isis/src/newhorizons/apps/mvic2isis/mvic2isis.cpp @@ -287,7 +287,7 @@ namespace Isis { bandBin.findKeyword("Name").addValue(name.toStdString()); bandBin.findKeyword("Center").addValue(center.toStdString(), "nanometers"); bandBin.findKeyword("Width").addValue(width.toStdString(), "nanometers"); - bandBin.findKeyword("OriginalBand").addValue(toString(i+1)); + bandBin.findKeyword("OriginalBand").addValue(Isis::toString(i+1)); QString fitsKey = QString("UTCMID%1").arg(i, 2, 10, QChar('0')); QString fitsVal = QString::fromStdString(fitslabel.findKeyword(fitsKey.toStdString(), Pvl::Traverse)); bandBin.findKeyword("UtcTime").addValue(fitsVal.toStdString()); diff --git a/isis/src/newhorizons/objs/NewHorizonsLeisaCamera/NewHorizonsLeisaCamera.cpp b/isis/src/newhorizons/objs/NewHorizonsLeisaCamera/NewHorizonsLeisaCamera.cpp index 273e4718e7..ce3f5146e5 100644 --- a/isis/src/newhorizons/objs/NewHorizonsLeisaCamera/NewHorizonsLeisaCamera.cpp +++ b/isis/src/newhorizons/objs/NewHorizonsLeisaCamera/NewHorizonsLeisaCamera.cpp @@ -91,7 +91,7 @@ namespace Isis { PvlGroup &bandBin = lab.findGroup("BandBin", Pvl::Traverse); PvlKeyword &orgBand = bandBin["OriginalBand"]; for (int i = 0; i < orgBand.size(); i++) { - m_originalBand.append(IString::ToInteger(orgBand[i])); + m_originalBand.append(Isis::toInt(orgBand[i])); } // Use the defualt no correction distortion map. diff --git a/isis/src/newhorizons/objs/NewHorizonsMvicFrameCamera/NewHorizonsMvicFrameCamera.cpp b/isis/src/newhorizons/objs/NewHorizonsMvicFrameCamera/NewHorizonsMvicFrameCamera.cpp index a738e01227..12190dc0dc 100644 --- a/isis/src/newhorizons/objs/NewHorizonsMvicFrameCamera/NewHorizonsMvicFrameCamera.cpp +++ b/isis/src/newhorizons/objs/NewHorizonsMvicFrameCamera/NewHorizonsMvicFrameCamera.cpp @@ -70,7 +70,7 @@ namespace Isis { PvlKeyword &origBand = bandBin["OriginalBand"]; PvlKeyword &utcTime = bandBin["UtcTime"]; for(int i = 0; i < origBand.size(); i++) { - m_originalBand.push_back(IString::ToInteger(origBand[i])); + m_originalBand.push_back(Isis::toInt(origBand[i])); m_utcTime.push_back(QString::fromStdString(utcTime[i])); } diff --git a/isis/src/odyssey/apps/thm2isis/thm2isis.cpp b/isis/src/odyssey/apps/thm2isis/thm2isis.cpp index 1c0bf67a56..c03bf1e6aa 100644 --- a/isis/src/odyssey/apps/thm2isis/thm2isis.cpp +++ b/isis/src/odyssey/apps/thm2isis/thm2isis.cpp @@ -109,7 +109,7 @@ namespace Isis { if(outputCubes.size() != 1) { int numFramelets = p.Lines() / frameletLines; isis3Lab.findGroup("Instrument").addKeyword( - PvlKeyword("NumFramelets", toString(numFramelets)), Pvl::Replace + PvlKeyword("NumFramelets", Isis::toString(numFramelets)), Pvl::Replace ); QString frameletType = ((i == 0) ? "Odd" : "Even"); @@ -189,7 +189,7 @@ namespace Isis { // Add at time offset to the Instrument group double spacecraftClockOffset = ui.GetDouble("TIMEOFFSET"); - inst += PvlKeyword("SpacecraftClockOffset", toString(spacecraftClockOffset), "seconds"); + inst += PvlKeyword("SpacecraftClockOffset", Isis::toString(spacecraftClockOffset), "seconds"); isis3.addGroup(inst); @@ -199,7 +199,7 @@ namespace Isis { // The original band is the original ISIS cube band number upon ingestion PvlKeyword originalBand("OriginalBand"); for(int i = 1; i <= numBands; i++) { - originalBand.addValue(toString(i)); + originalBand.addValue(Isis::toString(i)); } bandBin += originalBand; @@ -253,10 +253,10 @@ namespace Isis { // Create the Kernel Group PvlGroup kerns("Kernels"); if(instId == "THEMIS_IR") { - kerns += PvlKeyword("NaifFrameCode", toString(-53031)); + kerns += PvlKeyword("NaifFrameCode", Isis::toString(-53031)); } else { - kerns += PvlKeyword("NaifFrameCode", toString(-53032)); + kerns += PvlKeyword("NaifFrameCode", Isis::toString(-53032)); } isis3.addGroup(kerns); } diff --git a/isis/src/odyssey/apps/thmnoseam/main.cpp b/isis/src/odyssey/apps/thmnoseam/main.cpp index 16e27e8c29..0656eced1e 100644 --- a/isis/src/odyssey/apps/thmnoseam/main.cpp +++ b/isis/src/odyssey/apps/thmnoseam/main.cpp @@ -133,7 +133,7 @@ void IsisMain() { PvlGroup &inputInstrumentGrp = evenCube->group("Instrument"); PvlKeyword &spatialSumming = inputInstrumentGrp["SpatialSumming"]; - frameletSize = 192 / IString::ToInteger(spatialSumming[0]); + frameletSize = 192 / Isis::toInt(spatialSumming[0]); overlapSize = FrameletOverlapSize(); if(overlapSize == 0) { diff --git a/isis/src/odyssey/apps/thmvisflat/main.cpp b/isis/src/odyssey/apps/thmvisflat/main.cpp index 49a88342e2..d0e72ebc19 100644 --- a/isis/src/odyssey/apps/thmvisflat/main.cpp +++ b/isis/src/odyssey/apps/thmvisflat/main.cpp @@ -46,7 +46,7 @@ void IsisMain() { vector flatcubes; vector fcubeMgrs; - int summing = IString::ToInteger(icube.group("Instrument")["SpatialSumming"][0]); + int summing = Isis::toInt(icube.group("Instrument")["SpatialSumming"][0]); for(int filt = 0; filt < 5; filt++) { QString filePattern = "$odyssey/calibration/flat_filter_"; @@ -79,7 +79,7 @@ void IsisMain() { PvlKeyword &filtNums = icube.label()->findGroup("BandBin", Pvl::Traverse)["FilterNumber"]; for(int i = 0; i < filtNums.size(); i++) { - filter.push_back(IString::ToInteger(filtNums[i])); + filter.push_back(Isis::toInt(filtNums[i])); } LineManager ocubeMgr(ocube); diff --git a/isis/src/odyssey/apps/thmvistrim/main.cpp b/isis/src/odyssey/apps/thmvistrim/main.cpp index 0ff9b9d713..dc4553fdf4 100644 --- a/isis/src/odyssey/apps/thmvistrim/main.cpp +++ b/isis/src/odyssey/apps/thmvistrim/main.cpp @@ -50,7 +50,7 @@ void IsisMain() { p.SetOutputCube("TO"); - frameletSize = 192 / IString::ToInteger(icube->group("Instrument")["SpatialSumming"][0]); + frameletSize = 192 / Isis::toInt(icube->group("Instrument")["SpatialSumming"][0]); frameletTopTrimSize = ui.GetInteger("TOPTRIM"); frameletLeftTrimSize = ui.GetInteger("LEFTTRIM"); frameletRightTrimSize = ui.GetInteger("RIGHTTRIM"); diff --git a/isis/src/odyssey/objs/ThemisIrCamera/ThemisIrCamera.cpp b/isis/src/odyssey/objs/ThemisIrCamera/ThemisIrCamera.cpp index 7eed8ed805..872c8b70ad 100644 --- a/isis/src/odyssey/objs/ThemisIrCamera/ThemisIrCamera.cpp +++ b/isis/src/odyssey/objs/ThemisIrCamera/ThemisIrCamera.cpp @@ -57,7 +57,7 @@ namespace Isis { PvlGroup &bandBin = lab.findGroup("BandBin", Pvl::Traverse); PvlKeyword &orgBand = bandBin["FilterNumber"]; for(int i = 0; i < orgBand.size(); i++) { - p_originalBand.push_back(IString::ToInteger(orgBand[i])); + p_originalBand.push_back(Isis::toInt(orgBand[i])); } // Themis IR had a summing mode added. This directly affects the line diff --git a/isis/src/odyssey/objs/ThemisVisCamera/ThemisVisCamera.cpp b/isis/src/odyssey/objs/ThemisVisCamera/ThemisVisCamera.cpp index ffc3fe36da..52a995de27 100644 --- a/isis/src/odyssey/objs/ThemisVisCamera/ThemisVisCamera.cpp +++ b/isis/src/odyssey/objs/ThemisVisCamera/ThemisVisCamera.cpp @@ -79,7 +79,7 @@ namespace Isis { PvlKeyword &filterNumbers = bandBin["FilterNumber"]; for (int i = 0; i < filterNumbers.size(); i++) { - p_filterNumber.append(IString::ToInteger(filterNumbers[i])); + p_filterNumber.append(Isis::toInt(filterNumbers[i])); } diff --git a/isis/src/osirisrex/apps/tagcams2isis/tagcams2isis.cpp b/isis/src/osirisrex/apps/tagcams2isis/tagcams2isis.cpp index 7949dc987b..1b65776a22 100644 --- a/isis/src/osirisrex/apps/tagcams2isis/tagcams2isis.cpp +++ b/isis/src/osirisrex/apps/tagcams2isis/tagcams2isis.cpp @@ -157,7 +157,7 @@ namespace Isis { // Create YearDoy keyword in Archive group iTime stime(QString::fromStdString(instGrp["StartTime"][0])); - PvlKeyword yeardoy("YearDoy", toString(stime.Year()*1000 + stime.DayOfYear())); + PvlKeyword yeardoy("YearDoy", Isis::toString(stime.Year()*1000 + stime.DayOfYear())); archiveGrp.addKeyword(yeardoy); output->putGroup(archiveGrp); @@ -181,7 +181,7 @@ namespace Isis { if ( "NFT" == instId ) b = -273.43; double camHeadTempC = a * ((double)rawcamT) + b; - instGrp.addKeyword(PvlKeyword("CameraHeadTemperature", toString(camHeadTempC), "celsius")); + instGrp.addKeyword(PvlKeyword("CameraHeadTemperature", Isis::toString(camHeadTempC), "celsius")); output->putGroup(instGrp); // Create a Band Bin group diff --git a/isis/src/qisis/objs/CubeViewport/CubeViewport.cpp b/isis/src/qisis/objs/CubeViewport/CubeViewport.cpp index e3baa7ac95..3b118b2c63 100644 --- a/isis/src/qisis/objs/CubeViewport/CubeViewport.cpp +++ b/isis/src/qisis/objs/CubeViewport/CubeViewport.cpp @@ -1375,15 +1375,15 @@ namespace Isis { whatsThisObj += PvlKeyword("Cube", p_cube->fileName().toStdString()); PvlGroup cubeGrp("CubeDimensions"); - cubeGrp += PvlKeyword("Samples", toString(p_cube->sampleCount())); - cubeGrp += PvlKeyword("Lines", toString(p_cube->lineCount())); - cubeGrp += PvlKeyword("Bands", toString(p_cube->bandCount())); + cubeGrp += PvlKeyword("Samples", Isis::toString(p_cube->sampleCount())); + cubeGrp += PvlKeyword("Lines", Isis::toString(p_cube->lineCount())); + cubeGrp += PvlKeyword("Bands", Isis::toString(p_cube->bandCount())); whatsThisObj += cubeGrp; // Get Viewport Info PvlGroup viewportGrp("ViewportDimensions"); - viewportGrp += PvlKeyword("Samples", toString(viewport()->width())); - viewportGrp += PvlKeyword("Lines", toString(viewport()->height())); + viewportGrp += PvlKeyword("Samples", Isis::toString(viewport()->width())); + viewportGrp += PvlKeyword("Lines", Isis::toString(viewport()->height())); whatsThisObj += viewportGrp; // Get Cube area Info @@ -1403,14 +1403,14 @@ namespace Isis { bandGrp += PvlKeyword("Color", "RGB"); - virtualKey = toString(iRedBand); - virtualKey += toString(iGreenBand); - virtualKey += toString(iBlueBand); + virtualKey = Isis::toString(iRedBand); + virtualKey += Isis::toString(iGreenBand); + virtualKey += Isis::toString(iBlueBand); bandGrp += virtualKey; - physicalKey = toString(p_cube->physicalBand(iRedBand)); - physicalKey += toString(p_cube->physicalBand(iGreenBand)); - physicalKey += toString(p_cube->physicalBand(iBlueBand)); + physicalKey = Isis::toString(p_cube->physicalBand(iRedBand)); + physicalKey += Isis::toString(p_cube->physicalBand(iGreenBand)); + physicalKey += Isis::toString(p_cube->physicalBand(iBlueBand)); bandGrp += physicalKey; if(iFilterSize) { @@ -1442,8 +1442,8 @@ namespace Isis { bandGrp += PvlKeyword("Color", "Gray"); - bandGrp += PvlKeyword("Virtual", toString(iGrayBand)); - bandGrp += PvlKeyword("Physical", toString(p_cube->physicalBand(iGrayBand))); + bandGrp += PvlKeyword("Virtual", Isis::toString(iGrayBand)); + bandGrp += PvlKeyword("Physical", Isis::toString(p_cube->physicalBand(iGrayBand))); if(iFilterSize && iGrayBand <= iFilterSize) { bandGrp += PvlKeyword("FilterName", filterName[iGrayBand-1]); @@ -1453,10 +1453,10 @@ namespace Isis { //start, end line and sample double sl, ss, es, el; getCubeArea(ss, es, sl, el); - cubeAreaPvl += PvlKeyword("StartSample", toString(int(ss + 0.5))); - cubeAreaPvl += PvlKeyword("EndSample", toString(int(es + 0.5))); - cubeAreaPvl += PvlKeyword("StartLine", toString(int(sl + 0.5))); - cubeAreaPvl += PvlKeyword("EndLine", toString(int(el + 0.5))); + cubeAreaPvl += PvlKeyword("StartSample", Isis::toString(int(ss + 0.5))); + cubeAreaPvl += PvlKeyword("EndSample", Isis::toString(int(es + 0.5))); + cubeAreaPvl += PvlKeyword("StartLine", Isis::toString(int(sl + 0.5))); + cubeAreaPvl += PvlKeyword("EndLine", Isis::toString(int(el + 0.5))); cubeAreaPvl += bandGrp; whatsThisObj += cubeAreaPvl; pWhatsThisPvl += whatsThisObj; diff --git a/isis/src/qisis/objs/Directory/ExportImagesWorkOrder.cpp b/isis/src/qisis/objs/Directory/ExportImagesWorkOrder.cpp index ed078fee06..1927852bba 100644 --- a/isis/src/qisis/objs/Directory/ExportImagesWorkOrder.cpp +++ b/isis/src/qisis/objs/Directory/ExportImagesWorkOrder.cpp @@ -246,7 +246,7 @@ namespace Isis { if (*m_numErrors != 0) { result.append( - IException(IException::Unknown,"Failed to export [" + std::to_string(*m_numErrors) + "] images", + IException(IException::Unknown,"Failed to export [" + Isis::toString(*m_numErrors) + "] images", _FILEINFO_)); } diff --git a/isis/src/qisis/objs/FileTool/FileTool.cpp b/isis/src/qisis/objs/FileTool/FileTool.cpp index 509beb4b5d..b2f0171e08 100644 --- a/isis/src/qisis/objs/FileTool/FileTool.cpp +++ b/isis/src/qisis/objs/FileTool/FileTool.cpp @@ -703,16 +703,16 @@ namespace Isis { int iNumBands = pInCube->bandCount(); PvlGroup results("Results"); - results += PvlKeyword("InputLines", toString(pInCube->lineCount())); - results += PvlKeyword("InputSamples", toString(pInCube->sampleCount())); - results += PvlKeyword("StartingLine", toString(dStartLine)); - results += PvlKeyword("StartingSample", toString(dStartSample)); - results += PvlKeyword("EndingLine", toString(dEndLine)); - results += PvlKeyword("EndingSample", toString(dEndSample)); - results += PvlKeyword("LineIncrement", toString(1)); - results += PvlKeyword("SampleIncrement", toString(1)); - results += PvlKeyword("OutputLines", toString(pNumLines)); - results += PvlKeyword("OutputSamples", toString(pNumSamples)); + results += PvlKeyword("InputLines", Isis::toString(pInCube->lineCount())); + results += PvlKeyword("InputSamples", Isis::toString(pInCube->sampleCount())); + results += PvlKeyword("StartingLine", Isis::toString(dStartLine)); + results += PvlKeyword("StartingSample", Isis::toString(dStartSample)); + results += PvlKeyword("EndingLine", Isis::toString(dEndLine)); + results += PvlKeyword("EndingSample", Isis::toString(dEndSample)); + results += PvlKeyword("LineIncrement", Isis::toString(1)); + results += PvlKeyword("SampleIncrement", Isis::toString(1)); + results += PvlKeyword("OutputLines", Isis::toString(pNumLines)); + results += PvlKeyword("OutputSamples", Isis::toString(pNumSamples)); SubArea subArea; subArea.SetSubArea(pInCube->lineCount(), pInCube->sampleCount(), dStartLine, dStartSample, dEndLine, dEndSample, 1.0, 1.0); diff --git a/isis/src/qisis/objs/ImageFileListWidget/ImageFileListWidget.cpp b/isis/src/qisis/objs/ImageFileListWidget/ImageFileListWidget.cpp index 45782a9862..0e1d4c1d4a 100644 --- a/isis/src/qisis/objs/ImageFileListWidget/ImageFileListWidget.cpp +++ b/isis/src/qisis/objs/ImageFileListWidget/ImageFileListWidget.cpp @@ -189,11 +189,11 @@ namespace Isis { key = key.Convert(" ", '_'); bool visible = !m_tree->isColumnHidden(col); - output += PvlKeyword(key, toString((int)visible)); + output += PvlKeyword(key, Isis::toString((int)visible)); col = (ImageTreeWidgetItem::TreeColumn)(col + 1); } - output += PvlKeyword("SortColumn", toString(m_tree->sortColumn())); + output += PvlKeyword("SortColumn", Isis::toString(m_tree->sortColumn())); // Now store groups and the cubes that are in those groups for (int i = 0; i < m_tree->topLevelItemCount(); i++) { @@ -633,7 +633,7 @@ namespace Isis { // stream.writeEndElement(); // // stream.writeStartElement("position"); -// //qDebug()<<"ImageFileListWidget::save Position = "<text().toStdString()); obj += PvlKeyword("Longitude", m_lonLineEdit->text().toStdString()); obj += PvlKeyword("Area", m_areaLineEdit->text().toStdString()); - obj += PvlKeyword("Visible", toString((int)(m_box != NULL))); + obj += PvlKeyword("Visible", Isis::toString((int)(m_box != NULL))); } return obj; diff --git a/isis/src/qisis/objs/MosaicSceneWidget/MosaicControlNetTool.cpp b/isis/src/qisis/objs/MosaicSceneWidget/MosaicControlNetTool.cpp index c271dedf00..2cd658d540 100644 --- a/isis/src/qisis/objs/MosaicSceneWidget/MosaicControlNetTool.cpp +++ b/isis/src/qisis/objs/MosaicSceneWidget/MosaicControlNetTool.cpp @@ -164,16 +164,16 @@ namespace Isis { obj += PvlKeyword("FileName", m_controlNetFile.toStdString()); obj += PvlKeyword("Visible", - std::to_string((int)(m_controlNetGraphics && m_controlNetGraphics->isVisible()))); - obj += PvlKeyword("Movement", std::to_string(m_movementArrowColorSource)); + Isis::toString((int)(m_controlNetGraphics && m_controlNetGraphics->isVisible()))); + obj += PvlKeyword("Movement", Isis::toString(m_movementArrowColorSource)); if (maxMovementColorMeasureCount() != -1) { - obj += PvlKeyword("MovementColorMaxMeasureCount", std::to_string(m_measureCount)); + obj += PvlKeyword("MovementColorMaxMeasureCount", Isis::toString(m_measureCount)); } if (maxMovementColorResidualMagnitude() != Null) { obj += PvlKeyword("MovementColorMaxResidualMagnitude", - std::to_string(m_residualMagnitude)); + Isis::toString(m_residualMagnitude)); } return obj; @@ -190,11 +190,11 @@ namespace Isis { } if (obj.hasKeyword("MovementColorMaxMeasureCount")) { - m_measureCount = IString::ToInteger(obj["MovementColorMaxMeasureCount"][0]); + m_measureCount = Isis::toInt(obj["MovementColorMaxMeasureCount"][0]); } if (obj.hasKeyword("MovementColorMaxResidualMagnitude")) { - m_residualMagnitude = IString::ToDouble(obj["MovementColorMaxResidualMagnitude"][0]); + m_residualMagnitude = Isis::toDouble(obj["MovementColorMaxResidualMagnitude"][0]); } loadNetwork(); diff --git a/isis/src/qisis/objs/MosaicSceneWidget/MosaicFindTool.cpp b/isis/src/qisis/objs/MosaicSceneWidget/MosaicFindTool.cpp index d8bf3f84a8..7f7d17087b 100644 --- a/isis/src/qisis/objs/MosaicSceneWidget/MosaicFindTool.cpp +++ b/isis/src/qisis/objs/MosaicSceneWidget/MosaicFindTool.cpp @@ -172,7 +172,7 @@ namespace Isis { obj += PvlKeyword("Latitude", p_latLineEdit->text().toStdString()); obj += PvlKeyword("Longitude", p_lonLineEdit->text().toStdString()); - obj += PvlKeyword("Visible", toString((int)(p_findSpot != NULL))); + obj += PvlKeyword("Visible", Isis::toString((int)(p_findSpot != NULL))); return obj; } diff --git a/isis/src/qisis/objs/MosaicSceneWidget/MosaicGridTool.cpp b/isis/src/qisis/objs/MosaicSceneWidget/MosaicGridTool.cpp index 75648c2512..b8ff4d2867 100644 --- a/isis/src/qisis/objs/MosaicSceneWidget/MosaicGridTool.cpp +++ b/isis/src/qisis/objs/MosaicSceneWidget/MosaicGridTool.cpp @@ -568,52 +568,52 @@ namespace Isis { tproj->PolarRadius(), Distance::Meters); if (obj["BaseLatitude"][0] != "Null") - m_baseLat = Latitude(IString::ToDouble(obj["BaseLatitude"][0]), equatorialRadius, polarRadius, + m_baseLat = Latitude(Isis::toDouble(obj["BaseLatitude"][0]), equatorialRadius, polarRadius, Latitude::Planetocentric, Angle::Degrees); if (obj["BaseLongitude"][0] != "Null") - m_baseLon = Longitude(IString::ToDouble(obj["BaseLongitude"][0]), Angle::Degrees); + m_baseLon = Longitude(Isis::toDouble(obj["BaseLongitude"][0]), Angle::Degrees); if (obj["LatitudeIncrement"][0] != "Null") - m_latInc = Angle(IString::ToDouble(obj["LatitudeIncrement"][0]), Angle::Degrees); + m_latInc = Angle(Isis::toDouble(obj["LatitudeIncrement"][0]), Angle::Degrees); if (obj["LongitudeIncrement"][0] != "Null") - m_lonInc = Angle(IString::ToDouble(obj["LongitudeIncrement"][0]), Angle::Degrees); + m_lonInc = Angle(Isis::toDouble(obj["LongitudeIncrement"][0]), Angle::Degrees); if (obj.hasKeyword("LatitudeExtentType")) { if (obj["LatitudeExtentType"][0] != "Null") - m_latExtents = (GridExtentSource)IString::ToInteger(obj["LatitudeExtentType"][0]); + m_latExtents = (GridExtentSource)Isis::toInt(obj["LatitudeExtentType"][0]); } if (obj.hasKeyword("MinimumLatitude")) { if (obj["MinimumLatitude"][0] != "Null") - m_minLat = Latitude(IString::ToDouble(obj["MinimumLatitude"][0]), equatorialRadius, polarRadius, + m_minLat = Latitude(Isis::toDouble(obj["MinimumLatitude"][0]), equatorialRadius, polarRadius, Latitude::Planetocentric, Angle::Degrees); } if (obj.hasKeyword("MaximumLatitude")) { if (obj["MaximumLatitude"][0] != "Null") - m_maxLat = Latitude(IString::ToDouble(obj["MaximumLatitude"][0]), equatorialRadius, polarRadius, + m_maxLat = Latitude(Isis::toDouble(obj["MaximumLatitude"][0]), equatorialRadius, polarRadius, Latitude::Planetocentric, Angle::Degrees); } if (obj.hasKeyword("LongitudeExtentType")) { if (obj["LongitudeExtentType"][0] != "Null") - m_lonExtents = (GridExtentSource)IString::ToInteger(obj["LongitudeExtentType"][0]); + m_lonExtents = (GridExtentSource)Isis::toInt(obj["LongitudeExtentType"][0]); } if (obj.hasKeyword("MinimumLongitude")) { if (obj["MinimumLongitude"][0] != "Null") - m_minLon = Longitude(IString::ToDouble(obj["MinimumLongitude"][0]), Angle::Degrees); + m_minLon = Longitude(Isis::toDouble(obj["MinimumLongitude"][0]), Angle::Degrees); } if (obj.hasKeyword("MaximumLongitude")) { if (obj["MaximumLongitude"][0] != "Null") - m_maxLon = Longitude(IString::ToDouble(obj["MaximumLongitude"][0]), Angle::Degrees); + m_maxLon = Longitude(Isis::toDouble(obj["MaximumLongitude"][0]), Angle::Degrees); } if (obj["Density"][0] != "Null") - m_density = IString::ToDouble(obj["Density"][0]); + m_density = Isis::toDouble(obj["Density"][0]); if (obj.hasKeyword("CheckTheBoxes")) { @@ -647,24 +647,24 @@ namespace Isis { PvlObject MosaicGridTool::toPvl() const { PvlObject obj(projectPvlObjectName().toStdString()); - obj += PvlKeyword("ShouldCheckBoxes", toString((int)m_shouldCheckBoxes)); + obj += PvlKeyword("ShouldCheckBoxes", Isis::toString((int)m_shouldCheckBoxes)); - obj += PvlKeyword("BaseLatitude", toString(m_baseLat.degrees())); - obj += PvlKeyword("BaseLongitude", toString(m_baseLon.degrees())); + obj += PvlKeyword("BaseLatitude", Isis::toString(m_baseLat.degrees())); + obj += PvlKeyword("BaseLongitude", Isis::toString(m_baseLon.degrees())); - obj += PvlKeyword("LatitudeIncrement", toString(m_latInc.degrees())); - obj += PvlKeyword("LongitudeIncrement", toString(m_lonInc.degrees())); + obj += PvlKeyword("LatitudeIncrement", Isis::toString(m_latInc.degrees())); + obj += PvlKeyword("LongitudeIncrement", Isis::toString(m_lonInc.degrees())); - obj += PvlKeyword("LatitudeExtentType", toString(m_latExtents)); - obj += PvlKeyword("MaximumLatitude", toString(m_maxLat.degrees())); - obj += PvlKeyword("MinimumLongitude", toString(m_minLon.degrees())); + obj += PvlKeyword("LatitudeExtentType", Isis::toString(m_latExtents)); + obj += PvlKeyword("MaximumLatitude", Isis::toString(m_maxLat.degrees())); + obj += PvlKeyword("MinimumLongitude", Isis::toString(m_minLon.degrees())); - obj += PvlKeyword("LongitudeExtentType", toString(m_lonExtents)); - obj += PvlKeyword("MinimumLatitude", toString(m_minLat.degrees())); - obj += PvlKeyword("MaximumLongitude", toString(m_maxLon.degrees())); + obj += PvlKeyword("LongitudeExtentType", Isis::toString(m_lonExtents)); + obj += PvlKeyword("MinimumLatitude", Isis::toString(m_minLat.degrees())); + obj += PvlKeyword("MaximumLongitude", Isis::toString(m_maxLon.degrees())); - obj += PvlKeyword("Density", toString(m_density)); - obj += PvlKeyword("Visible", toString((int)(m_gridItem != NULL))); + obj += PvlKeyword("Density", Isis::toString(m_density)); + obj += PvlKeyword("Visible", Isis::toString((int)(m_gridItem != NULL))); return obj; } diff --git a/isis/src/qisis/objs/MosaicSceneWidget/MosaicSceneWidget.cpp b/isis/src/qisis/objs/MosaicSceneWidget/MosaicSceneWidget.cpp index 7b5ba8ddd9..e3b38411c3 100644 --- a/isis/src/qisis/objs/MosaicSceneWidget/MosaicSceneWidget.cpp +++ b/isis/src/qisis/objs/MosaicSceneWidget/MosaicSceneWidget.cpp @@ -357,9 +357,9 @@ namespace Isis { cam->radii(radii); mappingGrp += PvlKeyword("TargetName", cam->target()->name().toStdString()); - mappingGrp += PvlKeyword("EquatorialRadius", toString(radii[0].meters()), + mappingGrp += PvlKeyword("EquatorialRadius", Isis::toString(radii[0].meters()), "meters"); - mappingGrp += PvlKeyword("PolarRadius", toString(radii[2].meters()), + mappingGrp += PvlKeyword("PolarRadius", Isis::toString(radii[2].meters()), "meters"); } @@ -535,8 +535,8 @@ namespace Isis { mosaicScenePosition += PvlKeyword("ViewTransform", std::string(dataBuffer.data().toHex())); PvlKeyword scrollPos("ScrollPosition"); - scrollPos += toString(getView()->horizontalScrollBar()->value()); - scrollPos += toString(getView()->verticalScrollBar()->value()); + scrollPos += Isis::toString(getView()->horizontalScrollBar()->value()); + scrollPos += Isis::toString(getView()->verticalScrollBar()->value()); mosaicScenePosition += scrollPos; output += mosaicScenePosition; @@ -554,7 +554,7 @@ namespace Isis { foreach(MosaicSceneItem * mosaicSceneItem, *m_mosaicSceneItems) { PvlKeyword zValue("ZValue"); zValue += mosaicSceneItem->image()->id().toStdString(); - zValue += toString(mosaicSceneItem->zValue()); + zValue += Isis::toString(mosaicSceneItem->zValue()); zOrders += zValue; } @@ -601,7 +601,7 @@ namespace Isis { zOrderIndex ++) { const PvlKeyword &zOrder = zOrders[zOrderIndex]; - (*m_projectImageZOrders)[QString::fromStdString(zOrder[0])] = IString::ToDouble(zOrder[1]); + (*m_projectImageZOrders)[QString::fromStdString(zOrder[0])] = Isis::toDouble(zOrder[1]); } } @@ -1377,8 +1377,8 @@ namespace Isis { transformStream >> viewTransform; getView()->setTransform(viewTransform); - QPoint projectScrollPos(IString::ToInteger(positionInfo["ScrollPosition"][0]), - IString::ToInteger(positionInfo["ScrollPosition"][1])); + QPoint projectScrollPos(Isis::toInt(positionInfo["ScrollPosition"][0]), + Isis::toInt(positionInfo["ScrollPosition"][1])); getView()->horizontalScrollBar()->setValue(projectScrollPos.x()); getView()->verticalScrollBar()->setValue(projectScrollPos.y()); diff --git a/isis/src/qisis/objs/ScatterPlotTool/ScatterPlotData.cpp b/isis/src/qisis/objs/ScatterPlotTool/ScatterPlotData.cpp index 46c2378e6d..b67b582b31 100644 --- a/isis/src/qisis/objs/ScatterPlotTool/ScatterPlotData.cpp +++ b/isis/src/qisis/objs/ScatterPlotTool/ScatterPlotData.cpp @@ -253,8 +253,8 @@ namespace Isis { } - std::string msg = "Bin at index [" + toString(index) + "] not found. " - "There are [" + toString(numberOfBins()) + "] bins"; + std::string msg = "Bin at index [" + Isis::toString(index) + "] not found. " + "There are [" + Isis::toString(numberOfBins()) + "] bins"; throw IException(IException::Programmer, msg, _FILEINFO_); } @@ -447,8 +447,8 @@ namespace Isis { int xIndex = binIndex; if (xIndex < 0 || yIndex < 0 || xIndex >= xSize || yIndex >= ySize) { - std::string msg = "Bin at index [" + toString(binIndex) + "] not found. " - "There are [" + toString(numberOfBins()) + "] bins"; + std::string msg = "Bin at index [" + Isis::toString(binIndex) + "] not found. " + "There are [" + Isis::toString(numberOfBins()) + "] bins"; throw IException(IException::Programmer, msg, _FILEINFO_); } diff --git a/isis/src/qisis/objs/Shape/Shape.cpp b/isis/src/qisis/objs/Shape/Shape.cpp index 118a0fddaf..15f9ec80ad 100644 --- a/isis/src/qisis/objs/Shape/Shape.cpp +++ b/isis/src/qisis/objs/Shape/Shape.cpp @@ -748,27 +748,27 @@ namespace Isis { m_projectionName = QString::fromStdString(obj.findGroup("Mapping")["ProjectionName"][0]); if (mapGroup.hasKeyword("CenterLongitude")) - m_centerLongitude = Longitude(IString::ToDouble(obj.findGroup("Mapping")["CenterLongitude"][0]), + m_centerLongitude = Longitude(Isis::toDouble(obj.findGroup("Mapping")["CenterLongitude"][0]), mapGroup, Angle::Degrees); if (mapGroup.hasKeyword("CenterLatitude")) - m_centerLatitude = Latitude(IString::ToDouble(obj.findGroup("Mapping")["CenterLatitude"][0]), + m_centerLatitude = Latitude(Isis::toDouble(obj.findGroup("Mapping")["CenterLatitude"][0]), mapGroup, Angle::Degrees); if (mapGroup.hasKeyword("MinimumLatitude")) - m_minimumLatitude = Latitude(IString::ToDouble(obj.findGroup("Mapping")["MinimumLatitude"][0]), + m_minimumLatitude = Latitude(Isis::toDouble(obj.findGroup("Mapping")["MinimumLatitude"][0]), mapGroup, Angle::Degrees); if (mapGroup.hasKeyword("MaximumLatitude")) - m_maximumLatitude = Latitude(IString::ToDouble(obj.findGroup("Mapping")["MaximumLatitude"][0]), + m_maximumLatitude = Latitude(Isis::toDouble(obj.findGroup("Mapping")["MaximumLatitude"][0]), mapGroup, Angle::Degrees); if (mapGroup.hasKeyword("MinimumLongitude")) - m_minimumLongitude = Longitude(IString::ToDouble(obj.findGroup("Mapping")["MinimumLongitude"][0]), + m_minimumLongitude = Longitude(Isis::toDouble(obj.findGroup("Mapping")["MinimumLongitude"][0]), mapGroup, Angle::Degrees); if (mapGroup.hasKeyword("MaximumLongitude")) - m_maximumLongitude = Longitude(IString::ToDouble(obj.findGroup("Mapping")["MaximumLongitude"][0]), + m_maximumLongitude = Longitude(Isis::toDouble(obj.findGroup("Mapping")["MaximumLongitude"][0]), mapGroup, Angle::Degrees); if (mapGroup.hasKeyword("PixelResolution")) diff --git a/isis/src/qisis/objs/SpectralPlotTool/SpectralPlotTool.cpp b/isis/src/qisis/objs/SpectralPlotTool/SpectralPlotTool.cpp index aeec415e83..4f2752ba5a 100644 --- a/isis/src/qisis/objs/SpectralPlotTool/SpectralPlotTool.cpp +++ b/isis/src/qisis/objs/SpectralPlotTool/SpectralPlotTool.cpp @@ -669,7 +669,7 @@ namespace Isis { if (bandBin.hasKeyword("Center")) { PvlKeyword &wavelength = bandBin.findKeyword("Center"); if (wavelength.size() > (band - 1)) { - labels.push_back(IString::ToDouble(wavelength[band-1])); + labels.push_back(Isis::toDouble(wavelength[band-1])); } } } diff --git a/isis/src/qisis/objs/SpectralPlotTool/SpectralPlotWindow.cpp b/isis/src/qisis/objs/SpectralPlotTool/SpectralPlotWindow.cpp index 657d6a318b..9fe3242812 100644 --- a/isis/src/qisis/objs/SpectralPlotTool/SpectralPlotWindow.cpp +++ b/isis/src/qisis/objs/SpectralPlotTool/SpectralPlotWindow.cpp @@ -121,7 +121,7 @@ namespace Isis { /*This is were we need to set the x value to the band number.*/ if (grayBand > 0) { if (xAxisUnits() == PlotCurve::Wavelength) { - m_grayBandLine->setXValue(IString::ToDouble(wavelengths[grayBand-1])); + m_grayBandLine->setXValue(Isis::toDouble(wavelengths[grayBand-1])); } else { m_grayBandLine->setXValue(grayBand); @@ -136,7 +136,7 @@ namespace Isis { if (redBand > 0) { if (xAxisUnits() == PlotCurve::Wavelength) { - m_redBandLine->setXValue(IString::ToDouble(wavelengths[redBand-1])); + m_redBandLine->setXValue(Isis::toDouble(wavelengths[redBand-1])); } else { m_redBandLine->setXValue(redBand); @@ -150,7 +150,7 @@ namespace Isis { } if (greenBand > 0) { if (xAxisUnits() == PlotCurve::Wavelength) { - m_greenBandLine->setXValue(IString::ToDouble(wavelengths[greenBand-1])); + m_greenBandLine->setXValue(Isis::toDouble(wavelengths[greenBand-1])); } else { m_greenBandLine->setXValue(greenBand); @@ -165,7 +165,7 @@ namespace Isis { if (blueBand > 0) { if (xAxisUnits() == PlotCurve::Wavelength) { - m_blueBandLine->setXValue(IString::ToDouble(wavelengths[blueBand-1])); + m_blueBandLine->setXValue(Isis::toDouble(wavelengths[blueBand-1])); } else { m_blueBandLine->setXValue(blueBand); diff --git a/isis/src/qisis/objs/StretchTool/StretchTool.cpp b/isis/src/qisis/objs/StretchTool/StretchTool.cpp index c944627a6c..2c9f7cdaec 100644 --- a/isis/src/qisis/objs/StretchTool/StretchTool.cpp +++ b/isis/src/qisis/objs/StretchTool/StretchTool.cpp @@ -511,13 +511,13 @@ namespace Isis { } else { std::vector keywordValueRed; - keywordValueRed.push_back(PvlKeyword("BandNumber", toString(cvp->redBand()))); + keywordValueRed.push_back(PvlKeyword("BandNumber", Isis::toString(cvp->redBand()))); std::vector keywordValueGreen; - keywordValueGreen.push_back(PvlKeyword("BandNumber", toString(cvp->greenBand()))); + keywordValueGreen.push_back(PvlKeyword("BandNumber", Isis::toString(cvp->greenBand()))); std::vector keywordValueBlue; - keywordValueBlue.push_back(PvlKeyword("BandNumber", toString(cvp->blueBand()))); + keywordValueBlue.push_back(PvlKeyword("BandNumber", Isis::toString(cvp->blueBand()))); CubeStretch redStretch = icube->readCubeStretch(stretchName, keywordValueRed); CubeStretch greenStretch = icube->readCubeStretch(stretchName, keywordValueGreen); diff --git a/isis/src/rosetta/apps/rososiris2isis/main.cpp b/isis/src/rosetta/apps/rososiris2isis/main.cpp index 5b8757ee3f..da70042f49 100644 --- a/isis/src/rosetta/apps/rososiris2isis/main.cpp +++ b/isis/src/rosetta/apps/rososiris2isis/main.cpp @@ -138,21 +138,21 @@ void IsisMain() { throw IException(e, IException::Io, msg, _FILEINFO_); } } - // bandBin += PvlKeyword("FilterId", toString(filterId)); + // bandBin += PvlKeyword("FilterId", Isis::toString(filterId)); bbGrp.addKeyword(PvlKeyword("FilterOneName", filterNames[0].toStdString())); - bbGrp.addKeyword(PvlKeyword("FilterOneCenter", toString(filterCenters[0]), "nanometers")); - bbGrp.addKeyword(PvlKeyword("FilterOneWidth", toString(filterWidths[0]), "nanometers")); + bbGrp.addKeyword(PvlKeyword("FilterOneCenter", Isis::toString(filterCenters[0]), "nanometers")); + bbGrp.addKeyword(PvlKeyword("FilterOneWidth", Isis::toString(filterWidths[0]), "nanometers")); bbGrp.addKeyword(PvlKeyword("FilterTwoName", filterNames[1].toStdString())); - bbGrp.addKeyword(PvlKeyword("FilterTwoCenter", toString(filterCenters[1]), "nanometers")); - bbGrp.addKeyword(PvlKeyword("FilterTwoWidth", toString(filterWidths[1]), "nanometers")); + bbGrp.addKeyword(PvlKeyword("FilterTwoCenter", Isis::toString(filterCenters[1]), "nanometers")); + bbGrp.addKeyword(PvlKeyword("FilterTwoWidth", Isis::toString(filterWidths[1]), "nanometers")); outcube->putGroup(bbGrp); PvlGroup kerns("Kernels"); if (instId.compare("OSINAC", Qt::CaseInsensitive) == 0) { - kerns += PvlKeyword("NaifFrameCode", toString(-226111)); //should I add [-filtno] directly after the number? That's what Dawn did + kerns += PvlKeyword("NaifFrameCode", Isis::toString(-226111)); //should I add [-filtno] directly after the number? That's what Dawn did } else if (instId.compare("OSIWAC", Qt::CaseInsensitive) == 0) { - kerns += PvlKeyword("NaifFrameCode", toString(-226112)); //should I add [-filtno] directly after the number? That's what Dawn did + kerns += PvlKeyword("NaifFrameCode", Isis::toString(-226112)); //should I add [-filtno] directly after the number? That's what Dawn did } else { std::string msg = "Input file [" + inFile.expanded() + "] has an invalid " + diff --git a/isis/src/rosetta/apps/rosvirtis2isis/main.cpp b/isis/src/rosetta/apps/rosvirtis2isis/main.cpp index 26c062aafb..aa06b1575e 100644 --- a/isis/src/rosetta/apps/rosvirtis2isis/main.cpp +++ b/isis/src/rosetta/apps/rosvirtis2isis/main.cpp @@ -420,7 +420,7 @@ void IsisMain () scs2e_c( (SpiceInt) -226, stopScet.toLatin1().data(), &etEnd); PvlKeyword &frameParam = inst["FrameParameter"]; - double exposureTime = IString::ToDouble(frameParam[0]); + double exposureTime = Isis::toDouble(frameParam[0]); QString startTime = iTime(etStart-exposureTime).UTC(); QString stopTime = iTime(etEnd-exposureTime).UTC(); @@ -451,13 +451,13 @@ void IsisMain () // VIRTIS_H is also supported. PvlGroup kerns("Kernels"); if (channelid == "VIRTIS_M_IR") { - kerns += PvlKeyword("NaifFrameCode", toString(-226213)); + kerns += PvlKeyword("NaifFrameCode", Isis::toString(-226213)); } else if (channelid == "VIRTIS_M_VIS") { - kerns += PvlKeyword("NaifFrameCode", toString(-226211)); + kerns += PvlKeyword("NaifFrameCode", Isis::toString(-226211)); } else if (channelid == "VIRTIS_H") { - kerns += PvlKeyword("NaifFrameCode", toString(-226220)); + kerns += PvlKeyword("NaifFrameCode", Isis::toString(-226220)); } else { std::string msg = "Input file [" + inFile.expanded() + "] has an invalid " + @@ -471,7 +471,7 @@ void IsisMain () const PvlKeyword &frameKey = outcube->group("Instrument").findKeyword("FrameParameter"); // The third frame key is always the number of scans in between dark current scans. // So, we need to add one to that in order to get the number of lines to next dark current. - int darkRate = IString::ToInteger(frameKey[3]) + 1; + int darkRate = Isis::toInt(frameKey[3]) + 1; LineManager darkLineManager(*outcube); for (int band = 1; band <= outcube->bandCount(); band++) { diff --git a/isis/src/rosetta/objs/RosettaVirtisCamera/RosettaVirtisCamera.cpp b/isis/src/rosetta/objs/RosettaVirtisCamera/RosettaVirtisCamera.cpp index 2d3401c9ac..26cc4c377c 100644 --- a/isis/src/rosetta/objs/RosettaVirtisCamera/RosettaVirtisCamera.cpp +++ b/isis/src/rosetta/objs/RosettaVirtisCamera/RosettaVirtisCamera.cpp @@ -104,9 +104,9 @@ namespace Isis { // convert milliseconds to seconds - m_exposureTime = IString::ToDouble(frameParam[0]) * 0.001; - m_summing = IString::ToDouble(frameParam[1]); - m_scanRate = IString::ToDouble(frameParam[2]); + m_exposureTime = Isis::toDouble(frameParam[0]) * 0.001; + m_summing = Isis::toDouble(frameParam[1]); + m_scanRate = Isis::toDouble(frameParam[2]); // Setup detector map // Get the line scan rates/times @@ -527,21 +527,21 @@ namespace Isis { } // Add some necessary keywords - quats.Label() += PvlKeyword("CkTableStartTime", toString(startTime())); - quats.Label() += PvlKeyword("CkTableEndTime", toString(endTime())); - quats.Label() += PvlKeyword("CkTableOriginalSize", toString(quats.Records())); + quats.Label() += PvlKeyword("CkTableStartTime", Isis::toString(startTime())); + quats.Label() += PvlKeyword("CkTableEndTime", Isis::toString(endTime())); + quats.Label() += PvlKeyword("CkTableOriginalSize", Isis::toString(quats.Records())); // Create the time dependant frames keyword int virZeroId = getInteger("FRAME_" + virZero); - PvlKeyword tdf("TimeDependentFrames", toString(virZeroId)); // ROS_VIRTIS_M_{ID}_ZERO + PvlKeyword tdf("TimeDependentFrames", Isis::toString(virZeroId)); // ROS_VIRTIS_M_{ID}_ZERO tdf.addValue("-226200"); // ROS_VIRTIS tdf.addValue("-226000"); // ROSETTA_SPACECRAFT tdf.addValue("1"); // J2000 quats.Label() += tdf; // Create constant rotation frames - PvlKeyword cf("ConstantFrames", toString(virZeroId)); - cf.addValue(toString(virZeroId)); + PvlKeyword cf("ConstantFrames", Isis::toString(virZeroId)); + cf.addValue(Isis::toString(virZeroId)); quats.Label() += cf; SpiceDouble identity[3][3]; @@ -551,7 +551,7 @@ namespace Isis { PvlKeyword crot("ConstantRotation"); for (int i = 0 ; i < 3 ; i++) { for (int j = 0 ; j < 3 ; j++) { - crot.addValue(toString(identity[i][j])); + crot.addValue(Isis::toString(identity[i][j])); } } diff --git a/isis/src/socet/apps/socetlinescankeywords/socetlinescankeywords.cpp b/isis/src/socet/apps/socetlinescankeywords/socetlinescankeywords.cpp index 55c340b2e0..37dad4997a 100644 --- a/isis/src/socet/apps/socetlinescankeywords/socetlinescankeywords.cpp +++ b/isis/src/socet/apps/socetlinescankeywords/socetlinescankeywords.cpp @@ -700,8 +700,8 @@ void socetlinescankeywords(Cube *input, UserInterface &ui) { Distance targetRadii[3]; if (input->label()->hasGroup("Mapping")) { PvlGroup &mappingGroup = input->label()->findGroup("Mapping"); - targetRadii[0].setMeters(IString::ToDouble(mappingGroup["EquatorialRadius"][0])); - targetRadii[2].setMeters(IString::ToDouble(mappingGroup["PolarRadius"][0])); + targetRadii[0].setMeters(Isis::toDouble(mappingGroup["EquatorialRadius"][0])); + targetRadii[2].setMeters(Isis::toDouble(mappingGroup["PolarRadius"][0])); } else { try { diff --git a/isis/src/system/apps/isisdataeval/isisdataeval.cpp b/isis/src/system/apps/isisdataeval/isisdataeval.cpp index 3a6c26a0e0..9dd14e61df 100644 --- a/isis/src/system/apps/isisdataeval/isisdataeval.cpp +++ b/isis/src/system/apps/isisdataeval/isisdataeval.cpp @@ -182,17 +182,17 @@ namespace Isis { PvlGroup results("Results"); results.addKeyword( PvlKeyword( "ISISDATA", isisdata.expanded() ) ); results.addKeyword( PvlKeyword( "DATADIR", datadir.toStdString() ) ); - results.addKeyword( PvlKeyword( "EmptyKernelDBs", toString( inventory_counts.m_empty ) ) ); - results.addKeyword( PvlKeyword( "MissingKernelDBs", toString( inventory_counts.m_missing ) ) ); - results.addKeyword( PvlKeyword( "SymlinkKernelFiles", toString( inventory_counts.m_symlinks ) ) ); - results.addKeyword( PvlKeyword( "ExternalKernelFiles", toString( inventory_counts.m_externals ) ) ); - results.addKeyword( PvlKeyword( "ErrorKernelFiles", toString( inventory_counts.m_errors ) ) ); - results.addKeyword( PvlKeyword( "TotalDBConfigFiles", toString( t_configs ), "conf" ) ); - results.addKeyword( PvlKeyword( "TotalKernelDBFiles", toString( t_kerneldbs ), "db" ) ); - results.addKeyword( PvlKeyword( "TotalDirectories", toString( t_dirs ) ) ); - results.addKeyword( PvlKeyword( "TotalDataFiles", toString( t_files ) ) ); - results.addKeyword( PvlKeyword( "TotalInstallSize", toString( t_install_size ), "bytes" ) ); - results.addKeyword( PvlKeyword( "TotalVolumeSize", toString( t_volume_size ), "GB" ) ); + results.addKeyword( PvlKeyword( "EmptyKernelDBs", Isis::toString( inventory_counts.m_empty ) ) ); + results.addKeyword( PvlKeyword( "MissingKernelDBs", Isis::toString( inventory_counts.m_missing ) ) ); + results.addKeyword( PvlKeyword( "SymlinkKernelFiles", Isis::toString( inventory_counts.m_symlinks ) ) ); + results.addKeyword( PvlKeyword( "ExternalKernelFiles", Isis::toString( inventory_counts.m_externals ) ) ); + results.addKeyword( PvlKeyword( "ErrorKernelFiles", Isis::toString( inventory_counts.m_errors ) ) ); + results.addKeyword( PvlKeyword( "TotalDBConfigFiles", Isis::toString( t_configs ), "conf" ) ); + results.addKeyword( PvlKeyword( "TotalKernelDBFiles", Isis::toString( t_kerneldbs ), "db" ) ); + results.addKeyword( PvlKeyword( "TotalDirectories", Isis::toString( t_dirs ) ) ); + results.addKeyword( PvlKeyword( "TotalDataFiles", Isis::toString( t_files ) ) ); + results.addKeyword( PvlKeyword( "TotalInstallSize", Isis::toString( t_install_size ), "bytes" ) ); + results.addKeyword( PvlKeyword( "TotalVolumeSize", Isis::toString( t_volume_size ), "GB" ) ); // If users wants kernel issues reported, write it out here if ( ui.WasEntered( "TOISSUES" ) ) { @@ -392,17 +392,17 @@ namespace Isis { } // Report results - results.addKeyword( PvlKeyword( "MissingInInventory", toString( error_counts_t.m_missing ) ) ); - results.addKeyword( PvlKeyword( "SymlinkInInventory", toString( error_counts_t.m_symlinks ) ) ); - results.addKeyword( PvlKeyword( "ExternalToInventory", toString( error_counts_t.m_externals ) ) ); - results.addKeyword( PvlKeyword( "ErrorInInventory", toString( error_counts_t.m_errors ) ) ); + results.addKeyword( PvlKeyword( "MissingInInventory", Isis::toString( error_counts_t.m_missing ) ) ); + results.addKeyword( PvlKeyword( "SymlinkInInventory", Isis::toString( error_counts_t.m_symlinks ) ) ); + results.addKeyword( PvlKeyword( "ExternalToInventory", Isis::toString( error_counts_t.m_externals ) ) ); + results.addKeyword( PvlKeyword( "ErrorInInventory", Isis::toString( error_counts_t.m_errors ) ) ); if ( needHash ) { QByteArray v_hash_data = volume_hash.result(); QString volume_hash_str = QString::fromUtf8( v_hash_data.toHex() ); BigInt hbsize = HashBufferSizeBytes; - results.addKeyword( PvlKeyword( "HashBufferSize", toString(hbsize), "bytes" ) ); + results.addKeyword( PvlKeyword( "HashBufferSize", Isis::toString(hbsize), "bytes" ) ); results.addKeyword( PvlKeyword( "TotalVolumeHash", volume_hash_str.toStdString(), hashtype.toStdString() ) ); } diff --git a/isis/src/system/apps/kerneldbgen/kerneldbgen.cpp b/isis/src/system/apps/kerneldbgen/kerneldbgen.cpp index 6199bea42b..135eadbd44 100644 --- a/isis/src/system/apps/kerneldbgen/kerneldbgen.cpp +++ b/isis/src/system/apps/kerneldbgen/kerneldbgen.cpp @@ -234,7 +234,7 @@ namespace Isis { throw IException(IException::Unknown, "Expected the keyword File in ["+ kernelFileName.original() +"] to have two " "values, a mission data directory and a path into " - "that directory. The keyword has ["+ toString(key.size()) +"] values.", + "that directory. The keyword has ["+ Isis::toString(key.size()) +"] values.", _FILEINFO_); } } @@ -247,9 +247,9 @@ namespace Isis { } } else { - throw IException(IException::Unknown, "Expected Pvl Group [" + primaryGroup.name() + "] in the first Pvl Object [" + primaryObject.name() + "] " - "in the DB file [" + kernelFileName.original() + "] to have a single keyword (named " - "File), but found [" + toString(primaryGroup.keywords()) + "] keywords", + throw IException(IException::Unknown, "Expected Pvl Group " + primaryGroup.name() + " in the first Pvl Object " + primaryObject.name() + " " + "in the DB file " + kernelFileName.original() + " to have a single keyword (named " + "File), but found " + Isis::toString(primaryGroup.keywords()) + " keywords", _FILEINFO_); } } @@ -260,14 +260,14 @@ namespace Isis { } } else { - throw IException(IException::Unknown,"Expected one Pvl Group in the first Pvl Object [" + primaryObject.name() + "] in " - "the DB file [" + kernelFileName.original() + "] but found [" + toString(primaryObject.groups()) + "]", _FILEINFO_); + throw IException(IException::Unknown,"Expected one Pvl Group in the first Pvl Object " + primaryObject.name() + " in " + "the DB file " + kernelFileName.original() + " but found " + Isis::toString(primaryObject.groups()), _FILEINFO_); } } else { throw IException(IException::Unknown, "Expected one Pvl Object in the DB file ["+kernelFileName.original()+"] but " - "found ["+ toString(kernelDbPvl.objects()) +"]", + "found ["+ Isis::toString(kernelDbPvl.objects()) +"]", _FILEINFO_); } } diff --git a/isis/src/system/apps/prtloganalyzer/ProgramAnalyzer.cpp b/isis/src/system/apps/prtloganalyzer/ProgramAnalyzer.cpp index 895cba0ef4..14d49a2f7b 100644 --- a/isis/src/system/apps/prtloganalyzer/ProgramAnalyzer.cpp +++ b/isis/src/system/apps/prtloganalyzer/ProgramAnalyzer.cpp @@ -202,16 +202,16 @@ void ProgramAnalyzer::add(PvlObject &program) { PvlGroup ProgramAnalyzer::review(const QString &name) const { PvlGroup pvl(name.toStdString()); - pvl += PvlKeyword("Programs", toString(size())); - pvl += PvlKeyword("Unique", toString(Programs())); - pvl += PvlKeyword("Included", toString(LimitTotals(_includes))); - pvl += PvlKeyword("Excluded", toString(LimitTotals(_excludes))); - pvl += PvlKeyword("Valid", toString(valid())); - pvl += PvlKeyword("Errors", toString(errors())); - pvl += PvlKeyword("ZeroTime", toString(zerotime())); - pvl += PvlKeyword("NoData", toString(nodata())); - pvl += PvlKeyword("BadData", toString(baddata())); - pvl += PvlKeyword("Total", toString(count())); + pvl += PvlKeyword("Programs", Isis::toString(size())); + pvl += PvlKeyword("Unique", Isis::toString(Programs())); + pvl += PvlKeyword("Included", Isis::toString(LimitTotals(_includes))); + pvl += PvlKeyword("Excluded", Isis::toString(LimitTotals(_excludes))); + pvl += PvlKeyword("Valid", Isis::toString(valid())); + pvl += PvlKeyword("Errors", Isis::toString(errors())); + pvl += PvlKeyword("ZeroTime", Isis::toString(zerotime())); + pvl += PvlKeyword("NoData", Isis::toString(nodata())); + pvl += PvlKeyword("BadData", Isis::toString(baddata())); + pvl += PvlKeyword("Total", Isis::toString(count())); return (pvl); } @@ -490,7 +490,7 @@ PvlGroup ProgramAnalyzer::toPvl(const RunTimeStats &stats, const QString &name) const { PvlGroup pvl((name.isEmpty() ? stats.pname.toStdString() : name.toStdString())); - pvl += PvlKeyword("Hits", toString(stats.contime.TotalPixels())); + pvl += PvlKeyword("Hits", Isis::toString(stats.contime.TotalPixels())); pvl += PvlKeyword("ConnectTimeMinimum", DblToStr(stats.contime.Minimum(), 2).toStdString()); pvl += PvlKeyword("ConnectTimeMaximum", DblToStr(stats.contime.Maximum(), 2).toStdString()); pvl += PvlKeyword("ConnectTimeAverage", DblToStr(stats.contime.Average(), 2).toStdString()); diff --git a/isis/src/tgo/apps/tgocassis2isis/tgocassis2isis.cpp b/isis/src/tgo/apps/tgocassis2isis/tgocassis2isis.cpp index a95487abf0..c89f6dce48 100644 --- a/isis/src/tgo/apps/tgocassis2isis/tgocassis2isis.cpp +++ b/isis/src/tgo/apps/tgocassis2isis/tgocassis2isis.cpp @@ -400,7 +400,7 @@ namespace Isis { PvlKeyword summingMode("SummingMode", sumMode.toStdString()); outputLabel->findGroup("Instrument", Pvl::Traverse).addKeyword(summingMode); - PvlKeyword yeardoy("YearDoy", toString(stime.Year()*1000 + stime.DayOfYear())); + PvlKeyword yeardoy("YearDoy", Isis::toString(stime.Year()*1000 + stime.DayOfYear())); archive.addKeyword(yeardoy); // Set units on optional archived keywords @@ -444,7 +444,7 @@ namespace Isis { int spacecraftCode = -143400; - kern += PvlKeyword("NaifFrameCode", toString(spacecraftCode)); + kern += PvlKeyword("NaifFrameCode", Isis::toString(spacecraftCode)); if (filter.compare("PAN", Qt::CaseInsensitive) == 0) { spacecraftCode = -143421; @@ -466,7 +466,7 @@ namespace Isis { } // Add Kernel to BandBin Group - bandBin.addKeyword(PvlKeyword("NaifIkCode", toString(spacecraftCode))); + bandBin.addKeyword(PvlKeyword("NaifIkCode", Isis::toString(spacecraftCode))); } else { std::string msg = "Unrecognized Spacecraft name [" diff --git a/isis/src/tgo/apps/tgocassismos/tgocassismos.cpp b/isis/src/tgo/apps/tgocassismos/tgocassismos.cpp index 0ec6f2ab86..c5c475fd8e 100644 --- a/isis/src/tgo/apps/tgocassismos/tgocassismos.cpp +++ b/isis/src/tgo/apps/tgocassismos/tgocassismos.cpp @@ -250,13 +250,13 @@ namespace Isis { mos += PvlKeyword("StartTime ", firstStartTime.toStdString()); mos += PvlKeyword("StopTime ", stopTime.toStdString()); mos += PvlKeyword("SpacecraftClockStartCount ", startClock.toStdString()); - mos += PvlKeyword("IncidenceAngle ", toString(incidenceAngle), "degrees"); - mos += PvlKeyword("EmissionAngle ", toString(emissionAngle), "degrees"); - mos += PvlKeyword("PhaseAngle ", toString(phaseAngle), "degrees"); - mos += PvlKeyword("LocalTime ", toString(localSolarTime)); - mos += PvlKeyword("SolarLongitude ", toString(solarLongitude), "degrees"); - mos += PvlKeyword("SubSolarAzimuth ", toString(sunAzimuth), "degrees"); - mos += PvlKeyword("NorthAzimuth ", toString(northAzimuth), "degrees"); + mos += PvlKeyword("IncidenceAngle ", Isis::toString(incidenceAngle), "degrees"); + mos += PvlKeyword("EmissionAngle ", Isis::toString(emissionAngle), "degrees"); + mos += PvlKeyword("PhaseAngle ", Isis::toString(phaseAngle), "degrees"); + mos += PvlKeyword("LocalTime ", Isis::toString(localSolarTime)); + mos += PvlKeyword("SolarLongitude ", Isis::toString(solarLongitude), "degrees"); + mos += PvlKeyword("SubSolarAzimuth ", Isis::toString(sunAzimuth), "degrees"); + mos += PvlKeyword("NorthAzimuth ", Isis::toString(northAzimuth), "degrees"); Cube mosCube; mosCube.open(ui.GetCubeName("TO"), "rw"); diff --git a/isis/src/tgo/apps/tgocassisstitch/tgocassisstitch.cpp b/isis/src/tgo/apps/tgocassisstitch/tgocassisstitch.cpp index 2aafb2eecd..c12a575cf9 100644 --- a/isis/src/tgo/apps/tgocassisstitch/tgocassisstitch.cpp +++ b/isis/src/tgo/apps/tgocassisstitch/tgocassisstitch.cpp @@ -224,10 +224,10 @@ namespace Isis { frameCube.putGroup(archiveGroup); AlphaCube frameletAlphaCube(*frameletCube); - stitchGroup["FilterStartSamples"] += toString(frameletAlphaCube.AlphaSample(0.0)); - stitchGroup["FilterSamples"] += toString(frameletAlphaCube.BetaSamples()); - stitchGroup["FilterStartLines"] += toString(frameletAlphaCube.AlphaLine(0.0)); - stitchGroup["FilterLines"] += toString(frameletAlphaCube.BetaLines()); + stitchGroup["FilterStartSamples"] += Isis::toString(frameletAlphaCube.AlphaSample(0.0)); + stitchGroup["FilterSamples"] += Isis::toString(frameletAlphaCube.BetaSamples()); + stitchGroup["FilterStartLines"] += Isis::toString(frameletAlphaCube.AlphaLine(0.0)); + stitchGroup["FilterLines"] += Isis::toString(frameletAlphaCube.BetaLines()); PvlGroup frameletArchGroup = frameletCube->group("Archive"); stitchGroup["FilterFileNames"] += frameletArchGroup["FileName"]; diff --git a/isis/src/tgo/apps/tgocassisunstitch/tgocassisunstitch.cpp b/isis/src/tgo/apps/tgocassisunstitch/tgocassisunstitch.cpp index e6647715b7..ebb708faf1 100644 --- a/isis/src/tgo/apps/tgocassisunstitch/tgocassisunstitch.cpp +++ b/isis/src/tgo/apps/tgocassisunstitch/tgocassisunstitch.cpp @@ -89,14 +89,14 @@ namespace Isis { PvlKeyword filterWidth = inputLabel->findKeyword("FilterWidths", PvlObject::Traverse); for (int i = 0; i < filterKey.size(); i++) { - g_frameletInfoList.append(FilterInfo(IString::ToInteger(filterIkCodes[i]), + g_frameletInfoList.append(FilterInfo(Isis::toInt(filterIkCodes[i]), QString::fromStdString(filterKey[i]), - IString::ToDouble(filterStartSamples[i]), - IString::ToDouble(filterStartLines[i]), - IString::ToDouble(filterSamples[i]), - IString::ToDouble(filterLines[i]), - IString::ToDouble(filterWavelength[i]), - IString::ToDouble(filterWidth[i]))); + Isis::toDouble(filterStartSamples[i]), + Isis::toDouble(filterStartLines[i]), + Isis::toDouble(filterSamples[i]), + Isis::toDouble(filterLines[i]), + Isis::toDouble(filterWavelength[i]), + Isis::toDouble(filterWidth[i]))); } // Collect the tables and history from the input stitched cube @@ -188,9 +188,9 @@ namespace Isis { bandBin.addKeyword(PvlKeyword("FilterName", g_frameletInfoList[i].m_filterName.toStdString()), PvlObject::Replace); - bandBin.addKeyword(PvlKeyword("Center", toString(g_frameletInfoList[i].m_wavelength))); - bandBin.addKeyword(PvlKeyword("Width", toString(g_frameletInfoList[i].m_width))); - bandBin.addKeyword(PvlKeyword("NaifIkCode", toString(g_frameletInfoList[i].m_frameId))); + bandBin.addKeyword(PvlKeyword("Center", Isis::toString(g_frameletInfoList[i].m_wavelength))); + bandBin.addKeyword(PvlKeyword("Width", Isis::toString(g_frameletInfoList[i].m_width))); + bandBin.addKeyword(PvlKeyword("NaifIkCode", Isis::toString(g_frameletInfoList[i].m_frameId))); // Add the alpha cube AlphaCube frameletArea(cube->sampleCount(), cube->lineCount(), diff --git a/isis/src/tgo/objs/TgoCassisCamera/TgoCassisCamera.cpp b/isis/src/tgo/objs/TgoCassisCamera/TgoCassisCamera.cpp index cee5062b59..3adb98afdb 100644 --- a/isis/src/tgo/objs/TgoCassisCamera/TgoCassisCamera.cpp +++ b/isis/src/tgo/objs/TgoCassisCamera/TgoCassisCamera.cpp @@ -69,7 +69,7 @@ namespace Isis { // 0 = 1x1 (No summing) // 1 = 2x2 // 2 = 4x4 - int sumMode = IString::ToInteger(inst["SummingMode"][0]); + int sumMode = Isis::toInt(inst["SummingMode"][0]); int summing = sumMode * 2; // Setup camera detector map @@ -103,7 +103,7 @@ namespace Isis { // Set start time to center of exposure time to ensure // the proper SPICE data is cached. - double p_exposureDur = IString::ToDouble(inst["ExposureDuration"]); + double p_exposureDur = Isis::toDouble(inst["ExposureDuration"]); iTime p_etStart = et + ( p_exposureDur / 2.0); setTime(p_etStart); diff --git a/isis/src/tgo/objs/TgoCassisCamera/unitTest.cpp b/isis/src/tgo/objs/TgoCassisCamera/unitTest.cpp index 90d847a89c..7db2043745 100644 --- a/isis/src/tgo/objs/TgoCassisCamera/unitTest.cpp +++ b/isis/src/tgo/objs/TgoCassisCamera/unitTest.cpp @@ -60,7 +60,7 @@ int main(void) { // Test Shutter Open/Close const PvlGroup &inst = c.label()->findGroup("Instrument", Pvl::Traverse); - double exposureDuration = IString::ToDouble( inst["ExposureDuration"][0] ); + double exposureDuration = Isis::toDouble( inst["ExposureDuration"][0] ); QString stime = QString::fromStdString(inst["StartTime"]); double et; str2et_c(stime.toLatin1().data(), &et); diff --git a/isis/src/viking/apps/vik2isis/main.cpp b/isis/src/viking/apps/vik2isis/main.cpp index 0f70bf384e..2ecfb90a9c 100644 --- a/isis/src/viking/apps/vik2isis/main.cpp +++ b/isis/src/viking/apps/vik2isis/main.cpp @@ -176,9 +176,9 @@ void TranslateVikingLabels(Pvl &pdsLabel, Cube *ocube) { filterCenter = 0.590000; filterWidth = 0.150000; } - bandBin += PvlKeyword("FilterId", toString(filterId)); - bandBin += PvlKeyword("Center", toString(filterCenter), "micrometers"); - bandBin += PvlKeyword("Width", toString(filterWidth), "micrometers"); + bandBin += PvlKeyword("FilterId", Isis::toString(filterId)); + bandBin += PvlKeyword("Center", Isis::toString(filterCenter), "micrometers"); + bandBin += PvlKeyword("Width", Isis::toString(filterWidth), "micrometers"); ocube->putGroup(bandBin); // Setup the kernel group @@ -208,7 +208,7 @@ void TranslateVikingLabels(Pvl &pdsLabel, Cube *ocube) { // Set up the nominal reseaus group PvlGroup res("Reseaus"); - Pvl nomRes("$viking" + toString(spn) + "/reseaus/nominal.pvl"); + Pvl nomRes("$viking" + Isis::toString(spn) + "/reseaus/nominal.pvl"); PvlKeyword samps, lines, type, valid; lines = PvlKeyword("Line"); samps = PvlKeyword("Sample"); diff --git a/isis/src/viking/apps/vikcal/main.cpp b/isis/src/viking/apps/vikcal/main.cpp index ffa9430ae4..dbb8d77f35 100644 --- a/isis/src/viking/apps/vikcal/main.cpp +++ b/isis/src/viking/apps/vikcal/main.cpp @@ -71,24 +71,24 @@ void IsisMain() { calgrp.addComment("DI(l,s) = (1.0/(exp*w1))*G(l,s)*(gain*DR(l,s)+DC(l,s)+offt+offc)"); calgrp.addComment("with w1 = w0*((dist0*dist0) / (dist1*dist1))"); calgrp.addComment("and offt(l,s) = A*l + B*l*l + C*s + D*l*s + E"); - calgrp += PvlKeyword("offc", toString(calParam->Offset())); - calgrp += PvlKeyword("exp", toString(calParam->Exposure())); - calgrp += PvlKeyword("gain", toString(calParam->Gain())); + calgrp += PvlKeyword("offc", Isis::toString(calParam->Offset())); + calgrp += PvlKeyword("exp", Isis::toString(calParam->Exposure())); + calgrp += PvlKeyword("gain", Isis::toString(calParam->Gain())); calgrp += PvlKeyword("DR", in.toStdString()); calgrp += PvlKeyword("DC", calParam->OffsetFile().toStdString()); calgrp += PvlKeyword("G", calParam->GainFile().toStdString()); - calgrp += PvlKeyword("w0", toString(calParam->Omega0())); - calgrp += PvlKeyword("w1", toString(calParam->Omega1())); - calgrp += PvlKeyword("dist0", toString(calParam->Distance())); - calgrp += PvlKeyword("dist1", toString(calParam->Dist1())); - calgrp += PvlKeyword("1.0/exp*w1", toString(1.0 / (calParam->Exposure() * calParam->Omega1()))); - - calgrp += PvlKeyword("Acoeff", toString(calParam->Acoeff())); - calgrp += PvlKeyword("Bcoeff", toString(calParam->Bcoeff())); - calgrp += PvlKeyword("Ccoeff", toString(calParam->Ccoeff())); - calgrp += PvlKeyword("Dcoeff", toString(calParam->Dcoeff())); - calgrp += PvlKeyword("Ecoeff", toString(calParam->Ecoeff())); + calgrp += PvlKeyword("w0", Isis::toString(calParam->Omega0())); + calgrp += PvlKeyword("w1", Isis::toString(calParam->Omega1())); + calgrp += PvlKeyword("dist0", Isis::toString(calParam->Distance())); + calgrp += PvlKeyword("dist1", Isis::toString(calParam->Dist1())); + calgrp += PvlKeyword("1.0/exp*w1", Isis::toString(1.0 / (calParam->Exposure() * calParam->Omega1()))); + + calgrp += PvlKeyword("Acoeff", Isis::toString(calParam->Acoeff())); + calgrp += PvlKeyword("Bcoeff", Isis::toString(calParam->Bcoeff())); + calgrp += PvlKeyword("Ccoeff", Isis::toString(calParam->Ccoeff())); + calgrp += PvlKeyword("Dcoeff", Isis::toString(calParam->Dcoeff())); + calgrp += PvlKeyword("Ecoeff", Isis::toString(calParam->Ecoeff())); ocube->putGroup(calgrp); diff --git a/isis/src/viking/apps/vikcal/vikcal.cpp b/isis/src/viking/apps/vikcal/vikcal.cpp index b6d942d9ce..c388efe3c5 100644 --- a/isis/src/viking/apps/vikcal/vikcal.cpp +++ b/isis/src/viking/apps/vikcal/vikcal.cpp @@ -77,24 +77,24 @@ namespace Isis { calgrp.addComment("DI(l,s) = (1.0/(exp*w1))*G(l,s)*(gain*DR(l,s)+DC(l,s)+offt+offc)"); calgrp.addComment("with w1 = w0*((dist0*dist0) / (dist1*dist1))"); calgrp.addComment("and offt(l,s) = A*l + B*l*l + C*s + D*l*s + E"); - calgrp += PvlKeyword("offc", toString(calParam->Offset())); - calgrp += PvlKeyword("exp", toString(calParam->Exposure())); - calgrp += PvlKeyword("gain", toString(calParam->Gain())); + calgrp += PvlKeyword("offc", Isis::toString(calParam->Offset())); + calgrp += PvlKeyword("exp", Isis::toString(calParam->Exposure())); + calgrp += PvlKeyword("gain", Isis::toString(calParam->Gain())); calgrp += PvlKeyword("DR", in.toStdString()); calgrp += PvlKeyword("DC", calParam->OffsetFile().toStdString()); calgrp += PvlKeyword("G", calParam->GainFile().toStdString()); - calgrp += PvlKeyword("w0", toString(calParam->Omega0())); - calgrp += PvlKeyword("w1", toString(calParam->Omega1())); - calgrp += PvlKeyword("dist0", toString(calParam->Distance())); - calgrp += PvlKeyword("dist1", toString(calParam->Dist1())); - calgrp += PvlKeyword("1.0/exp*w1", toString(1.0 / (calParam->Exposure() * calParam->Omega1()))); - - calgrp += PvlKeyword("Acoeff", toString(calParam->Acoeff())); - calgrp += PvlKeyword("Bcoeff", toString(calParam->Bcoeff())); - calgrp += PvlKeyword("Ccoeff", toString(calParam->Ccoeff())); - calgrp += PvlKeyword("Dcoeff", toString(calParam->Dcoeff())); - calgrp += PvlKeyword("Ecoeff", toString(calParam->Ecoeff())); + calgrp += PvlKeyword("w0", Isis::toString(calParam->Omega0())); + calgrp += PvlKeyword("w1", Isis::toString(calParam->Omega1())); + calgrp += PvlKeyword("dist0", Isis::toString(calParam->Distance())); + calgrp += PvlKeyword("dist1", Isis::toString(calParam->Dist1())); + calgrp += PvlKeyword("1.0/exp*w1", Isis::toString(1.0 / (calParam->Exposure() * calParam->Omega1()))); + + calgrp += PvlKeyword("Acoeff", Isis::toString(calParam->Acoeff())); + calgrp += PvlKeyword("Bcoeff", Isis::toString(calParam->Bcoeff())); + calgrp += PvlKeyword("Ccoeff", Isis::toString(calParam->Ccoeff())); + calgrp += PvlKeyword("Dcoeff", Isis::toString(calParam->Dcoeff())); + calgrp += PvlKeyword("Ecoeff", Isis::toString(calParam->Ecoeff())); ocube->putGroup(calgrp); diff --git a/isis/src/voyager/apps/voy2isis/main.cpp b/isis/src/voyager/apps/voy2isis/main.cpp index 251fdb24fe..f2f3d63d25 100644 --- a/isis/src/voyager/apps/voy2isis/main.cpp +++ b/isis/src/voyager/apps/voy2isis/main.cpp @@ -234,12 +234,12 @@ void TranslateVoyagerLabels(Pvl &inputLab, Cube *ocube) { spacecraftNumber = "1"; if(instId == "NARROW_ANGLE_CAMERA") { spacecraftCode = -31101; - kern += PvlKeyword("NaifFrameCode", toString(spacecraftCode)); + kern += PvlKeyword("NaifFrameCode", Isis::toString(spacecraftCode)); instId = "issna"; } else if (instId == "WIDE_ANGLE_CAMERA") { spacecraftCode = -31102; - kern += PvlKeyword("NaifFrameCode", toString(spacecraftCode)); + kern += PvlKeyword("NaifFrameCode", Isis::toString(spacecraftCode)); instId = "isswa"; } else { @@ -254,12 +254,12 @@ void TranslateVoyagerLabels(Pvl &inputLab, Cube *ocube) { spacecraftNumber = "2"; if(instId == "NARROW_ANGLE_CAMERA") { spacecraftCode = -32101; - kern += PvlKeyword("NaifFrameCode", toString(spacecraftCode)); + kern += PvlKeyword("NaifFrameCode", Isis::toString(spacecraftCode)); instId = "issna"; } else if (instId == "WIDE_ANGLE_CAMERA") { spacecraftCode = -32102; - kern += PvlKeyword("NaifFrameCode", toString(spacecraftCode)); + kern += PvlKeyword("NaifFrameCode", Isis::toString(spacecraftCode)); instId = "isswa"; } else { diff --git a/isis/src/voyager/apps/voycal/main.cpp b/isis/src/voyager/apps/voycal/main.cpp index fa6da8911d..adbb3c16a8 100644 --- a/isis/src/voyager/apps/voycal/main.cpp +++ b/isis/src/voyager/apps/voycal/main.cpp @@ -199,11 +199,11 @@ void IsisMain() { calgrp.addKeyword(calib[4]); calgrp.addKeyword(calib[5]); calgrp.addKeyword(calib[6]); - calgrp.addKeyword(PvlKeyword("CalcSunDistance",toString(dist1))); + calgrp.addKeyword(PvlKeyword("CalcSunDistance",Isis::toString(dist1))); calgrp.addKeyword(instrument["ExposureDuration"]); - calgrp.addKeyword(PvlKeyword("XMLT",toString(XMLT))); - calgrp.addKeyword(PvlKeyword("Omega_W1",toString(w1))); - calgrp.addKeyword(PvlKeyword("CalcExpoDuration",toString(newExpo))); + calgrp.addKeyword(PvlKeyword("XMLT",Isis::toString(XMLT))); + calgrp.addKeyword(PvlKeyword("Omega_W1",Isis::toString(w1))); + calgrp.addKeyword(PvlKeyword("CalcExpoDuration",Isis::toString(newExpo))); // Linear correction equation and constants if (linear) { @@ -215,10 +215,10 @@ void IsisMain() { linearity.addComment("XNORM = NormalizingPower"); linearity.addComment("KPOWER = K_PowerOfNon-Linearity"); calgrp.addKeyword(linearity); - calgrp.addKeyword(PvlKeyword("ACoefficient",toString(aCoef))); - calgrp.addKeyword(PvlKeyword("B_HighEndNon-LinearityCorrection",toString(bHighEnd))); - calgrp.addKeyword(PvlKeyword("K_PowerOfNon-Linearity",toString(kPowerOf))); - calgrp.addKeyword(PvlKeyword("NormalizingPower",toString(normalizingPower))); + calgrp.addKeyword(PvlKeyword("ACoefficient",Isis::toString(aCoef))); + calgrp.addKeyword(PvlKeyword("B_HighEndNon-LinearityCorrection",Isis::toString(bHighEnd))); + calgrp.addKeyword(PvlKeyword("K_PowerOfNon-Linearity",Isis::toString(kPowerOf))); + calgrp.addKeyword(PvlKeyword("NormalizingPower",Isis::toString(normalizingPower))); } else { calgrp.addKeyword(PvlKeyword("LinearityCorrection","False")); diff --git a/isis/src/voyager/apps/voyramp/main.cpp b/isis/src/voyager/apps/voyramp/main.cpp index 434f2274e5..489d6e99b9 100644 --- a/isis/src/voyager/apps/voyramp/main.cpp +++ b/isis/src/voyager/apps/voyramp/main.cpp @@ -155,10 +155,10 @@ void IsisMain() { plasmaC = detb3/deta; // Create data to go in Radiometry group - PvlKeyword top = PvlKeyword("TopCorrectiveDN", toString(y1)); + PvlKeyword top = PvlKeyword("TopCorrectiveDN", Isis::toString(y1)); top.addComment("Voyramp plasma torus corrective DN values:"); - PvlKeyword mid = PvlKeyword("MiddleCorrectiveDN", toString(y2)); - PvlKeyword bot = PvlKeyword("BottomCorrectiveDN", toString(y3)); + PvlKeyword mid = PvlKeyword("MiddleCorrectiveDN", Isis::toString(y2)); + PvlKeyword bot = PvlKeyword("BottomCorrectiveDN", Isis::toString(y3)); // Add it radio += top; diff --git a/isis/tests/CameraFixtures.cpp b/isis/tests/CameraFixtures.cpp index cf14e8aa07..3a22bbf6d0 100644 --- a/isis/tests/CameraFixtures.cpp +++ b/isis/tests/CameraFixtures.cpp @@ -219,9 +219,9 @@ namespace Isis { label.addObject(isisCube); PvlGroup &dim = label.findObject("IsisCube").findObject("Core").findGroup("Dimensions"); - dim.findKeyword("Samples").setValue(toString(samples)); - dim.findKeyword("Lines").setValue(toString(lines)); - dim.findKeyword("Bands").setValue(toString(bands)); + dim.findKeyword("Samples").setValue(Isis::toString(samples)); + dim.findKeyword("Lines").setValue(Isis::toString(lines)); + dim.findKeyword("Bands").setValue(Isis::toString(bands)); delete testCube; testCube = new Cube(); @@ -245,9 +245,9 @@ namespace Isis { projLabel.addObject(isisProjCube); PvlGroup &projDim = projLabel.findObject("IsisCube").findObject("Core").findGroup("Dimensions"); - projDim.findKeyword("Samples").setValue(toString(samples)); - projDim.findKeyword("Lines").setValue(toString(lines)); - projDim.findKeyword("Bands").setValue(toString(bands)); + projDim.findKeyword("Samples").setValue(Isis::toString(samples)); + projDim.findKeyword("Lines").setValue(Isis::toString(lines)); + projDim.findKeyword("Bands").setValue(Isis::toString(bands)); delete projTestCube; projTestCube = new Cube(); diff --git a/isis/tests/CubeFixtures.cpp b/isis/tests/CubeFixtures.cpp index 071a454612..0a6f4166cd 100644 --- a/isis/tests/CubeFixtures.cpp +++ b/isis/tests/CubeFixtures.cpp @@ -308,13 +308,13 @@ namespace Isis { } PvlGroup reseausGroup("Reseaus"); - PvlKeyword samples = PvlKeyword("Sample", toString(reseaus[0].first)); - PvlKeyword lines = PvlKeyword("Line", toString(reseaus[0].second)); + PvlKeyword samples = PvlKeyword("Sample", Isis::toString(reseaus[0].first)); + PvlKeyword lines = PvlKeyword("Line", Isis::toString(reseaus[0].second)); PvlKeyword types = PvlKeyword("Type", "5"); PvlKeyword valid = PvlKeyword("Valid", "1"); for (size_t i = 1; i < reseaus.size(); i++) { - samples += toString(reseaus[i].first); - lines += toString(reseaus[i].second); + samples += Isis::toString(reseaus[i].first); + lines += Isis::toString(reseaus[i].second); types += "5"; valid += "1"; } diff --git a/isis/tests/FunctionalTestsApollofindrx.cpp b/isis/tests/FunctionalTestsApollofindrx.cpp index 0067067d07..fc715b9b09 100644 --- a/isis/tests/FunctionalTestsApollofindrx.cpp +++ b/isis/tests/FunctionalTestsApollofindrx.cpp @@ -69,19 +69,19 @@ TEST_F(LargeCube, FunctionalTestApollofindrxDefault) { PvlGroup newReseaus = newLab.findObject("IsisCube").findGroup("Reseaus"); PvlKeyword testKeyword = newReseaus.findKeyword("Line"); - EXPECT_NEAR(IString::ToDouble(testKeyword[0]), 100.8141, 0.0001); - EXPECT_NEAR(IString::ToDouble(testKeyword[1]), 192.8, 0.0001); - EXPECT_NEAR(IString::ToDouble(testKeyword[2]), 275.8, 0.0001); + EXPECT_NEAR(Isis::toDouble(testKeyword[0]), 100.8141, 0.0001); + EXPECT_NEAR(Isis::toDouble(testKeyword[1]), 192.8, 0.0001); + EXPECT_NEAR(Isis::toDouble(testKeyword[2]), 275.8, 0.0001); testKeyword = newReseaus.findKeyword("Sample"); - EXPECT_NEAR(IString::ToDouble(testKeyword[0]), 100.8141, 0.0001); - EXPECT_NEAR(IString::ToDouble(testKeyword[1]), 192.8, 0.0001); - EXPECT_NEAR(IString::ToDouble(testKeyword[2]), 167.8, 0.0001); + EXPECT_NEAR(Isis::toDouble(testKeyword[0]), 100.8141, 0.0001); + EXPECT_NEAR(Isis::toDouble(testKeyword[1]), 192.8, 0.0001); + EXPECT_NEAR(Isis::toDouble(testKeyword[2]), 167.8, 0.0001); testKeyword = newReseaus.findKeyword("Valid"); - EXPECT_EQ(IString::ToInteger(testKeyword[0]), 1); - EXPECT_EQ(IString::ToInteger(testKeyword[1]), 1); - EXPECT_EQ(IString::ToInteger(testKeyword[2]), 1); + EXPECT_EQ(Isis::toInt(testKeyword[0]), 1); + EXPECT_EQ(Isis::toInt(testKeyword[1]), 1); + EXPECT_EQ(Isis::toInt(testKeyword[2]), 1); EXPECT_PRED_FORMAT2(AssertStringsEqual, newReseaus.findKeyword("Status"), "Refined"); diff --git a/isis/tests/FunctionalTestsApolloremrx.cpp b/isis/tests/FunctionalTestsApolloremrx.cpp index c2cb8d53ff..04eaef7a64 100644 --- a/isis/tests/FunctionalTestsApolloremrx.cpp +++ b/isis/tests/FunctionalTestsApolloremrx.cpp @@ -36,19 +36,19 @@ TEST_F(ApolloCube, FunctionalTestApolloremrxDefault) { PvlGroup reseausGroup = isisLabel->findObject("IsisCube").findGroup("Reseaus"); PvlKeyword lineKey = reseausGroup.findKeyword("Line"); - EXPECT_NEAR(IString::ToDouble(lineKey[0]), 200, 0.0001); - EXPECT_NEAR(IString::ToDouble(lineKey[1]), 400, 0.0001); - EXPECT_NEAR(IString::ToDouble(lineKey[2]), 600, 0.0001); + EXPECT_NEAR(Isis::toDouble(lineKey[0]), 200, 0.0001); + EXPECT_NEAR(Isis::toDouble(lineKey[1]), 400, 0.0001); + EXPECT_NEAR(Isis::toDouble(lineKey[2]), 600, 0.0001); PvlKeyword sampleKey = reseausGroup.findKeyword("Sample"); - EXPECT_NEAR(IString::ToDouble(sampleKey[0]), 200, 0.0001); - EXPECT_NEAR(IString::ToDouble(sampleKey[1]), 400, 0.0001); - EXPECT_NEAR(IString::ToDouble(sampleKey[2]), 600, 0.0001); + EXPECT_NEAR(Isis::toDouble(sampleKey[0]), 200, 0.0001); + EXPECT_NEAR(Isis::toDouble(sampleKey[1]), 400, 0.0001); + EXPECT_NEAR(Isis::toDouble(sampleKey[2]), 600, 0.0001); PvlKeyword validKey = reseausGroup.findKeyword("Valid"); - EXPECT_EQ(IString::ToInteger(validKey[0]), 1); - EXPECT_EQ(IString::ToInteger(validKey[1]), 1); - EXPECT_EQ(IString::ToInteger(validKey[2]), 1); + EXPECT_EQ(Isis::toInt(validKey[0]), 1); + EXPECT_EQ(Isis::toInt(validKey[1]), 1); + EXPECT_EQ(Isis::toInt(validKey[2]), 1); EXPECT_PRED_FORMAT2(AssertStringsEqual, reseausGroup.findKeyword("Status"), "Removed"); diff --git a/isis/tests/FunctionalTestsCaminfo.cpp b/isis/tests/FunctionalTestsCaminfo.cpp index 4b6a6828a8..0197ef71f1 100644 --- a/isis/tests/FunctionalTestsCaminfo.cpp +++ b/isis/tests/FunctionalTestsCaminfo.cpp @@ -200,7 +200,7 @@ TEST_F(DefaultCube, FunctionalTestCaminfoDefault) { record[entry] = group.name(); entry++; for (int j = 0; j < group.keywords(); j++) { - record[entry] = IString::ToDouble(group[j][0]); + record[entry] = Isis::toDouble(group[j][0]); entry++; } table += record; @@ -469,7 +469,7 @@ TEST_F(DefaultCube, FunctionalTestCaminfoCamStatsTable) { record[entry] = group.name(); entry++; for (int j = 0; j < group.keywords(); j++) { - record[entry] = IString::ToDouble(group[j][0]); + record[entry] = Isis::toDouble(group[j][0]); entry++; } table += record; diff --git a/isis/tests/FunctionalTestsCampt.cpp b/isis/tests/FunctionalTestsCampt.cpp index e729f557a9..a999ae111a 100644 --- a/isis/tests/FunctionalTestsCampt.cpp +++ b/isis/tests/FunctionalTestsCampt.cpp @@ -88,9 +88,9 @@ TEST_F(DefaultCube, FunctionalTestCamptDefaultParameters) { EXPECT_NEAR( (double) groundPoint.findKeyword("PositiveWest360Longitude"), 104.10707141824, 1e-8); EXPECT_NEAR( (double) groundPoint.findKeyword("PositiveWest180Longitude"), 104.10707141824, 1e-8); - EXPECT_NEAR(IString::ToDouble(groundPoint.findKeyword("BodyFixedCoordinate")[0]), -818.59644749774, 1e-8); - EXPECT_NEAR(IString::ToDouble(groundPoint.findKeyword("BodyFixedCoordinate")[1]), -3257.2675597135, 1e-8); - EXPECT_NEAR(IString::ToDouble(groundPoint.findKeyword("BodyFixedCoordinate")[2]), 603.17640797124, 1e-8); + EXPECT_NEAR( Isis::toDouble(groundPoint.findKeyword("BodyFixedCoordinate")[0]), -818.59644749774, 1e-8); + EXPECT_NEAR( Isis::toDouble(groundPoint.findKeyword("BodyFixedCoordinate")[1]), -3257.2675597135, 1e-8); + EXPECT_NEAR( Isis::toDouble(groundPoint.findKeyword("BodyFixedCoordinate")[2]), 603.17640797124, 1e-8); EXPECT_NEAR( (double) groundPoint.findKeyword("LocalRadius"), 3412288.6569795, 1e-8); EXPECT_NEAR( (double) groundPoint.findKeyword("SampleResolution"), 18.904248467739, 1e-8); @@ -100,9 +100,9 @@ TEST_F(DefaultCube, FunctionalTestCamptDefaultParameters) { EXPECT_NEAR( (double) groundPoint.findKeyword("ObliqueLineResolution"), 19.589652452595999, 1e-8); EXPECT_NEAR( (double) groundPoint.findKeyword("ObliqueSampleResolution"), 19.589652452595999, 1e-8); - EXPECT_NEAR(IString::ToDouble(groundPoint.findKeyword("SpacecraftPosition")[0]), -1152.8979327717, 1e-8); - EXPECT_NEAR(IString::ToDouble(groundPoint.findKeyword("SpacecraftPosition")[1]), -3930.9421518203, 1e-8); - EXPECT_NEAR(IString::ToDouble(groundPoint.findKeyword("SpacecraftPosition")[2]), 728.14118380775, 1e-8); + EXPECT_NEAR( Isis::toDouble(groundPoint.findKeyword("SpacecraftPosition")[0]), -1152.8979327717, 1e-8); + EXPECT_NEAR( Isis::toDouble(groundPoint.findKeyword("SpacecraftPosition")[1]), -3930.9421518203, 1e-8); + EXPECT_NEAR( Isis::toDouble(groundPoint.findKeyword("SpacecraftPosition")[2]), 728.14118380775, 1e-8); EXPECT_NEAR( (double) groundPoint.findKeyword("SpacecraftAzimuth"), 240.08514246657, 1e-8); EXPECT_NEAR( (double) groundPoint.findKeyword("SlantDistance"), 762.37204454685, 1e-8); @@ -113,9 +113,9 @@ TEST_F(DefaultCube, FunctionalTestCamptDefaultParameters) { EXPECT_NEAR( (double) groundPoint.findKeyword("OffNadirAngle"), 9.9273765143684, 1e-8); EXPECT_NEAR( (double) groundPoint.findKeyword("SubSpacecraftGroundAzimuth"), 267.5318718687, 1e-8); - EXPECT_NEAR(IString::ToDouble(groundPoint.findKeyword("SunPosition")[0]), 147591102.63158, 1e-8); - EXPECT_NEAR(IString::ToDouble(groundPoint.findKeyword("SunPosition")[1]), -127854342.1274, 1e-8); - EXPECT_NEAR(IString::ToDouble(groundPoint.findKeyword("SunPosition")[2]), -81844199.02275, 1e-8); + EXPECT_NEAR( Isis::toDouble(groundPoint.findKeyword("SunPosition")[0]), 147591102.63158, 1e-8); + EXPECT_NEAR( Isis::toDouble(groundPoint.findKeyword("SunPosition")[1]), -127854342.1274, 1e-8); + EXPECT_NEAR( Isis::toDouble(groundPoint.findKeyword("SunPosition")[2]), -81844199.02275, 1e-8); EXPECT_NEAR( (double) groundPoint.findKeyword("SubSolarAzimuth"), 92.033828156965, 1e-8); EXPECT_NEAR( (double) groundPoint.findKeyword("SolarDistance"), 1.4153000672557, 1e-8); @@ -133,17 +133,17 @@ TEST_F(DefaultCube, FunctionalTestCamptDefaultParameters) { EXPECT_NEAR( (double) groundPoint.findKeyword("LocalSolarTime"), 7.7862975330952, 1e-8); EXPECT_NEAR( (double) groundPoint.findKeyword("SolarLongitude"), 294.73518830594998, 1e-8); - EXPECT_NEAR(IString::ToDouble(groundPoint.findKeyword("LookDirectionBodyFixed")[0]), 0.43850176257802, 1e-8); - EXPECT_NEAR(IString::ToDouble(groundPoint.findKeyword("LookDirectionBodyFixed")[1]), 0.88365594846443, 1e-8); - EXPECT_NEAR(IString::ToDouble(groundPoint.findKeyword("LookDirectionBodyFixed")[2]), -0.16391573737569, 1e-8); + EXPECT_NEAR( Isis::toDouble(groundPoint.findKeyword("LookDirectionBodyFixed")[0]), 0.43850176257802, 1e-8); + EXPECT_NEAR( Isis::toDouble(groundPoint.findKeyword("LookDirectionBodyFixed")[1]), 0.88365594846443, 1e-8); + EXPECT_NEAR( Isis::toDouble(groundPoint.findKeyword("LookDirectionBodyFixed")[2]), -0.16391573737569, 1e-8); - EXPECT_NEAR(IString::ToDouble(groundPoint.findKeyword("LookDirectionJ2000")[0]), 0.44577814515745, 1e-8); - EXPECT_NEAR(IString::ToDouble(groundPoint.findKeyword("LookDirectionJ2000")[1]), -0.52737586689974, 1e-8); - EXPECT_NEAR(IString::ToDouble(groundPoint.findKeyword("LookDirectionJ2000")[2]), -0.72329561059897, 1e-8); + EXPECT_NEAR( Isis::toDouble(groundPoint.findKeyword("LookDirectionJ2000")[0]), 0.44577814515745, 1e-8); + EXPECT_NEAR( Isis::toDouble(groundPoint.findKeyword("LookDirectionJ2000")[1]), -0.52737586689974, 1e-8); + EXPECT_NEAR( Isis::toDouble(groundPoint.findKeyword("LookDirectionJ2000")[2]), -0.72329561059897, 1e-8); - EXPECT_NEAR(IString::ToDouble(groundPoint.findKeyword("LookDirectionCamera")[0]), -1.27447324380581e-04, 1e-8); - EXPECT_NEAR(IString::ToDouble(groundPoint.findKeyword("LookDirectionCamera")[1]), 2.5816511718707e-05, 1e-8); - EXPECT_NEAR(IString::ToDouble(groundPoint.findKeyword("LookDirectionCamera")[2]), 0.99999999154535, 1e-8); + EXPECT_NEAR( Isis::toDouble(groundPoint.findKeyword("LookDirectionCamera")[0]), -1.27447324380581e-04, 1e-8); + EXPECT_NEAR( Isis::toDouble(groundPoint.findKeyword("LookDirectionCamera")[1]), 2.5816511718707e-05, 1e-8); + EXPECT_NEAR( Isis::toDouble(groundPoint.findKeyword("LookDirectionCamera")[2]), 0.99999999154535, 1e-8); } TEST_F(DefaultCube, FunctionalTestCamptSetSL) { diff --git a/isis/tests/FunctionalTestsChan1m32isis.cpp b/isis/tests/FunctionalTestsChan1m32isis.cpp index 37086b4a57..795cf833e9 100644 --- a/isis/tests/FunctionalTestsChan1m32isis.cpp +++ b/isis/tests/FunctionalTestsChan1m32isis.cpp @@ -75,26 +75,26 @@ TEST(Chan1m32Isis, Chan1m32IsisTestFowardAscending) { ASSERT_EQ(bandbin["FilterNumber"].size(), 256); ASSERT_EQ(bandbin["OriginalBand"].size(), 256); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["Center"][0]), 446.02); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["Center"][64]), 1084.8); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["Center"][128]), 1723.5899999999999); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["Center"][255]), 2991.17); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["Center"][0]), 446.02); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["Center"][64]), 1084.8); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["Center"][128]), 1723.5899999999999); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["Center"][255]), 2991.17); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["Width"][0]), 12.31); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["Width"][64]), 12.29); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["Width"][128]), 12.61); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["Width"][255]), 12.18); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["Width"][0]), 12.31); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["Width"][64]), 12.29); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["Width"][128]), 12.61); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["Width"][255]), 12.18); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["FilterNumber"][0]), 5); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["FilterNumber"][64]), 69); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["FilterNumber"][128]), 133); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["FilterNumber"][255]), 260); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["FilterNumber"][0]), 5); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["FilterNumber"][64]), 69); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["FilterNumber"][128]), 133); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["FilterNumber"][255]), 260); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["OriginalBand"][0]), 1); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["OriginalBand"][64]), 65); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["OriginalBand"][128]), 129); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["OriginalBand"][255]), 256); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["OriginalBand"][0]), 1); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["OriginalBand"][64]), 65); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["OriginalBand"][128]), 129); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["OriginalBand"][255]), 256); // Kernels Group PvlGroup &kernel = isisLabel->findGroup("Kernels", Pvl::Traverse); @@ -359,20 +359,20 @@ TEST(Chan1m32Isis, Chan1m32IsisTestL0) { ASSERT_EQ(bandbin["FilterNumber"].size(), 85); ASSERT_EQ(bandbin["OriginalBand"].size(), 85); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["Center"][0]), 460.990); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["Center"][21]), 1009.95); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["Center"][42]), 1429.15); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["Center"][84]), 2976.20); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["Center"][0]), 460.990); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["Center"][21]), 1009.95); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["Center"][42]), 1429.15); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["Center"][84]), 2976.20); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["FilterNumber"][0]), 5); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["FilterNumber"][21]), 57); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["FilterNumber"][42]), 99); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["FilterNumber"][84]), 253); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["FilterNumber"][0]), 5); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["FilterNumber"][21]), 57); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["FilterNumber"][42]), 99); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["FilterNumber"][84]), 253); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["OriginalBand"][0]), 1); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["OriginalBand"][21]), 22); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["OriginalBand"][42]), 43); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["OriginalBand"][84]), 85); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["OriginalBand"][0]), 1); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["OriginalBand"][21]), 22); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["OriginalBand"][42]), 43); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["OriginalBand"][84]), 85); // Kernels Group PvlGroup &kernel = isisLabel->findGroup("Kernels", Pvl::Traverse); diff --git a/isis/tests/FunctionalTestsFootprintinit.cpp b/isis/tests/FunctionalTestsFootprintinit.cpp index 0749385e77..4aebc0b575 100644 --- a/isis/tests/FunctionalTestsFootprintinit.cpp +++ b/isis/tests/FunctionalTestsFootprintinit.cpp @@ -142,8 +142,8 @@ TEST_F(DefaultCube, FunctionalTestFootprintinitPrecision) { ASSERT_TRUE(testCube->label()->hasObject("Polygon")); ASSERT_TRUE(log.hasGroup("Results")); - ASSERT_EQ(100, IString::ToInteger(log.findGroup("Results").findKeyword("LINC")[0])); - ASSERT_EQ(100, IString::ToInteger(log.findGroup("Results").findKeyword("SINC")[0])); + ASSERT_EQ(100, Isis::toInt(log.findGroup("Results").findKeyword("LINC")[0])); + ASSERT_EQ(100, Isis::toInt(log.findGroup("Results").findKeyword("SINC")[0])); ImagePolygon poly = testCube->readFootprint(); diff --git a/isis/tests/FunctionalTestsFrameStitch.cpp b/isis/tests/FunctionalTestsFrameStitch.cpp index 7699125724..4bd02ccad1 100644 --- a/isis/tests/FunctionalTestsFrameStitch.cpp +++ b/isis/tests/FunctionalTestsFrameStitch.cpp @@ -163,7 +163,7 @@ TEST_F(PushFramePair, FunctionalTestFramestitchFlip) { ASSERT_TRUE(outCube.hasGroup("Instrument")); ASSERT_TRUE(outCube.group("Instrument").hasKeyword("DataFlipped")); - EXPECT_TRUE(toBool(outCube.group("Instrument")["DataFlipped"])); + EXPECT_TRUE(Isis::toInt(outCube.group("Instrument")["DataFlipped"])); } TEST_F(FlippedPushFramePair, FunctionalTestFramestitchNoFlip) { @@ -213,7 +213,7 @@ TEST_F(FlippedPushFramePair, FunctionalTestFramestitchNoFlip) { ASSERT_TRUE(outCube.hasGroup("Instrument")); ASSERT_TRUE(outCube.group("Instrument").hasKeyword("DataFlipped")); - EXPECT_TRUE(toBool(outCube.group("Instrument")["DataFlipped"])); + EXPECT_TRUE(Isis::toInt(outCube.group("Instrument")["DataFlipped"])); } TEST_F(FlippedPushFramePair, FunctionalTestFramestitchFlip) { @@ -264,7 +264,7 @@ TEST_F(FlippedPushFramePair, FunctionalTestFramestitchFlip) { ASSERT_TRUE(outCube.hasGroup("Instrument")); ASSERT_TRUE(outCube.group("Instrument").hasKeyword("DataFlipped")); - EXPECT_FALSE(toBool(outCube.group("Instrument")["DataFlipped"])); + EXPECT_FALSE(Isis::toInt(outCube.group("Instrument")["DataFlipped"])); } TEST_F(PushFramePair, FunctionalTestFramestitchDifferentObservations) { diff --git a/isis/tests/FunctionalTestsHicubenorm.cpp b/isis/tests/FunctionalTestsHicubenorm.cpp index 1175de0d04..2d90989f53 100644 --- a/isis/tests/FunctionalTestsHicubenorm.cpp +++ b/isis/tests/FunctionalTestsHicubenorm.cpp @@ -130,10 +130,10 @@ TEST_F(MroHiriseCube, FunctionalTestHicubenormNewVersion) { PvlGroup stats("Results"); for(int i = 1; i <= 1204; i++) { stats += PvlKeyword("Band", "1"); - stats += PvlKeyword("RowCol", toString(i)); - stats += PvlKeyword("ValidPixels", toString(1056)); - stats += PvlKeyword("Mean", toString(i)); - stats += PvlKeyword("Median", toString(i/2)); + stats += PvlKeyword("RowCol", Isis::toString(i)); + stats += PvlKeyword("ValidPixels", Isis::toString(1056)); + stats += PvlKeyword("Mean", Isis::toString(i)); + stats += PvlKeyword("Median", Isis::toString(i/2)); // the rest shouldn't matter stats += PvlKeyword("Std", "0.0"); stats += PvlKeyword("Minimum", "0.0"); diff --git a/isis/tests/FunctionalTestsHimos.cpp b/isis/tests/FunctionalTestsHimos.cpp index 739c31f7b2..66d39f45d7 100644 --- a/isis/tests/FunctionalTestsHimos.cpp +++ b/isis/tests/FunctionalTestsHimos.cpp @@ -61,13 +61,13 @@ TEST_F(MroHiriseCube, FunctionalTestHimosDefault) { EXPECT_EQ(mos["StopTime"][0], "2006-09-29T15:16:35.036"); EXPECT_EQ(mos["SpacecraftClockStopCount"][0], "844010213:55196"); - EXPECT_NEAR(IString::ToDouble(mos["IncidenceAngle"][0]), 59.687930340662, 1e-6); - EXPECT_NEAR(IString::ToDouble(mos["EmissionAngle"][0]), 0.091672512439956, 1e-6); - EXPECT_NEAR(IString::ToDouble(mos["PhaseAngle"][0]), 59.597812369363, 1e-6); - EXPECT_NEAR(IString::ToDouble(mos["LocalTime"][0]), 15.486088288555, 1e-6); - EXPECT_NEAR(IString::ToDouble(mos["SolarLongitude"][0]), 113.54746578654, 1e-6); - EXPECT_NEAR(IString::ToDouble(mos["SubSolarAzimuth"][0]), 212.41484032558 , 1e-6); - EXPECT_NEAR(IString::ToDouble(mos["NorthAzimuth"][0]), 270.00024569628, 1e-6); + EXPECT_NEAR(Isis::toDouble(mos["IncidenceAngle"][0]), 59.687930340662, 1e-6); + EXPECT_NEAR(Isis::toDouble(mos["EmissionAngle"][0]), 0.091672512439956, 1e-6); + EXPECT_NEAR(Isis::toDouble(mos["PhaseAngle"][0]), 59.597812369363, 1e-6); + EXPECT_NEAR(Isis::toDouble(mos["LocalTime"][0]), 15.486088288555, 1e-6); + EXPECT_NEAR(Isis::toDouble(mos["SolarLongitude"][0]), 113.54746578654, 1e-6); + EXPECT_NEAR(Isis::toDouble(mos["SubSolarAzimuth"][0]), 212.41484032558 , 1e-6); + EXPECT_NEAR(Isis::toDouble(mos["NorthAzimuth"][0]), 270.00024569628, 1e-6); EXPECT_EQ(mos["cpmmTdiFlag"][5], "128"); EXPECT_EQ(mos["cpmmSummingFlag"][5], "1"); diff --git a/isis/tests/FunctionalTestsIsisImport.cpp b/isis/tests/FunctionalTestsIsisImport.cpp index 4629cafe39..511a593d67 100644 --- a/isis/tests/FunctionalTestsIsisImport.cpp +++ b/isis/tests/FunctionalTestsIsisImport.cpp @@ -66,9 +66,9 @@ End)"; PvlGroup dimensionsGroup = label->findObject("IsisCube").findObject("Core").findGroup("Dimensions"); - EXPECT_EQ(IString::ToInteger(dimensionsGroup["Samples"][0]), 3); - EXPECT_EQ(IString::ToInteger(dimensionsGroup["Lines"][0]), 2); - EXPECT_EQ(IString::ToInteger(dimensionsGroup["Bands"][0]), 1); + EXPECT_EQ(Isis::toInt(dimensionsGroup["Samples"][0]), 3); + EXPECT_EQ(Isis::toInt(dimensionsGroup["Lines"][0]), 2); + EXPECT_EQ(Isis::toInt(dimensionsGroup["Bands"][0]), 1); EXPECT_EQ(cube.sampleCount(), 3); EXPECT_EQ(cube.lineCount(), 2); diff --git a/isis/tests/FunctionalTestsIsisImportLo.cpp b/isis/tests/FunctionalTestsIsisImportLo.cpp index 946277258d..007b7727da 100644 --- a/isis/tests/FunctionalTestsIsisImportLo.cpp +++ b/isis/tests/FunctionalTestsIsisImportLo.cpp @@ -64,25 +64,25 @@ TEST(IsisImportTests, loTestDefault) { ASSERT_EQ(inst["FiducialID"][14], "144b"); ASSERT_EQ(inst["FiducialID"][29], "283b"); - ASSERT_DOUBLE_EQ(IString::ToDouble(inst["FiducialSamples"][0]), 32162.0); - ASSERT_DOUBLE_EQ(IString::ToDouble(inst["FiducialSamples"][6]), 24295.0); - ASSERT_DOUBLE_EQ(IString::ToDouble(inst["FiducialSamples"][14]), 16593.0); - ASSERT_DOUBLE_EQ(IString::ToDouble(inst["FiducialSamples"][29]), 1248.0); - - ASSERT_DOUBLE_EQ(IString::ToDouble(inst["FiducialLines"][0]), 8510.0); - ASSERT_DOUBLE_EQ(IString::ToDouble(inst["FiducialLines"][6]), 8504.0); - ASSERT_DOUBLE_EQ(IString::ToDouble(inst["FiducialLines"][14]), 584.0); - ASSERT_DOUBLE_EQ(IString::ToDouble(inst["FiducialLines"][29]), 8496.0); - - ASSERT_DOUBLE_EQ(IString::ToDouble(inst["FiducialXCoordinates"][0]), -108.168); - ASSERT_DOUBLE_EQ(IString::ToDouble(inst["FiducialXCoordinates"][6]), -53.474); - ASSERT_DOUBLE_EQ(IString::ToDouble(inst["FiducialXCoordinates"][14]), 0.122); - ASSERT_DOUBLE_EQ(IString::ToDouble(inst["FiducialXCoordinates"][29]), 106.844); - - ASSERT_DOUBLE_EQ(IString::ToDouble(inst["FiducialYCoordinates"][0]), 27.476); - ASSERT_DOUBLE_EQ(IString::ToDouble(inst["FiducialYCoordinates"][6]), 27.5); - ASSERT_DOUBLE_EQ(IString::ToDouble(inst["FiducialYCoordinates"][14]), -27.493); - ASSERT_DOUBLE_EQ(IString::ToDouble(inst["FiducialYCoordinates"][29]), 27.479); + ASSERT_DOUBLE_EQ(Isis::toDouble(inst["FiducialSamples"][0]), 32162.0); + ASSERT_DOUBLE_EQ(Isis::toDouble(inst["FiducialSamples"][6]), 24295.0); + ASSERT_DOUBLE_EQ(Isis::toDouble(inst["FiducialSamples"][14]), 16593.0); + ASSERT_DOUBLE_EQ(Isis::toDouble(inst["FiducialSamples"][29]), 1248.0); + + ASSERT_DOUBLE_EQ(Isis::toDouble(inst["FiducialLines"][0]), 8510.0); + ASSERT_DOUBLE_EQ(Isis::toDouble(inst["FiducialLines"][6]), 8504.0); + ASSERT_DOUBLE_EQ(Isis::toDouble(inst["FiducialLines"][14]), 584.0); + ASSERT_DOUBLE_EQ(Isis::toDouble(inst["FiducialLines"][29]), 8496.0); + + ASSERT_DOUBLE_EQ(Isis::toDouble(inst["FiducialXCoordinates"][0]), -108.168); + ASSERT_DOUBLE_EQ(Isis::toDouble(inst["FiducialXCoordinates"][6]), -53.474); + ASSERT_DOUBLE_EQ(Isis::toDouble(inst["FiducialXCoordinates"][14]), 0.122); + ASSERT_DOUBLE_EQ(Isis::toDouble(inst["FiducialXCoordinates"][29]), 106.844); + + ASSERT_DOUBLE_EQ(Isis::toDouble(inst["FiducialYCoordinates"][0]), 27.476); + ASSERT_DOUBLE_EQ(Isis::toDouble(inst["FiducialYCoordinates"][6]), 27.5); + ASSERT_DOUBLE_EQ(Isis::toDouble(inst["FiducialYCoordinates"][14]), -27.493); + ASSERT_DOUBLE_EQ(Isis::toDouble(inst["FiducialYCoordinates"][29]), 27.479); // Bandbin Group PvlGroup &bandbin = isisLabel->findGroup("BandBin", Pvl::Traverse); diff --git a/isis/tests/FunctionalTestsJitterfit.cpp b/isis/tests/FunctionalTestsJitterfit.cpp index f10ca8752b..0059d2e4dd 100644 --- a/isis/tests/FunctionalTestsJitterfit.cpp +++ b/isis/tests/FunctionalTestsJitterfit.cpp @@ -72,12 +72,12 @@ TEST_F(TempTestingFiles, DISABLED_FunctionalTestJitterfitDefault){ Pvl *isisLabel = cube.label(); PvlGroup &inst = isisLabel->findGroup("Instrument", Pvl::Traverse); - EXPECT_DOUBLE_EQ(IString::ToDouble(inst["JitterSampleCoefficients"][0]), -6.3185740156776303e-09); - EXPECT_DOUBLE_EQ(IString::ToDouble(inst["JitterSampleCoefficients"][1]), 2.44034713747508e-06); - EXPECT_DOUBLE_EQ(IString::ToDouble(inst["JitterSampleCoefficients"][2]), 0.0032581267520383002); - EXPECT_DOUBLE_EQ(IString::ToDouble(inst["JitterLineCoefficients"][0]), -2.7623177125388001e-09); - EXPECT_DOUBLE_EQ(IString::ToDouble(inst["JitterLineCoefficients"][1]), 3.3727910440682698e-06); - EXPECT_DOUBLE_EQ(IString::ToDouble(inst["JitterLineCoefficients"][2]), 0.0013484324974775001); + EXPECT_DOUBLE_EQ(Isis::toDouble(inst["JitterSampleCoefficients"][0]), -6.3185740156776303e-09); + EXPECT_DOUBLE_EQ(Isis::toDouble(inst["JitterSampleCoefficients"][1]), 2.44034713747508e-06); + EXPECT_DOUBLE_EQ(Isis::toDouble(inst["JitterSampleCoefficients"][2]), 0.0032581267520383002); + EXPECT_DOUBLE_EQ(Isis::toDouble(inst["JitterLineCoefficients"][0]), -2.7623177125388001e-09); + EXPECT_DOUBLE_EQ(Isis::toDouble(inst["JitterLineCoefficients"][1]), 3.3727910440682698e-06); + EXPECT_DOUBLE_EQ(Isis::toDouble(inst["JitterLineCoefficients"][2]), 0.0013484324974775001); // Test residuals CSVReader::CSVAxis residLine; diff --git a/isis/tests/FunctionalTestsLeisa2isis.cpp b/isis/tests/FunctionalTestsLeisa2isis.cpp index 58f8528fc2..ad49286f2d 100644 --- a/isis/tests/FunctionalTestsLeisa2isis.cpp +++ b/isis/tests/FunctionalTestsLeisa2isis.cpp @@ -68,20 +68,20 @@ TEST(Leisa2Isis, Leisa2IsisTestDefault) { ASSERT_EQ(bandbin["Width"].size(), 256); ASSERT_EQ(bandbin["OriginalBand"].size(), 256); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["Center"][0]), 2.4892); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["Center"][64]), 1.9784); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["Center"][128]), 1.572); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["Center"][255]), 2.0898); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["Center"][0]), 2.4892); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["Center"][64]), 1.9784); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["Center"][128]), 1.572); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["Center"][255]), 2.0898); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["Width"][0]), 0.011228); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["Width"][64]), 0.008924); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["Width"][128]), 0.007091); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["Width"][255]), 0.004915); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["Width"][0]), 0.011228); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["Width"][64]), 0.008924); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["Width"][128]), 0.007091); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["Width"][255]), 0.004915); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["OriginalBand"][0]), 1); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["OriginalBand"][64]), 65); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["OriginalBand"][128]), 129); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["OriginalBand"][255]), 256); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["OriginalBand"][0]), 1); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["OriginalBand"][64]), 65); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["OriginalBand"][128]), 129); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["OriginalBand"][255]), 256); // Kernels Group PvlGroup &kernel = isisLabel->findGroup("Kernels", Pvl::Traverse); @@ -304,20 +304,20 @@ TEST(Leisa2Isis, Leisa2IsisTestRaw) { ASSERT_EQ(bandbin["Width"].size(), 256); ASSERT_EQ(bandbin["OriginalBand"].size(), 256); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["Center"][0]), 2.4892); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["Center"][64]), 1.9784); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["Center"][128]), 1.572); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["Center"][255]), 2.0898); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["Center"][0]), 2.4892); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["Center"][64]), 1.9784); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["Center"][128]), 1.572); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["Center"][255]), 2.0898); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["Width"][0]), 0.011228); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["Width"][64]), 0.008924); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["Width"][128]), 0.007091); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["Width"][255]), 0.004915); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["Width"][0]), 0.011228); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["Width"][64]), 0.008924); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["Width"][128]), 0.007091); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["Width"][255]), 0.004915); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["OriginalBand"][0]), 1); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["OriginalBand"][64]), 65); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["OriginalBand"][128]), 129); - ASSERT_DOUBLE_EQ(IString::ToDouble(bandbin["OriginalBand"][255]), 256); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["OriginalBand"][0]), 1); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["OriginalBand"][64]), 65); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["OriginalBand"][128]), 129); + ASSERT_DOUBLE_EQ(Isis::toDouble(bandbin["OriginalBand"][255]), 256); } diff --git a/isis/tests/FunctionalTestsLo2isis.cpp b/isis/tests/FunctionalTestsLo2isis.cpp index 66dd956f18..b249cc5b49 100644 --- a/isis/tests/FunctionalTestsLo2isis.cpp +++ b/isis/tests/FunctionalTestsLo2isis.cpp @@ -56,25 +56,25 @@ TEST(lo2isisTest, lo2isisTestDefault) { ASSERT_EQ(inst["FiducialID"][14], "144b"); ASSERT_EQ(inst["FiducialID"][29], "283b"); - ASSERT_DOUBLE_EQ(IString::ToDouble(inst["FiducialSamples"][0]), 32162.0); - ASSERT_DOUBLE_EQ(IString::ToDouble(inst["FiducialSamples"][6]), 24295.0); - ASSERT_DOUBLE_EQ(IString::ToDouble(inst["FiducialSamples"][14]), 16593.0); - ASSERT_DOUBLE_EQ(IString::ToDouble(inst["FiducialSamples"][29]), 1248.0); - - ASSERT_DOUBLE_EQ(IString::ToDouble(inst["FiducialLines"][0]), 8510.0); - ASSERT_DOUBLE_EQ(IString::ToDouble(inst["FiducialLines"][6]), 8504.0); - ASSERT_DOUBLE_EQ(IString::ToDouble(inst["FiducialLines"][14]), 584.0); - ASSERT_DOUBLE_EQ(IString::ToDouble(inst["FiducialLines"][29]), 8496.0); - - ASSERT_DOUBLE_EQ(IString::ToDouble(inst["FiducialXCoordinates"][0]), -108.168); - ASSERT_DOUBLE_EQ(IString::ToDouble(inst["FiducialXCoordinates"][6]), -53.474); - ASSERT_DOUBLE_EQ(IString::ToDouble(inst["FiducialXCoordinates"][14]), 0.122); - ASSERT_DOUBLE_EQ(IString::ToDouble(inst["FiducialXCoordinates"][29]), 106.844); - - ASSERT_DOUBLE_EQ(IString::ToDouble(inst["FiducialYCoordinates"][0]), 27.476); - ASSERT_DOUBLE_EQ(IString::ToDouble(inst["FiducialYCoordinates"][6]), 27.5); - ASSERT_DOUBLE_EQ(IString::ToDouble(inst["FiducialYCoordinates"][14]), -27.493); - ASSERT_DOUBLE_EQ(IString::ToDouble(inst["FiducialYCoordinates"][29]), 27.479); + ASSERT_DOUBLE_EQ(Isis::toDouble(inst["FiducialSamples"][0]), 32162.0); + ASSERT_DOUBLE_EQ(Isis::toDouble(inst["FiducialSamples"][6]), 24295.0); + ASSERT_DOUBLE_EQ(Isis::toDouble(inst["FiducialSamples"][14]), 16593.0); + ASSERT_DOUBLE_EQ(Isis::toDouble(inst["FiducialSamples"][29]), 1248.0); + + ASSERT_DOUBLE_EQ(Isis::toDouble(inst["FiducialLines"][0]), 8510.0); + ASSERT_DOUBLE_EQ(Isis::toDouble(inst["FiducialLines"][6]), 8504.0); + ASSERT_DOUBLE_EQ(Isis::toDouble(inst["FiducialLines"][14]), 584.0); + ASSERT_DOUBLE_EQ(Isis::toDouble(inst["FiducialLines"][29]), 8496.0); + + ASSERT_DOUBLE_EQ(Isis::toDouble(inst["FiducialXCoordinates"][0]), -108.168); + ASSERT_DOUBLE_EQ(Isis::toDouble(inst["FiducialXCoordinates"][6]), -53.474); + ASSERT_DOUBLE_EQ(Isis::toDouble(inst["FiducialXCoordinates"][14]), 0.122); + ASSERT_DOUBLE_EQ(Isis::toDouble(inst["FiducialXCoordinates"][29]), 106.844); + + ASSERT_DOUBLE_EQ(Isis::toDouble(inst["FiducialYCoordinates"][0]), 27.476); + ASSERT_DOUBLE_EQ(Isis::toDouble(inst["FiducialYCoordinates"][6]), 27.5); + ASSERT_DOUBLE_EQ(Isis::toDouble(inst["FiducialYCoordinates"][14]), -27.493); + ASSERT_DOUBLE_EQ(Isis::toDouble(inst["FiducialYCoordinates"][29]), 27.479); // Bandbin Group PvlGroup &bandbin = isisLabel->findGroup("BandBin", Pvl::Traverse); diff --git a/isis/tests/FunctionalTestsLorri2isis.cpp b/isis/tests/FunctionalTestsLorri2isis.cpp index c1e7c8dd5c..0e238dda35 100644 --- a/isis/tests/FunctionalTestsLorri2isis.cpp +++ b/isis/tests/FunctionalTestsLorri2isis.cpp @@ -58,8 +58,8 @@ TEST(Lorri2Isis, Lorri2IsisTestDefault) { // BandBin Group PvlGroup &bandbin = isisLabel->findGroup("BandBin", Pvl::Traverse); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin["Center"][0]), 600); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin["Width"][0]), 500); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin["Center"][0]), 600); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin["Width"][0]), 500); // Kernels Group PvlGroup &kernel = isisLabel->findGroup("Kernels", Pvl::Traverse); @@ -123,8 +123,8 @@ TEST(Lorri2Isis, Lorri2IsisTestRaw) { // BandBin Group PvlGroup &bandbin = isisLabel->findGroup("BandBin", Pvl::Traverse); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin["Center"][0]), 600); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin["Width"][0]), 500); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin["Center"][0]), 600); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin["Width"][0]), 500); // Kernels Group PvlGroup &kernel = isisLabel->findGroup("Kernels", Pvl::Traverse); diff --git a/isis/tests/FunctionalTestsLrowac2isis.cpp b/isis/tests/FunctionalTestsLrowac2isis.cpp index 00114382ed..89be6431ee 100644 --- a/isis/tests/FunctionalTestsLrowac2isis.cpp +++ b/isis/tests/FunctionalTestsLrowac2isis.cpp @@ -52,12 +52,12 @@ TEST(Lrowac2isisTests, FunctionalTestLrowac2isisDefault) { EXPECT_EQ(uvEvenInst["StartTime"][0], "2009-09-15T07:27:49.230000"); EXPECT_EQ(uvEvenInst["StopTime"][0], "2009-09-15T07:30:19.542000"); EXPECT_EQ(uvEvenInst["MissionPhaseName"][0], "COMMISSIONING"); - EXPECT_EQ(IString::ToDouble(uvEvenInst["BeginTemperatureFpa"][0]), -1.66529297828674); - EXPECT_EQ(IString::ToDouble(uvEvenInst["MiddleTemperatureFpa"][0]), -1.12489998340607); - EXPECT_EQ(IString::ToDouble(uvEvenInst["EndTemperatureFpa"][0]), -0.669131994247437); - EXPECT_EQ(IString::ToDouble(uvEvenInst["BeginTemperatureScs"][0]), 10.8307619094849); - EXPECT_EQ(IString::ToDouble(uvEvenInst["MiddleTemperatureScs"][0]), 10.914568901062); - EXPECT_EQ(IString::ToDouble(uvEvenInst["EndTemperatureScs"][0]), 10.9736194610596); + EXPECT_EQ(Isis::toDouble(uvEvenInst["BeginTemperatureFpa"][0]), -1.66529297828674); + EXPECT_EQ(Isis::toDouble(uvEvenInst["MiddleTemperatureFpa"][0]), -1.12489998340607); + EXPECT_EQ(Isis::toDouble(uvEvenInst["EndTemperatureFpa"][0]), -0.669131994247437); + EXPECT_EQ(Isis::toDouble(uvEvenInst["BeginTemperatureScs"][0]), 10.8307619094849); + EXPECT_EQ(Isis::toDouble(uvEvenInst["MiddleTemperatureScs"][0]), 10.914568901062); + EXPECT_EQ(Isis::toDouble(uvEvenInst["EndTemperatureScs"][0]), 10.9736194610596); EXPECT_EQ(uvEvenInst["Mode"][0], "0"); EXPECT_EQ(uvEvenInst["DataFlipped"][0], "No"); EXPECT_EQ(uvEvenInst["ColorOffset"][0], "0"); @@ -106,12 +106,12 @@ TEST(Lrowac2isisTests, FunctionalTestLrowac2isisDefault) { EXPECT_EQ(uvOddInst["StartTime"][0], "2009-09-15T07:27:49.230000"); EXPECT_EQ(uvOddInst["StopTime"][0], "2009-09-15T07:30:19.542000"); EXPECT_EQ(uvOddInst["MissionPhaseName"][0], "COMMISSIONING"); - EXPECT_EQ(IString::ToDouble(uvOddInst["BeginTemperatureFpa"][0]), -1.66529297828674); - EXPECT_EQ(IString::ToDouble(uvOddInst["MiddleTemperatureFpa"][0]), -1.12489998340607); - EXPECT_EQ(IString::ToDouble(uvOddInst["EndTemperatureFpa"][0]), -0.669131994247437); - EXPECT_EQ(IString::ToDouble(uvOddInst["BeginTemperatureScs"][0]), 10.8307619094849); - EXPECT_EQ(IString::ToDouble(uvOddInst["MiddleTemperatureScs"][0]), 10.914568901062); - EXPECT_EQ(IString::ToDouble(uvOddInst["EndTemperatureScs"][0]), 10.9736194610596); + EXPECT_EQ(Isis::toDouble(uvOddInst["BeginTemperatureFpa"][0]), -1.66529297828674); + EXPECT_EQ(Isis::toDouble(uvOddInst["MiddleTemperatureFpa"][0]), -1.12489998340607); + EXPECT_EQ(Isis::toDouble(uvOddInst["EndTemperatureFpa"][0]), -0.669131994247437); + EXPECT_EQ(Isis::toDouble(uvOddInst["BeginTemperatureScs"][0]), 10.8307619094849); + EXPECT_EQ(Isis::toDouble(uvOddInst["MiddleTemperatureScs"][0]), 10.914568901062); + EXPECT_EQ(Isis::toDouble(uvOddInst["EndTemperatureScs"][0]), 10.9736194610596); EXPECT_EQ(uvOddInst["Mode"][0], "0"); EXPECT_EQ(uvOddInst["DataFlipped"][0], "No"); EXPECT_EQ(uvOddInst["ColorOffset"][0], "0"); @@ -160,12 +160,12 @@ TEST(Lrowac2isisTests, FunctionalTestLrowac2isisDefault) { EXPECT_EQ(visEvenInst["StartTime"][0], "2009-09-15T07:27:49.230000"); EXPECT_EQ(visEvenInst["StopTime"][0], "2009-09-15T07:30:19.542000"); EXPECT_EQ(visEvenInst["MissionPhaseName"][0], "COMMISSIONING"); - EXPECT_EQ(IString::ToDouble(visEvenInst["BeginTemperatureFpa"][0]), -1.66529297828674); - EXPECT_EQ(IString::ToDouble(visEvenInst["MiddleTemperatureFpa"][0]), -1.12489998340607); - EXPECT_EQ(IString::ToDouble(visEvenInst["EndTemperatureFpa"][0]), -0.669131994247437); - EXPECT_EQ(IString::ToDouble(visEvenInst["BeginTemperatureScs"][0]), 10.8307619094849); - EXPECT_EQ(IString::ToDouble(visEvenInst["MiddleTemperatureScs"][0]), 10.914568901062); - EXPECT_EQ(IString::ToDouble(visEvenInst["EndTemperatureScs"][0]), 10.9736194610596); + EXPECT_EQ(Isis::toDouble(visEvenInst["BeginTemperatureFpa"][0]), -1.66529297828674); + EXPECT_EQ(Isis::toDouble(visEvenInst["MiddleTemperatureFpa"][0]), -1.12489998340607); + EXPECT_EQ(Isis::toDouble(visEvenInst["EndTemperatureFpa"][0]), -0.669131994247437); + EXPECT_EQ(Isis::toDouble(visEvenInst["BeginTemperatureScs"][0]), 10.8307619094849); + EXPECT_EQ(Isis::toDouble(visEvenInst["MiddleTemperatureScs"][0]), 10.914568901062); + EXPECT_EQ(Isis::toDouble(visEvenInst["EndTemperatureScs"][0]), 10.9736194610596); EXPECT_EQ(visEvenInst["Mode"][0], "0"); EXPECT_EQ(visEvenInst["DataFlipped"][0], "No"); EXPECT_EQ(visEvenInst["ColorOffset"][0], "0"); @@ -214,12 +214,12 @@ TEST(Lrowac2isisTests, FunctionalTestLrowac2isisDefault) { EXPECT_EQ(visOddInst["StartTime"][0], "2009-09-15T07:27:49.230000"); EXPECT_EQ(visOddInst["StopTime"][0], "2009-09-15T07:30:19.542000"); EXPECT_EQ(visOddInst["MissionPhaseName"][0], "COMMISSIONING"); - EXPECT_EQ(IString::ToDouble(visOddInst["BeginTemperatureFpa"][0]), -1.66529297828674); - EXPECT_EQ(IString::ToDouble(visOddInst["MiddleTemperatureFpa"][0]), -1.12489998340607); - EXPECT_EQ(IString::ToDouble(visOddInst["EndTemperatureFpa"][0]), -0.669131994247437); - EXPECT_EQ(IString::ToDouble(visOddInst["BeginTemperatureScs"][0]), 10.8307619094849); - EXPECT_EQ(IString::ToDouble(visOddInst["MiddleTemperatureScs"][0]), 10.914568901062); - EXPECT_EQ(IString::ToDouble(visOddInst["EndTemperatureScs"][0]), 10.9736194610596); + EXPECT_EQ(Isis::toDouble(visOddInst["BeginTemperatureFpa"][0]), -1.66529297828674); + EXPECT_EQ(Isis::toDouble(visOddInst["MiddleTemperatureFpa"][0]), -1.12489998340607); + EXPECT_EQ(Isis::toDouble(visOddInst["EndTemperatureFpa"][0]), -0.669131994247437); + EXPECT_EQ(Isis::toDouble(visOddInst["BeginTemperatureScs"][0]), 10.8307619094849); + EXPECT_EQ(Isis::toDouble(visOddInst["MiddleTemperatureScs"][0]), 10.914568901062); + EXPECT_EQ(Isis::toDouble(visOddInst["EndTemperatureScs"][0]), 10.9736194610596); EXPECT_EQ(visOddInst["Mode"][0], "0"); EXPECT_EQ(visOddInst["DataFlipped"][0], "No"); EXPECT_EQ(visOddInst["ColorOffset"][0], "0"); diff --git a/isis/tests/FunctionalTestsMimap2isis.cpp b/isis/tests/FunctionalTestsMimap2isis.cpp index ad89ea43f8..ca762b2cb9 100644 --- a/isis/tests/FunctionalTestsMimap2isis.cpp +++ b/isis/tests/FunctionalTestsMimap2isis.cpp @@ -39,8 +39,8 @@ TEST(FunctionalTestMimap2Isis, Default) { PvlGroup &pixels = isisLabel->findGroup("Pixels", Pvl::Traverse); EXPECT_PRED_FORMAT2(AssertStringsEqual, pixels.findKeyword("Type"), "SignedWord"); EXPECT_PRED_FORMAT2(AssertStringsEqual, pixels.findKeyword("ByteOrder"), "Lsb"); - EXPECT_DOUBLE_EQ(IString::ToDouble( pixels.findKeyword("Base")), 0.0); - EXPECT_DOUBLE_EQ(IString::ToDouble( pixels.findKeyword("Multiplier")), 2.0e-05); + EXPECT_DOUBLE_EQ(Isis::toDouble( pixels.findKeyword("Base")), 0.0); + EXPECT_DOUBLE_EQ(Isis::toDouble( pixels.findKeyword("Multiplier")), 2.0e-05); // Instrument Group PvlGroup &inst = isisLabel->findGroup("Instrument", Pvl::Traverse); @@ -93,79 +93,79 @@ TEST(FunctionalTestMimap2Isis, Default) { EXPECT_PRED_FORMAT2(AssertStringsEqual, archive.findKeyword("ImageUnit"), "ND"); for (int i = 0; i < 9; i++) { - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("MinForStatisticalEvaluation")[i]), 0) << "Error at index: " << i; - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("MaxForStatisticalEvaluation")[i]), 32767) << "Error at index: " << i; + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("MinForStatisticalEvaluation")[i]), 0) << "Error at index: " << i; + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("MaxForStatisticalEvaluation")[i]), 32767) << "Error at index: " << i; } - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneMaximumDn")[0]), 32268); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneMaximumDn")[1]), 32178); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneMaximumDn")[2]), 32562); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneMaximumDn")[3]), 31727); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneMaximumDn")[4]), 32684); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneMaximumDn")[5]), 32528); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneMaximumDn")[6]), 32179); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneMaximumDn")[7]), 32293); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneMaximumDn")[8]), 32433); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneMaximumDn")[0]), 32268); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneMaximumDn")[1]), 32178); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneMaximumDn")[2]), 32562); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneMaximumDn")[3]), 31727); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneMaximumDn")[4]), 32684); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneMaximumDn")[5]), 32528); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneMaximumDn")[6]), 32179); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneMaximumDn")[7]), 32293); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneMaximumDn")[8]), 32433); for (int i = 0; i < 7; i++) { - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneMinimumDn")[i]), 0) << "Error at index: " << i;; - } - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneMinimumDn")[8]), 1); - - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneAverageDn")[0]), 3096.5); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneAverageDn")[1]), 5582.3); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneAverageDn")[2]), 5993.3); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneAverageDn")[3]), 6101.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneAverageDn")[4]), 6480.5); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneAverageDn")[5]), 6425.4); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneAverageDn")[6]), 6767.4); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneAverageDn")[7]), 8075.3); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneAverageDn")[8]), 9526.2); - - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneStdevDn")[0]), 1232.1); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneStdevDn")[1]), 1933.4); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneStdevDn")[2]), 2080.3); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneStdevDn")[3]), 2053.8); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneStdevDn")[4]), 2138.1); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneStdevDn")[5]), 2049.9); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneStdevDn")[6]), 2110.4); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneStdevDn")[7]), 2367.1); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneStdevDn")[8]), 2629.7); - - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneModeDn")[0]), 2980); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneModeDn")[1]), 5635); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneModeDn")[2]), 3); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneModeDn")[3]), 6095); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneModeDn")[4]), 6324); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneModeDn")[5]), 0); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneModeDn")[6]), 0); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneModeDn")[7]), 7965); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneModeDn")[8]), 9305); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneMinimumDn")[i]), 0) << "Error at index: " << i;; + } + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneMinimumDn")[8]), 1); + + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneAverageDn")[0]), 3096.5); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneAverageDn")[1]), 5582.3); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneAverageDn")[2]), 5993.3); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneAverageDn")[3]), 6101.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneAverageDn")[4]), 6480.5); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneAverageDn")[5]), 6425.4); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneAverageDn")[6]), 6767.4); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneAverageDn")[7]), 8075.3); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneAverageDn")[8]), 9526.2); + + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneStdevDn")[0]), 1232.1); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneStdevDn")[1]), 1933.4); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneStdevDn")[2]), 2080.3); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneStdevDn")[3]), 2053.8); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneStdevDn")[4]), 2138.1); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneStdevDn")[5]), 2049.9); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneStdevDn")[6]), 2110.4); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneStdevDn")[7]), 2367.1); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneStdevDn")[8]), 2629.7); + + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneModeDn")[0]), 2980); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneModeDn")[1]), 5635); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneModeDn")[2]), 3); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneModeDn")[3]), 6095); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneModeDn")[4]), 6324); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneModeDn")[5]), 0); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneModeDn")[6]), 0); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneModeDn")[7]), 7965); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneModeDn")[8]), 9305); for (int i = 0; i < 9; i++) { - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("ShadowedAreaMinimum")[i]), 0) << "Error at index: " << i; - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("ShadowedAreaMaximum")[i]), 327) << "Error at index: " << i; + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("ShadowedAreaMinimum")[i]), 0) << "Error at index: " << i; + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("ShadowedAreaMaximum")[i]), 327) << "Error at index: " << i; } - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("ShadowedAreaPercentage")[0]), 2); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("ShadowedAreaPercentage")[1]), 2); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("ShadowedAreaPercentage")[2]), 2); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("ShadowedAreaPercentage")[3]), 2); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("ShadowedAreaPercentage")[4]), 1); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("ShadowedAreaPercentage")[5]), 3); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("ShadowedAreaPercentage")[6]), 2); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("ShadowedAreaPercentage")[7]), 1); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("ShadowedAreaPercentage")[8]), 1); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("ShadowedAreaPercentage")[0]), 2); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("ShadowedAreaPercentage")[1]), 2); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("ShadowedAreaPercentage")[2]), 2); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("ShadowedAreaPercentage")[3]), 2); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("ShadowedAreaPercentage")[4]), 1); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("ShadowedAreaPercentage")[5]), 3); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("ShadowedAreaPercentage")[6]), 2); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("ShadowedAreaPercentage")[7]), 1); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("ShadowedAreaPercentage")[8]), 1); EXPECT_PRED_FORMAT2(AssertStringsEqual, archive.findKeyword("InvalidType")[0], "SATURATION"); EXPECT_PRED_FORMAT2(AssertStringsEqual, archive.findKeyword("InvalidType")[1], "MINUS"); EXPECT_PRED_FORMAT2(AssertStringsEqual, archive.findKeyword("InvalidType")[2], "DUMMY_DEFECT"); EXPECT_PRED_FORMAT2(AssertStringsEqual, archive.findKeyword("InvalidType")[3], "OTHER"); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("InvalidValue")[0]), -20000); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("InvalidValue")[1]), -21000); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("InvalidValue")[2]), -22000); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("InvalidValue")[3]), -23000); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("InvalidValue")[0]), -20000); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("InvalidValue")[1]), -21000); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("InvalidValue")[2]), -22000); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("InvalidValue")[3]), -23000); EXPECT_PRED_FORMAT2(AssertStringsEqual, archive.findKeyword("InvalidPixels")[0], "(94, 365, 0, 0)"); EXPECT_PRED_FORMAT2(AssertStringsEqual, archive.findKeyword("InvalidPixels")[1], "(176, 370, 0, 0)"); @@ -177,10 +177,10 @@ TEST(FunctionalTestMimap2Isis, Default) { EXPECT_PRED_FORMAT2(AssertStringsEqual, archive.findKeyword("InvalidPixels")[7], "(162, 1245, 0, 0)"); EXPECT_PRED_FORMAT2(AssertStringsEqual, archive.findKeyword("InvalidPixels")[8], "(585, 952, 0, 0)"); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("OutOfImageBoundsValue")), -30000); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("OutOfImageBoundsValue")), -30000); for (int i = 0; i < 9; i++) { - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("OutOfImageBoundsPixel")[i]), 0) << "Error at index: " << i; + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("OutOfImageBoundsPixel")[i]), 0) << "Error at index: " << i; } EXPECT_PRED_FORMAT2(AssertStringsEqual, archive.findKeyword("StretchedFlag"), "FALSE"); @@ -212,19 +212,19 @@ TEST(FunctionalTestMimap2Isis, Default) { EXPECT_PRED_FORMAT2(AssertStringsEqual, archive.findKeyword("RadCnvCoef")[i], "(1.470593, 2.204781, 2.244315, 2.734361, 1.885889, 3.04924, 3.312096, 4.788256, 7.969085)") << "Error at index: " << i; } - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("RefCnvCoef")[0]), 0.002353311); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("RefCnvCoef")[1]), 0.002450451); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("RefCnvCoef")[2]), 0.003549924); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("RefCnvCoef")[3]), 0.003886012); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("RefCnvCoef")[4]), 0.004316842); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("RefCnvCoef")[5]), 0.004316842); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("RefCnvCoef")[6]), 0.004893535); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("RefCnvCoef")[7]), 0.007400877); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("RefCnvCoef")[8]), 0.01218292); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("RefCnvCoef")[0]), 0.002353311); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("RefCnvCoef")[1]), 0.002450451); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("RefCnvCoef")[2]), 0.003549924); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("RefCnvCoef")[3]), 0.003886012); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("RefCnvCoef")[4]), 0.004316842); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("RefCnvCoef")[5]), 0.004316842); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("RefCnvCoef")[6]), 0.004893535); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("RefCnvCoef")[7]), 0.007400877); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("RefCnvCoef")[8]), 0.01218292); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("StandardGeometry")[0]), 30.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("StandardGeometry")[1]), 0.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("StandardGeometry")[2]), 30.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("StandardGeometry")[0]), 30.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("StandardGeometry")[1]), 0.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("StandardGeometry")[2]), 30.0); EXPECT_PRED_FORMAT2(AssertStringsEqual, archive.findKeyword("PhotoCorrId"), "LISM ORIGINAL"); @@ -251,48 +251,48 @@ TEST(FunctionalTestMimap2Isis, Default) { EXPECT_PRED_FORMAT2(AssertStringsEqual, archive.findKeyword("MatchingMosaic"), "N/A"); for (int i = 0; i < 5; i++) { - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("L2aDeadPixelThreshold")[i]), 35) << "Error at index: " << i; - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("L2aSaturationThreshold")[i]), 1023) << "Error at index: " << i; - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("DarkValidMinimum")[i]), -3) << "Error at index: " << i; + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("L2aDeadPixelThreshold")[i]), 35) << "Error at index: " << i; + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("L2aSaturationThreshold")[i]), 1023) << "Error at index: " << i; + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("DarkValidMinimum")[i]), -3) << "Error at index: " << i; } for (int i = 5; i < 9; i++) { - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("L2aDeadPixelThreshold")[i]), 200) << "Error at index: " << i; - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("L2aSaturationThreshold")[i]), 4095) << "Error at index: " << i; - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("DarkValidMinimum")[i]), -10) << "Error at index: " << i; + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("L2aDeadPixelThreshold")[i]), 200) << "Error at index: " << i; + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("L2aSaturationThreshold")[i]), 4095) << "Error at index: " << i; + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("DarkValidMinimum")[i]), -10) << "Error at index: " << i; } - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("FtValidMinimum")), -2); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("RadianceSaturationThreshold")), 425.971); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("RefSaturationThreshold")), 0.65534); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("FtValidMinimum")), -2); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("RadianceSaturationThreshold")), 425.971); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("RefSaturationThreshold")), 0.65534); // BandBin Group PvlGroup &bandbin = isisLabel->findGroup("BandBin", Pvl::Traverse); for (int i = 0; i < 5; i++) { - EXPECT_PRED_FORMAT2(AssertStringsEqual, bandbin.findKeyword("FilterName")[i], "MV" + toString(i + 1)) << "Error at index: " << i; + EXPECT_PRED_FORMAT2(AssertStringsEqual, bandbin.findKeyword("FilterName")[i], "MV" + Isis::toString(i + 1)) << "Error at index: " << i; } for (int i = 5; i < 9; i++) { - EXPECT_PRED_FORMAT2(AssertStringsEqual, bandbin.findKeyword("FilterName")[i], "MN" + toString(i - 4)) << "Error at index: " << i; - } - - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Center")[0]), 414.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Center")[1]), 749.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Center")[2]), 901.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Center")[3]), 950.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Center")[4]), 1001.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Center")[5]), 1000.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Center")[6]), 1049.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Center")[7]), 1248.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Center")[8]), 1548.0); - - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Width")[0]), 20.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Width")[1]), 12.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Width")[2]), 21.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Width")[3]), 30.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Width")[4]), 42.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Width")[5]), 27.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Width")[6]), 28.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Width")[7]), 33.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Width")[8]), 48.0); + EXPECT_PRED_FORMAT2(AssertStringsEqual, bandbin.findKeyword("FilterName")[i], "MN" + Isis::toString(i - 4)) << "Error at index: " << i; + } + + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Center")[0]), 414.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Center")[1]), 749.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Center")[2]), 901.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Center")[3]), 950.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Center")[4]), 1001.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Center")[5]), 1000.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Center")[6]), 1049.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Center")[7]), 1248.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Center")[8]), 1548.0); + + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Width")[0]), 20.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Width")[1]), 12.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Width")[2]), 21.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Width")[3]), 30.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Width")[4]), 42.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Width")[5]), 27.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Width")[6]), 28.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Width")[7]), 33.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Width")[8]), 48.0); EXPECT_PRED_FORMAT2(AssertStringsEqual, bandbin.findKeyword("BaseBand"), "MV5"); @@ -351,84 +351,84 @@ TEST(FunctionalTestMimap2Isis, L3C) { EXPECT_PRED_FORMAT2(AssertStringsEqual, archive.findKeyword("ImageUnit"), "ND"); for (int i = 0; i < 9; i++) { - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("MinForStatisticalEvaluation")[i]), 0) << "Error at index: " << i; - EXPECT_DOUBLE_EQ(IString::ToDouble( archive.findKeyword("MaxForStatisticalEvaluation")[i]), 32767) << "Error at index: " << i; - } - - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneMaximumDn")[0]), 20866); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneMaximumDn")[1]), 31905); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneMaximumDn")[2]), 32710); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneMaximumDn")[3]), 32352); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneMaximumDn")[4]), 32589); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneMaximumDn")[5]), 32644); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneMaximumDn")[6]), 32670); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneMaximumDn")[7]), 32720); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneMaximumDn")[8]), 32673); - - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneMinimumDn")[0]), 6); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneMinimumDn")[1]), 14); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneMinimumDn")[2]), 12); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneMinimumDn")[3]), 18); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneMinimumDn")[4]), 23); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneMinimumDn")[5]), 0); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneMinimumDn")[6]), 0); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneMinimumDn")[7]), 0); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneMinimumDn")[8]), 11); - - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneAverageDn")[0]), 5313.7); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneAverageDn")[1]), 9108.2); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneAverageDn")[2]), 9735.2); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneAverageDn")[3]), 9950.5); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneAverageDn")[4]), 10454.1); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneAverageDn")[5]), 9948.5); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneAverageDn")[6]), 10312.5); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneAverageDn")[7]), 11676.5); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneAverageDn")[8]), 13360.7); - - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneStdevDn")[0]), 2756.2); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneStdevDn")[1]), 4579.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneStdevDn")[2]), 5173.3); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneStdevDn")[3]), 4877.5); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneStdevDn")[4]), 5046.1); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneStdevDn")[5]), 5216.4); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneStdevDn")[6]), 5294.5); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneStdevDn")[7]), 5561.1); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneStdevDn")[8]), 5645.0); - - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneModeDn")[0]), 4834); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneModeDn")[1]), 8614); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneModeDn")[2]), 8969); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneModeDn")[3]), 9179); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneModeDn")[4]), 9650); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneModeDn")[5]), 0); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneModeDn")[6]), 0); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneModeDn")[7]), 0); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneModeDn")[8]), 13310); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("MinForStatisticalEvaluation")[i]), 0) << "Error at index: " << i; + EXPECT_DOUBLE_EQ(Isis::toDouble( archive.findKeyword("MaxForStatisticalEvaluation")[i]), 32767) << "Error at index: " << i; + } + + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneMaximumDn")[0]), 20866); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneMaximumDn")[1]), 31905); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneMaximumDn")[2]), 32710); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneMaximumDn")[3]), 32352); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneMaximumDn")[4]), 32589); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneMaximumDn")[5]), 32644); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneMaximumDn")[6]), 32670); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneMaximumDn")[7]), 32720); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneMaximumDn")[8]), 32673); + + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneMinimumDn")[0]), 6); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneMinimumDn")[1]), 14); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneMinimumDn")[2]), 12); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneMinimumDn")[3]), 18); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneMinimumDn")[4]), 23); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneMinimumDn")[5]), 0); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneMinimumDn")[6]), 0); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneMinimumDn")[7]), 0); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneMinimumDn")[8]), 11); + + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneAverageDn")[0]), 5313.7); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneAverageDn")[1]), 9108.2); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneAverageDn")[2]), 9735.2); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneAverageDn")[3]), 9950.5); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneAverageDn")[4]), 10454.1); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneAverageDn")[5]), 9948.5); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneAverageDn")[6]), 10312.5); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneAverageDn")[7]), 11676.5); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneAverageDn")[8]), 13360.7); + + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneStdevDn")[0]), 2756.2); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneStdevDn")[1]), 4579.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneStdevDn")[2]), 5173.3); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneStdevDn")[3]), 4877.5); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneStdevDn")[4]), 5046.1); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneStdevDn")[5]), 5216.4); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneStdevDn")[6]), 5294.5); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneStdevDn")[7]), 5561.1); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneStdevDn")[8]), 5645.0); + + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneModeDn")[0]), 4834); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneModeDn")[1]), 8614); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneModeDn")[2]), 8969); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneModeDn")[3]), 9179); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneModeDn")[4]), 9650); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneModeDn")[5]), 0); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneModeDn")[6]), 0); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneModeDn")[7]), 0); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneModeDn")[8]), 13310); for (int i = 0; i < 9; i++) { - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("ShadowedAreaMinimum")[i]), 0) << "Error at index: " << i; - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("ShadowedAreaMaximum")[i]), 500) << "Error at index: " << i; + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("ShadowedAreaMinimum")[i]), 0) << "Error at index: " << i; + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("ShadowedAreaMaximum")[i]), 500) << "Error at index: " << i; } - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("ShadowedAreaPercentage")[0]), 1); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("ShadowedAreaPercentage")[1]), 0); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("ShadowedAreaPercentage")[2]), 1); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("ShadowedAreaPercentage")[3]), 0); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("ShadowedAreaPercentage")[4]), 0); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("ShadowedAreaPercentage")[5]), 6); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("ShadowedAreaPercentage")[6]), 5); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("ShadowedAreaPercentage")[7]), 2); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("ShadowedAreaPercentage")[8]), 0); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("ShadowedAreaPercentage")[0]), 1); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("ShadowedAreaPercentage")[1]), 0); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("ShadowedAreaPercentage")[2]), 1); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("ShadowedAreaPercentage")[3]), 0); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("ShadowedAreaPercentage")[4]), 0); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("ShadowedAreaPercentage")[5]), 6); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("ShadowedAreaPercentage")[6]), 5); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("ShadowedAreaPercentage")[7]), 2); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("ShadowedAreaPercentage")[8]), 0); EXPECT_PRED_FORMAT2(AssertStringsEqual, archive.findKeyword("InvalidType")[0], "SATURATION"); EXPECT_PRED_FORMAT2(AssertStringsEqual, archive.findKeyword("InvalidType")[1], "MINUS"); EXPECT_PRED_FORMAT2(AssertStringsEqual, archive.findKeyword("InvalidType")[2], "DUMMY_DEFECT"); EXPECT_PRED_FORMAT2(AssertStringsEqual, archive.findKeyword("InvalidType")[3], "OTHER"); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("InvalidValue")[0]), -20000); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("InvalidValue")[1]), -21000); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("InvalidValue")[2]), -22000); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("InvalidValue")[3]), -23000); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("InvalidValue")[0]), -20000); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("InvalidValue")[1]), -21000); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("InvalidValue")[2]), -22000); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("InvalidValue")[3]), -23000); EXPECT_PRED_FORMAT2(AssertStringsEqual, archive.findKeyword("InvalidPixels")[0], "(100, 0, 0, 7)"); EXPECT_PRED_FORMAT2(AssertStringsEqual, archive.findKeyword("InvalidPixels")[1], "(2956, 0, 0, 622)"); @@ -440,10 +440,10 @@ TEST(FunctionalTestMimap2Isis, L3C) { EXPECT_PRED_FORMAT2(AssertStringsEqual, archive.findKeyword("InvalidPixels")[7], "(33821, 135, 0, 112625)"); EXPECT_PRED_FORMAT2(AssertStringsEqual, archive.findKeyword("InvalidPixels")[8], "(51843, 162, 0, 209314)"); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("OutOfImageBoundsValue")), -30000); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("OutOfImageBoundsValue")), -30000); for (int i = 0; i < 9; i++) { - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("OutOfImageBoundsPixel")[i]), 1642126) << "Error at index: " << i; + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("OutOfImageBoundsPixel")[i]), 1642126) << "Error at index: " << i; } EXPECT_PRED_FORMAT2(AssertStringsEqual, archive.findKeyword("DarkFileName")[0], "MIN_DRK_01313_01398_L___003.csv"); @@ -456,30 +456,30 @@ TEST(FunctionalTestMimap2Isis, L3C) { EXPECT_PRED_FORMAT2(AssertStringsEqual, archive.findKeyword("NonlinFileName")[0], "MIN_NLT_PRFLT_N___v01.csv"); EXPECT_PRED_FORMAT2(AssertStringsEqual, archive.findKeyword("NonlinFileName")[1], "MIV_NLT_PRFLT_N___v01.csv"); - EXPECT_NEAR(IString::ToDouble(archive.findKeyword("RadCnvCoef")[0]), 1.470593, .000001); - EXPECT_NEAR(IString::ToDouble(archive.findKeyword("RadCnvCoef")[1]), 2.204781, .000001); - EXPECT_NEAR(IString::ToDouble(archive.findKeyword("RadCnvCoef")[2]), 2.244315, .000001); - EXPECT_NEAR(IString::ToDouble(archive.findKeyword("RadCnvCoef")[3]), 2.734361, .000001); - EXPECT_NEAR(IString::ToDouble(archive.findKeyword("RadCnvCoef")[4]), 1.885889, .000001); - EXPECT_NEAR(IString::ToDouble(archive.findKeyword("RadCnvCoef")[5]), 3.04924, .000001); - EXPECT_NEAR(IString::ToDouble(archive.findKeyword("RadCnvCoef")[6]), 3.312096, .000001); - EXPECT_NEAR(IString::ToDouble(archive.findKeyword("RadCnvCoef")[7]), 4.788256, .000001); - EXPECT_NEAR(IString::ToDouble(archive.findKeyword("RadCnvCoef")[8]), 7.969085, .000001); - - - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("RefCnvCoef")[0]), 0.002353311); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("RefCnvCoef")[1]), 0.002450451); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("RefCnvCoef")[2]), 0.003549924); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("RefCnvCoef")[3]), 0.003886012); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("RefCnvCoef")[4]), 0.004316842); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("RefCnvCoef")[5]), 0.004316842); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("RefCnvCoef")[6]), 0.004893535); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("RefCnvCoef")[7]), 0.007400877); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("RefCnvCoef")[8]), 0.01218292); - - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("StandardGeometry")[0]), 30.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("StandardGeometry")[1]), 0.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("StandardGeometry")[2]), 30.0); + EXPECT_NEAR(Isis::toDouble(archive.findKeyword("RadCnvCoef")[0]), 1.470593, .000001); + EXPECT_NEAR(Isis::toDouble(archive.findKeyword("RadCnvCoef")[1]), 2.204781, .000001); + EXPECT_NEAR(Isis::toDouble(archive.findKeyword("RadCnvCoef")[2]), 2.244315, .000001); + EXPECT_NEAR(Isis::toDouble(archive.findKeyword("RadCnvCoef")[3]), 2.734361, .000001); + EXPECT_NEAR(Isis::toDouble(archive.findKeyword("RadCnvCoef")[4]), 1.885889, .000001); + EXPECT_NEAR(Isis::toDouble(archive.findKeyword("RadCnvCoef")[5]), 3.04924, .000001); + EXPECT_NEAR(Isis::toDouble(archive.findKeyword("RadCnvCoef")[6]), 3.312096, .000001); + EXPECT_NEAR(Isis::toDouble(archive.findKeyword("RadCnvCoef")[7]), 4.788256, .000001); + EXPECT_NEAR(Isis::toDouble(archive.findKeyword("RadCnvCoef")[8]), 7.969085, .000001); + + + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("RefCnvCoef")[0]), 0.002353311); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("RefCnvCoef")[1]), 0.002450451); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("RefCnvCoef")[2]), 0.003549924); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("RefCnvCoef")[3]), 0.003886012); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("RefCnvCoef")[4]), 0.004316842); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("RefCnvCoef")[5]), 0.004316842); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("RefCnvCoef")[6]), 0.004893535); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("RefCnvCoef")[7]), 0.007400877); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("RefCnvCoef")[8]), 0.01218292); + + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("StandardGeometry")[0]), 30.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("StandardGeometry")[1]), 0.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("StandardGeometry")[2]), 30.0); EXPECT_PRED_FORMAT2(AssertStringsEqual, archive.findKeyword("PhotoCorrId"), "LISM ORIGINAL"); @@ -496,48 +496,48 @@ TEST(FunctionalTestMimap2Isis, L3C) { EXPECT_PRED_FORMAT2(AssertStringsEqual, archive.findKeyword("ResamplingMethod"), "Bi-Linear"); for (int i = 0; i < 5; i++) { - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("L2aDeadPixelThreshold")[i]), 35) << "Error at index: " << i; - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("L2aSaturationThreshold")[i]), 1023) << "Error at index: " << i; - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("DarkValidMinimum")[i]), -3) << "Error at index: " << i; + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("L2aDeadPixelThreshold")[i]), 35) << "Error at index: " << i; + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("L2aSaturationThreshold")[i]), 1023) << "Error at index: " << i; + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("DarkValidMinimum")[i]), -3) << "Error at index: " << i; } for (int i = 5; i < 9; i++) { - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("L2aDeadPixelThreshold")[i]), 200) << "Error at index: " << i; - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("L2aSaturationThreshold")[i]), 4095) << "Error at index: " << i; - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("DarkValidMinimum")[i]), -10) << "Error at index: " << i; + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("L2aDeadPixelThreshold")[i]), 200) << "Error at index: " << i; + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("L2aSaturationThreshold")[i]), 4095) << "Error at index: " << i; + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("DarkValidMinimum")[i]), -10) << "Error at index: " << i; } - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("FtValidMinimum")), -2); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("RadianceSaturationThreshold")), 425.971); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("RefSaturationThreshold")), 0.65534); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("FtValidMinimum")), -2); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("RadianceSaturationThreshold")), 425.971); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("RefSaturationThreshold")), 0.65534); // BandBin Group PvlGroup &bandbin = isisLabel->findGroup("BandBin", Pvl::Traverse); for (int i = 0; i < 5; i++) { - EXPECT_PRED_FORMAT2(AssertStringsEqual, bandbin.findKeyword("FilterName")[i], "MV" + toString(i + 1)) << "Error at index: " << i; + EXPECT_PRED_FORMAT2(AssertStringsEqual, bandbin.findKeyword("FilterName")[i], "MV" + Isis::toString(i + 1)) << "Error at index: " << i; } for (int i = 5; i < 9; i++) { - EXPECT_PRED_FORMAT2(AssertStringsEqual, bandbin.findKeyword("FilterName")[i], "MN" + toString(i - 4)) << "Error at index: " << i; - } - - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Center")[0]), 414.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Center")[1]), 749.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Center")[2]), 901.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Center")[3]), 950.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Center")[4]), 1001.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Center")[5]), 1000.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Center")[6]), 1049.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Center")[7]), 1248.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Center")[8]), 1548.0); - - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Width")[0]), 20.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Width")[1]), 12.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Width")[2]), 21.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Width")[3]), 30.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Width")[4]), 42.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Width")[5]), 27.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Width")[6]), 28.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Width")[7]), 33.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Width")[8]), 48.0); + EXPECT_PRED_FORMAT2(AssertStringsEqual, bandbin.findKeyword("FilterName")[i], "MN" + Isis::toString(i - 4)) << "Error at index: " << i; + } + + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Center")[0]), 414.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Center")[1]), 749.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Center")[2]), 901.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Center")[3]), 950.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Center")[4]), 1001.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Center")[5]), 1000.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Center")[6]), 1049.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Center")[7]), 1248.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Center")[8]), 1548.0); + + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Width")[0]), 20.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Width")[1]), 12.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Width")[2]), 21.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Width")[3]), 30.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Width")[4]), 42.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Width")[5]), 27.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Width")[6]), 28.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Width")[7]), 33.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Width")[8]), 48.0); EXPECT_PRED_FORMAT2(AssertStringsEqual, bandbin.findKeyword("BaseBand"), "MV5"); } @@ -578,84 +578,84 @@ TEST(FunctionalTestMimap2Isis, MAPv3) { EXPECT_PRED_FORMAT2(AssertStringsEqual, archive.findKeyword("ImageUnit"), "ND"); for (int i = 0; i < 9; i++) { - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("MinForStatisticalEvaluation")[i]), 0) << "Error at index: " << i; - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("MaxForStatisticalEvaluation")[i]), 32767) << "Error at index: " << i; - } - - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneMaximumDn")[0]), 11914); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneMaximumDn")[1]), 18693); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneMaximumDn")[2]), 22004); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneMaximumDn")[3]), 21392); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneMaximumDn")[4]), 22057); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneMaximumDn")[5]), 19521); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneMaximumDn")[6]), 20790); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneMaximumDn")[7]), 22610); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneMaximumDn")[8]), 27149); - - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneMinimumDn")[0]), 2336); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneMinimumDn")[1]), 4236); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneMinimumDn")[2]), 4020); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneMinimumDn")[3]), 4643); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneMinimumDn")[4]), 4957); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneMinimumDn")[5]), 5559); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneMinimumDn")[6]), 5804); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneMinimumDn")[7]), 6892); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneMinimumDn")[8]), 8121); - - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneAverageDn")[0]), 3739.9); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneAverageDn")[1]), 6790.8); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneAverageDn")[2]), 7729.2); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneAverageDn")[3]), 7954.9); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneAverageDn")[4]), 8312.9); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneAverageDn")[5]), 8080.9); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneAverageDn")[6]), 8416.3); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneAverageDn")[7]), 9692.3); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneAverageDn")[8]), 11512.4); - - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneStdevDn")[0]), 528.9); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneStdevDn")[1]), 785.4); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneStdevDn")[2]), 860.7); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneStdevDn")[3]), 826.7); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneStdevDn")[4]), 837.4); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneStdevDn")[5]), 798.7); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneStdevDn")[6]), 837.1); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneStdevDn")[7]), 882.8); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneStdevDn")[8]), 1005.1); - - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneModeDn")[0]), 3495); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneModeDn")[1]), 6483); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneModeDn")[2]), 7484); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneModeDn")[3]), 7645); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneModeDn")[4]), 8086); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneModeDn")[5]), 7789); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneModeDn")[6]), 8103); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneModeDn")[7]), 9429); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("SceneModeDn")[8]), 11274); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("MinForStatisticalEvaluation")[i]), 0) << "Error at index: " << i; + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("MaxForStatisticalEvaluation")[i]), 32767) << "Error at index: " << i; + } + + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneMaximumDn")[0]), 11914); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneMaximumDn")[1]), 18693); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneMaximumDn")[2]), 22004); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneMaximumDn")[3]), 21392); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneMaximumDn")[4]), 22057); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneMaximumDn")[5]), 19521); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneMaximumDn")[6]), 20790); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneMaximumDn")[7]), 22610); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneMaximumDn")[8]), 27149); + + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneMinimumDn")[0]), 2336); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneMinimumDn")[1]), 4236); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneMinimumDn")[2]), 4020); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneMinimumDn")[3]), 4643); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneMinimumDn")[4]), 4957); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneMinimumDn")[5]), 5559); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneMinimumDn")[6]), 5804); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneMinimumDn")[7]), 6892); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneMinimumDn")[8]), 8121); + + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneAverageDn")[0]), 3739.9); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneAverageDn")[1]), 6790.8); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneAverageDn")[2]), 7729.2); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneAverageDn")[3]), 7954.9); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneAverageDn")[4]), 8312.9); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneAverageDn")[5]), 8080.9); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneAverageDn")[6]), 8416.3); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneAverageDn")[7]), 9692.3); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneAverageDn")[8]), 11512.4); + + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneStdevDn")[0]), 528.9); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneStdevDn")[1]), 785.4); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneStdevDn")[2]), 860.7); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneStdevDn")[3]), 826.7); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneStdevDn")[4]), 837.4); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneStdevDn")[5]), 798.7); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneStdevDn")[6]), 837.1); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneStdevDn")[7]), 882.8); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneStdevDn")[8]), 1005.1); + + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneModeDn")[0]), 3495); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneModeDn")[1]), 6483); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneModeDn")[2]), 7484); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneModeDn")[3]), 7645); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneModeDn")[4]), 8086); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneModeDn")[5]), 7789); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneModeDn")[6]), 8103); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneModeDn")[7]), 9429); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("SceneModeDn")[8]), 11274); for (int i = 0; i < 9; i++) { - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("ShadowedAreaMinimum")[i]), 0) << "Error at index: " << i; - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("ShadowedAreaMaximum")[i]), 500) << "Error at index: " << i; + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("ShadowedAreaMinimum")[i]), 0) << "Error at index: " << i; + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("ShadowedAreaMaximum")[i]), 500) << "Error at index: " << i; } - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("ShadowedAreaPercentage")[0]), 0); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("ShadowedAreaPercentage")[1]), 0); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("ShadowedAreaPercentage")[2]), 0); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("ShadowedAreaPercentage")[3]), 0); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("ShadowedAreaPercentage")[4]), 0); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("ShadowedAreaPercentage")[5]), 0); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("ShadowedAreaPercentage")[6]), 0); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("ShadowedAreaPercentage")[7]), 0); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("ShadowedAreaPercentage")[8]), 0); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("ShadowedAreaPercentage")[0]), 0); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("ShadowedAreaPercentage")[1]), 0); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("ShadowedAreaPercentage")[2]), 0); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("ShadowedAreaPercentage")[3]), 0); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("ShadowedAreaPercentage")[4]), 0); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("ShadowedAreaPercentage")[5]), 0); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("ShadowedAreaPercentage")[6]), 0); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("ShadowedAreaPercentage")[7]), 0); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("ShadowedAreaPercentage")[8]), 0); EXPECT_PRED_FORMAT2(AssertStringsEqual, archive.findKeyword("InvalidType")[0], "SATURATION"); EXPECT_PRED_FORMAT2(AssertStringsEqual, archive.findKeyword("InvalidType")[1], "MINUS"); EXPECT_PRED_FORMAT2(AssertStringsEqual, archive.findKeyword("InvalidType")[2], "DUMMY_DEFECT"); EXPECT_PRED_FORMAT2(AssertStringsEqual, archive.findKeyword("InvalidType")[3], "OTHER"); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("InvalidValue")[0]), -20000); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("InvalidValue")[1]), -21000); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("InvalidValue")[2]), -22000); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("InvalidValue")[3]), -23000); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("InvalidValue")[0]), -20000); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("InvalidValue")[1]), -21000); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("InvalidValue")[2]), -22000); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("InvalidValue")[3]), -23000); EXPECT_PRED_FORMAT2(AssertStringsEqual, archive.findKeyword("InvalidPixels")[0], "(0, 0, 0, 0)"); EXPECT_PRED_FORMAT2(AssertStringsEqual, archive.findKeyword("InvalidPixels")[1], "(0, 0, 0, 0)"); @@ -667,10 +667,10 @@ TEST(FunctionalTestMimap2Isis, MAPv3) { EXPECT_PRED_FORMAT2(AssertStringsEqual, archive.findKeyword("InvalidPixels")[7], "(0, 0, 0, 0)"); EXPECT_PRED_FORMAT2(AssertStringsEqual, archive.findKeyword("InvalidPixels")[8], "(0, 0, 0, 0)"); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("OutOfImageBoundsValue")), -30000); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("OutOfImageBoundsValue")), -30000); for (int i = 0; i < 9; i++) { - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("OutOfImageBoundsPixel")[i]), 0) << "Error at index: " << i; + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("OutOfImageBoundsPixel")[i]), 0) << "Error at index: " << i; } EXPECT_PRED_FORMAT2(AssertStringsEqual, archive.findKeyword("DarkFileName")[0], "MIV_DRK_04375_04723_S___002.csv"); @@ -683,30 +683,30 @@ TEST(FunctionalTestMimap2Isis, MAPv3) { EXPECT_PRED_FORMAT2(AssertStringsEqual, archive.findKeyword("NonlinFileName")[0], "MIV_NLT_PRFLT_N___v01.csv"); EXPECT_PRED_FORMAT2(AssertStringsEqual, archive.findKeyword("NonlinFileName")[1], "MIN_NLT_PRFLT_N___v01.csv"); - EXPECT_NEAR(IString::ToDouble(archive.findKeyword("RadCnvCoef")[0]), 1.470593, .000001); - EXPECT_NEAR(IString::ToDouble(archive.findKeyword("RadCnvCoef")[1]), 2.204781, .000001); - EXPECT_NEAR(IString::ToDouble(archive.findKeyword("RadCnvCoef")[2]), 2.244315, .000001); - EXPECT_NEAR(IString::ToDouble(archive.findKeyword("RadCnvCoef")[3]), 2.734361, .000001); - EXPECT_NEAR(IString::ToDouble(archive.findKeyword("RadCnvCoef")[4]), 1.885889, .000001); - EXPECT_NEAR(IString::ToDouble(archive.findKeyword("RadCnvCoef")[5]), 3.04924, .000001); - EXPECT_NEAR(IString::ToDouble(archive.findKeyword("RadCnvCoef")[6]), 3.312096, .000001); - EXPECT_NEAR(IString::ToDouble(archive.findKeyword("RadCnvCoef")[7]), 4.788256, .000001); - EXPECT_NEAR(IString::ToDouble(archive.findKeyword("RadCnvCoef")[8]), 7.969085, .000001); - - - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("RefCnvCoef")[0]), 0.002353311); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("RefCnvCoef")[1]), 0.002450451); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("RefCnvCoef")[2]), 0.003549924); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("RefCnvCoef")[3]), 0.003886012); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("RefCnvCoef")[4]), 0.004316842); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("RefCnvCoef")[5]), 0.004316842); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("RefCnvCoef")[6]), 0.004893535); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("RefCnvCoef")[7]), 0.007400877); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("RefCnvCoef")[8]), 0.01218292); - - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("StandardGeometry")[0]), 30.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("StandardGeometry")[1]), 0.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("StandardGeometry")[2]), 30.0); + EXPECT_NEAR(Isis::toDouble(archive.findKeyword("RadCnvCoef")[0]), 1.470593, .000001); + EXPECT_NEAR(Isis::toDouble(archive.findKeyword("RadCnvCoef")[1]), 2.204781, .000001); + EXPECT_NEAR(Isis::toDouble(archive.findKeyword("RadCnvCoef")[2]), 2.244315, .000001); + EXPECT_NEAR(Isis::toDouble(archive.findKeyword("RadCnvCoef")[3]), 2.734361, .000001); + EXPECT_NEAR(Isis::toDouble(archive.findKeyword("RadCnvCoef")[4]), 1.885889, .000001); + EXPECT_NEAR(Isis::toDouble(archive.findKeyword("RadCnvCoef")[5]), 3.04924, .000001); + EXPECT_NEAR(Isis::toDouble(archive.findKeyword("RadCnvCoef")[6]), 3.312096, .000001); + EXPECT_NEAR(Isis::toDouble(archive.findKeyword("RadCnvCoef")[7]), 4.788256, .000001); + EXPECT_NEAR(Isis::toDouble(archive.findKeyword("RadCnvCoef")[8]), 7.969085, .000001); + + + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("RefCnvCoef")[0]), 0.002353311); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("RefCnvCoef")[1]), 0.002450451); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("RefCnvCoef")[2]), 0.003549924); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("RefCnvCoef")[3]), 0.003886012); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("RefCnvCoef")[4]), 0.004316842); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("RefCnvCoef")[5]), 0.004316842); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("RefCnvCoef")[6]), 0.004893535); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("RefCnvCoef")[7]), 0.007400877); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("RefCnvCoef")[8]), 0.01218292); + + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("StandardGeometry")[0]), 30.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("StandardGeometry")[1]), 0.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("StandardGeometry")[2]), 30.0); EXPECT_PRED_FORMAT2(AssertStringsEqual, archive.findKeyword("PhotoCorrId"), "LISM ORIGINAL"); @@ -723,48 +723,48 @@ TEST(FunctionalTestMimap2Isis, MAPv3) { EXPECT_PRED_FORMAT2(AssertStringsEqual, archive.findKeyword("ResamplingMethod"), "Bi-Linear"); for (int i = 0; i < 5; i++) { - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("L2aDeadPixelThreshold")[i]), 35) << "Error at index: " << i; - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("L2aSaturationThreshold")[i]), 1023) << "Error at index: " << i; - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("DarkValidMinimum")[i]), -3) << "Error at index: " << i; + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("L2aDeadPixelThreshold")[i]), 35) << "Error at index: " << i; + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("L2aSaturationThreshold")[i]), 1023) << "Error at index: " << i; + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("DarkValidMinimum")[i]), -3) << "Error at index: " << i; } for (int i = 5; i < 9; i++) { - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("L2aDeadPixelThreshold")[i]), 200) << "Error at index: " << i; - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("L2aSaturationThreshold")[i]), 4095) << "Error at index: " << i; - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("DarkValidMinimum")[i]), -10) << "Error at index: " << i; + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("L2aDeadPixelThreshold")[i]), 200) << "Error at index: " << i; + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("L2aSaturationThreshold")[i]), 4095) << "Error at index: " << i; + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("DarkValidMinimum")[i]), -10) << "Error at index: " << i; } - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("FtValidMinimum")), -2); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("RadianceSaturationThreshold")), 425.971); - EXPECT_DOUBLE_EQ(IString::ToDouble(archive.findKeyword("RefSaturationThreshold")), 0.65534); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("FtValidMinimum")), -2); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("RadianceSaturationThreshold")), 425.971); + EXPECT_DOUBLE_EQ(Isis::toDouble(archive.findKeyword("RefSaturationThreshold")), 0.65534); // BandBin Group PvlGroup &bandbin = isisLabel->findGroup("BandBin", Pvl::Traverse); for (int i = 0; i < 5; i++) { - EXPECT_PRED_FORMAT2(AssertStringsEqual, bandbin.findKeyword("FilterName")[i], "MV" + toString(i + 1)) << "Error at index: " << i; + EXPECT_PRED_FORMAT2(AssertStringsEqual, bandbin.findKeyword("FilterName")[i], "MV" + Isis::toString(i + 1)) << "Error at index: " << i; } for (int i = 5; i < 9; i++) { - EXPECT_PRED_FORMAT2(AssertStringsEqual, bandbin.findKeyword("FilterName")[i], "MN" + toString(i - 4)) << "Error at index: " << i; - } - - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Center")[0]), 414.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Center")[1]), 749.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Center")[2]), 901.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Center")[3]), 950.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Center")[4]), 1001.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Center")[5]), 1000.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Center")[6]), 1049.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Center")[7]), 1248.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Center")[8]), 1548.0); - - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Width")[0]), 20.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Width")[1]), 12.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Width")[2]), 21.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Width")[3]), 30.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Width")[4]), 42.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Width")[5]), 27.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Width")[6]), 28.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Width")[7]), 33.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandbin.findKeyword("Width")[8]), 48.0); + EXPECT_PRED_FORMAT2(AssertStringsEqual, bandbin.findKeyword("FilterName")[i], "MN" + Isis::toString(i - 4)) << "Error at index: " << i; + } + + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Center")[0]), 414.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Center")[1]), 749.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Center")[2]), 901.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Center")[3]), 950.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Center")[4]), 1001.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Center")[5]), 1000.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Center")[6]), 1049.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Center")[7]), 1248.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Center")[8]), 1548.0); + + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Width")[0]), 20.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Width")[1]), 12.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Width")[2]), 21.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Width")[3]), 30.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Width")[4]), 42.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Width")[5]), 27.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Width")[6]), 28.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Width")[7]), 33.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandbin.findKeyword("Width")[8]), 48.0); EXPECT_PRED_FORMAT2(AssertStringsEqual, bandbin.findKeyword("BaseBand"), "MV5"); } diff --git a/isis/tests/FunctionalTestsPds2isis.cpp b/isis/tests/FunctionalTestsPds2isis.cpp index 7475986846..0a360e7f01 100644 --- a/isis/tests/FunctionalTestsPds2isis.cpp +++ b/isis/tests/FunctionalTestsPds2isis.cpp @@ -37,8 +37,8 @@ TEST(Pds2Isis, Pds2isisTestDefault) { PvlGroup pixels = outLabel->findGroup("Pixels", Pvl::Traverse); ASSERT_EQ(pixels["Type"][0], "UnsignedByte"); ASSERT_EQ(pixels["ByteOrder"][0], "Lsb"); - ASSERT_EQ(IString::ToDouble(pixels["Base"]), 0.0); - ASSERT_EQ(IString::ToDouble(pixels["Multiplier"]), 1.0); + ASSERT_EQ(Isis::toDouble(pixels["Base"]), 0.0); + ASSERT_EQ(Isis::toDouble(pixels["Multiplier"]), 1.0); PvlGroup archive = outLabel->findGroup("Archive", Pvl::Traverse); ASSERT_EQ(archive["DataSetId"][0], "MGS-M-MOC-NA/WA-2-DSDP-L0-V1.0"); @@ -83,59 +83,59 @@ TEST(Pds2Isis, Pds2isisTestBandBin) { bool ok = false; PvlGroup bandbin = outLabel->findGroup("BandBin", Pvl::Traverse); - ASSERT_EQ(IString::ToDouble(bandbin["Center"][0]), 0.7360); - ASSERT_EQ(IString::ToDouble(bandbin["Center"][1]), 0.8750); - ASSERT_EQ(IString::ToDouble(bandbin["Center"][2]), 1.0546); - ASSERT_EQ(IString::ToDouble(bandbin["Center"][3]), 1.3326); - ASSERT_EQ(IString::ToDouble(bandbin["Center"][4]), 1.6110); - ASSERT_EQ(IString::ToDouble(bandbin["Center"][5]), 1.8914); - ASSERT_EQ(IString::ToDouble(bandbin["Center"][6]), 2.1728); - ASSERT_EQ(IString::ToDouble(bandbin["Center"][7]), 2.4529); - ASSERT_EQ(IString::ToDouble(bandbin["Center"][8]), 2.7382); - ASSERT_EQ(IString::ToDouble(bandbin["Center"][9]), 3.0178); - ASSERT_EQ(IString::ToDouble(bandbin["Center"][10]), 3.3012); - ASSERT_EQ(IString::ToDouble(bandbin["Center"][11]), 3.5839); - ASSERT_EQ(IString::ToDouble(bandbin["Center"][12]), 3.8670); - ASSERT_EQ(IString::ToDouble(bandbin["Center"][13]), 4.1503); - ASSERT_EQ(IString::ToDouble(bandbin["Center"][14]), 4.4343); - ASSERT_EQ(IString::ToDouble(bandbin["Center"][15]), 4.7164); - ASSERT_EQ(IString::ToDouble(bandbin["Center"][16]), 4.9988); - - ASSERT_EQ(IString::ToDouble(bandbin["Width"][0]), 0.0125); - ASSERT_EQ(IString::ToDouble(bandbin["Width"][1]), 0.0125); - ASSERT_EQ(IString::ToDouble(bandbin["Width"][2]), 0.0250); - ASSERT_EQ(IString::ToDouble(bandbin["Width"][3]), 0.0250); - ASSERT_EQ(IString::ToDouble(bandbin["Width"][4]), 0.0250); - ASSERT_EQ(IString::ToDouble(bandbin["Width"][5]), 0.0250); - ASSERT_EQ(IString::ToDouble(bandbin["Width"][6]), 0.0250); - ASSERT_EQ(IString::ToDouble(bandbin["Width"][7]), 0.0250); - ASSERT_EQ(IString::ToDouble(bandbin["Width"][8]), 0.0250); - ASSERT_EQ(IString::ToDouble(bandbin["Width"][9]), 0.0250); - ASSERT_EQ(IString::ToDouble(bandbin["Width"][10]), 0.0250); - ASSERT_EQ(IString::ToDouble(bandbin["Width"][11]), 0.0250); - ASSERT_EQ(IString::ToDouble(bandbin["Width"][12]), 0.0250); - ASSERT_EQ(IString::ToDouble(bandbin["Width"][13]), 0.0250); - ASSERT_EQ(IString::ToDouble(bandbin["Width"][14]), 0.0250); - ASSERT_EQ(IString::ToDouble(bandbin["Width"][15]), 0.0250); - ASSERT_EQ(IString::ToDouble(bandbin["Width"][16]), 0.0250); - - ASSERT_EQ(IString::ToInteger(bandbin["FilterNumber"][0]), 1); - ASSERT_EQ(IString::ToInteger(bandbin["FilterNumber"][1]), 2); - ASSERT_EQ(IString::ToInteger(bandbin["FilterNumber"][2]), 3); - ASSERT_EQ(IString::ToInteger(bandbin["FilterNumber"][3]), 4); - ASSERT_EQ(IString::ToInteger(bandbin["FilterNumber"][4]), 5); - ASSERT_EQ(IString::ToInteger(bandbin["FilterNumber"][5]), 6); - ASSERT_EQ(IString::ToInteger(bandbin["FilterNumber"][6]), 7); - ASSERT_EQ(IString::ToInteger(bandbin["FilterNumber"][7]), 8); - ASSERT_EQ(IString::ToInteger(bandbin["FilterNumber"][8]), 9); - ASSERT_EQ(IString::ToInteger(bandbin["FilterNumber"][9]), 10); - ASSERT_EQ(IString::ToInteger(bandbin["FilterNumber"][10]), 11); - ASSERT_EQ(IString::ToInteger(bandbin["FilterNumber"][11]), 12); - ASSERT_EQ(IString::ToInteger(bandbin["FilterNumber"][12]), 13); - ASSERT_EQ(IString::ToInteger(bandbin["FilterNumber"][13]), 14); - ASSERT_EQ(IString::ToInteger(bandbin["FilterNumber"][14]), 15); - ASSERT_EQ(IString::ToInteger(bandbin["FilterNumber"][15]), 16); - ASSERT_EQ(IString::ToInteger(bandbin["FilterNumber"][16]), 17); + ASSERT_EQ(Isis::toDouble(bandbin["Center"][0]), 0.7360); + ASSERT_EQ(Isis::toDouble(bandbin["Center"][1]), 0.8750); + ASSERT_EQ(Isis::toDouble(bandbin["Center"][2]), 1.0546); + ASSERT_EQ(Isis::toDouble(bandbin["Center"][3]), 1.3326); + ASSERT_EQ(Isis::toDouble(bandbin["Center"][4]), 1.6110); + ASSERT_EQ(Isis::toDouble(bandbin["Center"][5]), 1.8914); + ASSERT_EQ(Isis::toDouble(bandbin["Center"][6]), 2.1728); + ASSERT_EQ(Isis::toDouble(bandbin["Center"][7]), 2.4529); + ASSERT_EQ(Isis::toDouble(bandbin["Center"][8]), 2.7382); + ASSERT_EQ(Isis::toDouble(bandbin["Center"][9]), 3.0178); + ASSERT_EQ(Isis::toDouble(bandbin["Center"][10]), 3.3012); + ASSERT_EQ(Isis::toDouble(bandbin["Center"][11]), 3.5839); + ASSERT_EQ(Isis::toDouble(bandbin["Center"][12]), 3.8670); + ASSERT_EQ(Isis::toDouble(bandbin["Center"][13]), 4.1503); + ASSERT_EQ(Isis::toDouble(bandbin["Center"][14]), 4.4343); + ASSERT_EQ(Isis::toDouble(bandbin["Center"][15]), 4.7164); + ASSERT_EQ(Isis::toDouble(bandbin["Center"][16]), 4.9988); + + ASSERT_EQ(Isis::toDouble(bandbin["Width"][0]), 0.0125); + ASSERT_EQ(Isis::toDouble(bandbin["Width"][1]), 0.0125); + ASSERT_EQ(Isis::toDouble(bandbin["Width"][2]), 0.0250); + ASSERT_EQ(Isis::toDouble(bandbin["Width"][3]), 0.0250); + ASSERT_EQ(Isis::toDouble(bandbin["Width"][4]), 0.0250); + ASSERT_EQ(Isis::toDouble(bandbin["Width"][5]), 0.0250); + ASSERT_EQ(Isis::toDouble(bandbin["Width"][6]), 0.0250); + ASSERT_EQ(Isis::toDouble(bandbin["Width"][7]), 0.0250); + ASSERT_EQ(Isis::toDouble(bandbin["Width"][8]), 0.0250); + ASSERT_EQ(Isis::toDouble(bandbin["Width"][9]), 0.0250); + ASSERT_EQ(Isis::toDouble(bandbin["Width"][10]), 0.0250); + ASSERT_EQ(Isis::toDouble(bandbin["Width"][11]), 0.0250); + ASSERT_EQ(Isis::toDouble(bandbin["Width"][12]), 0.0250); + ASSERT_EQ(Isis::toDouble(bandbin["Width"][13]), 0.0250); + ASSERT_EQ(Isis::toDouble(bandbin["Width"][14]), 0.0250); + ASSERT_EQ(Isis::toDouble(bandbin["Width"][15]), 0.0250); + ASSERT_EQ(Isis::toDouble(bandbin["Width"][16]), 0.0250); + + ASSERT_EQ(Isis::toInt(bandbin["FilterNumber"][0]), 1); + ASSERT_EQ(Isis::toInt(bandbin["FilterNumber"][1]), 2); + ASSERT_EQ(Isis::toInt(bandbin["FilterNumber"][2]), 3); + ASSERT_EQ(Isis::toInt(bandbin["FilterNumber"][3]), 4); + ASSERT_EQ(Isis::toInt(bandbin["FilterNumber"][4]), 5); + ASSERT_EQ(Isis::toInt(bandbin["FilterNumber"][5]), 6); + ASSERT_EQ(Isis::toInt(bandbin["FilterNumber"][6]), 7); + ASSERT_EQ(Isis::toInt(bandbin["FilterNumber"][7]), 8); + ASSERT_EQ(Isis::toInt(bandbin["FilterNumber"][8]), 9); + ASSERT_EQ(Isis::toInt(bandbin["FilterNumber"][9]), 10); + ASSERT_EQ(Isis::toInt(bandbin["FilterNumber"][10]), 11); + ASSERT_EQ(Isis::toInt(bandbin["FilterNumber"][11]), 12); + ASSERT_EQ(Isis::toInt(bandbin["FilterNumber"][12]), 13); + ASSERT_EQ(Isis::toInt(bandbin["FilterNumber"][13]), 14); + ASSERT_EQ(Isis::toInt(bandbin["FilterNumber"][14]), 15); + ASSERT_EQ(Isis::toInt(bandbin["FilterNumber"][15]), 16); + ASSERT_EQ(Isis::toInt(bandbin["FilterNumber"][16]), 17); std::unique_ptr hist (outCube.histogram(0)); ASSERT_NEAR(hist->Average(), 0.205984, 1e-3); @@ -165,21 +165,21 @@ TEST(Pds2Isis, Pds2isisTestOffset) { PvlGroup mapping = outLabel->findGroup("Mapping", Pvl::Traverse); ASSERT_EQ(mapping["ProjectionName"][0], "SimpleCylindrical"); - ASSERT_EQ(IString::ToDouble(mapping["CenterLongitude"]), 180.0); + ASSERT_EQ(Isis::toDouble(mapping["CenterLongitude"]), 180.0); ASSERT_EQ(mapping["TargetName"][0], "Moon"); - ASSERT_EQ(IString::ToDouble(mapping["EquatorialRadius"]), 1737400.0); - ASSERT_EQ(IString::ToDouble(mapping["PolarRadius"]), 1737400.0); + ASSERT_EQ(Isis::toDouble(mapping["EquatorialRadius"]), 1737400.0); + ASSERT_EQ(Isis::toDouble(mapping["PolarRadius"]), 1737400.0); ASSERT_EQ(mapping["LatitudeType"][0], "Planetocentric"); ASSERT_EQ(mapping["LongitudeDirection"][0], "PositiveEast"); ASSERT_EQ((int)mapping["LongitudeDomain"], 360); - ASSERT_EQ(IString::ToDouble(mapping["MinimumLatitude"]), -90.0); - ASSERT_EQ(IString::ToDouble(mapping["MaximumLatitude"]), 90.0); - ASSERT_EQ(IString::ToDouble(mapping["MinimumLongitude"]), 0.0); - ASSERT_EQ(IString::ToDouble(mapping["MaximumLongitude"]), 360.0); - ASSERT_EQ(IString::ToDouble(mapping["UpperLeftCornerX"]), -5458204.8); - ASSERT_EQ(IString::ToDouble(mapping["UpperLeftCornerY"]), 2729102.4); - ASSERT_EQ(IString::ToDouble(mapping["PixelResolution"]), 7580.84); - ASSERT_EQ(IString::ToDouble(mapping["Scale"]), 4.0); + ASSERT_EQ(Isis::toDouble(mapping["MinimumLatitude"]), -90.0); + ASSERT_EQ(Isis::toDouble(mapping["MaximumLatitude"]), 90.0); + ASSERT_EQ(Isis::toDouble(mapping["MinimumLongitude"]), 0.0); + ASSERT_EQ(Isis::toDouble(mapping["MaximumLongitude"]), 360.0); + ASSERT_EQ(Isis::toDouble(mapping["UpperLeftCornerX"]), -5458204.8); + ASSERT_EQ(Isis::toDouble(mapping["UpperLeftCornerY"]), 2729102.4); + ASSERT_EQ(Isis::toDouble(mapping["PixelResolution"]), 7580.84); + ASSERT_EQ(Isis::toDouble(mapping["Scale"]), 4.0); std::unique_ptr hist (outCube.histogram()); ASSERT_NEAR(hist->Average(), 1.7375e+06, 10); @@ -208,21 +208,21 @@ TEST(Pds2Isis, Pds2isisTestProjection) { PvlGroup mapping = outLabel->findGroup("Mapping", Pvl::Traverse); ASSERT_EQ(mapping["ProjectionName"][0], "Sinusoidal"); - ASSERT_EQ(IString::ToDouble(mapping["CenterLongitude"]), 325.3829); + ASSERT_EQ(Isis::toDouble(mapping["CenterLongitude"]), 325.3829); ASSERT_EQ(mapping["TargetName"][0], "Venus"); - ASSERT_EQ(IString::ToDouble(mapping["EquatorialRadius"]), 6051920.0); - ASSERT_EQ(IString::ToDouble(mapping["PolarRadius"]), 6051920.0); + ASSERT_EQ(Isis::toDouble(mapping["EquatorialRadius"]), 6051920.0); + ASSERT_EQ(Isis::toDouble(mapping["PolarRadius"]), 6051920.0); ASSERT_EQ(mapping["LatitudeType"][0], "Planetocentric"); ASSERT_EQ(mapping["LongitudeDirection"][0], "PositiveEast"); ASSERT_EQ((int)mapping["LongitudeDomain"], 360); - ASSERT_EQ(IString::ToDouble(mapping["MinimumLatitude"]), -29.6357); - ASSERT_EQ(IString::ToDouble(mapping["MaximumLatitude"]), -28.9092); - ASSERT_EQ(IString::ToDouble(mapping["MinimumLongitude"]), 322.0367); - ASSERT_EQ(IString::ToDouble(mapping["MaximumLongitude"]), 322.8903); - ASSERT_EQ(IString::ToDouble(mapping["UpperLeftCornerX"]), -307162.5); - ASSERT_EQ(IString::ToDouble(mapping["UpperLeftCornerY"]), -3053025.0); - ASSERT_EQ(IString::ToDouble(mapping["PixelResolution"]), 75.0); - ASSERT_EQ(IString::ToDouble(mapping["Scale"]), 1407.4); + ASSERT_EQ(Isis::toDouble(mapping["MinimumLatitude"]), -29.6357); + ASSERT_EQ(Isis::toDouble(mapping["MaximumLatitude"]), -28.9092); + ASSERT_EQ(Isis::toDouble(mapping["MinimumLongitude"]), 322.0367); + ASSERT_EQ(Isis::toDouble(mapping["MaximumLongitude"]), 322.8903); + ASSERT_EQ(Isis::toDouble(mapping["UpperLeftCornerX"]), -307162.5); + ASSERT_EQ(Isis::toDouble(mapping["UpperLeftCornerY"]), -3053025.0); + ASSERT_EQ(Isis::toDouble(mapping["PixelResolution"]), 75.0); + ASSERT_EQ(Isis::toDouble(mapping["Scale"]), 1407.4); std::unique_ptr hist (outCube.histogram()); ASSERT_NEAR(hist->Average(), 67.7978515625, .00001); diff --git a/isis/tests/FunctionalTestsPhocube.cpp b/isis/tests/FunctionalTestsPhocube.cpp index d3a69d8cf6..8abe2a3415 100644 --- a/isis/tests/FunctionalTestsPhocube.cpp +++ b/isis/tests/FunctionalTestsPhocube.cpp @@ -42,8 +42,8 @@ TEST_F(DefaultCube, FunctionalTestPhocubeDefault) { EXPECT_EQ((int) bandBin.findKeyword("FilterId"), 4); for (int i = 0; i < cube.bandCount(); i++) { - EXPECT_DOUBLE_EQ(IString::ToDouble(bandBin.findKeyword("Center")[i]), 1.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandBin.findKeyword("Width")[i]), 1.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandBin.findKeyword("Center")[i]), 1.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandBin.findKeyword("Width")[i]), 1.0); } std::unique_ptr hist (cube.histogram(0)); @@ -493,8 +493,8 @@ TEST(Phocube, FunctionalTestPhocubeSunIlluminationMask) { // verify center and width entries in BandBin group for (int i = 0; i < cube.bandCount(); i++) { - EXPECT_DOUBLE_EQ(IString::ToDouble(bandBin.findKeyword("Center")[i]), 650.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandBin.findKeyword("Width")[i]), 1.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandBin.findKeyword("Center")[i]), 650.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandBin.findKeyword("Width")[i]), 1.0); } // verify statistics of SunIlluminationMask band @@ -550,8 +550,8 @@ TEST(Phocube, FunctionalTestPhocubeSurfaceObliqueDetectorResolution) { // verify center and width entries in BandBin group for (int i = 0; i < cube.bandCount(); i++) { - EXPECT_DOUBLE_EQ(IString::ToDouble(bandBin.findKeyword("Center")[i]), 650.0); - EXPECT_DOUBLE_EQ(IString::ToDouble(bandBin.findKeyword("Width")[i]), 1.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandBin.findKeyword("Center")[i]), 650.0); + EXPECT_DOUBLE_EQ(Isis::toDouble(bandBin.findKeyword("Width")[i]), 1.0); } // verify statistics of SurfaceObliqueDetectorResolution band diff --git a/isis/tests/FunctionalTestsSumspice.cpp b/isis/tests/FunctionalTestsSumspice.cpp index 074b40308c..8ba0a8e033 100644 --- a/isis/tests/FunctionalTestsSumspice.cpp +++ b/isis/tests/FunctionalTestsSumspice.cpp @@ -42,8 +42,8 @@ TEST(Sumspice, FunctionalTestSumspiceTimeUpdate) { // SumTimeHistory Group PvlGroup &sumTime = isisLabel->findGroup("SumTimeHistory", Pvl::Traverse); EXPECT_EQ(sumTime["SUMFILE"][0], "N2395699394"); - EXPECT_EQ(IString::ToDouble(sumTime["SpacecraftClockStartCount"][0]), 2395694888); - EXPECT_EQ(IString::ToDouble(sumTime["SpacecraftClockStopCount"][0]), 2395695365); + EXPECT_EQ(Isis::toDouble(sumTime["SpacecraftClockStartCount"][0]), 2395694888); + EXPECT_EQ(Isis::toDouble(sumTime["SpacecraftClockStopCount"][0]), 2395695365); EXPECT_EQ(sumTime["StartTime"][0], "2005-09-21T10:44:07"); EXPECT_EQ(sumTime["StopTime"][0], "2005-09-21T10:44:07"); diff --git a/isis/tests/TestUtilities.cpp b/isis/tests/TestUtilities.cpp index 3f48de1350..2020fec6ce 100644 --- a/isis/tests/TestUtilities.cpp +++ b/isis/tests/TestUtilities.cpp @@ -34,8 +34,8 @@ namespace Isis { if (e.errorType() == errorType) return ::testing::AssertionSuccess(); return ::testing::AssertionFailure() << "IExeption "<< e_expr << "\'s error type (" - << std::to_string(e.errorType()) << ") does not match expected error type (" - << std::to_string(errorType) << ")."; + << Isis::toString(e.errorType()) << ") does not match expected error type (" + << Isis::toString(errorType) << ")."; } @@ -303,8 +303,8 @@ namespace Isis { if (numDiff > tolerance) { differences.push_back( "Values [" + json1.dump() + "] and [" + json2.dump() + "] differ by [" - + std::to_string(numDiff) + "] which is greater than tolerance [" - + std::to_string(tolerance) + "] at [" + jsonPointer + "]"); + + Isis::toString(numDiff) + "] which is greater than tolerance [" + + Isis::toString(tolerance) + "] at [" + jsonPointer + "]"); } break; From dc938d1856bceb8c5edc2e3d48b92c646f503960 Mon Sep 17 00:00:00 2001 From: Austin Sanders Date: Thu, 26 Sep 2024 10:25:18 -0600 Subject: [PATCH 2/4] Updated formatting for tests --- gtest | 2 +- isis/src/base/objs/Area3D/Area3D.truth | 6 +- isis/src/base/objs/AutoReg/AutoReg.cpp | 2 +- isis/src/base/objs/Blobber/Blobber.truth | 6 +- .../CameraPointInfo/CameraPointInfo.truth | 4 +- .../base/objs/CubeAttribute/CubeAttribute.cpp | 12 ++-- isis/src/base/objs/GisGeometry/unitTest.cpp | 14 ++-- isis/src/base/objs/Hillshade/Hillshade.truth | 6 +- .../LunarLambertEmpirical.truth | 8 +-- .../MinnaertEmpirical/MinnaertEmpirical.truth | 8 +-- .../base/objs/NaifDskPlateModel/unitTest.cpp | 6 +- isis/src/base/objs/NaifDskShape/unitTest.cpp | 12 ++-- .../SpectralDefinition1D.cpp | 6 +- .../SpectralDefinition1D.truth | 68 +++++++++---------- .../BundleObservationSolveSettings.cpp | 6 +- isis/src/core/include/SpecialPixel.h | 3 + isis/src/core/tests/PvlKeywordTests.cpp | 18 ----- .../BundleObservationSolveSettingsTests.cpp | 6 +- isis/tests/StatisticsTest.cpp | 2 +- 19 files changed, 90 insertions(+), 105 deletions(-) diff --git a/gtest b/gtest index f8d7d77c06..eff443c6ef 160000 --- a/gtest +++ b/gtest @@ -1 +1 @@ -Subproject commit f8d7d77c06936315286eb55f8de22cd23c188571 +Subproject commit eff443c6ef5eb6ab598bfaae27f9427fdb4f6af7 diff --git a/isis/src/base/objs/Area3D/Area3D.truth b/isis/src/base/objs/Area3D/Area3D.truth index a8c198f6e9..c7b5f4e6c5 100644 --- a/isis/src/base/objs/Area3D/Area3D.truth +++ b/isis/src/base/objs/Area3D/Area3D.truth @@ -76,6 +76,6 @@ Area3D 1 = Area3D 2... Area3D 1 = -1.7976931348623e+308,0,-1.7976931348623e+308 ----- Testing Error Checking ----- -**PROGRAMMER ERROR** Cannot have a 3D area with inverted X coordinates of [1 meters] to [0 meters]. -**PROGRAMMER ERROR** Cannot have a 3D area with inverted Y coordinates of [1 meters] to [0 meters]. -**PROGRAMMER ERROR** Cannot have a 3D area with inverted Z coordinates of [1 meters] to [0 meters]. +**PROGRAMMER ERROR** Cannot have a 3D area with inverted X coordinates of [1.0 meters] to [0.0 meters]. +**PROGRAMMER ERROR** Cannot have a 3D area with inverted Y coordinates of [1.0 meters] to [0.0 meters]. +**PROGRAMMER ERROR** Cannot have a 3D area with inverted Z coordinates of [1.0 meters] to [0.0 meters]. diff --git a/isis/src/base/objs/AutoReg/AutoReg.cpp b/isis/src/base/objs/AutoReg/AutoReg.cpp index 481f824581..0976a3a215 100644 --- a/isis/src/base/objs/AutoReg/AutoReg.cpp +++ b/isis/src/base/objs/AutoReg/AutoReg.cpp @@ -201,7 +201,7 @@ namespace Isis { } if(algo.hasKeyword("SubpixelAccuracy")) { - SetSubPixelAccuracy(Isis::toString((int)algo["SubpixelAccuracy"]) == "True"); + SetSubPixelAccuracy(Isis::toBool(algo["SubpixelAccuracy"]) == true); } if(algo.hasKeyword("ReductionFactor")) { diff --git a/isis/src/base/objs/Blobber/Blobber.truth b/isis/src/base/objs/Blobber/Blobber.truth index c9ca1feb4b..156850e720 100644 --- a/isis/src/base/objs/Blobber/Blobber.truth +++ b/isis/src/base/objs/Blobber/Blobber.truth @@ -11,9 +11,9 @@ Number Blob Samples: 16 Total Pixels: 2688 ** Blob Values... -Pixel[0][0] = 1008 -Pixel[84][8] = 1115 -Pixel[167][15] = 1259 +Pixel[0][0] = 1008.0 +Pixel[84][8] = 1115.0 +Pixel[167][15] = 1259.0 ** Test Blobber direct access (via filename)... diff --git a/isis/src/base/objs/CameraPointInfo/CameraPointInfo.truth b/isis/src/base/objs/CameraPointInfo/CameraPointInfo.truth index 0eae5d11c6..834060a49f 100644 --- a/isis/src/base/objs/CameraPointInfo/CameraPointInfo.truth +++ b/isis/src/base/objs/CameraPointInfo/CameraPointInfo.truth @@ -1,7 +1,7 @@ Group = GroundPoint Sample = 1.0 Line = 1.0 - PixelValue = 21 + PixelValue = 21.0 RightAscension = 254.44877411829 Declination = 67.288137235407 PlanetocentricLatitude = -85.539935681585 @@ -64,7 +64,7 @@ End_Group Group = GroundPoint Sample = 155.47884244269 Line = 184.71817081965 - PixelValue = 29 + PixelValue = 29.0 RightAscension = 262.28855950942 Declination = 65.693319737566 PlanetocentricLatitude = -84.5 diff --git a/isis/src/base/objs/CubeAttribute/CubeAttribute.cpp b/isis/src/base/objs/CubeAttribute/CubeAttribute.cpp index 2443a10138..63cf1117a4 100644 --- a/isis/src/base/objs/CubeAttribute/CubeAttribute.cpp +++ b/isis/src/base/objs/CubeAttribute/CubeAttribute.cpp @@ -323,15 +323,15 @@ namespace Isis { void CubeAttributeOutput::setMinimum(double min) { if (!IsSpecial(min)) { - QString newRange = QString::number(min) + ":"; + QString newRange = QString::fromStdString(Isis::toString(min)) + ":"; if (!IsSpecial(maximum())) - newRange += QString::number(maximum()); + newRange += QString::fromStdString(Isis::toString(maximum())); setAttribute(newRange, &CubeAttributeOutput::isRange); } else if (!IsSpecial(maximum())) { - setAttribute(":" + QString::number(maximum()), &CubeAttributeOutput::isRange); + setAttribute(":" + QString::fromStdString(Isis::toString(maximum())), &CubeAttributeOutput::isRange); } else { setAttribute("", &CubeAttributeOutput::isRange); @@ -341,15 +341,15 @@ namespace Isis { void CubeAttributeOutput::setMaximum(double max) { if (!IsSpecial(max)) { - QString newRange = ":" + QString::number(max); + QString newRange = ":" + QString::fromStdString(Isis::toString(max)); if (!IsSpecial(minimum())) - newRange = QString::number(minimum()) + newRange; + newRange = QString::fromStdString(Isis::toString(minimum())) + newRange; setAttribute(newRange, &CubeAttributeOutput::isRange); } else if (!IsSpecial(minimum())) { - setAttribute(QString::number(minimum()) + ":", &CubeAttributeOutput::isRange); + setAttribute(QString::fromStdString(Isis::toString(minimum())) + ":", &CubeAttributeOutput::isRange); } else { setAttribute("", &CubeAttributeOutput::isRange); diff --git a/isis/src/base/objs/GisGeometry/unitTest.cpp b/isis/src/base/objs/GisGeometry/unitTest.cpp index 4bed1e8fcd..d6e435970c 100644 --- a/isis/src/base/objs/GisGeometry/unitTest.cpp +++ b/isis/src/base/objs/GisGeometry/unitTest.cpp @@ -268,13 +268,13 @@ void printBasicInfo(GisGeometry geom, QString description) { */ void printTargetInfo(GisGeometry geom, GisGeometry target, QString description) { qDebug() << description; - qDebug() << " distance? " << QString::number(geom.distance(target)); - qDebug() << " intersects? " << QString::number(geom.intersects(target)); - qDebug() << " contains? " << QString::number(geom.contains(target)); - qDebug() << " disjoint? " << QString::number(geom.disjoint(target)); - qDebug() << " overlaps? " << QString::number(geom.overlaps(target)); - qDebug() << " equals? " << QString::number(geom.equals(target)); - qDebug() << " intersect ratio? " << QString::number(geom.intersectRatio(target)); + qDebug() << " distance? " << QString::fromStdString(Isis::toString(geom.distance(target))); + qDebug() << " intersects? " << QString::fromStdString(Isis::toString(geom.intersects(target))); + qDebug() << " contains? " << QString::fromStdString(Isis::toString(geom.contains(target))); + qDebug() << " disjoint? " << QString::fromStdString(Isis::toString(geom.disjoint(target))); + qDebug() << " overlaps? " << QString::fromStdString(Isis::toString(geom.overlaps(target))); + qDebug() << " equals? " << QString::fromStdString(Isis::toString(geom.equals(target))); + qDebug() << " intersect ratio? " << QString::fromStdString(Isis::toString(geom.intersectRatio(target))); qDebug() << ""; } diff --git a/isis/src/base/objs/Hillshade/Hillshade.truth b/isis/src/base/objs/Hillshade/Hillshade.truth index c401c09191..894f5291e6 100644 --- a/isis/src/base/objs/Hillshade/Hillshade.truth +++ b/isis/src/base/objs/Hillshade/Hillshade.truth @@ -2,9 +2,9 @@ Default constructed: Hillshade[ azimuth = zenith = resolution = Null ] Empty constructed: Hillshade[ azimuth = zenith = resolution = Null ] Copied empty: Hillshade[ azimuth = zenith = resolution = Null ] Assigned empty: Hillshade[ azimuth = zenith = resolution = Null ] -Valid: Hillshade[ azimuth = 0.0 degrees zenith = 15.0 degrees resolution = 5.0 ] -Copied valid: Hillshade[ azimuth = 0.0 degrees zenith = 15.0 degrees resolution = 5.0 ] -Assigned valid: Hillshade[ azimuth = 0.0 degrees zenith = 15.0 degrees resolution = 5.0 ] +Valid: Hillshade[ azimuth = 0.0 degrees zenith = 15.0 degrees resolution = 5 ] +Copied valid: Hillshade[ azimuth = 0.0 degrees zenith = 15.0 degrees resolution = 5 ] +Assigned valid: Hillshade[ azimuth = 0.0 degrees zenith = 15.0 degrees resolution = 5 ] Test computations diff --git a/isis/src/base/objs/LunarLambertEmpirical/LunarLambertEmpirical.truth b/isis/src/base/objs/LunarLambertEmpirical/LunarLambertEmpirical.truth index 5bcd731886..bf5411eae8 100644 --- a/isis/src/base/objs/LunarLambertEmpirical/LunarLambertEmpirical.truth +++ b/isis/src/base/objs/LunarLambertEmpirical/LunarLambertEmpirical.truth @@ -31,10 +31,10 @@ Object = PhotometricModel Name = LunarLambertEmpirical PhaseList = (0, 10, 20, 30, 40, 50, 60, 70, 80, 90, 100, 110, 120, 130, 140) - LList = (0, 0.1, 0.2, 0.3, 0.4, 0.5, 0.6, 0.7, 0.8, 0.9, 1, 1.1, - 1.2, 1.3, 1.4) - PhaseCurveList = (0, 0.3, 0.6, 0.9, 1.2, 1.5, 1.8, 2.1, 2.4, 2.7, 3, 3.3, - 3.6, 3.9, 4.2) + LList = (0.0, 0.1, 0.2, 0.3, 0.4, 0.5, 0.6, 0.7, 0.8, 0.9, 1.0, + 1.1, 1.2, 1.3, 1.4) + PhaseCurveList = (0.0, 0.3, 0.6, 0.9, 1.2, 1.5, 1.8, 2.1, 2.4, 2.7, 3.0, + 3.3, 3.6, 3.9, 4.2) End_Group End_Object End diff --git a/isis/src/base/objs/MinnaertEmpirical/MinnaertEmpirical.truth b/isis/src/base/objs/MinnaertEmpirical/MinnaertEmpirical.truth index 4c235e235e..52411011e2 100644 --- a/isis/src/base/objs/MinnaertEmpirical/MinnaertEmpirical.truth +++ b/isis/src/base/objs/MinnaertEmpirical/MinnaertEmpirical.truth @@ -31,10 +31,10 @@ Object = PhotometricModel Name = MinnaertEmpirical PhaseList = (0, 10, 20, 30, 40, 50, 60, 70, 80, 90, 100, 110, 120, 130, 140) - KList = (0, 0.1, 0.2, 0.3, 0.4, 0.5, 0.6, 0.7, 0.8, 0.9, 1, 1.1, - 1.2, 1.3, 1.4) - PhaseCurveList = (0, 0.3, 0.6, 0.9, 1.2, 1.5, 1.8, 2.1, 2.4, 2.7, 3, 3.3, - 3.6, 3.9, 4.2) + KList = (0.0, 0.1, 0.2, 0.3, 0.4, 0.5, 0.6, 0.7, 0.8, 0.9, 1.0, + 1.1, 1.2, 1.3, 1.4) + PhaseCurveList = (0.0, 0.3, 0.6, 0.9, 1.2, 1.5, 1.8, 2.1, 2.4, 2.7, 3.0, + 3.3, 3.6, 3.9, 4.2) End_Group End_Object End diff --git a/isis/src/base/objs/NaifDskPlateModel/unitTest.cpp b/isis/src/base/objs/NaifDskPlateModel/unitTest.cpp index 2ea12da8cf..7e7688099c 100755 --- a/isis/src/base/objs/NaifDskPlateModel/unitTest.cpp +++ b/isis/src/base/objs/NaifDskPlateModel/unitTest.cpp @@ -70,7 +70,7 @@ int main(int argc, char *argv[]) { Latitude lat(0.0, Angle::Degrees); Longitude lon(0.0, Angle::Degrees); SurfacePoint *sp = naifPlateModelFromDSK.point(lat, lon); - qDebug() << "Surface point at pole is null? " << QString::number(sp == NULL); + qDebug() << "Surface point at pole is null? " << QString::fromStdString(Isis::toString(sp == NULL)); qDebug() << "Surface point: " << sp->GetX().meters() << sp->GetY().meters() << sp->GetZ().meters() @@ -87,7 +87,7 @@ int main(int argc, char *argv[]) { Intercept *intercept = naifPlateModelFromDSK.intercept(obsPos, rayDir); qDebug() << "Ray Dir: " << rayDir; qDebug() << "Observer: " << obsPos; - qDebug() << "Intercept is null? " << QString::number(intercept == NULL); + qDebug() << "Intercept is null? " << QString::fromStdString(Isis::toString(intercept == NULL)); qDebug() << "intercept plateID? " << naifPlateModelFromDSK.plateIdOfIntercept(obsPos, rayDir, xpoint); @@ -97,7 +97,7 @@ int main(int argc, char *argv[]) { intercept = naifPlateModelFromDSK.intercept(obsPos, rayDir); qDebug() << "Ray Dir: " << rayDir; qDebug() << "Observer: " << obsPos; - qDebug() << "Intercept is null? " << QString::number(intercept == NULL); + qDebug() << "Intercept is null? " << QString::fromStdString(Isis::toString(intercept == NULL)); qDebug() << "intercept plate name = " << intercept->shape()->name(); qDebug() << "intercept vertex (obsPos position) = " << intercept->observer(); qDebug() << "intercept vector (look direction) = " << intercept->lookDirectionRay(); diff --git a/isis/src/base/objs/NaifDskShape/unitTest.cpp b/isis/src/base/objs/NaifDskShape/unitTest.cpp index af98498255..206520bc78 100755 --- a/isis/src/base/objs/NaifDskShape/unitTest.cpp +++ b/isis/src/base/objs/NaifDskShape/unitTest.cpp @@ -54,7 +54,7 @@ int main(int argc, char *argv[]) { qDebug() << "Default constructor."; NaifDskShape shapeModel; qDebug() << "Shape name is " << shapeModel.name(); - qDebug() << "Shape is DEM type? " << QString::number(shapeModel.isDEM()); + qDebug() << "Shape is DEM type? " << QString::fromStdString(Isis::toString(shapeModel.isDEM())); qDebug() << ""; @@ -68,7 +68,7 @@ int main(int argc, char *argv[]) { obsPos.push_back(0.0); obsPos.push_back(0.0); obsPos.push_back(0.0); lookDir.push_back(1.0); lookDir.push_back(1.0); lookDir.push_back(1.0); bool success = shapeModelFromPlate.intersectSurface(obsPos, lookDir); - qDebug() << "Intersection successful? " << QString::number(success); + qDebug() << "Intersection successful? " << QString::fromStdString(Isis::toString(success)); qDebug() << ""; qDebug() << "Construct NaifDskShape object from cube labels with ShapeModel=DSK file."; @@ -79,7 +79,7 @@ int main(int argc, char *argv[]) { obsPos[0] = 0.0; obsPos[1] = 0.0; obsPos[2] = 1000.0; lookDir[0] = 0.0; lookDir[1] = -1.0; lookDir[2] = -1.0; success = shapeModelFromPvlShape.intersectSurface(obsPos, lookDir); - qDebug() << "Intersection successful? " << QString::number(success); + qDebug() << "Intersection successful? " << QString::fromStdString(Isis::toString(success)); qDebug() << "Try to intersect surface at obsPos (1000,0,0) and ground point (1,0,0)"; Displacement x(1.0, Displacement::Meters); @@ -94,7 +94,7 @@ int main(int argc, char *argv[]) { qDebug() << "Intercept Y = " << point->DisplacementToDouble(point->GetY(), SurfacePoint::Kilometers); qDebug() << "Intercept Z = " << point->DisplacementToDouble(point->GetZ(), SurfacePoint::Kilometers); } - qDebug() << "Intersection successful? " << QString::number(success); + qDebug() << "Intersection successful? " << QString::fromStdString(Isis::toString(success)); qDebug() << ""; qDebug() << "Construct NaifDskShape object from cube labels with ElevationModel=DSK file."; @@ -111,11 +111,11 @@ int main(int argc, char *argv[]) { obsPos[0] = 1000.0; obsPos[1] = 0.0; obsPos[2] = 0.0; lookDir[0] = -1.0; lookDir[1] = 0.0; lookDir[2] = 0.0; success = shapeModelFromPvlElevation.intersectSurface(obsPos, lookDir); - qDebug() << "Intersection successful? " << QString::number(success); + qDebug() << "Intersection successful? " << QString::fromStdString(Isis::toString(success)); qDebug() << "Intersection valid? " << shapeModelFromPvlElevation.surfaceIntersection()->Valid(); const Intercept *intercept = shapeModelFromPvlElevation.intercept(); - qDebug() << "Intercept is null? " << QString::number(intercept == NULL); + qDebug() << "Intercept is null? " << QString::fromStdString(Isis::toString(intercept == NULL)); SurfacePoint xp = intercept->location(); NaifVertex xpoint(3); xpoint[0] = xp.GetX().meters(); diff --git a/isis/src/base/objs/SpectralDefinition1D/SpectralDefinition1D.cpp b/isis/src/base/objs/SpectralDefinition1D/SpectralDefinition1D.cpp index 8a909e7271..1d9c9e9536 100644 --- a/isis/src/base/objs/SpectralDefinition1D/SpectralDefinition1D.cpp +++ b/isis/src/base/objs/SpectralDefinition1D/SpectralDefinition1D.cpp @@ -97,13 +97,13 @@ namespace Isis { QString temp; for (int i=0; ilength(); i++){ temp +="----Section "; - temp +=QString::number(i); + temp += QString::fromStdString(Isis::toString(i)); temp +="----\n"; for(int j=0; jat(i)->length(); j++){ temp+="Wavelength= "; - temp+=QString::number(m_spectelList->at(i)->at(j).centerWavelength()); + temp+=QString::fromStdString(Isis::toString(m_spectelList->at(i)->at(j).centerWavelength())); temp+=", Width= "; - temp+=QString::number(m_spectelList->at(i)->at(j).filterWidth()); + temp+=QString::fromStdString(Isis::toString(m_spectelList->at(i)->at(j).filterWidth())); temp+="\n"; } } diff --git a/isis/src/base/objs/SpectralDefinition1D/SpectralDefinition1D.truth b/isis/src/base/objs/SpectralDefinition1D/SpectralDefinition1D.truth index d6a537d970..1a56b52962 100644 --- a/isis/src/base/objs/SpectralDefinition1D/SpectralDefinition1D.truth +++ b/isis/src/base/objs/SpectralDefinition1D/SpectralDefinition1D.truth @@ -71,37 +71,37 @@ Section number is: 1 ----- Testing multiple sections in opposite order----- ----Section 0---- -Wavelength= 8, Width= 0.308 -Wavelength= 7, Width= 0.307 -Wavelength= 6, Width= 0.306 -Wavelength= 5, Width= 0.305 -Wavelength= 4, Width= 0.304 -Wavelength= 3, Width= 0.303 -Wavelength= 2, Width= 0.302 -Wavelength= 1, Width= 0.301 +Wavelength= 8.0, Width= 0.308 +Wavelength= 7.0, Width= 0.307 +Wavelength= 6.0, Width= 0.306 +Wavelength= 5.0, Width= 0.305 +Wavelength= 4.0, Width= 0.304 +Wavelength= 3.0, Width= 0.303 +Wavelength= 2.0, Width= 0.302 +Wavelength= 1.0, Width= 0.301 ----Section 1---- -Wavelength= 6, Width= 0.1511 +Wavelength= 6.0, Width= 0.1511 Wavelength= 5.5, Width= 0.151 -Wavelength= 5, Width= 0.1509 +Wavelength= 5.0, Width= 0.1509 Wavelength= 4.5, Width= 0.1508 -Wavelength= 4, Width= 0.1507 +Wavelength= 4.0, Width= 0.1507 Wavelength= 3.5, Width= 0.1506 -Wavelength= 3, Width= 0.1505 +Wavelength= 3.0, Width= 0.1505 Wavelength= 2.5, Width= 0.1504 -Wavelength= 2, Width= 0.1503 +Wavelength= 2.0, Width= 0.1503 Wavelength= 1.5, Width= 0.1502 -Wavelength= 1, Width= 0.1501 +Wavelength= 1.0, Width= 0.1501 ----Section 2---- Wavelength= 6.25, Width= 0.078 -Wavelength= 6, Width= 0.076 +Wavelength= 6.0, Width= 0.076 Wavelength= 5.75, Width= 0.075 Wavelength= 5.5, Width= 0.074 Wavelength= 5.25, Width= 0.073 -Wavelength= 5, Width= 0.072 +Wavelength= 5.0, Width= 0.072 Wavelength= 4.75, Width= 0.071 Wavelength= 4.5, Width= 0.07 ----Section 3---- -Wavelength= 10, Width= 4 +Wavelength= 10.0, Width= 4.0 The number of sections is : 4 Spectel at band: 28 : Wavelength=10 Width=4 Spectel at band: 28 : Wavelength=10 Width=4 @@ -143,37 +143,37 @@ Section number is: 1 ---- Testing toString --- ----Section 0---- -Wavelength= 8, Width= 0.308 -Wavelength= 7, Width= 0.307 -Wavelength= 6, Width= 0.306 -Wavelength= 5, Width= 0.305 -Wavelength= 4, Width= 0.304 -Wavelength= 3, Width= 0.303 -Wavelength= 2, Width= 0.302 -Wavelength= 1, Width= 0.301 +Wavelength= 8.0, Width= 0.308 +Wavelength= 7.0, Width= 0.307 +Wavelength= 6.0, Width= 0.306 +Wavelength= 5.0, Width= 0.305 +Wavelength= 4.0, Width= 0.304 +Wavelength= 3.0, Width= 0.303 +Wavelength= 2.0, Width= 0.302 +Wavelength= 1.0, Width= 0.301 ----Section 1---- -Wavelength= 6, Width= 0.1511 +Wavelength= 6.0, Width= 0.1511 Wavelength= 5.5, Width= 0.151 -Wavelength= 5, Width= 0.1509 +Wavelength= 5.0, Width= 0.1509 Wavelength= 4.5, Width= 0.1508 -Wavelength= 4, Width= 0.1507 +Wavelength= 4.0, Width= 0.1507 Wavelength= 3.5, Width= 0.1506 -Wavelength= 3, Width= 0.1505 +Wavelength= 3.0, Width= 0.1505 Wavelength= 2.5, Width= 0.1504 -Wavelength= 2, Width= 0.1503 +Wavelength= 2.0, Width= 0.1503 Wavelength= 1.5, Width= 0.1502 -Wavelength= 1, Width= 0.1501 +Wavelength= 1.0, Width= 0.1501 ----Section 2---- Wavelength= 6.25, Width= 0.078 -Wavelength= 6, Width= 0.076 +Wavelength= 6.0, Width= 0.076 Wavelength= 5.75, Width= 0.075 Wavelength= 5.5, Width= 0.074 Wavelength= 5.25, Width= 0.073 -Wavelength= 5, Width= 0.072 +Wavelength= 5.0, Width= 0.072 Wavelength= 4.75, Width= 0.071 Wavelength= 4.5, Width= 0.07 ----Section 3---- -Wavelength= 10, Width= 4 +Wavelength= 10.0, Width= 4.0 ---- Testing for errors --- diff --git a/isis/src/control/objs/BundleUtilities/BundleObservationSolveSettings.cpp b/isis/src/control/objs/BundleUtilities/BundleObservationSolveSettings.cpp index 7f4d207e6a..eda5bbaccc 100644 --- a/isis/src/control/objs/BundleUtilities/BundleObservationSolveSettings.cpp +++ b/isis/src/control/objs/BundleUtilities/BundleObservationSolveSettings.cpp @@ -1221,8 +1221,8 @@ namespace Isis { stream.writeAttribute("numberCoefSolved", QString::number(m_numberCamAngleCoefSolved)); stream.writeAttribute("degree", QString::number(m_ckDegree)); stream.writeAttribute("solveDegree", QString::number(m_ckSolveDegree)); - stream.writeAttribute("solveTwist", QString::number(m_solveTwist)); - stream.writeAttribute("solveOverExisting", QString::number(m_solvePointingPolynomialOverExisting)); + stream.writeAttribute("solveTwist", QString::fromStdString(Isis::toString(m_solveTwist))); + stream.writeAttribute("solveOverExisting", QString::fromStdString(Isis::toString(m_solvePointingPolynomialOverExisting))); stream.writeAttribute("interpolationType", QString::number(m_pointingInterpolationType)); stream.writeStartElement("aprioriPointingSigmas"); @@ -1244,7 +1244,7 @@ namespace Isis { stream.writeAttribute("numberCoefSolved", QString::number(m_numberCamPosCoefSolved)); stream.writeAttribute("degree", QString::number(m_spkDegree)); stream.writeAttribute("solveDegree", QString::number(m_spkSolveDegree)); - stream.writeAttribute("solveOverHermiteSpline", QString::number(m_solvePositionOverHermiteSpline)); + stream.writeAttribute("solveOverHermiteSpline", QString::fromStdString(Isis::toString(m_solvePositionOverHermiteSpline))); stream.writeAttribute("interpolationType", QString::number(m_positionInterpolationType)); stream.writeStartElement("aprioriPositionSigmas"); diff --git a/isis/src/core/include/SpecialPixel.h b/isis/src/core/include/SpecialPixel.h index 88895bb6cd..24be01ebc1 100644 --- a/isis/src/core/include/SpecialPixel.h +++ b/isis/src/core/include/SpecialPixel.h @@ -376,9 +376,12 @@ namespace Isis { return "Invalid"; } + /* std::ostringstream result; result << std::setprecision(precision) << std::scientific << d; return result.str(); + */ + return Isis::toString(d); } diff --git a/isis/src/core/tests/PvlKeywordTests.cpp b/isis/src/core/tests/PvlKeywordTests.cpp index 6bca6bfc6f..d6a38b5e22 100644 --- a/isis/src/core/tests/PvlKeywordTests.cpp +++ b/isis/src/core/tests/PvlKeywordTests.cpp @@ -224,11 +224,7 @@ TEST(PvlKeyword, IndexSetValue) key.addValue("3.3", "feet"); key.addValue("Hello World!"); -<<<<<<< HEAD key[1] = toString(88); -======= - key[1] = Isis::toString(88); ->>>>>>> e6eff8ddd (Update std::tostring, stoi, stod to IString functions) EXPECT_EQ(key[1], "88"); } @@ -326,11 +322,7 @@ TEST(PvlKeyword, KeywordValidationNull) TEST(PvlKeyword, KeywordValidationFail) { try { PvlKeyword pvlTmplKwrd("KeyName", "integer"); -<<<<<<< HEAD PvlKeyword pvlKwrd("KeyName", toString(3.5)); -======= - PvlKeyword pvlKwrd("KeyName", Isis::toString(3.5)); ->>>>>>> e6eff8ddd (Update std::tostring, stoi, stod to IString functions) pvlTmplKwrd.validateKeyword(pvlKwrd); } catch(Isis::IException &e) { @@ -341,11 +333,7 @@ TEST(PvlKeyword, KeywordValidationFail) { TEST(PvlKeyword, KeywordValidationPositive) { try { PvlKeyword pvlTmplKwrd("KeyName", "integer"); -<<<<<<< HEAD PvlKeyword pvlKwrd("KeyName", toString(-3)); -======= - PvlKeyword pvlKwrd("KeyName", Isis::toString(-3)); ->>>>>>> e6eff8ddd (Update std::tostring, stoi, stod to IString functions) pvlTmplKwrd.validateKeyword(pvlKwrd, "positive"); } catch(Isis::IException &e) { @@ -356,15 +344,9 @@ TEST(PvlKeyword, KeywordValidationPositive) { TEST(PvlKeyword, KeywordValidationRange) { try { PvlKeyword pvlTmplKwrd("KeyName", "integer"); -<<<<<<< HEAD PvlKeyword pvlTmplKwrdRange("KeyName__Range", toString(0)); pvlTmplKwrdRange.addValue(toString(10)); PvlKeyword pvlKwrd("KeyName", toString(11)); -======= - PvlKeyword pvlTmplKwrdRange("KeyName__Range", Isis::toString(0)); - pvlTmplKwrdRange.addValue(Isis::toString(10)); - PvlKeyword pvlKwrd("KeyName", Isis::toString(11)); ->>>>>>> e6eff8ddd (Update std::tostring, stoi, stod to IString functions) pvlTmplKwrd.validateKeyword(pvlKwrd, "", &pvlTmplKwrdRange); } catch(Isis::IException &e) { diff --git a/isis/tests/BundleObservationSolveSettingsTests.cpp b/isis/tests/BundleObservationSolveSettingsTests.cpp index 24bce0467b..bcc1f843a4 100644 --- a/isis/tests/BundleObservationSolveSettingsTests.cpp +++ b/isis/tests/BundleObservationSolveSettingsTests.cpp @@ -386,11 +386,11 @@ TEST(BundleObservationSolveSettings, SaveSettings){ EXPECT_PRED_FORMAT2(AssertQStringsEqual, pointingOptionsAtts.namedItem("solveTwist").nodeValue(), - QString::number(boss.solveTwist())); + QString::fromStdString(Isis::toString(boss.solveTwist()))); EXPECT_PRED_FORMAT2(AssertQStringsEqual, pointingOptionsAtts.namedItem("solveOverExisting").nodeValue(), - QString::number(boss.solvePolyOverPointing())); + QString::fromStdString(Isis::toString(boss.solvePolyOverPointing()))); EXPECT_PRED_FORMAT2(AssertQStringsEqual, pointingOptionsAtts.namedItem("interpolationType").nodeValue(), "3"); @@ -431,7 +431,7 @@ TEST(BundleObservationSolveSettings, SaveSettings){ EXPECT_PRED_FORMAT2(AssertQStringsEqual, positionOptionsAtts.namedItem("solveOverHermiteSpline").nodeValue(), - QString::number(boss.solvePositionOverHermite())); + QString::fromStdString(Isis::toString(boss.solvePositionOverHermite()))); EXPECT_PRED_FORMAT2(AssertQStringsEqual, positionOptionsAtts.namedItem("interpolationType").nodeValue(), "3"); diff --git a/isis/tests/StatisticsTest.cpp b/isis/tests/StatisticsTest.cpp index 3f56edfe25..a384a1945f 100644 --- a/isis/tests/StatisticsTest.cpp +++ b/isis/tests/StatisticsTest.cpp @@ -265,6 +265,6 @@ TEST(Statistics,XMLReadWrite) { EXPECT_DOUBLE_EQ(hrsPixels.text().toDouble(), 0.0); EXPECT_DOUBLE_EQ(underRangePixels.text().toDouble(), 0.0); EXPECT_DOUBLE_EQ(overRangePixels.text().toDouble(), 0.0); - EXPECT_STREQ(removedData.text().toStdString().c_str(), "No"); + EXPECT_STREQ(removedData.text().toStdString().c_str(), "0"); } From e9a9577d97e83a86c3cf11f44058f2504066d3fe Mon Sep 17 00:00:00 2001 From: Austin Sanders Date: Fri, 27 Sep 2024 11:14:38 -0600 Subject: [PATCH 3/4] Fix unit tests --- .../InlineCalculator/InlineCalculator.cpp | 2 +- .../ProcessExportPds4/ProcessExportPds4.cpp | 4 +- isis/src/base/objs/Statistics/unitTest.cpp | 4 +- .../base/objs/TriangularPlate/unitTest.cpp | 18 ++-- isis/src/base/objs/UserInterface/unitTest.cpp | 34 ++++---- .../objs/BundleSettings/BundleSettings.cpp | 30 +++---- .../objs/BundleSettings/BundleSettings.truth | 6 +- .../BundleObservationSolveSettings.cpp | 6 +- .../MaximumLikelihoodWFunctions.cpp | 4 +- .../MaximumLikelihoodWFunctions/unitTest.cpp | 84 +++++++++---------- isis/tests/BundleSettingsTests.cpp | 28 +++---- 11 files changed, 110 insertions(+), 110 deletions(-) diff --git a/isis/src/base/objs/InlineCalculator/InlineCalculator.cpp b/isis/src/base/objs/InlineCalculator/InlineCalculator.cpp index 53f3523e9a..1976301361 100644 --- a/isis/src/base/objs/InlineCalculator/InlineCalculator.cpp +++ b/isis/src/base/objs/InlineCalculator/InlineCalculator.cpp @@ -255,7 +255,7 @@ namespace Isis { bool InlineCalculator::isScalar(const QString &scalar) { if (scalar.isEmpty()) return (false); try { - scalar.toDouble(); + Isis::toDouble(scalar.toStdString()); return (true); } catch (IException &e) { diff --git a/isis/src/base/objs/ProcessExportPds4/ProcessExportPds4.cpp b/isis/src/base/objs/ProcessExportPds4/ProcessExportPds4.cpp index 436e780e61..9ad02e16c1 100644 --- a/isis/src/base/objs/ProcessExportPds4/ProcessExportPds4.cpp +++ b/isis/src/base/objs/ProcessExportPds4/ProcessExportPds4.cpp @@ -895,12 +895,12 @@ namespace Isis { QDomElement scalingFactorElement = m_domDoc->createElement("scaling_factor"); PvlToXmlTranslationManager::setElementValue(scalingFactorElement, - QString::fromStdString(toString(multiplier))); + QString::fromStdString(Isis::toString(multiplier))); elementArrayElement.appendChild(scalingFactorElement); QDomElement offsetElement = m_domDoc->createElement("value_offset"); PvlToXmlTranslationManager::setElementValue(offsetElement, - QString::fromStdString(toString(base))); + QString::fromStdString(Isis::toString(base))); elementArrayElement.appendChild(offsetElement); } diff --git a/isis/src/base/objs/Statistics/unitTest.cpp b/isis/src/base/objs/Statistics/unitTest.cpp index 56506ded0e..f7d81fde72 100644 --- a/isis/src/base/objs/Statistics/unitTest.cpp +++ b/isis/src/base/objs/Statistics/unitTest.cpp @@ -86,8 +86,8 @@ int main(int argc, char *argv[]) { qDebug() << "ChebyShev Max: " << s.ChebyshevMaximum(); qDebug() << "Best Minimum: " << s.BestMinimum(); qDebug() << "Best Maximum: " << s.BestMaximum(); - qDebug() << "Valid Minimum: " << s.ValidMinimum(); - qDebug() << "Valid Maximum: " << s.ValidMaximum(); + qDebug() << "Valid Minimum: " << QString::fromStdString(Isis::toString(s.ValidMinimum())); + qDebug() << "Valid Maximum: " << QString::fromStdString(Isis::toString(s.ValidMaximum())); qDebug() << "Total Pixels: " << s.TotalPixels(); qDebug() << "Valid Pixels: " << s.ValidPixels(); qDebug() << "Null Pixels: " << s.NullPixels(); diff --git a/isis/src/base/objs/TriangularPlate/unitTest.cpp b/isis/src/base/objs/TriangularPlate/unitTest.cpp index 5ba0232e97..e832ab1621 100755 --- a/isis/src/base/objs/TriangularPlate/unitTest.cpp +++ b/isis/src/base/objs/TriangularPlate/unitTest.cpp @@ -60,7 +60,7 @@ int main(int argc, char *argv[]) { qDebug() << "Observer: " << vertex; qDebug() << "Has intercept? " << tp.hasIntercept(vertex, raydir); Intercept *i = tp.intercept(vertex, raydir); - qDebug() << "Intercept is null? " << QString::number(i == NULL); + qDebug() << "Intercept is null? " << QString::fromStdString(Isis::toString(i == NULL)); qDebug() << ""; // No Plate Intercept - Case (en < 0 && tdot12 > 0) raydir[0] = 0.0; raydir[1] = 0.0; raydir[2] = 1.0; @@ -70,7 +70,7 @@ int main(int argc, char *argv[]) { qDebug() << "Observer: " << vertex; qDebug() << "Has intercept? " << tp.hasIntercept(vertex, raydir); i = tp.intercept(vertex, raydir); - qDebug() << "Intercept is null? " << QString::number(i == NULL); + qDebug() << "Intercept is null? " << QString::fromStdString(Isis::toString(i == NULL)); qDebug() << ""; // No Plate Intercept - Case (en < 0, tdot12 == 0, && tdot23 > 0) raydir[0] = -1.0; raydir[1] = 1.0; raydir[2] = 0.0; @@ -80,7 +80,7 @@ int main(int argc, char *argv[]) { qDebug() << "Observer: " << vertex; qDebug() << "Has intercept? " << tp.hasIntercept(vertex, raydir); i = tp.intercept(vertex, raydir); - qDebug() << "Intercept is null? " << QString::number(i == NULL); + qDebug() << "Intercept is null? " << QString::fromStdString(Isis::toString(i == NULL)); qDebug() << ""; // No Plate Intercept - Case (en < 0, tdot12 == 0, tdot23 < 0, && tdot31 > 0) raydir[0] = 1.0; raydir[1] = -1.0; raydir[2] = 0.0; @@ -90,7 +90,7 @@ int main(int argc, char *argv[]) { qDebug() << "Observer: " << vertex; qDebug() << "Has intercept? " << tp.hasIntercept(vertex, raydir); i = tp.intercept(vertex, raydir); - qDebug() << "Intercept is null? " << QString::number(i == NULL); + qDebug() << "Intercept is null? " << QString::fromStdString(Isis::toString(i == NULL)); qDebug() << ""; // No Plate Intercept - Case (en > 0 && tdot12 < 0) raydir[0] = 0.0; raydir[1] = 0.0; raydir[2] = -1.0; @@ -100,7 +100,7 @@ int main(int argc, char *argv[]) { qDebug() << "Observer: " << vertex; qDebug() << "Has intercept? " << tp.hasIntercept(vertex, raydir); i = tp.intercept(vertex, raydir); - qDebug() << "Intercept is null? " << QString::number(i == NULL); + qDebug() << "Intercept is null? " << QString::fromStdString(Isis::toString(i == NULL)); qDebug() << ""; // No Plate Intercept - Case (en > 0, tdot12 == 0, && tdot23 < 0) raydir[0] = -1.0; raydir[1] = 0.0; raydir[2] = 0.0; @@ -110,7 +110,7 @@ int main(int argc, char *argv[]) { qDebug() << "Observer: " << vertex; qDebug() << "Has intercept? " << tp.hasIntercept(vertex, raydir); i = tp.intercept(vertex, raydir); - qDebug() << "Intercept is null? " << QString::number(i == NULL); + qDebug() << "Intercept is null? " << QString::fromStdString(Isis::toString(i == NULL)); qDebug() << ""; // No Plate Intercept - Case (en > 0, tdot12 == tdot23 == 0, && tdot31 < 0) raydir[0] = 0.0; raydir[1] = -1.0; raydir[2] = 0.0; @@ -120,7 +120,7 @@ int main(int argc, char *argv[]) { qDebug() << "Observer: " << vertex; qDebug() << "Has intercept? " << tp.hasIntercept(vertex, raydir); i = tp.intercept(vertex, raydir); - qDebug() << "Intercept is null? " << QString::number(i == NULL); + qDebug() << "Intercept is null? " << QString::fromStdString(Isis::toString(i == NULL)); qDebug() << ""; // No Plate Intercept - Case (en != 0 && tdot12 == tdot23 == tdot31 == 0) raydir[0] = 0.0; raydir[1] = 0.0; raydir[2] = 0.0; @@ -130,7 +130,7 @@ int main(int argc, char *argv[]) { qDebug() << "Observer: " << vertex; qDebug() << "Has intercept? " << tp.hasIntercept(vertex, raydir); i = tp.intercept(vertex, raydir); - qDebug() << "Intercept is null? " << QString::number(i == NULL); + qDebug() << "Intercept is null? " << QString::fromStdString(Isis::toString(i == NULL)); qDebug() << ""; // Plate Intercept = true raydir[0] = 1.0; raydir[1] = 1.0; raydir[2] = 1.0; @@ -159,7 +159,7 @@ int main(int argc, char *argv[]) { qDebug() << "Longitude: " << lon; qDebug() << "Has point? " << tp.hasPoint(pole, lon); SurfacePoint *spPole = tp.point(pole, lon); - qDebug() << "Surface point at pole is null? " << QString::number(spPole == NULL); + qDebug() << "Surface point at pole is null? " << QString::fromStdString(Isis::toString(spPole == NULL)); qDebug() << ""; Latitude equator(0.0, Angle::Degrees); qDebug() << "Look for surface point using equator"; diff --git a/isis/src/base/objs/UserInterface/unitTest.cpp b/isis/src/base/objs/UserInterface/unitTest.cpp index e644de2d41..eec0df3c0f 100644 --- a/isis/src/base/objs/UserInterface/unitTest.cpp +++ b/isis/src/base/objs/UserInterface/unitTest.cpp @@ -39,7 +39,7 @@ int main(int argc, char *argv[]) { Isis::UserInterface ui(QString::fromStdString(unitTestXml), myArgc, myArgv); cout << "FROM: " << ui.GetAsString("FROM").toStdString() << endl; cout << "TO: " << ui.GetAsString("TO").toStdString() << endl; - cout << "GUI: " << ui.IsInteractive() << endl; + cout << "GUI: " << Isis::toString(ui.IsInteractive()) << endl; cout << endl; } @@ -58,7 +58,7 @@ int main(int argc, char *argv[]) { Isis::UserInterface ui(QString::fromStdString(highpass), myArgc, myArgv); cout << "FROM: " << ui.GetAsString("FROM").toStdString() << endl; cout << "TO: " << ui.GetAsString("TO").toStdString() << endl; - cout << "GUI: " << ui.IsInteractive() << endl; + cout << "GUI: " << Isis::toString(ui.IsInteractive()) << endl; cout << endl; } @@ -72,7 +72,7 @@ int main(int argc, char *argv[]) { Isis::UserInterface ui(QString::fromStdString(unitTestXml), myArgcQ, myArgv); cout << "FROM: " << ui.GetAsString("FROM").toStdString() << endl; cout << "TO: " << ui.GetAsString("TO").toStdString() << endl; - cout << "GUI: " << ui.IsInteractive() << endl; + cout << "GUI: " << Isis::toString(ui.IsInteractive()) << endl; cout << endl; } @@ -100,7 +100,7 @@ int main(int argc, char *argv[]) { cout << vals[i].toStdString(); } cout << endl; - cout << "GUI: " << ui.IsInteractive() << endl; + cout << "GUI: " << Isis::toString(ui.IsInteractive()) << endl; cout << endl; } @@ -126,7 +126,7 @@ int main(int argc, char *argv[]) { cout << " >> '" << vals[i].toStdString() << "'" << endl; } cout << endl; - cout << "GUI: " << ui.IsInteractive() << endl; + cout << "GUI: " << Isis::toString(ui.IsInteractive()) << endl; cout << endl; } @@ -152,7 +152,7 @@ int main(int argc, char *argv[]) { cout << " >> " << vals[i].toStdString() << endl; } cout << endl; - cout << "GUI: " << ui.IsInteractive() << endl; + cout << "GUI: " << Isis::toString(ui.IsInteractive()) << endl; cout << endl; } @@ -213,7 +213,7 @@ int main(int argc, char *argv[]) { Isis::UserInterface ui(QString::fromStdString(highpass), myArgc, myArgv); cout << "FROM: " << ui.GetAsString("FROM").toStdString() << endl; cout << "TO: " << ui.GetAsString("TO").toStdString() << endl; - cout << "GUI: " << ui.IsInteractive() << endl; + cout << "GUI: " << Isis::toString(ui.IsInteractive()) << endl; cout << endl; } @@ -228,7 +228,7 @@ int main(int argc, char *argv[]) { Isis::UserInterface ui(QString::fromStdString(unitTestXml), myArgc, myArgv); cout << "FROM: " << ui.GetAsString("FROM").toStdString() << endl; cout << "TO: " << ui.GetAsString("TO").toStdString() << endl; - cout << "GUI: " << ui.IsInteractive() << endl; + cout << "GUI: " << Isis::toString(ui.IsInteractive()) << endl; cout << endl; } @@ -358,7 +358,7 @@ int main(int argc, char *argv[]) { Isis::UserInterface ui(QString::fromStdString(unitTestXml), myArgc, myArgv); cout << "FROM: " << ui.GetAsString("FROM").toStdString() << endl; cout << "TO: " << ui.GetAsString("TO").toStdString() << endl; - cout << "GUI: " << ui.IsInteractive() << endl; + cout << "GUI: " << Isis::toString(ui.IsInteractive()) << endl; cout << endl; } @@ -384,7 +384,7 @@ int main(int argc, char *argv[]) { strcpy(myArgv[myArgc++], "unitTest"); Isis::UserInterface ui(QString::fromStdString(unitTestXml), myArgc, myArgv); - cout << "GUI: " << ui.IsInteractive() << endl; + cout << "GUI: " << Isis::toString(ui.IsInteractive()) << endl; cout << endl; } @@ -393,7 +393,7 @@ int main(int argc, char *argv[]) { strcpy(myArgv[myArgc++], "./unitTest"); Isis::UserInterface ui(QString::fromStdString(unitTestXml), myArgc, myArgv); - cout << "GUI: " << ui.IsInteractive() << endl; + cout << "GUI: " << Isis::toString(ui.IsInteractive()) << endl; cout << endl; } @@ -432,7 +432,7 @@ int main(int argc, char *argv[]) { strcpy(myArgv[myArgc++], "-nogui"); Isis::UserInterface ui(QString::fromStdString(highpass), myArgc, myArgv); - cout << "GUI: " << ui.IsInteractive() << endl; + cout << "GUI: " << Isis::toString(ui.IsInteractive()) << endl; cout << endl; } @@ -450,7 +450,7 @@ int main(int argc, char *argv[]) { ui.SetBatchList(i); cout << "FROM: " << ui.GetAsString("FROM").toStdString() << endl; cout << "TO: " << ui.GetAsString("TO").toStdString() << endl; - cout << "GUI: " << ui.IsInteractive() << endl; + cout << "GUI: " << Isis::toString(ui.IsInteractive()) << endl; cout << endl; } cout << "Finished Batchlist Test" << endl; @@ -814,7 +814,7 @@ int main(int argc, char *argv[]) { Isis::UserInterface ui(QString::fromStdString(unitTestXml), myArgc, myArgv); cout << "FROM: " << ui.GetAsString("FROM").toStdString() << endl; cout << "TO: " << ui.GetAsString("TO").toStdString() << endl; - cout << "GUI: " << ui.IsInteractive() << endl; + cout << "GUI: " << Isis::toString(ui.IsInteractive()) << endl; cout << endl; } @@ -829,7 +829,7 @@ int main(int argc, char *argv[]) { Isis::UserInterface ui(QString::fromStdString(unitTestXml), myArgc, myArgv); cout << "FROM: " << ui.GetAsString("FROM").toStdString() << endl; cout << "TO: " << ui.GetAsString("TO").toStdString() << endl; - cout << "GUI: " << ui.IsInteractive() << endl; + cout << "GUI: " << Isis::toString(ui.IsInteractive()) << endl; cout << endl; } @@ -871,7 +871,7 @@ int main(int argc, char *argv[]) { Isis::UserInterface ui(QString::fromStdString(unitTestXml), myArgc, myArgv); cout << "FROM: " << ui.GetAsString("FROM").toStdString() << endl; cout << "TO: " << ui.GetAsString("TO").toStdString() << endl; - cout << "GUI: " << ui.IsInteractive() << endl; + cout << "GUI: " << Isis::toString(ui.IsInteractive()) << endl; cout << endl; } @@ -956,7 +956,7 @@ int main(int argc, char *argv[]) { Isis::UserInterface ui(QString::fromStdString(unitTestXml), myArgc, myArgv); cout << "FROM: " << ui.GetAsString("FROM").toStdString() << endl; cout << "TO: " << ui.GetAsString("TO").toStdString() << endl; - cout << "GUI: " << ui.IsInteractive() << endl; + cout << "GUI: " << Isis::toString(ui.IsInteractive()) << endl; cout << endl; ui.SaveHistory(); diff --git a/isis/src/control/objs/BundleSettings/BundleSettings.cpp b/isis/src/control/objs/BundleSettings/BundleSettings.cpp index 568a74a4d8..ed00a06dbc 100644 --- a/isis/src/control/objs/BundleSettings/BundleSettings.cpp +++ b/isis/src/control/objs/BundleSettings/BundleSettings.cpp @@ -1027,16 +1027,16 @@ namespace Isis { stream.writeStartElement("globalSettings"); - stream.writeTextElement("validateNetwork", QString::fromStdString(toString(validateNetwork()))); + stream.writeTextElement("validateNetwork", QString::fromStdString(Isis::toString(validateNetwork()))); stream.writeStartElement("solveOptions"); - stream.writeAttribute("solveObservationMode", QString::fromStdString(toString(solveObservationMode()))); - stream.writeAttribute("solveRadius", QString::fromStdString(toString(solveRadius()))); - stream.writeAttribute("controlPointCoordTypeReports", QString::fromStdString(toString(controlPointCoordTypeReports()))); - stream.writeAttribute("controlPointCoordTypeBundle", QString::fromStdString(toString(controlPointCoordTypeBundle()))); - stream.writeAttribute("updateCubeLabel", QString::fromStdString(toString(updateCubeLabel()))); - stream.writeAttribute("errorPropagation", QString::fromStdString(toString(errorPropagation()))); - stream.writeAttribute("createInverseMatrix", QString::fromStdString(toString(createInverseMatrix()))); + stream.writeAttribute("solveObservationMode", QString::fromStdString(Isis::toString(solveObservationMode()))); + stream.writeAttribute("solveRadius", QString::fromStdString(Isis::toString(solveRadius()))); + stream.writeAttribute("controlPointCoordTypeReports", QString::number(controlPointCoordTypeReports())); + stream.writeAttribute("controlPointCoordTypeBundle", QString::number(controlPointCoordTypeBundle())); + stream.writeAttribute("updateCubeLabel", QString::fromStdString(Isis::toString(updateCubeLabel()))); + stream.writeAttribute("errorPropagation", QString::fromStdString(Isis::toString(errorPropagation()))); + stream.writeAttribute("createInverseMatrix", QString::fromStdString(Isis::toString(createInverseMatrix()))); stream.writeEndElement(); stream.writeStartElement("aprioriSigmas"); @@ -1044,26 +1044,26 @@ namespace Isis { stream.writeAttribute("pointCoord1", "N/A"); } else { - stream.writeAttribute("pointCoord1", QString::fromStdString(toString(globalPointCoord1AprioriSigma()))); + stream.writeAttribute("pointCoord1", QString::fromStdString(Isis::toString(globalPointCoord1AprioriSigma()))); } if (IsSpecial(globalPointCoord2AprioriSigma())) { stream.writeAttribute("pointCoord2", "N/A"); } else { - stream.writeAttribute("pointCoord2", QString::fromStdString(toString(globalPointCoord2AprioriSigma()))); + stream.writeAttribute("pointCoord2", QString::fromStdString(Isis::toString(globalPointCoord2AprioriSigma()))); } if (IsSpecial(globalPointCoord3AprioriSigma())) { stream.writeAttribute("pointCoord3", "N/A"); } else { - stream.writeAttribute("pointCoord3", QString::fromStdString(toString(globalPointCoord3AprioriSigma()))); + stream.writeAttribute("pointCoord3", QString::fromStdString(Isis::toString(globalPointCoord3AprioriSigma()))); } stream.writeEndElement(); stream.writeStartElement("outlierRejectionOptions"); - stream.writeAttribute("rejection", QString::fromStdString(toString(outlierRejection()))); + stream.writeAttribute("rejection", QString::fromStdString(Isis::toString(outlierRejection()))); if (outlierRejection()) { - stream.writeAttribute("multiplier", QString::fromStdString(toString(outlierRejectionMultiplier()))); + stream.writeAttribute("multiplier", QString::fromStdString(Isis::toString(outlierRejectionMultiplier()))); } else { stream.writeAttribute("multiplier", "N/A"); @@ -1074,7 +1074,7 @@ namespace Isis { stream.writeAttribute("convergenceCriteria", convergenceCriteriaToString(convergenceCriteria())); stream.writeAttribute("threshold", - QString::fromStdString(toString(convergenceCriteriaThreshold()))); + QString::fromStdString(Isis::toString(convergenceCriteriaThreshold()))); stream.writeAttribute("maximumIterations", QString::fromStdString(toString(convergenceCriteriaMaximumIterations()))); stream.writeEndElement(); @@ -1084,7 +1084,7 @@ namespace Isis { stream.writeStartElement("model"); stream.writeAttribute("type", MaximumLikelihoodWFunctions::modelToString(m_maximumLikelihood[i].first)); - stream.writeAttribute("quantile", QString::fromStdString(toString(m_maximumLikelihood[i].second))); + stream.writeAttribute("quantile", QString::fromStdString(Isis::toString(m_maximumLikelihood[i].second))); stream.writeEndElement(); } stream.writeEndElement(); diff --git a/isis/src/control/objs/BundleSettings/BundleSettings.truth b/isis/src/control/objs/BundleSettings/BundleSettings.truth index 443fa90b2b..5583958455 100644 --- a/isis/src/control/objs/BundleSettings/BundleSettings.truth +++ b/isis/src/control/objs/BundleSettings/BundleSettings.truth @@ -261,9 +261,9 @@ Now get BundleObservationSolveSettings at index 1 "Huber" "0.27" -"Welsch" "28.0" -"HuberModified" "29.0" -"Chen" "30.0" +"Welsch" "28" +"HuberModified" "29" +"Chen" "30" Testing static enum-to-string and string-to-enum methods... "Sigma0" diff --git a/isis/src/control/objs/BundleUtilities/BundleObservationSolveSettings.cpp b/isis/src/control/objs/BundleUtilities/BundleObservationSolveSettings.cpp index eda5bbaccc..f3eec3d3f3 100644 --- a/isis/src/control/objs/BundleUtilities/BundleObservationSolveSettings.cpp +++ b/isis/src/control/objs/BundleUtilities/BundleObservationSolveSettings.cpp @@ -1223,7 +1223,7 @@ namespace Isis { stream.writeAttribute("solveDegree", QString::number(m_ckSolveDegree)); stream.writeAttribute("solveTwist", QString::fromStdString(Isis::toString(m_solveTwist))); stream.writeAttribute("solveOverExisting", QString::fromStdString(Isis::toString(m_solvePointingPolynomialOverExisting))); - stream.writeAttribute("interpolationType", QString::number(m_pointingInterpolationType)); + stream.writeAttribute("interpolationType", QString::fromStdString(Isis::toString(m_pointingInterpolationType))); stream.writeStartElement("aprioriPointingSigmas"); for (int i = 0; i < m_anglesAprioriSigma.size(); i++) { @@ -1231,7 +1231,7 @@ namespace Isis { stream.writeTextElement("sigma", "N/A"); } else { - stream.writeTextElement("sigma", QString::number(m_anglesAprioriSigma[i])); + stream.writeTextElement("sigma", QString::fromStdString(Isis::toString(m_anglesAprioriSigma[i]))); } } stream.writeEndElement();// end aprioriPointingSigmas @@ -1253,7 +1253,7 @@ namespace Isis { stream.writeTextElement("sigma", "N/A"); } else { - stream.writeTextElement("sigma", QString::number(m_positionAprioriSigma[i])); + stream.writeTextElement("sigma", QString::fromStdString(Isis::toString(m_positionAprioriSigma[i]))); } } stream.writeEndElement();// end aprioriPositionSigmas diff --git a/isis/src/control/objs/MaximumLikelihoodWFunctions/MaximumLikelihoodWFunctions.cpp b/isis/src/control/objs/MaximumLikelihoodWFunctions/MaximumLikelihoodWFunctions.cpp index 1995367789..45eede9f7e 100644 --- a/isis/src/control/objs/MaximumLikelihoodWFunctions/MaximumLikelihoodWFunctions.cpp +++ b/isis/src/control/objs/MaximumLikelihoodWFunctions/MaximumLikelihoodWFunctions.cpp @@ -398,8 +398,8 @@ namespace Isis { */ QString MaximumLikelihoodWFunctions::weightedResidualCutoff() { if (m_model == Huber || m_model == HuberModified) return "N/A"; - else if (m_model == Welsch) return QString::number(m_tweakingConstant * 1.5); - else if (m_model == Chen) return QString::number(m_tweakingConstant); + else if (m_model == Welsch) return QString::fromStdString(Isis::toString(m_tweakingConstant * 1.5)); + else if (m_model == Chen) return QString::fromStdString(Isis::toString(m_tweakingConstant)); else throw IException(IException::Programmer, "Estimation model has not been set.", _FILEINFO_); } diff --git a/isis/src/control/objs/MaximumLikelihoodWFunctions/unitTest.cpp b/isis/src/control/objs/MaximumLikelihoodWFunctions/unitTest.cpp index fcf05adb7c..486d86f13c 100644 --- a/isis/src/control/objs/MaximumLikelihoodWFunctions/unitTest.cpp +++ b/isis/src/control/objs/MaximumLikelihoodWFunctions/unitTest.cpp @@ -41,9 +41,9 @@ int main(int argc, char *argv[]) { MaximumLikelihoodWFunctions wFunc; qDebug() << "Model = " << MaximumLikelihoodWFunctions::modelToString(wFunc.model()); - qDebug() << "TweakingConstant = " << QString::number(wFunc.tweakingConstant()); + qDebug() << "TweakingConstant = " << QString::fromStdString(Isis::toString(wFunc.tweakingConstant())); qDebug() << "WeightedResidualCutoff = " << wFunc.weightedResidualCutoff(); - qDebug() << "TweakingConstantQuantile = " << QString::number(wFunc.tweakingConstantQuantile()); + qDebug() << "TweakingConstantQuantile = " << QString::fromStdString(Isis::toString(wFunc.tweakingConstantQuantile())); temp = wFunc.sqrtWeightScaler(-0.5); qDebug() << "wFunc->sqrtWeightScaler(-0.5): " << temp; temp = wFunc.sqrtWeightScaler(0.75); @@ -58,9 +58,9 @@ int main(int argc, char *argv[]) { qDebug() << "TC constant re-set to 2.0:"; qDebug() << "Model = " << MaximumLikelihoodWFunctions::modelToString(wFunc.model()); - qDebug() << "TweakingConstant = " << QString::number(wFunc.tweakingConstant()); + qDebug() << "TweakingConstant = " << QString::fromStdString(Isis::toString(wFunc.tweakingConstant())); qDebug() << "WeightedResidualCutoff = " << wFunc.weightedResidualCutoff(); - qDebug() << "TweakingConstantQuantile = " << QString::number(wFunc.tweakingConstantQuantile()); + qDebug() << "TweakingConstantQuantile = " << QString::fromStdString(Isis::toString(wFunc.tweakingConstantQuantile())); temp = wFunc.sqrtWeightScaler(-0.5); qDebug() << "wFunc->sqrtWeightScaler(-0.5): " << temp; temp = wFunc.sqrtWeightScaler(0.75); @@ -75,9 +75,9 @@ int main(int argc, char *argv[]) { qDebug() << "TC constant re-set to default:"; qDebug() << "Model = " << MaximumLikelihoodWFunctions::modelToString(wFunc.model()); - qDebug() << "TweakingConstant = " << QString::number(wFunc.tweakingConstant()); + qDebug() << "TweakingConstant = " << QString::fromStdString(Isis::toString(wFunc.tweakingConstant())); qDebug() << "WeightedResidualCutoff = " << wFunc.weightedResidualCutoff(); - qDebug() << "TweakingConstantQuantile = " << QString::number(wFunc.tweakingConstantQuantile()); + qDebug() << "TweakingConstantQuantile = " << QString::fromStdString(Isis::toString(wFunc.tweakingConstantQuantile())); temp = wFunc.sqrtWeightScaler(-0.5); qDebug() << "wFunc->sqrtWeightScaler(-0.5): " << temp; temp = wFunc.sqrtWeightScaler(0.75); @@ -92,9 +92,9 @@ int main(int argc, char *argv[]) { qDebug() << "Model manually set with default TC:"; qDebug() << "Model = " << MaximumLikelihoodWFunctions::modelToString(wFunc.model()); - qDebug() << "TweakingConstant = " << QString::number(wFunc.tweakingConstant()); + qDebug() << "TweakingConstant = " << QString::fromStdString(Isis::toString(wFunc.tweakingConstant())); qDebug() << "WeightedResidualCutoff = " << wFunc.weightedResidualCutoff(); - qDebug() << "TweakingConstantQuantile = " << QString::number(wFunc.tweakingConstantQuantile()); + qDebug() << "TweakingConstantQuantile = " << QString::fromStdString(Isis::toString(wFunc.tweakingConstantQuantile())); temp = wFunc.sqrtWeightScaler(-0.5); qDebug() << "wFunc->sqrtWeightScaler(-0.5): " << temp; temp = wFunc.sqrtWeightScaler(0.75); @@ -109,9 +109,9 @@ int main(int argc, char *argv[]) { qDebug() << "Model manually set with TC = 2.0:"; qDebug() << "Model = " << MaximumLikelihoodWFunctions::modelToString(wFunc.model()); - qDebug() << "TweakingConstant = " << QString::number(wFunc.tweakingConstant()); + qDebug() << "TweakingConstant = " << QString::fromStdString(Isis::toString(wFunc.tweakingConstant())); qDebug() << "WeightedResidualCutoff = " << wFunc.weightedResidualCutoff(); - qDebug() << "TweakingConstantQuantile = " << QString::number(wFunc.tweakingConstantQuantile()); + qDebug() << "TweakingConstantQuantile = " << QString::fromStdString(Isis::toString(wFunc.tweakingConstantQuantile())); temp = wFunc.sqrtWeightScaler(-0.5); qDebug() << "wFunc->sqrtWeightScaler(-0.5): " << temp; temp = wFunc.sqrtWeightScaler(0.75); @@ -126,9 +126,9 @@ int main(int argc, char *argv[]) { qDebug() << "Testing Copy constructor:"; qDebug() << "Model = " << MaximumLikelihoodWFunctions::modelToString(copyWFunc.model()); - qDebug() << "TweakingConstant = " << QString::number(copyWFunc.tweakingConstant()); + qDebug() << "TweakingConstant = " << QString::fromStdString(Isis::toString(copyWFunc.tweakingConstant())); qDebug() << "WeightedResidualCutoff = " << copyWFunc.weightedResidualCutoff(); - qDebug() << "TweakingConstantQuantile = " << QString::number(copyWFunc.tweakingConstantQuantile()); + qDebug() << "TweakingConstantQuantile = " << QString::fromStdString(Isis::toString(copyWFunc.tweakingConstantQuantile())); temp = copyWFunc.sqrtWeightScaler(-0.5); qDebug() << "copyWFunc->sqrtWeightScaler(-0.5): " << temp; temp = copyWFunc.sqrtWeightScaler(0.75); @@ -147,9 +147,9 @@ int main(int argc, char *argv[]) { wFunc = MaximumLikelihoodWFunctions(MaximumLikelihoodWFunctions::stringToModel("HuberModified")); qDebug() << "Model = " << MaximumLikelihoodWFunctions::modelToString(wFunc.model()); - qDebug() << "TweakingConstant = " << QString::number(wFunc.tweakingConstant()); + qDebug() << "TweakingConstant = " << QString::fromStdString(Isis::toString(wFunc.tweakingConstant())); qDebug() << "WeightedResidualCutoff = " << wFunc.weightedResidualCutoff(); - qDebug() << "TweakingConstantQuantile = " << QString::number(wFunc.tweakingConstantQuantile()); + qDebug() << "TweakingConstantQuantile = " << QString::fromStdString(Isis::toString(wFunc.tweakingConstantQuantile())); temp = wFunc.sqrtWeightScaler(-0.5); qDebug() << "wFunc->sqrtWeightScaler(-0.5): " << temp; temp = wFunc.sqrtWeightScaler(0.75); @@ -164,9 +164,9 @@ int main(int argc, char *argv[]) { qDebug() << "TC constant re-set to 2.0:"; qDebug() << "Model = " << MaximumLikelihoodWFunctions::modelToString(wFunc.model()); - qDebug() << "TweakingConstant = " << QString::number(wFunc.tweakingConstant()); + qDebug() << "TweakingConstant = " << QString::fromStdString(Isis::toString(wFunc.tweakingConstant())); qDebug() << "WeightedResidualCutoff = " << wFunc.weightedResidualCutoff(); - qDebug() << "TweakingConstantQuantile = " << QString::number(wFunc.tweakingConstantQuantile()); + qDebug() << "TweakingConstantQuantile = " << QString::fromStdString(Isis::toString(wFunc.tweakingConstantQuantile())); temp = wFunc.sqrtWeightScaler(-0.5); qDebug() << "wFunc->sqrtWeightScaler(-0.5): " << temp; temp = wFunc.sqrtWeightScaler(0.75); @@ -181,9 +181,9 @@ int main(int argc, char *argv[]) { qDebug() << "TC constant re-set to default:"; qDebug() << "Model = " << MaximumLikelihoodWFunctions::modelToString(wFunc.model()); - qDebug() << "TweakingConstant = " << QString::number(wFunc.tweakingConstant()); + qDebug() << "TweakingConstant = " << QString::fromStdString(Isis::toString(wFunc.tweakingConstant())); qDebug() << "WeightedResidualCutoff = " << wFunc.weightedResidualCutoff(); - qDebug() << "TweakingConstantQuantile = " << QString::number(wFunc.tweakingConstantQuantile()); + qDebug() << "TweakingConstantQuantile = " << QString::fromStdString(Isis::toString(wFunc.tweakingConstantQuantile())); temp = wFunc.sqrtWeightScaler(-0.5); qDebug() << "wFunc->sqrtWeightScaler(-0.5): " << temp; temp = wFunc.sqrtWeightScaler(0.75); @@ -198,9 +198,9 @@ int main(int argc, char *argv[]) { qDebug() << "Model manually set to Huber_Modified with default TC:"; qDebug() << "Model = " << MaximumLikelihoodWFunctions::modelToString(wFunc.model()); - qDebug() << "TweakingConstant = " << QString::number(wFunc.tweakingConstant()); + qDebug() << "TweakingConstant = " << QString::fromStdString(Isis::toString(wFunc.tweakingConstant())); qDebug() << "WeightedResidualCutoff = " << wFunc.weightedResidualCutoff(); - qDebug() << "TweakingConstantQuantile = " << QString::number(wFunc.tweakingConstantQuantile()); + qDebug() << "TweakingConstantQuantile = " << QString::fromStdString(Isis::toString(wFunc.tweakingConstantQuantile())); temp = wFunc.sqrtWeightScaler(-0.5); qDebug() << "wFunc->sqrtWeightScaler(-0.5): " << temp; temp = wFunc.sqrtWeightScaler(0.75); @@ -215,9 +215,9 @@ int main(int argc, char *argv[]) { qDebug() << "Model manually set with TC = 2.0:"; qDebug() << "Model = " << MaximumLikelihoodWFunctions::modelToString(wFunc.model()); - qDebug() << "TweakingConstant = " << QString::number(wFunc.tweakingConstant()); + qDebug() << "TweakingConstant = " << QString::fromStdString(Isis::toString(wFunc.tweakingConstant())); qDebug() << "WeightedResidualCutoff = " << wFunc.weightedResidualCutoff(); - qDebug() << "TweakingConstantQuantile = " << QString::number(wFunc.tweakingConstantQuantile()); + qDebug() << "TweakingConstantQuantile = " << QString::fromStdString(Isis::toString(wFunc.tweakingConstantQuantile())); temp = wFunc.sqrtWeightScaler(-0.5); qDebug() << "wFunc->sqrtWeightScaler(-0.5): " << temp; temp = wFunc.sqrtWeightScaler(0.75); @@ -235,9 +235,9 @@ int main(int argc, char *argv[]) { wFunc = MaximumLikelihoodWFunctions(MaximumLikelihoodWFunctions::stringToModel("Welsch"), 2.0); qDebug() << "Model = " << MaximumLikelihoodWFunctions::modelToString(wFunc.model()); - qDebug() << "TweakingConstant = " << QString::number(wFunc.tweakingConstant()); + qDebug() << "TweakingConstant = " << QString::fromStdString(Isis::toString(wFunc.tweakingConstant())); qDebug() << "WeightedResidualCutoff = " << wFunc.weightedResidualCutoff(); - qDebug() << "TweakingConstantQuantile = " << QString::number(wFunc.tweakingConstantQuantile()); + qDebug() << "TweakingConstantQuantile = " << QString::fromStdString(Isis::toString(wFunc.tweakingConstantQuantile())); temp = wFunc.sqrtWeightScaler(-0.5); qDebug() << "wFunc->sqrtWeightScaler(-0.5): " << temp; temp = wFunc.sqrtWeightScaler(0.75); @@ -252,9 +252,9 @@ int main(int argc, char *argv[]) { qDebug() << "TC constant set to default:"; qDebug() << "Model = " << MaximumLikelihoodWFunctions::modelToString(wFunc.model()); - qDebug() << "TweakingConstant = " << QString::number(wFunc.tweakingConstant()); + qDebug() << "TweakingConstant = " << QString::fromStdString(Isis::toString(wFunc.tweakingConstant())); qDebug() << "WeightedResidualCutoff = " << wFunc.weightedResidualCutoff(); - qDebug() << "TweakingConstantQuantile = " << QString::number(wFunc.tweakingConstantQuantile()); + qDebug() << "TweakingConstantQuantile = " << QString::fromStdString(Isis::toString(wFunc.tweakingConstantQuantile())); temp = wFunc.sqrtWeightScaler(-0.5); qDebug() << "wFunc->sqrtWeightScaler(-0.5): " << temp; temp = wFunc.sqrtWeightScaler(0.75); @@ -269,9 +269,9 @@ int main(int argc, char *argv[]) { qDebug() << "Model manually set with default TC:"; qDebug() << "Model = " << MaximumLikelihoodWFunctions::modelToString(wFunc.model()); - qDebug() << "TweakingConstant = " << QString::number(wFunc.tweakingConstant()); + qDebug() << "TweakingConstant = " << QString::fromStdString(Isis::toString(wFunc.tweakingConstant())); qDebug() << "WeightedResidualCutoff = " << wFunc.weightedResidualCutoff(); - qDebug() << "TweakingConstantQuantile = " << QString::number(wFunc.tweakingConstantQuantile()); + qDebug() << "TweakingConstantQuantile = " << QString::fromStdString(Isis::toString(wFunc.tweakingConstantQuantile())); temp = wFunc.sqrtWeightScaler(-0.5); qDebug() << "wFunc->sqrtWeightScaler(-0.5): " << temp; temp = wFunc.sqrtWeightScaler(0.75); @@ -286,9 +286,9 @@ int main(int argc, char *argv[]) { qDebug() << "Model manually set with TC = 2.0:"; qDebug() << "Model = " << MaximumLikelihoodWFunctions::modelToString(wFunc.model()); - qDebug() << "TweakingConstant = " << QString::number(wFunc.tweakingConstant()); + qDebug() << "TweakingConstant = " << QString::fromStdString(Isis::toString(wFunc.tweakingConstant())); qDebug() << "WeightedResidualCutoff = " << wFunc.weightedResidualCutoff(); - qDebug() << "TweakingConstantQuantile = " << QString::number(wFunc.tweakingConstantQuantile()); + qDebug() << "TweakingConstantQuantile = " << QString::fromStdString(Isis::toString(wFunc.tweakingConstantQuantile())); temp = wFunc.sqrtWeightScaler(-0.5); qDebug() << "wFunc->sqrtWeightScaler(-0.5): " << temp; temp = wFunc.sqrtWeightScaler(0.75); @@ -307,9 +307,9 @@ int main(int argc, char *argv[]) { wFunc = MaximumLikelihoodWFunctions(MaximumLikelihoodWFunctions::stringToModel("Chen")); qDebug() << "Model = " << MaximumLikelihoodWFunctions::modelToString(wFunc.model()); - qDebug() << "TweakingConstant = " << QString::number(wFunc.tweakingConstant()); + qDebug() << "TweakingConstant = " << QString::fromStdString(Isis::toString(wFunc.tweakingConstant())); qDebug() << "WeightedResidualCutoff = " << wFunc.weightedResidualCutoff(); - qDebug() << "TweakingConstantQuantile = " << QString::number(wFunc.tweakingConstantQuantile()); + qDebug() << "TweakingConstantQuantile = " << QString::fromStdString(Isis::toString(wFunc.tweakingConstantQuantile())); temp = wFunc.sqrtWeightScaler(-0.5); qDebug() << "wFunc->sqrtWeightScaler(-0.5): " << temp; temp = wFunc.sqrtWeightScaler(0.75); @@ -324,9 +324,9 @@ int main(int argc, char *argv[]) { qDebug() << "TC constant re-set to 2.0:"; qDebug() << "Model = " << MaximumLikelihoodWFunctions::modelToString(wFunc.model()); - qDebug() << "TweakingConstant = " << QString::number(wFunc.tweakingConstant()); + qDebug() << "TweakingConstant = " << QString::fromStdString(Isis::toString(wFunc.tweakingConstant())); qDebug() << "WeightedResidualCutoff = " << wFunc.weightedResidualCutoff(); - qDebug() << "TweakingConstantQuantile = " << QString::number(wFunc.tweakingConstantQuantile()); + qDebug() << "TweakingConstantQuantile = " << QString::fromStdString(Isis::toString(wFunc.tweakingConstantQuantile())); temp = wFunc.sqrtWeightScaler(-0.5); qDebug() << "wFunc->sqrtWeightScaler(-0.5): " << temp; temp = wFunc.sqrtWeightScaler(0.75); @@ -341,9 +341,9 @@ int main(int argc, char *argv[]) { qDebug() << "TC constant re-set to default:"; qDebug() << "Model = " << MaximumLikelihoodWFunctions::modelToString(wFunc.model()); - qDebug() << "TweakingConstant = " << QString::number(wFunc.tweakingConstant()); + qDebug() << "TweakingConstant = " << QString::fromStdString(Isis::toString(wFunc.tweakingConstant())); qDebug() << "WeightedResidualCutoff = " << wFunc.weightedResidualCutoff(); - qDebug() << "TweakingConstantQuantile = " << QString::number(wFunc.tweakingConstantQuantile()); + qDebug() << "TweakingConstantQuantile = " << QString::fromStdString(Isis::toString(wFunc.tweakingConstantQuantile())); temp = wFunc.sqrtWeightScaler(-0.5); qDebug() << "wFunc->sqrtWeightScaler(-0.5): " << temp; temp = wFunc.sqrtWeightScaler(0.75); @@ -358,9 +358,9 @@ int main(int argc, char *argv[]) { qDebug() << "Model manually set with default TC:"; qDebug() << "Model = " << MaximumLikelihoodWFunctions::modelToString(wFunc.model()); - qDebug() << "TweakingConstant = " << QString::number(wFunc.tweakingConstant()); + qDebug() << "TweakingConstant = " << QString::fromStdString(Isis::toString(wFunc.tweakingConstant())); qDebug() << "WeightedResidualCutoff = " << wFunc.weightedResidualCutoff(); - qDebug() << "TweakingConstantQuantile = " << QString::number(wFunc.tweakingConstantQuantile()); + qDebug() << "TweakingConstantQuantile = " << QString::fromStdString(Isis::toString(wFunc.tweakingConstantQuantile())); temp = wFunc.sqrtWeightScaler(-0.5); qDebug() << "wFunc->sqrtWeightScaler(-0.5): " << temp; temp = wFunc.sqrtWeightScaler(0.75); @@ -375,9 +375,9 @@ int main(int argc, char *argv[]) { qDebug() << "Model manually set with TC = 2.0:"; qDebug() << "Model = " << MaximumLikelihoodWFunctions::modelToString(wFunc.model()); - qDebug() << "TweakingConstant = " << QString::number(wFunc.tweakingConstant()); + qDebug() << "TweakingConstant = " << QString::fromStdString(Isis::toString(wFunc.tweakingConstant())); qDebug() << "WeightedResidualCutoff = " << wFunc.weightedResidualCutoff(); - qDebug() << "TweakingConstantQuantile = " << QString::number(wFunc.tweakingConstantQuantile()); + qDebug() << "TweakingConstantQuantile = " << QString::fromStdString(Isis::toString(wFunc.tweakingConstantQuantile())); temp = wFunc.sqrtWeightScaler(-0.5); qDebug() << "wFunc->sqrtWeightScaler(-0.5): " << temp; temp = wFunc.sqrtWeightScaler(0.75); @@ -400,9 +400,9 @@ int main(int argc, char *argv[]) { inputData >> newWFunc; qDebug() << "Model = " << MaximumLikelihoodWFunctions::modelToString(wFunc.model()); - qDebug() << "TweakingConstant = " << QString::number(wFunc.tweakingConstant()); + qDebug() << "TweakingConstant = " << QString::fromStdString(Isis::toString(wFunc.tweakingConstant())); qDebug() << "WeightedResidualCutoff = " << wFunc.weightedResidualCutoff(); - qDebug() << "TweakingConstantQuantile = " << QString::number(wFunc.tweakingConstantQuantile()); + qDebug() << "TweakingConstantQuantile = " << QString::fromStdString(Isis::toString(wFunc.tweakingConstantQuantile())); temp = wFunc.sqrtWeightScaler(-0.5); qDebug() << "wFunc->sqrtWeightScaler(-0.5): " << temp; temp = wFunc.sqrtWeightScaler(0.75); diff --git a/isis/tests/BundleSettingsTests.cpp b/isis/tests/BundleSettingsTests.cpp index b8cc648ae5..0371dab500 100644 --- a/isis/tests/BundleSettingsTests.cpp +++ b/isis/tests/BundleSettingsTests.cpp @@ -262,7 +262,7 @@ TEST_P(BoolTest, saveValidateNetwork) { QDomElement validateNetwork = globalSettings.firstChildElement("validateNetwork"); ASSERT_FALSE(validateNetwork.isNull()); EXPECT_EQ("validateNetwork", validateNetwork.tagName()); - EXPECT_EQ(QString::number(testSettings.validateNetwork()), validateNetwork.text()); + EXPECT_EQ(QString::fromStdString(Isis::toString(testSettings.validateNetwork())), validateNetwork.text()); } TEST_P(BoolTest, outlierRejection) { @@ -285,12 +285,12 @@ TEST_P(BoolTest, saveOutlierRejection) { ASSERT_FALSE(outlierRejectionOptions.isNull()); QDomNamedNodeMap outlierRejectionOptionsAtts = outlierRejectionOptions.attributes(); EXPECT_EQ( - QString::number(testSettings.outlierRejection()), + QString::fromStdString(Isis::toString(testSettings.outlierRejection())), outlierRejectionOptionsAtts.namedItem("rejection").nodeValue() ); EXPECT_EQ( (testSettings.outlierRejection() ? - QString::number(testSettings.outlierRejectionMultiplier()) : "N/A"), + QString::fromStdString(Isis::toString(testSettings.outlierRejectionMultiplier())) : "N/A"), outlierRejectionOptionsAtts.namedItem("multiplier").nodeValue() ); } @@ -341,23 +341,23 @@ TEST_P(BoolTest, saveSolveOptions) { ASSERT_FALSE(solveOptions.isNull()); QDomNamedNodeMap solveOptionAtts = solveOptions.attributes(); EXPECT_EQ( - QString::number(testSettings.solveObservationMode()), + QString::fromStdString(Isis::toString(testSettings.solveObservationMode())), solveOptionAtts.namedItem("solveObservationMode").nodeValue() ); EXPECT_EQ( - QString::number(testSettings.solveRadius()), + QString::fromStdString(Isis::toString(testSettings.solveRadius())), solveOptionAtts.namedItem("solveRadius").nodeValue() ); EXPECT_EQ( - QString::number(testSettings.updateCubeLabel()), + QString::fromStdString(Isis::toString(testSettings.updateCubeLabel())), solveOptionAtts.namedItem("updateCubeLabel").nodeValue() ); EXPECT_EQ( - QString::number(testSettings.errorPropagation()), + QString::fromStdString(Isis::toString(testSettings.errorPropagation())), solveOptionAtts.namedItem("errorPropagation").nodeValue() ); EXPECT_EQ( - QString::number(testSettings.createInverseMatrix()), + QString::fromStdString(Isis::toString(testSettings.createInverseMatrix())), solveOptionAtts.namedItem("createInverseMatrix").nodeValue() ); } @@ -496,15 +496,15 @@ TEST(BundleSettings, saveGlobalSigmas) { ASSERT_FALSE(aprioriSigmas.isNull()); QDomNamedNodeMap aprioriSigmasAtts = aprioriSigmas.attributes(); EXPECT_EQ( - QString::number(testSettings.globalPointCoord1AprioriSigma()), + QString::fromStdString(Isis::toString(testSettings.globalPointCoord1AprioriSigma())), aprioriSigmasAtts.namedItem("pointCoord1").nodeValue() ); EXPECT_EQ( - QString::number(testSettings.globalPointCoord2AprioriSigma()), + QString::fromStdString(Isis::toString(testSettings.globalPointCoord2AprioriSigma())), aprioriSigmasAtts.namedItem("pointCoord2").nodeValue() ); EXPECT_EQ( - QString::number(testSettings.globalPointCoord3AprioriSigma()), + QString::fromStdString(Isis::toString(testSettings.globalPointCoord3AprioriSigma())), aprioriSigmasAtts.namedItem("pointCoord3").nodeValue() ); } @@ -622,11 +622,11 @@ TEST_P(ConvergenceCriteriaTest, saveConvergenceCriteria) { convergenceCriteriaOptionsAtts.namedItem("convergenceCriteria").nodeValue() ); EXPECT_EQ( - QString::number(testSettings.convergenceCriteriaThreshold()), + QString::fromStdString(Isis::toString(testSettings.convergenceCriteriaThreshold())), convergenceCriteriaOptionsAtts.namedItem("threshold").nodeValue() ); EXPECT_EQ( - QString::number(testSettings.convergenceCriteriaMaximumIterations()), + QString::fromStdString(Isis::toString(testSettings.convergenceCriteriaMaximumIterations())), convergenceCriteriaOptionsAtts.namedItem("maximumIterations").nodeValue() ); } @@ -781,7 +781,7 @@ TEST(BundleSettings, saveMaximumLikelyhoodModels) { modelAtts.namedItem("type").nodeValue() ); EXPECT_EQ( - QString::number(functions[modelIndex].second), + QString::fromStdString(Isis::toString(functions[modelIndex].second)), modelAtts.namedItem("quantile").nodeValue() ); } From a745181fcc3f2fd4c4f916bbb8cb3a10a78ec715 Mon Sep 17 00:00:00 2001 From: Austin Sanders Date: Fri, 27 Sep 2024 15:04:19 -0600 Subject: [PATCH 4/4] Fixed unit test --- .../src/base/objs/InlineInfixToPostfix/InlineInfixToPostfix.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/isis/src/base/objs/InlineInfixToPostfix/InlineInfixToPostfix.cpp b/isis/src/base/objs/InlineInfixToPostfix/InlineInfixToPostfix.cpp index f0ad222c3a..ea44e2aba7 100644 --- a/isis/src/base/objs/InlineInfixToPostfix/InlineInfixToPostfix.cpp +++ b/isis/src/base/objs/InlineInfixToPostfix/InlineInfixToPostfix.cpp @@ -155,7 +155,7 @@ namespace Isis { // if (InfixToPostfix::isKnownSymbol(token)) return (false); try { - token.toDouble(); + Isis::toDouble(token.toStdString()); return (true); } catch (IException &) {