"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "src/metgm/MetGmGroup1Ptr.cc" between
fimex-1.4.1.tar.gz and fimex-1.4.2.tar.gz

About: Fimex is a the File Interpolation, Manipulation and EXtraction library for gridded geospatial data. It converts between different, extensible dataformats (currently netcdf, NcML, grib1/2 and felt).

MetGmGroup1Ptr.cc  (fimex-1.4.1):MetGmGroup1Ptr.cc  (fimex-1.4.2)
/* /*
* Fimex * Fimex
* *
* (C) Copyright 2011, met.no * (C) Copyright 2011-2019, met.no
* *
* Project Info: https://wiki.met.no/fimex/start * Project Info: https://wiki.met.no/fimex/start
* *
* This library is free software; you can redistribute it and/or modify it * This library is free software; you can redistribute it and/or modify it
* under the terms of the GNU Lesser General Public License as published by * under the terms of the GNU Lesser General Public License as published by
* the Free Software Foundation; either version 2.1 of the License, or * the Free Software Foundation; either version 2.1 of the License, or
* (at your option) any later version. * (at your option) any later version.
* *
* This library is distributed in the hope that it will be useful, but * This library is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
skipping to change at line 40 skipping to change at line 40
#include "MetGmGroup1Ptr.h" #include "MetGmGroup1Ptr.h"
// fimex // fimex
// //
#include "fimex/CDM.h" #include "fimex/CDM.h"
#include "fimex/CDMReader.h" #include "fimex/CDMReader.h"
#include "fimex/CDMVariable.h" #include "fimex/CDMVariable.h"
#include "fimex/String2Type.h" #include "fimex/String2Type.h"
#include "fimex/TimeUnit.h" #include "fimex/TimeUnit.h"
// standard
#include <iostream>
namespace MetNoFimex { namespace MetNoFimex {
std::shared_ptr<MetGmGroup1Ptr> MetGmGroup1Ptr::createMetGmGroup1PtrForReading(c onst std::shared_ptr<MetGmHandlePtr> pMgmHandle) std::shared_ptr<MetGmGroup1Ptr> MetGmGroup1Ptr::createMetGmGroup1PtrForReading(c onst std::shared_ptr<MetGmHandlePtr> pMgmHandle)
{ {
std::shared_ptr<MetGmGroup1Ptr> gp1 = std::shared_ptr<MetGmGroup1Ptr>(new Me tGmGroup1Ptr(pMgmHandle)); std::shared_ptr<MetGmGroup1Ptr> gp1 = std::shared_ptr<MetGmGroup1Ptr>(new Me tGmGroup1Ptr(pMgmHandle));
gp1->analysis_t = mgm_get_analysis_date_time(*pMgmHandle); gp1->analysis_t = mgm_get_analysis_date_time(*pMgmHandle);
gp1->start_t = mgm_get_start_date_time(*pMgmHandle); gp1->start_t = mgm_get_start_date_time(*pMgmHandle);
gp1->freeText_ = mgm_get_free_text(*pMgmHandle); gp1->freeText_ = mgm_get_free_text(*pMgmHandle);
gp1->modelType_ = mgm_get_model_type(*pMgmHandle); gp1->modelType_ = mgm_get_model_type(*pMgmHandle);
skipping to change at line 105 skipping to change at line 102
gp1->dataType_ = 4; gp1->dataType_ = 4;
if(!gp1->parser_->dataType().empty()) { if(!gp1->parser_->dataType().empty()) {
/* value from xml */ /* value from xml */
gp1->dataType_ = string2type<unsigned int>(gp1->parser_->dataType().c_st r()); gp1->dataType_ = string2type<unsigned int>(gp1->parser_->dataType().c_st r());
} else if(cdmRef.getAttribute(cdmRef.globalAttributeNS(), DATA_TYPE, metgmDa taTypeAttribute)) { } else if(cdmRef.getAttribute(cdmRef.globalAttributeNS(), DATA_TYPE, metgmDa taTypeAttribute)) {
/* value from cdm model */ /* value from cdm model */
gp1->dataType_ = string2type<unsigned int>(metgmDataTypeAttribute.getStr ingValue().c_str()); gp1->dataType_ = string2type<unsigned int>(metgmDataTypeAttribute.getStr ingValue().c_str());
} }
CDMAttribute metgmModelTypeAttribute; CDMAttribute metgmModelTypeAttribute;
gp1->modelType_= std::string("----------------"); gp1->modelType_ = "----------------";
gp1->modelType_ = "Arome-----------";
if(!gp1->parser_->modelType().empty()) { if(!gp1->parser_->modelType().empty()) {
/* value from xml */ /* value from xml */
gp1->modelType_ = gp1->parser_->modelType(); gp1->modelType_ = gp1->parser_->modelType();
} else if(cdmRef.getAttribute(cdmRef.globalAttributeNS(), MODEL_TYPE, metgmM odelTypeAttribute)) { } else if(cdmRef.getAttribute(cdmRef.globalAttributeNS(), MODEL_TYPE, metgmM odelTypeAttribute)) {
/* value from cdm model */ /* value from cdm model */
gp1->modelType_ = metgmModelTypeAttribute.getStringValue(); gp1->modelType_ = metgmModelTypeAttribute.getStringValue();
} }
CDMAttribute metgmProductNationAttribute; CDMAttribute metgmProductNationAttribute;
gp1->productNation_ = "NOR"; gp1->productNation_ = "NOR";
 End of changes. 3 change blocks. 
5 lines changed or deleted 3 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)