poco/Foundation/src/TaskNotification.cpp

93 lines
1.3 KiB
C++
Raw Normal View History

2012-04-29 20:52:25 +02:00
//
// TaskNotification.cpp
//
// Library: Foundation
// Package: Tasks
// Module: Tasks
//
// Copyright (c) 2004-2006, Applied Informatics Software Engineering GmbH.
// and Contributors.
//
// SPDX-License-Identifier: BSL-1.0
2012-04-29 20:52:25 +02:00
//
#include "Poco/TaskNotification.h"
namespace Poco {
TaskNotification::TaskNotification(Task* pTask):
_pTask(pTask)
{
if (_pTask) _pTask->duplicate();
}
TaskNotification::~TaskNotification()
{
if (_pTask) _pTask->release();
}
TaskStartedNotification::TaskStartedNotification(Task* pTask):
TaskNotification(pTask)
{
}
TaskStartedNotification::~TaskStartedNotification()
{
}
TaskCancelledNotification::TaskCancelledNotification(Task* pTask):
TaskNotification(pTask)
{
}
TaskCancelledNotification::~TaskCancelledNotification()
{
}
TaskFinishedNotification::TaskFinishedNotification(Task* pTask):
TaskNotification(pTask)
{
}
TaskFinishedNotification::~TaskFinishedNotification()
{
}
TaskFailedNotification::TaskFailedNotification(Task* pTask, const Exception& exc):
TaskNotification(pTask),
_pException(exc.clone())
{
}
TaskFailedNotification::~TaskFailedNotification()
{
delete _pException;
}
TaskProgressNotification::TaskProgressNotification(Task* pTask, float progress):
TaskNotification(pTask),
_progress(progress)
{
}
TaskProgressNotification::~TaskProgressNotification()
{
}
} // namespace Poco