/** \file Contains hooks to iterators over lidar data in the zone \author Tom Paul \version $Id$ \date 16 August 2006 */ #ifndef _atm_LidarZone_h_ #define _atm_LidarZone_h_ #include #include #include #include #include #include #include #include namespace atm { /** \class LidarZone \brief Cloud data for a Lidar zone Provides iterators over vertical slices for which VAOD is measured, as well as access to measurements of data reated to the lowest cloud in the zone. \author Tom Paul \version $Id$ \date 31 Jul 2004 \ingroup atm */ class LidarZone : public VZone { private: typedef std::vector InternalVAODSliceVector; typedef InternalVAODSliceVector::const_iterator InternalVAODSliceIterator; mutable InternalVAODSliceVector* fVAODSliceVector; public: /// VAODSlice iterator returns a pointer to the attenuation data slice for this zone typedef boost::indirect_iterator VAODSliceIterator; /// Beginning of the collection of VAODenuation data slices VAODSliceIterator VAODSlicesBegin() const; /// End of the collection of VAODenuation data slices VAODSliceIterator VAODSlicesEnd() const; /// Return the lidar maximum signal range double GetLidarMaxHeight() const; /// Return cloud coverage for the zone (in percent) double GetCloudCoverage() const; /// Lowest cloud height for the zone double GetLowestCloudHeight() const; /// Lowest cloud thickness for the zone double GetLowestCloudThickness() const; /// Lowest cloud VAOD for the zone double GetLowestCloudVAOD() const; private: LidarZone(const std::string& zoneId, const std::string& lidarId, const std::string& zoneName, const double northing, const double easting); virtual ~LidarZone(); std::string fLidarIdString; std::string fLidarZoneIdString; mutable double* fLidarMaxHeight; mutable double* fCoverage; mutable double* fLowestHeight; mutable double* fLowestThickness; mutable double* fLowestVAOD; // helper method to get cloud data // template void GetCloudData(T*& requestedData, const std::string& property) const { requestedData = new T; det::VManager::IndexMap indexMap; indexMap["lidar_zone_id"] = fLidarZoneIdString; const det::Detector& det = det::Detector::GetInstance(); const det::VManager& manager = det.GetAManagerRegister(); try { const det::VManager::Status foundFlag = manager.GetData(*requestedData, "cloud", property, indexMap); if (foundFlag == det::VManager::eFound) return; } catch (...) { delete requestedData; requestedData = 0; throw; } throw utl::DataNotFoundInDBException("cloud", property, indexMap, boost::lexical_cast(det.GetTime())); } friend class LidarDB; }; } // atm #endif //_atm_LidarZone_h_ // Configure (x)emacs for this file ... // Local Variables: // mode: c++ // compile-command: "make -C .. -k" // End: