#ifndef ProtoGenWrapper_DError_H
#define ProtoGenWrapper_DError_H

#include <string>

#include "MySerializable.h"

#include "TypeDefs.h"
namespace ProtoGenWrapper
{
	class DError : public MySerializable
	{
	public:
		DError();
		DError(int32 severity, int32 code, const std::string &codeDescription, int32 vendorCode, const std::string &vendorCodeDescription);

		int32 GetSeverity() const;
		void SetSeverity(int32 severity);
		int32 GetCode() const;
		void SetCode(int32 code);
		std::string GetCodeDescription() const;
		void SetCodeDescription(const std::string &codeDescription);
		int32 GetVendorCode() const;
		void SetVendorCode(int32 code);
		std::string GetVendorCodeDescription() const;
		void SetVendorCodeDescription(const std::string &codeDescription);

		void Serialize(std::string* output) const override;
		void Deserialize(const std::string& data) override;

	protected:
		int32 _severity = 0;
		int32 _code = 0;
		std::string _codeDescription;
		int32 _vendorCode = 0;
		std::string _vendorCodeDescription;
	};
}
#endif // ProtoGenWrapper_DError_H
