#ifndef SLED_PROFILING_INTERNAL_REMOTE_GPERF_IMPL_H
#define SLED_PROFILING_INTERNAL_REMOTE_GPERF_IMPL_H

#pragma once
#include "sled/buffer.h"

namespace sled {
class RemoteGPerfImpl {
public:
    RemoteGPerfImpl(int port);
    ~RemoteGPerfImpl();

private:
    std::string HeapGET();
    std::string GrowthGET();

    // 1. read data from /proc/selfcmdline
    // 2. replace all NULL(\0) by new Lines
    std::string CmdLineGET();

    std::string SymbolGET();
    // request: 0x0824d061+0x0824d1cf
    // response: <hex address><tab><function name>
    std::string SymbolPOST(const std::string &address);
};
}// namespace sled

#endif// SLED_PROFILING_INTERNAL_REMOTE_GPERF_IMPL_H
