// Collection of code snippets by Arne Vajhøj 
// (from articles on eksperten.dk / vajhoej.dk written sometime between 2004 and now) 
#include <iostream>
#include <chrono>

using namespace std;
using namespace std::chrono;

#include "SimpleSingleton11.h"

SimpleSingleton11* SimpleSingleton11::instance = new SimpleSingleton11();

SimpleSingleton11::SimpleSingleton11()
{
    cout << "  Constructed\t: " << duration_cast<milliseconds>(system_clock::now().time_since_epoch()).count() << endl;
}

SimpleSingleton11& SimpleSingleton11::Instance()
{
    cout << "  Retrieved\t: " << duration_cast<milliseconds>(system_clock::now().time_since_epoch()).count() << endl;
    return *instance;
}

void SimpleSingleton11::Something()
{
    cout << "  Called\t: " << duration_cast<milliseconds>(system_clock::now().time_since_epoch()).count() << endl;
}
