blob: bd26884e827be5210ba1b5887c4f3d201bb84327 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
|
#pragma once
#include <ctype.h>
#include <stdio.h>
#include <fstream>
#include <iomanip>
#include <iostream>
#include <string>
#include <vector>
namespace openpower
{
namespace pels
{
/**
* @brief escape json - use it for PEL hex dumps.
* @param[in] std::string - the unescaped JSON as a string literal
* @return std::string - escaped JSON string literal
*/
std::string escapeJSON(const std::string& input);
/**
* @brief get hex dump for PEL section in json format.
* @param[in] const void* - Raw PEL data
* @param[i] size_t - size of Raw PEL
* @return char * - the Hex dump
*/
char* dumpHex(const void* data, size_t size);
} // namespace pels
} // namespace openpower
|