<commit_before>/*
 * waysome - wayland based window manager
 *
 * Copyright in alphabetical order:
 *
 * Copyright (C) 2014-2015 <NAME>
 * Copyright (C) 2014-2015 <NAME>
 * Copyright (C) 2014-2015 <NAME>
 * Copyright (C) 2014-2015 <NAME>
 * Copyright (C) 2014-2015 <NAME>
 *
 * This file is part of waysome.
 *
 * waysome is free software: you can redistribute it and/or modify it under the
 * terms of the GNU Lesser General Public License as published by the Free
 * Software Foundation, either version 2.1 of the License, or (at your option)
 * any later version.
 *
 * waysome is distributed in the hope that it will be useful, but WITHOUT ANY
 * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
 * A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
 * details.
 *
 * You should have received a copy of the GNU Lesser General Public License
 * along with waysome. If not, see <http://www.gnu.org/licenses/>.
 */

#ifndef __WS_LOGGER_MODULE_H__
#define __WS_LOGGER_MODULE_H__

#include <stdarg.h>
#include <pthread.h>

/**
 * Logging context
 */
struct ws_logger_context {
    char const* prefix;
};

/**
 * Initialize the logger module
 *
 * @return zero on success, else error code from errno.h
 */
int
ws_logger_init(void);

/**
 * Log with a logger
 *
 * @note `ctx` can be NULL
 */
void
ws_log(
    struct ws_logger_context* const ctx, //!< The logging context
    char* fmt,  //!< Format string
    ...         //!< Additional parameters
);

/*
 * void
 * ws_log_str(
 *     struct ws_string* const str
 * );
 *
 */

#endif // __WS_LOGGER_MODULE_H__<commit_msg>Add src/logger to "logger" documentation group<commit_after>/*
 * waysome - wayland based window manager
 *
 * Copyright in alphabetical order:
 *
 * Copyright (C) 2014-2015 <NAME>
 * Copyright (C) 2014-2015 <NAME>
 * Copyright (C) 2014-2015 <NAME>
 * Copyright (C) 2014-2015 <NAME>
 * Copyright (C) 2014-2015 <NAME>
 *
 * This file is part of waysome.
 *
 * waysome is free software: you can redistribute it and/or modify it under the
 * terms of the GNU Lesser General Public License as published by the Free
 * Software Foundation, either version 2.1 of the License, or (at your option)
 * any later version.
 *
 * waysome is distributed in the hope that it will be useful, but WITHOUT ANY
 * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
 * A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
 * details.
 *
 * You should have received a copy of the GNU Lesser General Public License
 * along with waysome. If not, see <http://www.gnu.org/licenses/>.
 */

/**
 * @addtogroup logger "Logging module"
 *
 * @{
 */

#ifndef __WS_LOGGER_MODULE_H__
#define __WS_LOGGER_MODULE_H__

#include <stdarg.h>
#include <pthread.h>

/**
 * Logging context
 */
struct ws_logger_context {
    char const* prefix;
};

/**
 * Initialize the logger module
 *
 * @return zero on success, else error code from errno.h
 */
int
ws_logger_init(void);

/**
 * Log with a logger
 *
 * @note `ctx` can be NULL
 */
void
ws_log(
    struct ws_logger_context* const ctx, //!< The logging context
    char* fmt,  //!< Format string
    ...         //!< Additional parameters
);

/*
 * void
 * ws_log_str(
 *     struct ws_string* const str
 * );
 *
 */

#endif // __WS_LOGGER_MODULE_H__

/**
 * @}
 */
{'fraction_non_alphanumeric': 0.10696145802210935, 'fraction_numerical': 0.02509710188228264, 'mean_word_length': 3.3088803088803087, 'pattern_counts': {'":': 0, '<': 25, '<?xml version=': 0, '>': 19, 'https://': 0, 'lorem ipsum': 0, 'www.': 2, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1506192', 'n_tokens_mistral': 1099, 'n_tokens_neox': 1018, 'n_words': 402}