<commit_before>#ifndef ABSTRACTLOG_H
#define ABSTRACTLOG_H

#include <Arduino.h>
#include "configuration\Configuration.h"

namespace Tinker{

	//! Abstract interface for any logger
	/*!
		Every object that should act as a logger must inherit from this class. 
		\author <NAME>
	*/
	class AbstractLog{
	public:
		//! Endline.
		virtual void endline()=0;
		//! Display a character array.
		virtual void display(char* str)=0;
		//! Display a byte value.
		virtual void display(byte v)=0;
		//! Display a float value.
		virtual void display(float v)=0;
		//! Display a double value.
		virtual void display(double v)=0;
		//! Display an integer value.
		virtual void display(int v)=0;
		//! Display an unsigned int value.
		virtual void display(unsigned int v)=0;
		//! Display an unsigned long value.
		virtual void display(unsigned long v)=0;
		//! Clear the logger.
		virtual void clear()=0;
	};
}
#ifdef ENABLE_LOGGER
	#define SECURE_LOG(_logptr,val){if(_logptr!=0){_logptr->display(val);_logptr->endline();}}
	#define SECURE_LOG_VAL(_logptr,name,val){if(_logptr!=0){_logptr->display(name);_logptr->display(": ");_logptr->display(val);_logptr->endline();}}
	#define SECURE_LOG_CLEAR(_logptr){if(_logptr!=0){_logptr->clear();}}
	#define SECURE_LOG_ONOFF(_logptr,name,v){\
		if(_logptr!=0){\
			if(v){\
				_logptr->display(name);_logptr->display(": ON");_logptr->endline();\
			}else{\
				_logptr->display(name);_logptr->display(": OFF");_logptr->endline();\
			}\
		}\
	}
#else
	#define SECURE_LOG(_logptr,val){}
	#define SECURE_LOG_VAL(_logptr,name,val){}
	#define SECURE_LOG_CLEAR(_logptr){}
	#define SECURE_LOG_ONOFF(_logptr,name){}
#endif

#endif<commit_msg>Fix #2<commit_after>#ifndef ABSTRACTLOG_H
#define ABSTRACTLOG_H

#include <Arduino.h>
#include "configuration\Configuration.h"

namespace Tinker{

	//! Abstract interface for any logger
	/*!
		Every object that should act as a logger must inherit from this class. 
		\author <NAME>
	*/
	class AbstractLog{
	public:
		//! Endline.
		virtual void endline()=0;
		//! Display a character array.
		virtual void display(char* str)=0;
		//! Display a byte value.
		virtual void display(byte v)=0;
		//! Display a float value.
		virtual void display(float v)=0;
		//! Display a double value.
		virtual void display(double v)=0;
		//! Display an integer value.
		virtual void display(int v)=0;
		//! Display an unsigned int value.
		virtual void display(unsigned int v)=0;
		//! Display an unsigned long value.
		virtual void display(unsigned long v)=0;
		//! Clear the logger.
		virtual void clear()=0;
	};
}
#ifdef ENABLE_LOGGER
	#define SECURE_LOG(logptr,val){if((logptr)!=0){(logptr)->display(val);(logptr)->endline();}}
	#define SECURE_LOG_VAL(logptr,name,val){if((logptr)!=0){(logptr)->display(name);(logptr)->display(": ");(logptr)->display(val);(logptr)->endline();}}
	#define SECURE_LOG_CLEAR(logptr){if((logptr)!=0){(logptr)->clear();}}
	#define SECURE_LOG_ONOFF(logptr,name,v){\
		if((logptr)!=0){\
			if(v){\
				(logptr)->display(name);(logptr)->display(": ON");(logptr)->endline();\
			}else{\
				(logptr)->display(name);(logptr)->display(": OFF");(logptr)->endline();\
			}\
		}\
	}
#else
	#define SECURE_LOG(logptr,val){}
	#define SECURE_LOG_VAL(logptr,name,val){}
	#define SECURE_LOG_CLEAR(logptr){}
	#define SECURE_LOG_ONOFF(logptr,name){}
#endif

#endif
{'fraction_non_alphanumeric': 0.17288033674082984, 'fraction_numerical': 0.008117859290438966, 'mean_word_length': 4.79616724738676, 'pattern_counts': {'":': 6, '<': 7, '<?xml version=': 0, '>': 33, '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': '6559208', 'n_tokens_mistral': 1271, 'n_tokens_neox': 1178, 'n_words': 264}