HiPipe  0.7.0
C++17 data pipeline with Python bindings.
base64.hpp
1 /****************************************************************************
2  * hipipe library
3  * Copyright (c) 2017, Cognexa Solutions s.r.o.
4  * Copyright (c) 2018, Iterait a.s.
5  * Author(s) Filip Matzner
6  *
7  * This file is distributed under the MIT License.
8  * See the accompanying file LICENSE.txt for the complete license agreement.
9  ****************************************************************************/
11 
12 #pragma once
13 
14 #include <vector>
15 #include <string>
16 
17 namespace hipipe {
18 
21 std::vector<std::uint8_t> base64_decode(const std::string& b64data);
22 
25 std::string base64_encode(const std::vector<std::uint8_t>& data);
26 
27 } // end namespace hipipe
hipipe::base64_decode
std::vector< std::uint8_t > base64_decode(const std::string &b64data)
Decode base64 encoded string to a vector of bytes.
hipipe::base64_encode
std::string base64_encode(const std::vector< std::uint8_t > &data)
Encode a vector of bytes to a base64 encoded string.