handles generic tasks
More...
#include <iostream>
#include <fstream>
#include <vector>
#include "rapidjson/document.h"
Go to the source code of this file.
|
| std::string | loadStringFromFile (std::string filepath) |
| | loads content from specified file to a string More...
|
| |
| std::string | JSEncode (const std::string &message) |
| | encodes a string in base 64 More...
|
| |
| std::string | JSEncode (const std::vector< std::string > &message) |
| | encodes strings in a vector to base 64 More...
|
| |
| std::string | JSONToString (const rapidjson::Document &doc) |
| | converts RapidJSON documents to a string representation More...
|
| |
| std::string | url_encode (const std::string &value) |
| | encodes a string into a url More...
|
| |
| std::string | base64Decode (const std::string &value) |
| | decodes a base 64 message More...
|
| |
|
bool | caseInsensitiveEquals (const std::string &a, const std::string &b) |
| |
handles generic tasks
- Author
- Jeb Nicholson
- Copyright
- 2023 Locked & Coded
◆ base64Decode()
| std::string base64Decode |
( |
const std::string & |
value | ) |
|
decodes a base 64 message
- Parameters
-
| value | message to be decoded |
- Returns
- the decoded message
◆ JSEncode() [1/2]
| std::string JSEncode |
( |
const std::string & |
message | ) |
|
encodes a string in base 64
- Parameters
-
| message | string to be encoded |
- Returns
- the encoded base 64 string
◆ JSEncode() [2/2]
| std::string JSEncode |
( |
const std::vector< std::string > & |
message | ) |
|
encodes strings in a vector to base 64
- Parameters
-
| message | vector of strings to be encoded |
- Returns
- string representation of an array of base 64 encoded messages
◆ JSONToString()
| std::string JSONToString |
( |
const rapidjson::Document & |
doc | ) |
|
converts RapidJSON documents to a string representation
- Parameters
-
| doc | the RapidJSON document to be converted |
- Returns
- string representation JSON
◆ loadStringFromFile()
| std::string loadStringFromFile |
( |
std::string |
filepath | ) |
|
loads content from specified file to a string
- Parameters
-
- Returns
- file content
- Parameters
-
| path | string representation of file path |
- Returns
- file content
◆ url_encode()
| std::string url_encode |
( |
const std::string & |
value | ) |
|