summaryrefslogtreecommitdiff
path: root/project2/basics/tasks/session/sessionClearTask.cpp
blob: 2b016be8d44741a7afe73ccbf849a1e2a15b2d4d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
#include <pch.hpp>
#include "scriptLoader.h"
#include "sessionClearTask.h"
#include "session.h"
#include "execContext.h"

NAMEDFACTORY("sessionclear", SessionClearTask, TaskFactory);

SessionClearTask::SessionClearTask(ScriptNodePtr p) :
	SourceObject(p),
	Task(p),
	key(p->value("key", NULL).as<Glib::ustring>())
{
}

SessionClearTask::~SessionClearTask()
{
}

void
SessionClearTask::execute(ExecContext * ec) const
{
	ec->getSession()->ClearValue(key);
}