StopObjectLocalization.cpp
Go to the documentation of this file.
1/*
2 * This file is part of ArmarX.
3 *
4 * ArmarX is free software; you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License version 2 as
6 * published by the Free Software Foundation.
7 *
8 * ArmarX is distributed in the hope that it will be useful, but
9 * WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 * GNU General Public License for more details.
12 *
13 * You should have received a copy of the GNU General Public License
14 * along with this program. If not, see <http://www.gnu.org/licenses/>.
15 *
16 * @package RobotSkillTemplates::ObjectLocalization
17 * @author Markus Grotz ( markus dot grotz at kit dot edu )
18 * @date 2016
19 * @copyright http://www.gnu.org/licenses/gpl-2.0.txt
20 * GNU General Public License
21 */
22
24
28
29
30using namespace armarx;
31using namespace ObjectLocalization;
32
33// DO NOT EDIT NEXT LINE
34StopObjectLocalization::SubClassRegistry
35 StopObjectLocalization::Registry(StopObjectLocalization::GetName(),
37
38void
40{
41 if (in.isObjectInstanceChannelSet())
42 {
43 memoryx::ObjectMemoryObserverInterfacePrx objectMemoryObserver = getObjectMemoryObserver();
44 objectMemoryObserver->releaseObjectClass(in.getObjectInstanceChannel());
45 }
46 if (in.isObjectIDSet())
47 {
48 // TODO: Stop localizing the object in the ObjectPoseStorage?
49 ARMARX_INFO << "Stopping localization for object '" << in.getObjectID() << "'";
50 }
51
52 emitSuccess();
53}
54
55//void StopObjectLocalization::run()
56//{
57// // put your user code for the execution-phase here
58// // runs in seperate thread, thus can do complex operations
59// // should check constantly whether isRunningTaskStopped() returns true
60//
61//// uncomment this if you need a continous run function. Make sure to use sleep or use blocking wait to reduce cpu load.
62// while (!isRunningTaskStopped()) // stop run function if returning true
63// {
64// // do your calculations
65// }
66//}
67
68//void StopObjectLocalization::onBreak()
69//{
70// // put your user code for the breaking point here
71// // execution time should be short (<100ms)
72//}
73
74void
76{
77 // put your user code for the exit point here
78 // execution time should be short (<100ms)
79}
80
81// DO NOT EDIT NEXT FUNCTION
StopObjectLocalization(const XMLStateConstructorParams &stateData)
static XMLStateFactoryBasePtr CreateInstance(XMLStateConstructorParams stateData)
#define ARMARX_INFO
The normal logging level.
Definition Logging.h:181
This file offers overloads of toIce() and fromIce() functions for STL container types.
IceInternal::Handle< XMLStateFactoryBase > XMLStateFactoryBasePtr
Definition XMLState.h:64