Golioth Firmware SDK
Loading...
Searching...
No Matches
log.h
Go to the documentation of this file.
1/*
2 * Copyright (c) 2022 Golioth, Inc.
3 *
4 * SPDX-License-Identifier: Apache-2.0
5 */
6
7#ifdef __cplusplus
8extern "C"
9{
10#endif
11
12#pragma once
13
15#include <golioth/client.h>
16
22
34enum golioth_status golioth_log_error(struct golioth_client *client,
35 const char *tag,
36 const char *log_message,
37 golioth_set_cb_fn callback,
38 void *callback_arg);
39
41enum golioth_status golioth_log_warn(struct golioth_client *client,
42 const char *tag,
43 const char *log_message,
44 golioth_set_cb_fn callback,
45 void *callback_arg);
46
48enum golioth_status golioth_log_info(struct golioth_client *client,
49 const char *tag,
50 const char *log_message,
51 golioth_set_cb_fn callback,
52 void *callback_arg);
53
55enum golioth_status golioth_log_debug(struct golioth_client *client,
56 const char *tag,
57 const char *log_message,
58 golioth_set_cb_fn callback,
59 void *callback_arg);
60
62
63#ifdef __cplusplus
64}
65#endif
golioth_status
void(* golioth_set_cb_fn)(struct golioth_client *client, enum golioth_status status, const struct golioth_coap_rsp_code *coap_rsp_code, const char *path, void *arg)
Definition client.h:254
enum golioth_status golioth_log_error(struct golioth_client *client, const char *tag, const char *log_message, golioth_set_cb_fn callback, void *callback_arg)
enum golioth_status golioth_log_info(struct golioth_client *client, const char *tag, const char *log_message, golioth_set_cb_fn callback, void *callback_arg)
Same as golioth_log_error, but for info level.
enum golioth_status golioth_log_warn(struct golioth_client *client, const char *tag, const char *log_message, golioth_set_cb_fn callback, void *callback_arg)
Same as golioth_log_error, but for warning level.
enum golioth_status golioth_log_debug(struct golioth_client *client, const char *tag, const char *log_message, golioth_set_cb_fn callback, void *callback_arg)
Same as golioth_log_error, but for debug level.