Medical Imaging Interaction Toolkit  2016.11.0
Medical Imaging Interaction Toolkit
mitkRdfNode.h
Go to the documentation of this file.
1 /*===================================================================
2 
3 The Medical Imaging Interaction Toolkit (MITK)
4 
5 Copyright (c) German Cancer Research Center,
6 Division of Medical and Biological Informatics.
7 All rights reserved.
8 
9 This software is distributed WITHOUT ANY WARRANTY; without
10 even the implied warranty of MERCHANTABILITY or FITNESS FOR
11 A PARTICULAR PURPOSE.
12 
13 See LICENSE.txt or http://www.mitk.org for details.
14 
15 ===================================================================*/
16 
17 #ifndef MITKRDFNODE_H
18 #define MITKRDFNODE_H
19 
20 #include <MitkRDFExports.h>
21 
22 #include "mitkRdfUri.h"
23 
24 #include <stdio.h>
25 #include <string>
26 
27 namespace mitk {
31  class MITKRDF_EXPORT RdfNode
32  {
33  public:
34 
38  enum Type { NOTHING, URI, LITERAL, BLANK };
39 
43  RdfNode();
44 
49  RdfNode(RdfUri uri);
50 
55  RdfNode(std::string text);
56 
62  RdfNode(std::string text, RdfUri dataType);
63 
64  virtual ~RdfNode();
65 
70  void SetType(Type type);
71 
76  void SetDatatype(RdfUri dataType);
77 
82  void SetValue(std::string value);
83 
88  Type GetType() const;
89 
94  RdfUri GetDatatype() const;
95 
100  std::string GetValue() const;
101 
102  bool operator==(const RdfNode &u) const;
103  bool operator!=(const RdfNode &u) const;
104 
105  private:
106  Type m_Type;
107  std::string m_Value;
108  RdfUri m_Datatype;
109  };
110 
111  MITKRDF_EXPORT std::ostream & operator<<(std::ostream &out, const mitk::RdfNode &n);
112 }
113 
114 #endif
MITKCORE_EXPORT bool operator!=(const InteractionEvent &a, const InteractionEvent &b)
MITKCORE_EXPORT std::ostream & operator<<(std::ostream &o, DataNode::Pointer &dtn)
DataCollection - Class to facilitate loading/accessing structured data.
MITKCORE_EXPORT bool operator==(const InteractionEvent &a, const InteractionEvent &b)