blob: f644b254be0f14708738369bcd837208cec9d90a [file] [log] [blame]
margaretha543f2002017-07-14 00:27:15 +02001package de.ids_mannheim.korap.entity;
2
margaretha50179c82017-07-20 15:36:05 +02003import javax.persistence.Column;
margaretha543f2002017-07-14 00:27:15 +02004import javax.persistence.Entity;
5import javax.persistence.GeneratedValue;
6import javax.persistence.GenerationType;
7import javax.persistence.Id;
8import javax.persistence.Table;
9
10import lombok.Getter;
11import lombok.Setter;
12
margaretha51e5e3f2018-10-17 15:10:03 +020013/**
14 * Describes annotation tags available in the system / used in
15 * annotating corpus data.
margaretha08bdabe2017-10-17 14:38:49 +020016 *
margaretha51e5e3f2018-10-17 15:10:03 +020017 * @author margaretha
margaretha08bdabe2017-10-17 14:38:49 +020018 *
19 */
margaretha543f2002017-07-14 00:27:15 +020020@Setter
margarethae353dfa2017-07-18 19:23:29 +020021@Getter
margaretha543f2002017-07-14 00:27:15 +020022@Entity
23@Table(name = "annotation")
24public class Annotation {
margarethae353dfa2017-07-18 19:23:29 +020025
margaretha51e5e3f2018-10-17 15:10:03 +020026 public Annotation () {}
27
28 public Annotation (String code, String type, String text, String description) {
29 this.code = code;
30 this.type = type;
31 this.text = text;
32 this.description = description;
33 }
34
margaretha543f2002017-07-14 00:27:15 +020035 @Id
36 @GeneratedValue(strategy = GenerationType.IDENTITY)
37 private int id;
margarethaa14f1c22017-07-19 18:51:04 +020038 private String code;
margaretha543f2002017-07-14 00:27:15 +020039 private String type;
margaretha51e5e3f2018-10-17 15:10:03 +020040 private String text;
margaretha543f2002017-07-14 00:27:15 +020041 private String description;
margaretha50179c82017-07-20 15:36:05 +020042 @Column(name = "de_description")
43 private String germanDescription;
44
margarethae353dfa2017-07-18 19:23:29 +020045 @Override
46 public String toString () {
margarethaa14f1c22017-07-19 18:51:04 +020047 return "id=" + id + ", code= " + code + ", type= " + type
margaretha50179c82017-07-20 15:36:05 +020048 + ", description=" + description + ", germanDescription="
49 + germanDescription;
margarethae353dfa2017-07-18 19:23:29 +020050 }
margaretha543f2002017-07-14 00:27:15 +020051}