1 // Copyright (C) 2014-2017 Bayerische Motoren Werke Aktiengesellschaft (BMW AG)
2 // This Source Code Form is subject to the terms of the Mozilla Public
3 // License, v. 2.0. If a copy of the MPL was not distributed with this
4 // file, You can obtain one at http://mozilla.org/MPL/2.0/.
5 
6 #include "../../../e2e_protection/include/buffer/buffer.hpp"
7 #include <iomanip>
8 
9 namespace vsomeip_v3 {
10 
operator <<(std::ostream & _os,const e2e_buffer & _buffer)11 std::ostream &operator<<(std::ostream &_os, const e2e_buffer &_buffer) {
12     for (auto b : _buffer) {
13         if (isupper(b)) {
14             _os << b;
15         } else {
16             _os << "[" << std::setfill('0') << std::setw(2) << std::hex << (uint32_t)b << std::dec << "]";
17         }
18     }
19     return _os;
20 }
21 
22 } // namespace vsomeip_v3
23