<commit_before>// stl includes
#include <cctype>
#include <algorithm>

// Bootsequence includes
#include <bootsequence/BootSequenceFactory.h>

// Local Bootsequence includes
#include "RainbowBootSequence.h"
#include "KittBootSequence.h"

BootSequence * BootSequenceFactory::createBootSequence(Hyperion * hyperion, const Json::Value & jsonConfig)
{
	std::string type = jsonConfig["type"].asString();
	std::transform(type.begin(), type.end(), type.begin(), ::tolower);

	if (type == "none")
	{
		return nullptr;
	}
	else if (type == "rainbow")
	{
		const unsigned duration_ms = jsonConfig["duration_ms"].asUInt();
		return new RainbowBootSequence(hyperion, duration_ms);
	}
	else if (type == "knightrider" || type == "knight rider")
	{
		const unsigned duration_ms = jsonConfig["duration_ms"].asUInt();
		return new KittBootSequence(hyperion, duration_ms);
	}<commit_msg>Added message to show selected boot-sequence<commit_after>// stl includes
#include <cctype>
#include <algorithm>

// Bootsequence includes
#include <bootsequence/BootSequenceFactory.h>

// Local Bootsequence includes
#include "RainbowBootSequence.h"
#include "KittBootSequence.h"

BootSequence * BootSequenceFactory::createBootSequence(Hyperion * hyperion, const Json::Value & jsonConfig)
{
	std::string type = jsonConfig["type"].asString();
	std::transform(type.begin(), type.end(), type.begin(), ::tolower);

	if (type == "none")
	{
		return nullptr;
	}
	else if (type == "rainbow")
	{
		std::cout << "SELECTED BOOT SEQUENCE: " << "RAINBOW" << std::endl;
		const unsigned duration_ms = jsonConfig["duration_ms"].asUInt();
		return new RainbowBootSequence(hyperion, duration_ms);
	}
	else if (type == "knightrider" || type == "knight rider")
	{
		std::cout << "SELECTED BOOT SEQUENCE: " << "KITT" << std::endl;
		const unsigned duration_ms = jsonConfig["duration_ms"].asUInt();
		return new KittBootSequence(hyperion, duration_ms);
	}
{'fraction_non_alphanumeric': 0.14968487394957983, 'fraction_numerical': 0.0, 'mean_word_length': 5.877256317689531, 'pattern_counts': {'":': 0, '<': 21, '<?xml version=': 0, '>': 9, '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': '7547525', 'n_tokens_mistral': 631, 'n_tokens_neox': 598, 'n_words': 143}