GraspSelectionCriterionBase.h
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 RobotComponents
17* @author Valerij Wittenbeck ( valerij.wittenbeck at student dot kit dot edu)
18* @date 2016
19* @copyright http://www.gnu.org/licenses/gpl-2.0.txt
20* GNU General Public License
21*/
22
23#pragma once
24
26
27#include <RobotComponents/interface/components/GraspingManager/GraspSelectionManagerInterface.h>
28
29namespace armarx
30{
31
33 {
34 public:
37 {
38 defineOptionalProperty<std::string>("GraspSelectionManagerName",
39 "GraspSelectionManager",
40 "Name of the GraspSelectionManager proxy");
41 }
42 };
43
45 virtual public GraspSelectionCriterionInterface,
46 virtual public Component
47 {
48 public:
49 /**
50 * @brief ABC for the GraspSelectionCriterion
51 *
52 * Each new criterion needs a filterGrasps(const GeneratedGraspList& grasps, const Ice::Current&) and
53 * filterPlacements(const GraspingPlacementList& placements, const Ice::Current&) method. If a criterion is
54 * supposed to only filter a GeneratedGraspList or GraspingPlacementList, respectively, the other method needs
55 * to only return the input list.
56 *
57 */
61
62 protected:
63 GraspSelectionManagerInterfacePrx graspSelectionManager;
64
65 // ManagedIceObject interface
66 protected:
67 void onInitComponent() override;
68 void onConnectComponent() override;
69
76 };
77
78} // namespace armarx
ComponentPropertyDefinitions(std::string prefix, bool hasObjectNameParameter=true)
Definition Component.cpp:46
Component()
Protected default constructor. Used for virtual inheritance. Use createManagedIceObject() instead.
Definition Component.cpp:66
std::string getConfigIdentifier()
Retrieve config identifier for this component as set in constructor.
Definition Component.cpp:90
void onInitComponent() override
Pure virtual hook for the subclass.
virtual void onConnectGraspSelectionCriterion()=0
virtual void onInitGraspSelectionCriterion()=0
void onConnectComponent() override
Pure virtual hook for the subclass.
PropertyDefinitionsPtr createPropertyDefinitions() override
GraspSelectionManagerInterfacePrx graspSelectionManager
GraspSelectionCriterionBase()
ABC for the GraspSelectionCriterion.
std::string prefix
Prefix of the properties such as namespace, domain, component name, etc.
PropertyDefinition< PropertyType > & defineOptionalProperty(const std::string &name, PropertyType defaultValue, const std::string &description="", PropertyDefinitionBase::PropertyConstness constness=PropertyDefinitionBase::eConstant)
This file offers overloads of toIce() and fromIce() functions for STL container types.
IceUtil::Handle< class PropertyDefinitionContainer > PropertyDefinitionsPtr
PropertyDefinitions smart pointer type.