knowrob
2.1.0
A Knowledge Base System for Cognition-enabled Robots
XSDAtomic.h
Go to the documentation of this file.
1
/*
2
* This file is part of KnowRob, please consult
3
* https://github.com/knowrob/knowrob for license details.
4
*/
5
6
#ifndef KNOWROB_XSD_ATOMIC_H
7
#define KNOWROB_XSD_ATOMIC_H
8
9
#include "string_view"
10
#include "
Atomic.h
"
11
#include "
RDFNode.h
"
12
#include "
XSDType.h
"
13
14
namespace
knowrob
{
18
class
XSDAtomic :
public
RDFNode,
public
Atomic {
19
public
:
20
explicit
XSDAtomic
(
XSDType
xsdType
)
21
:
RDFNode
(
RDFNodeType
::
LITERAL
),
22
Atomic
(
xsdType
==
XSDType
::
STRING
?
AtomicType
::
STRING
:
AtomicType
::
NUMERIC
),
23
xsdType_
(
xsdType
) {}
24
31
static
std::shared_ptr<XSDAtomic>
create
(std::string_view lexicalForm, std::string_view
xsdTypeIRI
);
32
37
std::string_view
xsdTypeIRI
()
const
;
38
43
XSDType
xsdType
()
const
{
return
xsdType_
; }
44
45
protected
:
46
XSDType
xsdType_
;
47
};
48
49
}
// knowrob
50
51
#endif
//KNOWROB_XSD_ATOMIC_H
knowrob::Atomic
Definition:
Atomic.h:32
knowrob::RDFNode
Definition:
RDFNode.h:27
knowrob::XSDAtomic::create
static std::shared_ptr< XSDAtomic > create(std::string_view lexicalForm, std::string_view xsdTypeIRI)
knowrob::XSDAtomic::xsdTypeIRI
std::string_view xsdTypeIRI() const
Definition:
XSDAtomic.cpp:90
knowrob::XSDAtomic::xsdType
XSDType xsdType() const
Definition:
XSDAtomic.h:43
knowrob::XSDAtomic::xsdType_
XSDType xsdType_
Definition:
XSDAtomic.h:46
knowrob::XSDAtomic::XSDAtomic
XSDAtomic(XSDType xsdType)
Definition:
XSDAtomic.h:20
Atomic.h
RDFNode.h
XSDType.h
knowrob
Definition:
DataSource.h:13
knowrob::AtomicType
AtomicType
Definition:
Atomic.h:17
knowrob::AtomicType::STRING
@ STRING
knowrob::AtomicType::NUMERIC
@ NUMERIC
knowrob::XSDType
XSDType
The XSDType enum Enumeration of the XSD types.
Definition:
XSDType.h:16
knowrob::RDFNodeType
RDFNodeType
Definition:
RDFNode.h:15
knowrob::RDFNodeType::LITERAL
@ LITERAL
include
knowrob
terms
XSDAtomic.h
Generated by
1.9.1