Program Listing for File logging.h

Return to documentation for file ( cpp/api/include/trtorch/logging.h )

/*
 * Copyright (c) NVIDIA Corporation.
 * All rights reserved.
 *
 * This library is licensed under the BSD-style license found in the
 * LICENSE file in the root directory of this source tree.
 */
#pragma once

#include <string>
#include "trtorch/macros.h"

namespace trtorch {
namespace logging {
enum Level {
    kINTERNAL_ERROR,
    kERROR,
    kWARNING,
    kINFO,
    kDEBUG,
    kGRAPH,
};

// Are these ones necessary for the user?
TRTORCH_API std::string get_logging_prefix();
TRTORCH_API void set_logging_prefix(std::string prefix);

TRTORCH_API void set_reportable_log_level(Level lvl);

TRTORCH_API void set_is_colored_output_on(bool colored_output_on);

TRTORCH_API Level get_reportable_log_level();

TRTORCH_API bool get_is_colored_output_on();

// Dont know if we want this?
TRTORCH_API void log(Level lvl, std::string msg);
} // namespace logging
} // namespace trtorch