LIMA
Libre Multilingual Analyzer — C++ API
Loading...
Searching...
No Matches
SemanticAnnotation.h
Go to the documentation of this file.
1// Copyright 2002-2013 CEA LIST
2// SPDX-FileCopyrightText: 2022 CEA LIST <gael.de-chalendar@cea.fr>
3//
4// SPDX-License-Identifier: MIT
5
6/************************************************************************
7 *
8 * @file SemanticAnnotation.h
9 * @author (romaric.besancon@cea.fr)
10 * @date Thu Sep 13 2007
11 * copyright Copyright (C) 2007 by CEA LIST
12 * Project s2lp
13 *
14 * @brief simple semantic annotation to be inserted in annotation graph, associated to only one vertex
15 *
16 *
17 ***********************************************************************/
18
19#ifndef SEMANTICANNOTATION_H
20#define SEMANTICANNOTATION_H
21
25#include <iostream>
26
27namespace Lima {
28namespace LinguisticProcessing {
29namespace SemanticAnalysis {
30
32{
33 public:
34 SemanticAnnotation(const std::string& type):m_type(type) {}
36
37 const std::string& getType() const { return m_type; }
38 void setType(const std::string& type) { m_type=type; }
39 void dump(std::ostream& os) { os << m_type; }
40
41 friend std::ostream& operator << (std::ostream&, const SemanticAnnotation&);
42
43 private:
44 std::string m_type;
45};
46
48{
49 public:
50 virtual int dump(std::ostream& os, Common::AnnotationGraphs::GenericAnnotation& ga) const override;
51};
52
53} // end namespace
54} // end namespace
55} // end namespace
56
57#endif
This file is the main header file for the data related to annotation graphs.
This class allows to convert any object into an annotation by inheritance.
virtual int dump(std::ostream &os, Common::AnnotationGraphs::GenericAnnotation &ga) const override
friend std::ostream & operator<<(std::ostream &, const SemanticAnnotation &)
NAUTITIA.