From 55eef968653da6e446a4779990060f5f0e5b9bce Mon Sep 17 00:00:00 2001 From: Michael Uleysky Date: Mon, 3 Oct 2016 14:02:08 +1000 Subject: [PATCH] Gmt module: Rename incorrect template name Base2NonNeg to right Base2Pos. --- modules/gmt/modgmt_func.h | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/modules/gmt/modgmt_func.h b/modules/gmt/modgmt_func.h index f6701ba..6919a27 100644 --- a/modules/gmt/modgmt_func.h +++ b/modules/gmt/modgmt_func.h @@ -195,7 +195,7 @@ class Base2CoordD: public DefaultConverter }; // Convertors for double non-negative value -class Base2NonNeg: public Base2Double +class Base2Pos: public Base2Double { public: double Convert(const ObjectBase* ob, bool* res, std::string& err) @@ -209,7 +209,7 @@ class Base2NonNeg: public Base2Double return t; } }; -using Base2NonNegD=DefaultConverter; +using Base2PosD=DefaultConverter; // Convertors for double values which must be in some interval template @@ -383,7 +383,7 @@ class Convert2Struct ONFPar proj("projection"); ONFPar region("region"); ONPar type("[projection][( |_)]t[ype]","mercator"); - ONPar width("width",gmt_projection::default_width),height("height",gmt_projection::default_width); + ONPar width("width",gmt_projection::default_width),height("height",gmt_projection::default_width); {ParseNamedParameters params(input,type,region,proj,width,height); if(!params) {err=params.Error(); goto fail;}} // Fail to parse by variant 3 @@ -433,7 +433,7 @@ class Convert2Struct } case(gmt_projection::TRANSMERCATOR): // t Parameters: central meridian (cmer, default is center of region), latitude of origin (orlat, default is 0.0), scale factor (scale, default is 1.0) { - ONPar scale("scale",1.0); + ONPar scale("scale",1.0); ONPar orlat("(l[atitude][( |_)][of( |_)]origin|o[rigin][( |_)]latitude)",0.0); {ParseNamedParameters apar(input,cmer,scale,orlat); if(!apar) {err=apar.Error(); goto fail;}} // Fail to parse additional parameters if( cmer.Exist() || changetype) p.t.cmer =cmer; @@ -572,7 +572,7 @@ class Convert2Struct { RPosPar type("projection type"); - RPosPar width("width"); + RPosPar width("width"); RPosPar region("region"); {ParsePositionalParameters params(input,0,3,type,width,region); if(!params) {err=params.Error(); goto fail;}} // Fail to parse by variant 4 @@ -586,7 +586,7 @@ class Convert2Struct { case(gmt_projection::XY): // x Parameter 4 is height (by default equal width) { - OPosPar height("height",p.width); + OPosPar height("height",p.width); {ParsePositionalParameters params(input,3,input->Size(),height); if(!params) {err=params.Error(); goto fail;}} // Fail to parse additional parameters p.x.height=height; break; @@ -611,7 +611,7 @@ class Convert2Struct { OPosPar cmer("central meridian",(p.region.xb+p.region.xe)*0.5); OPosPar orlat("latitude of origin",0.0); - OPosPar scale("scale",1.0); + OPosPar scale("scale",1.0); {ParsePositionalParameters params(input,3,input->Size(),cmer,orlat,scale); if(!params) {err=params.Error(); goto fail;}} // Fail to parse additional parameters p.t.cmer=cmer; p.t.orlat=orlat; p.t.scale=scale; break;