Skip to content

Commit

Permalink
check types of data and auxiliary variables
Browse files Browse the repository at this point in the history
  • Loading branch information
h-dh committed Jan 13, 2016
1 parent e9c9a14 commit 8323617
Show file tree
Hide file tree
Showing 9 changed files with 217 additions and 266 deletions.
7 changes: 7 additions & 0 deletions include/qa.h
Original file line number Diff line number Diff line change
Expand Up @@ -230,6 +230,9 @@ class QA : public IObj
std::vector<std::string> srcStr;
std::string revision;

static std::string tableSheet;
static std::string tableSheetSub;

std::string fail;
std::string fileStr;
std::string notAvailable;
Expand Down Expand Up @@ -262,4 +265,8 @@ class QA : public IObj
void setTable(std::string, std::string acronym="");
};

std::string QA::tableSheet=hdhC::empty;
std::string QA::tableSheetSub=hdhC::empty;

#endif

10 changes: 0 additions & 10 deletions include/qa_CMIP5.h
Original file line number Diff line number Diff line change
Expand Up @@ -186,10 +186,6 @@ struct CMOR
void checkRequestedAttributes(void);
void checkReqAtt_global(void);
void checkReqAtt_variable(Variable&);
/*
// requested by the CMOR table, thus checked in that context
void checkReqVariableType(void);
*/

// the next one is applied to several checks
void checkStringValues(
Expand Down Expand Up @@ -250,9 +246,6 @@ struct CMOR
//! Starting function for all table cross-checks.
void run(InFile&, VariableMetaData&);

static std::string tableSheet;
static std::string tableSheetSub;

// a little bit intricated, because of Omon-3D tracers, cf3hr, and cfSites
void bufTableSheets(VariableMetaData&);
std::vector<std::string> tableSheetBuf;
Expand Down Expand Up @@ -341,9 +334,6 @@ std::string CMOR::n_valid_max ="valid_max";
std::string CMOR::n_valid_min ="valid_min";
std::string CMOR::n_value ="value";

std::string CMOR::tableSheet=hdhC::empty;
std::string CMOR::tableSheetSub=hdhC::empty;

struct DRS_CV
{
DRS_CV(QA*);
Expand Down
1 change: 1 addition & 0 deletions include/qa_CORDEX.h
Original file line number Diff line number Diff line change
Expand Up @@ -223,6 +223,7 @@ class QA_Exp
void createVarMetaData(void);

void checkVariableType(void);
void checkVariableTypeX(size_t, size_t, size_t, std::string&);

//! Check time properties.
void domainCheck(void);
Expand Down
2 changes: 1 addition & 1 deletion include/qa_time.h
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ class QA_Time
void initResumeSession(void);

bool initTimeBounds(double offset=0.) ;
void initTimeTable(std::string id_1st, std::string id_2nd="");
void initTimeTable(void);

void openQA_NcContrib(NcAPI*);

Expand Down
16 changes: 13 additions & 3 deletions include/readline.h
Original file line number Diff line number Diff line change
Expand Up @@ -216,18 +216,26 @@ class ReadLine

//! Discard characters.
/*! From the first appearance to the end of the line.*/
void
void
skipCharacter( char c){ vSkipChars.push_back(c); isSkipCharacter=true; }

/*! Note that each character is discrded, not just the string */
void
void
skipCharacter(std::string);

//! Discard comments indicated by character [default: #].
/*! From the first appearance to the end of the line.*/
void
void
skipComment(char c='#');

//! Skip leading character(s)
/*! Note: the vector member has to be used for skipping '\0'.*/
void
skipLeadingChar(char c='\0'); // white chars by default

void
skipLeadingChar(std::vector<char>&);

//! Skip the first int lines.
bool
skipLines( int ); // skip the first int lines
Expand Down Expand Up @@ -257,6 +265,8 @@ class ReadLine

char commentChar; // default #
char lineContinuation;
std::vector<char> vc_skipLeadingChar;

std::vector<char> vSkipChars;
std::vector<double> val ; //line: converted values

Expand Down

0 comments on commit 8323617

Please sign in to comment.