/*
 * @Description: 
 * @Version: 1.0
 * @Autor: lishengyin
 * @Date: 2022-04-26 11:17:58
 * @LastEditors: Your Name lishengyin@sz-sunwin.com
 * @LastEditTime: 2022-06-16 21:57:05
 */

#ifndef __KUBESPHERENODES_HPP_
#define __KUBESPHERENODES_HPP_

#include "K8sServerBase.hpp"

class KubeSphereNodes:public MsgBase
{
public:
    std::string UID;
    std::string NAME;
    std::string CREATIONTIMESTAMP;
    std::string LABELS;
    std::string CAPACITY;
    std::string ALLOCATABLE;
    std::string CONDITIONS;
    std::string ADDRESSES;

public:
    KubeSphereNodes(){}
    ~KubeSphereNodes(){}


    /**
     * @description: objectTojson
     * @return {*}
     */    
    void ObjectToJson(rapidjson::Writer<rapidjson::StringBuffer>& writer) override;
    
    /**
     * @description: objectToJson
     * @param {string&} str
     * @return {*}
     */    
    void ObjectToJson(std::string& str) override;

    /**
     * @description: jsonToObject
     * @param {string&} json
     * @return {*}
     */    
    bool jsonToObject(const std::string& json) override;

    /**
     * @description: jsonToObject
     * @param {Value&} object
     * @return {*}
     */    
    bool jsonToObject(const rapidjson::Value& object) override;

    /**
     * @description: ObjectToSql
     * @param {string&} sql
     * @return {*}
     */    
    virtual bool ObjectToSql(std::string& sql) override;

    /**
     * @description: ObjectToSql后处理
     * @param {string&} sql
     * @return {*}
     */ 
    virtual bool ObjectToSqlBack(std::string & sql) override;
};




#endif