SSAGES  0.8.5
Software Suite for Advanced General Ensemble Simulations
NullRequirement.h
1 
26 #pragma once
27 
28 #include "Requirement.h"
29 
30 namespace Json
31 {
33 
37  {
38  public:
40  virtual void Reset() {}
41 
43  virtual void Parse(Value, const std::string&) {}
44 
46 
50  virtual void Validate(const Value& json, const std::string& path)
51  {
52  if(!json.isNull())
53  PushError(path + ": Must be a null value");
54  }
55  };
56 }
Requires value to be of type Null.
void PushError(const std::string &error)
Add error to list of error messages.
Definition: Requirement.h:53
virtual void Validate(const Value &json, const std::string &path)
Validate that JSON value is null.
virtual void Reset()
Reset this Requirement.
virtual void Parse(Value, const std::string &)
Parse JSON value to set up this Requirement.
Requirements on input files.
Definition: Requirement.h:39