ClassReader.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
* @author Fabian Reister ( fabian dot reister at kit dot edu )
17
* @date 2021
18
* @copyright http://www.gnu.org/licenses/gpl-2.0.txt
19
* GNU General Public License
20
*/
21
22
#pragma once
23
24
#include <map>
25
#include <optional>
26
27
#include <
RobotAPI/libraries/armem/client/util/SimpleReaderBase.h
>
28
#include <
RobotAPI/libraries/armem_objects/types.h
>
29
30
namespace
armarx::armem::obj::clazz
31
{
32
class
ClassReader
:
public
armem::client::util::SimpleReaderBase
33
{
34
public
:
35
ClassReader
() =
default
;
36
37
std::optional<armem::clazz::ObjectClass>
getObjectClass
(
const
std::string& providerName,
38
const
armarx::ObjectID
&
id
);
39
40
/**
41
* @brief Get object class information for object class IDs.
42
* @param objectIDs The object class IDs.
43
* @return The corresponding object classes.
44
* @throw armarx::armem::error::QueryFailed If the memory query failed.
45
*/
46
std::map<armarx::ObjectID, armem::clazz::ObjectClass>
47
getObjectClasses
(
const
std::vector<armarx::ObjectID>& objectIDs);
48
49
protected
:
50
std::string
propertyPrefix
()
const
final
;
51
Properties
defaultProperties
()
const
final
;
52
};
53
54
55
}
// namespace armarx::armem::obj::clazz
armarx::armem::obj::clazz::ClassReader::getObjectClasses
std::map< armarx::ObjectID, armem::clazz::ObjectClass > getObjectClasses(const std::vector< armarx::ObjectID > &objectIDs)
Get object class information for object class IDs.
Definition:
ClassReader.cpp:35
armarx::ObjectID
A known object ID of the form "Dataset/ClassName" or "Dataset/ClassName/InstanceName".
Definition:
ObjectID.h:11
armarx::armem::obj::clazz::ClassReader::defaultProperties
Properties defaultProperties() const final
Definition:
ClassReader.cpp:77
armarx::armem::obj::clazz::ClassReader::ClassReader
ClassReader()=default
armarx::armem::obj::clazz::ClassReader::propertyPrefix
std::string propertyPrefix() const final
Definition:
ClassReader.cpp:71
armarx::armem::obj::clazz
Definition:
ClassReader.cpp:7
armarx::armem::obj::clazz::ClassReader::getObjectClass
std::optional< armem::clazz::ObjectClass > getObjectClass(const std::string &providerName, const armarx::ObjectID &id)
Definition:
ClassReader.cpp:10
armarx::armem::obj::clazz::ClassReader
Definition:
ClassReader.h:32
types.h
armarx::armem::client::util::SimpleReaderBase::Properties
Definition:
SimpleReaderBase.h:43
SimpleReaderBase.h
armarx::armem::client::util::SimpleReaderBase
Definition:
SimpleReaderBase.h:38
RobotAPI
libraries
armem_objects
client
class
ClassReader.h
Generated on Sat Oct 12 2024 09:14:09 for armarx_documentation by
1.8.17