Json::Value settings_;
CharReaderBuilder();
- virtual ~CharReaderBuilder();
+ ~CharReaderBuilder() override;
- virtual CharReader* newCharReader() const;
+ CharReader* newCharReader() const override;
/** \return true if 'settings' are legal and consistent;
* otherwise, indicate bad settings via 'invalid'.
class JSON_API Exception : public std::exception {
public:
Exception(std::string const& msg);
- virtual ~Exception() throw();
- virtual char const* what() const throw();
+ ~Exception() throw() override;
+ char const* what() const throw() override;
protected:
std::string const msg_;
};
Json::Value settings_;
StreamWriterBuilder();
- virtual ~StreamWriterBuilder();
+ ~StreamWriterBuilder() override;
/**
* \throw std::exception if something goes wrong (e.g. invalid settings)
*/
- virtual StreamWriter* newStreamWriter() const;
+ StreamWriter* newStreamWriter() const override;
/** \return true if 'settings' are legal and consistent;
* otherwise, indicate bad settings via 'invalid'.
public:
FastWriter();
- virtual ~FastWriter() {}
+ ~FastWriter() override {}
void enableYAMLCompatibility();
void omitEndingLineFeed();
public: // overridden from Writer
- virtual std::string write(const Value& root);
+ std::string write(const Value& root) override;
private:
void writeValue(const Value& value);
class JSON_API StyledWriter : public Writer {
public:
StyledWriter();
- virtual ~StyledWriter() {}
+ ~StyledWriter() override {}
public: // overridden from Writer
/** \brief Serialize a Value in <a HREF="http://www.json.org">JSON</a> format.
* \param root Value to serialize.
* \return String containing the JSON document that represents the root value.
*/
- virtual std::string write(const Value& root);
+ std::string write(const Value& root) override;
private:
void writeValue(const Value& value);
: collectComments_(collectComments)
, reader_(features)
{}
- virtual bool parse(
+ bool parse(
char const* beginDoc, char const* endDoc,
- Value* root, std::string* errs) {
+ Value* root, std::string* errs) override {
bool ok = reader_.parse(beginDoc, endDoc, *root, collectComments_);
if (errs) {
*errs = reader_.getFormattedErrorMessages();
std::string const& nullSymbol,
std::string const& endingLineFeedSymbol,
bool useSpecialFloats);
- virtual int write(Value const& root, std::ostream* sout);
+ int write(Value const& root, std::ostream* sout) override;
private:
void writeValue(Value const& value);
void writeArrayValue(Value const& value);
} \
\
public: /* overidden from TestCase */ \
- virtual const char* testName() const { return #FixtureType "/" #name; } \
- virtual void runTestCase(); \
+ const char* testName() const override { return #FixtureType "/" #name; } \
+ void runTestCase() override; \
}; \
\
void Test##FixtureType##name::runTestCase()