StopStrategyFactory.cpp
Go to the documentation of this file.
1
/*
2
* This file is part of ArmarX.
3
*
4
* Copyright (C) 2011-2016, High Performance Humanoid Technologies (H2T), Karlsruhe Institute of Technology (KIT), all rights reserved.
5
*
6
* ArmarX is free software; you can redistribute it and/or modify
7
* it under the terms of the GNU General Public License version 2 as
8
* published by the Free Software Foundation.
9
*
10
* ArmarX is distributed in the hope that it will be useful, but
11
* WITHOUT ANY WARRANTY; without even the implied warranty of
12
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13
* GNU General Public License for more details.
14
*
15
* You should have received a copy of the GNU General Public License
16
* along with this program. If not, see <http://www.gnu.org/licenses/>.
17
*
18
* @package ArmarXCore::core
19
* @author Nicola Miskowiec
20
* @date 2016
21
* @copyright http://www.gnu.org/licenses/gpl-2.0.txt
22
* GNU General Public License
23
*/
24
25
26
#include "
StopStrategyFactory.h
"
27
28
using namespace
ScenarioManager
;
29
using namespace
Exec;
30
31
#include "
Stop.h
"
32
#include "
StopAndKill.h
"
33
#include "
Kill.h
"
34
35
StopStrategyPtr
StopStrategyFactory::getStopStrategy
(
ApplicationStopperPtr
appStopper)
36
{
37
return
StopStrategyPtr
(
new
Stop
(appStopper));
38
}
39
40
StopStrategyPtr
StopStrategyFactory::getStopAndKillStrategy
(
ApplicationStopperPtr
appStopper,
int
delay)
41
{
42
return
StopStrategyPtr
(
new
StopAndKill
(appStopper, delay));
43
}
44
45
StopStrategyPtr
StopStrategyFactory::getKillStrategy
(
ApplicationStopperPtr
appStopper)
46
{
47
return
StopStrategyPtr
(
new
Kill
(appStopper));
48
}
ScenarioManager::Exec::Kill
Definition:
Kill.h:39
ScenarioManager::Exec::ApplicationStopperPtr
std::shared_ptr< ApplicationStopper > ApplicationStopperPtr
Definition:
ApplicationStopper.h:55
ScenarioManager::Exec::StopStrategyPtr
std::shared_ptr< StopStrategy > StopStrategyPtr
Definition:
Executor.h:46
StopAndKill.h
Stop.h
ScenarioManager::Exec::StopStrategyFactory::getStopStrategy
StopStrategyPtr getStopStrategy(ApplicationStopperPtr appStopper)
Creates a StopStrategy that simply tries to stop the application.
Definition:
StopStrategyFactory.cpp:35
ScenarioManager::Exec::Stop
Simply stops the application, using the given ApplicationStopper. This StopStrategy can be made syste...
Definition:
Stop.h:39
ScenarioManager::Exec::StopStrategyFactory::getKillStrategy
StopStrategyPtr getKillStrategy(ApplicationStopperPtr appStopper)
Definition:
StopStrategyFactory.cpp:45
ScenarioManager::Exec::StopStrategyFactory::getStopAndKillStrategy
StopStrategyPtr getStopAndKillStrategy(ApplicationStopperPtr appStopper, int delay)
Creates a StopStrategy that first tries to stop the application, the waits a certain amount of time,...
Definition:
StopStrategyFactory.cpp:40
ScenarioManager
Definition:
Application.cpp:166
StopStrategyFactory.h
Kill.h
ScenarioManager::Exec::StopAndKill
First tries to stop, then kills an application, using the given ApplicationStopper....
Definition:
StopAndKill.h:41
ArmarXCore
util
ScenarioManagerCommon
executor
StopStrategyFactory.cpp
Generated on Sat Oct 12 2024 09:14:02 for armarx_documentation by
1.8.17