<commit_before>#ifndef _ALIB_H
#define _ALIB_H


//#include <boost/date_time/posix_time/posix_time.hpp>

#include "atype.h"
#include <time.h>

//namespace pt = boost::posix_time;

inline time_t sNow();

inline void printTime(time_t time);

/* This function will print the relative information of a block
 * DESCRIPTION:
 * it will print the:
 *	time (when the block was created)
 *	key (whatever that mean @alien)
 *	number of payloads
 *
 */
void printBlock(block *target);

/* Create a new pack (magnet link info)
 * DESCRIPTION:
 * it will allocate a pack struct, and all of its parameters
 * INPUT:
 * char * dn - display name
 * uint64_t xl - exact length (size in bytez)
 * char * xt - exact topic (URN with hash of file)
 * char * tr - tracker url
 * RETURN:
 * NULL - something went wrong :( (malloc failed)
 * ptr to new pack struct
 */
pack *newPack(char *dn, uint64_t xl, char *xt, char *tr);

tran *newTran();

block *newBlock(uint64_t key, uint32_t nPack, pack **packs);

chain *newChain(void);

//! return 1 on success
bool insertBlock(block *bx, chain *ch);

uint32_t deletePack(pack *target);

uint32_t deleteBlock(block *target);

uint32_t deleteChain(chain *target);

#endif//_ALIB_H

<commit_msg>added comment for sNow Why did you call this function sNow .. . .<commit_after>#ifndef _ALIB_H
#define _ALIB_H


//#include <boost/date_time/posix_time/posix_time.hpp>

#include "atype.h"
#include <time.h>

//namespace pt = boost::posix_time;

/* Get current time
 * DESCRIPTION:
 * Get the current time in seconds since Epoch
 */
inline time_t sNow();

inline void printTime(time_t time);

/* This function will print the relative information of a block
 * DESCRIPTION:
 * it will print the:
 *	time (when the block was created)
 *	key (whatever that mean @alien)
 *	number of payloads
 */
void printBlock(block *target);

/* Create a new pack (magnet link info)
 * DESCRIPTION:
 * it will allocate a pack struct, and all of its parameters
 * INPUT:
 * char * dn - display name
 * uint64_t xl - exact length (size in bytez)
 * char * xt - exact topic (URN with hash of file)
 * char * tr - tracker url
 * RETURN:
 * NULL - something went wrong :( (malloc failed)
 * ptr to new pack struct
 */
pack *newPack(char *dn, uint64_t xl, char *xt, char *tr);

tran *newTran();

/* Create a new block
 * DESCRIPTION:
 * 
 */
block *newBlock(uint64_t key, uint32_t nPack, pack **packs);

chain *newChain(void);

//! return 1 on success
bool insertBlock(block *bx, chain *ch);

uint32_t deletePack(pack *target);

uint32_t deleteBlock(block *target);

uint32_t deleteChain(chain *target);

#endif//_ALIB_H


{'fraction_non_alphanumeric': 0.11447166921898928, 'fraction_numerical': 0.011485451761102604, 'mean_word_length': 3.986641221374046, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 7, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, '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': '4892171', 'n_tokens_mistral': 929, 'n_tokens_neox': 886, 'n_words': 322}