From 618c88a6e3c594b8382b4c61710a968c6adcdf49 Mon Sep 17 00:00:00 2001 From: "Matthias P. Braendli" Date: Sat, 3 Mar 2018 18:03:17 +0100 Subject: Output YAML --- src/utils.hpp | 31 ++++++++++++++++++++++++------- 1 file changed, 24 insertions(+), 7 deletions(-) (limited to 'src/utils.hpp') diff --git a/src/utils.hpp b/src/utils.hpp index fdb673e..e473166 100644 --- a/src/utils.hpp +++ b/src/utils.hpp @@ -1,6 +1,6 @@ /* Copyright (C) 2014 CSP Innovazione nelle ICT s.c.a r.l. (http://www.csp.it/) - Copyright (C) 2017 Matthias P. Braendli (http://www.opendigitalradio.org) + Copyright (C) 2018 Matthias P. Braendli (http://www.opendigitalradio.org) Copyright (C) 2015 Data Path This program is free software: you can redistribute it and/or modify @@ -48,23 +48,38 @@ struct display_settings_t { std::string strprintf(const char* fmt, ...); -void printbuf(std::string header, +void printbuf(const std::string& header, const display_settings_t &disp, uint8_t* buffer, size_t size, - std::string desc=""); + const std::string& desc="", + const std::string& value=""); -void printfig(std::string header, +void printfig(const std::string& header, const display_settings_t &disp, uint8_t* buffer, size_t size, - std::string desc=""); + const std::string& desc="", + const std::string& value=""); -void printbuf(std::string header, +void printbuf(const std::string& header, int indent, uint8_t* buffer, size_t size, - std::string desc=""); + const std::string& desc="", + const std::string& value=""); + +void printbuf(const std::string& header, int indent = 0); + +void printvalue(const std::string& header, + int indent = 0, + const std::string& desc="", + const std::string& value=""); + +void printvalue(const std::string& header, + const display_settings_t &disp, + const std::string& desc="", + const std::string& value=""); void printinfo(const std::string &header, const display_settings_t &disp, @@ -73,6 +88,8 @@ void printinfo(const std::string &header, void printinfo(const std::string &header, int min_verb); +void printsequencestart(int indent = 0); + // sprintfMJD: convert MJD (Modified Julian Date) into date string int sprintfMJD(char *dst, int mjd); -- cgit v1.2.3