<commit_before>//
// Created by <NAME> Gelldur on 8/10/16.
//

#include "ScreenCreator.h"

Screen* ScreenCreator::create(const std::string& name)
{
	return create(name, Nodect("nullObject-screen:" + name, nullptr));
}

Screen* ScreenCreator::create(const std::string& name, Nodect&& nodeScreen)
{
	DLOG("%s:%s:%d", __FILE__, __func__, __LINE__);
	ELOG("No such screen: %s", name.c_str());
	throw std::runtime_error(std::string("No such screen: ") + name);
}<commit_msg>Refactor ScreenCreator to use Fail class<commit_after>//
// Created by <NAME> Gelldur on 8/10/16.
//

#include "ScreenCreator.h"

#include <exception/Fail.h>

Screen* ScreenCreator::create(const std::string& name)
{
	return create(name, Nodect("nullObject-screen:" + name, nullptr));
}

Screen* ScreenCreator::create(const std::string& name, Nodect&& nodeScreen)
{
	Fail(__FILE__, __func__, __LINE__).add("No such screen:").add(name).report();
	return nullptr;
}
{'fraction_non_alphanumeric': 0.17830290010741137, 'fraction_numerical': 0.010741138560687433, 'mean_word_length': 6.007518796992481, 'pattern_counts': {'":': 0, '<': 6, '<?xml version=': 0, '>': 6, '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': '2618553', 'n_tokens_mistral': 334, 'n_tokens_neox': 328, 'n_words': 76}