annotate src/main/java/de/mpiwg/itgroup/annotations/Annotation.java @ 105:7417f5915181 default tip

check admin permission before changing permissions. Enum for typesafe actions.
author casties
date Fri, 10 Feb 2017 15:45:35 +0100
parents acd44dfec9c8
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
4
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
1 /**
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
2 *
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
3 */
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
4 package de.mpiwg.itgroup.annotations;
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
5
70
2b1e6df5e21a added lgpl_v3 license information.
casties
parents: 50
diff changeset
6 /*
2b1e6df5e21a added lgpl_v3 license information.
casties
parents: 50
diff changeset
7 * #%L
2b1e6df5e21a added lgpl_v3 license information.
casties
parents: 50
diff changeset
8 * AnnotationManager
2b1e6df5e21a added lgpl_v3 license information.
casties
parents: 50
diff changeset
9 * %%
2b1e6df5e21a added lgpl_v3 license information.
casties
parents: 50
diff changeset
10 * Copyright (C) 2012 - 2014 MPIWG Berlin
2b1e6df5e21a added lgpl_v3 license information.
casties
parents: 50
diff changeset
11 * %%
2b1e6df5e21a added lgpl_v3 license information.
casties
parents: 50
diff changeset
12 * This program is free software: you can redistribute it and/or modify
2b1e6df5e21a added lgpl_v3 license information.
casties
parents: 50
diff changeset
13 * it under the terms of the GNU Lesser General Public License as
2b1e6df5e21a added lgpl_v3 license information.
casties
parents: 50
diff changeset
14 * published by the Free Software Foundation, either version 3 of the
2b1e6df5e21a added lgpl_v3 license information.
casties
parents: 50
diff changeset
15 * License, or (at your option) any later version.
2b1e6df5e21a added lgpl_v3 license information.
casties
parents: 50
diff changeset
16 *
2b1e6df5e21a added lgpl_v3 license information.
casties
parents: 50
diff changeset
17 * This program is distributed in the hope that it will be useful,
2b1e6df5e21a added lgpl_v3 license information.
casties
parents: 50
diff changeset
18 * but WITHOUT ANY WARRANTY; without even the implied warranty of
2b1e6df5e21a added lgpl_v3 license information.
casties
parents: 50
diff changeset
19 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
2b1e6df5e21a added lgpl_v3 license information.
casties
parents: 50
diff changeset
20 * GNU General Lesser Public License for more details.
2b1e6df5e21a added lgpl_v3 license information.
casties
parents: 50
diff changeset
21 *
2b1e6df5e21a added lgpl_v3 license information.
casties
parents: 50
diff changeset
22 * You should have received a copy of the GNU General Lesser Public
2b1e6df5e21a added lgpl_v3 license information.
casties
parents: 50
diff changeset
23 * License along with this program. If not, see
2b1e6df5e21a added lgpl_v3 license information.
casties
parents: 50
diff changeset
24 * <http://www.gnu.org/licenses/lgpl-3.0.html>.
2b1e6df5e21a added lgpl_v3 license information.
casties
parents: 50
diff changeset
25 * #L%
2b1e6df5e21a added lgpl_v3 license information.
casties
parents: 50
diff changeset
26 */
2b1e6df5e21a added lgpl_v3 license information.
casties
parents: 50
diff changeset
27
50
64aa756c60cc annotations ui can show and delete annotations now.
casties
parents: 48
diff changeset
28 import java.io.UnsupportedEncodingException;
16
794077e6288c CLOSED - # 252: Tags for Annotations
casties
parents: 15
diff changeset
29 import java.util.Set;
794077e6288c CLOSED - # 252: Tags for Annotations
casties
parents: 15
diff changeset
30
50
64aa756c60cc annotations ui can show and delete annotations now.
casties
parents: 48
diff changeset
31 import org.apache.commons.codec.binary.Base64;
64aa756c60cc annotations ui can show and delete annotations now.
casties
parents: 48
diff changeset
32
15
58357a4b86de ASSIGNED - # 249: Annotations shared in groups
casties
parents: 14
diff changeset
33 import de.mpiwg.itgroup.annotations.neo4j.AnnotationStore;
58357a4b86de ASSIGNED - # 249: Annotations shared in groups
casties
parents: 14
diff changeset
34
4
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
35 /**
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
36 * @author casties
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
37 *
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
38 */
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
39 public class Annotation {
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
40 /**
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
41 * The URI of this annotation.
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
42 */
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
43 protected String uri;
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
44
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
45 /**
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
46 * The annotation (body) text.
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
47 */
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
48 protected String bodyText;
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
49
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
50 /**
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
51 * The URI of the annotation text
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
52 */
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
53 protected String bodyUri;
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
54
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
55 /**
48
0e00bf8e27fb targets and resources of Annotation object are objects now.
casties
parents: 40
diff changeset
56 * The annotation target.
4
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
57 */
48
0e00bf8e27fb targets and resources of Annotation object are objects now.
casties
parents: 40
diff changeset
58 protected Target target;
4
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
59
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
60 /**
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
61 * The fragment part of the annotation target.
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
62 */
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
63 protected String targetFragment;
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
64
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
65 /**
40
03e0f7574224 saving and loading resource targets should work now (no searching yet)
casties
parents: 20
diff changeset
66 * The types of annotation target fragments.
4
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
67 *
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
68 */
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
69 public static enum FragmentTypes {
84
6bf38b5e30a8 also stores polygon shape image annotations.
casties
parents: 76
diff changeset
70 XPOINTER, AREA, WKT
4
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
71 };
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
72
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
73 /**
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
74 * The type of the annotation target fragment.
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
75 */
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
76 protected FragmentTypes fragmentType;
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
77
76
4e2dc67997a0 save text quote from Annotator.
casties
parents: 70
diff changeset
78 /**
4e2dc67997a0 save text quote from Annotator.
casties
parents: 70
diff changeset
79 * The selected text of the annotation target.
4e2dc67997a0 save text quote from Annotator.
casties
parents: 70
diff changeset
80 */
4e2dc67997a0 save text quote from Annotator.
casties
parents: 70
diff changeset
81 protected String quote;
40
03e0f7574224 saving and loading resource targets should work now (no searching yet)
casties
parents: 20
diff changeset
82
03e0f7574224 saving and loading resource targets should work now (no searching yet)
casties
parents: 20
diff changeset
83 /**
48
0e00bf8e27fb targets and resources of Annotation object are objects now.
casties
parents: 40
diff changeset
84 * The Resource that is annotated e.g. a book.
40
03e0f7574224 saving and loading resource targets should work now (no searching yet)
casties
parents: 20
diff changeset
85 * The target is part of this resource e.g. a page of a book.
03e0f7574224 saving and loading resource targets should work now (no searching yet)
casties
parents: 20
diff changeset
86 */
48
0e00bf8e27fb targets and resources of Annotation object are objects now.
casties
parents: 40
diff changeset
87 protected Resource resource;
40
03e0f7574224 saving and loading resource targets should work now (no searching yet)
casties
parents: 20
diff changeset
88
4
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
89 /**
9
b2bfc3bc9ba8 new internal actor class for creator.
casties
parents: 8
diff changeset
90 * The creator of this annotation.
4
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
91 */
9
b2bfc3bc9ba8 new internal actor class for creator.
casties
parents: 8
diff changeset
92 protected Actor creator;
5
bbf0cc5bee29 version 0.2 really works now
casties
parents: 4
diff changeset
93
bbf0cc5bee29 version 0.2 really works now
casties
parents: 4
diff changeset
94 /**
4
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
95 * The creation date of this annotation.
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
96 */
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
97 protected String created;
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
98
10
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
99 /**
95
acd44dfec9c8 added last update field for annotations in database.
casties
parents: 84
diff changeset
100 * The last update date of this annotation.
acd44dfec9c8 added last update field for annotations in database.
casties
parents: 84
diff changeset
101 */
acd44dfec9c8 added last update field for annotations in database.
casties
parents: 84
diff changeset
102 protected String updated;
acd44dfec9c8 added last update field for annotations in database.
casties
parents: 84
diff changeset
103
acd44dfec9c8 added last update field for annotations in database.
casties
parents: 84
diff changeset
104 /**
10
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
105 * The user or group that has admin permissions.
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
106 * null means any user.
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
107 */
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
108 protected Actor adminPermission;
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
109
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
110 /**
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
111 * The user or group that has delete permissions.
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
112 * null means any user.
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
113 */
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
114 protected Actor deletePermission;
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
115
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
116 /**
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
117 * The user or group that has update permissions.
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
118 * null means any user.
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
119 */
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
120 protected Actor updatePermission;
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
121
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
122 /**
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
123 * The user or group that has read permissions.
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
124 * null means any user.
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
125 */
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
126 protected Actor readPermission;
16
794077e6288c CLOSED - # 252: Tags for Annotations
casties
parents: 15
diff changeset
127
794077e6288c CLOSED - # 252: Tags for Annotations
casties
parents: 15
diff changeset
128 /**
794077e6288c CLOSED - # 252: Tags for Annotations
casties
parents: 15
diff changeset
129 * List of tags on this Annotation.
794077e6288c CLOSED - # 252: Tags for Annotations
casties
parents: 15
diff changeset
130 */
794077e6288c CLOSED - # 252: Tags for Annotations
casties
parents: 15
diff changeset
131 protected Set<String> tags;
14
629e15b345aa permissions mostly work. need more server-side checking.
casties
parents: 10
diff changeset
132
629e15b345aa permissions mostly work. need more server-side checking.
casties
parents: 10
diff changeset
133 /**
105
7417f5915181 check admin permission before changing permissions.
casties
parents: 95
diff changeset
134 * Enum of actions (for permissions).
7417f5915181 check admin permission before changing permissions.
casties
parents: 95
diff changeset
135 */
7417f5915181 check admin permission before changing permissions.
casties
parents: 95
diff changeset
136 public static enum Action {
7417f5915181 check admin permission before changing permissions.
casties
parents: 95
diff changeset
137 read, update, create, delete, admin
7417f5915181 check admin permission before changing permissions.
casties
parents: 95
diff changeset
138 }
7417f5915181 check admin permission before changing permissions.
casties
parents: 95
diff changeset
139
7417f5915181 check admin permission before changing permissions.
casties
parents: 95
diff changeset
140 /**
20
715aa11d138b fixes in permission handling: admin and delete default to creator.
casties
parents: 16
diff changeset
141 * Returns if the requested action is allowed for the given user on this annotation.
14
629e15b345aa permissions mostly work. need more server-side checking.
casties
parents: 10
diff changeset
142 *
629e15b345aa permissions mostly work. need more server-side checking.
casties
parents: 10
diff changeset
143 * @param action
15
58357a4b86de ASSIGNED - # 249: Annotations shared in groups
casties
parents: 14
diff changeset
144 * @param user
58357a4b86de ASSIGNED - # 249: Annotations shared in groups
casties
parents: 14
diff changeset
145 * @param store AnnotationStore to check group membership
14
629e15b345aa permissions mostly work. need more server-side checking.
casties
parents: 10
diff changeset
146 * @return
629e15b345aa permissions mostly work. need more server-side checking.
casties
parents: 10
diff changeset
147 */
105
7417f5915181 check admin permission before changing permissions.
casties
parents: 95
diff changeset
148 public boolean isActionAllowed(Action action, Person user, AnnotationStore store) {
7417f5915181 check admin permission before changing permissions.
casties
parents: 95
diff changeset
149 if (action == Action.read) {
14
629e15b345aa permissions mostly work. need more server-side checking.
casties
parents: 10
diff changeset
150 Actor reader = getReadPermission();
629e15b345aa permissions mostly work. need more server-side checking.
casties
parents: 10
diff changeset
151 if (reader == null) {
20
715aa11d138b fixes in permission handling: admin and delete default to creator.
casties
parents: 16
diff changeset
152 // if not specified then everybody is allowed
14
629e15b345aa permissions mostly work. need more server-side checking.
casties
parents: 10
diff changeset
153 return true;
629e15b345aa permissions mostly work. need more server-side checking.
casties
parents: 10
diff changeset
154 } else {
15
58357a4b86de ASSIGNED - # 249: Annotations shared in groups
casties
parents: 14
diff changeset
155 return reader.isEquivalentWith(user, store);
14
629e15b345aa permissions mostly work. need more server-side checking.
casties
parents: 10
diff changeset
156 }
105
7417f5915181 check admin permission before changing permissions.
casties
parents: 95
diff changeset
157 } else if (action == Action.update) {
14
629e15b345aa permissions mostly work. need more server-side checking.
casties
parents: 10
diff changeset
158 // require at least an authenticated user
15
58357a4b86de ASSIGNED - # 249: Annotations shared in groups
casties
parents: 14
diff changeset
159 if (user == null) return false;
14
629e15b345aa permissions mostly work. need more server-side checking.
casties
parents: 10
diff changeset
160 Actor updater = getUpdatePermission();
629e15b345aa permissions mostly work. need more server-side checking.
casties
parents: 10
diff changeset
161 if (updater == null) {
20
715aa11d138b fixes in permission handling: admin and delete default to creator.
casties
parents: 16
diff changeset
162 // if not specified then everybody is allowed
14
629e15b345aa permissions mostly work. need more server-side checking.
casties
parents: 10
diff changeset
163 return true;
629e15b345aa permissions mostly work. need more server-side checking.
casties
parents: 10
diff changeset
164 } else {
15
58357a4b86de ASSIGNED - # 249: Annotations shared in groups
casties
parents: 14
diff changeset
165 return updater.isEquivalentWith(user, store);
14
629e15b345aa permissions mostly work. need more server-side checking.
casties
parents: 10
diff changeset
166 }
105
7417f5915181 check admin permission before changing permissions.
casties
parents: 95
diff changeset
167 } else if (action == Action.delete) {
14
629e15b345aa permissions mostly work. need more server-side checking.
casties
parents: 10
diff changeset
168 // require at least an authenticated user
15
58357a4b86de ASSIGNED - # 249: Annotations shared in groups
casties
parents: 14
diff changeset
169 if (user == null) return false;
20
715aa11d138b fixes in permission handling: admin and delete default to creator.
casties
parents: 16
diff changeset
170 Actor deleter = getDeletePermission();
715aa11d138b fixes in permission handling: admin and delete default to creator.
casties
parents: 16
diff changeset
171 if (deleter == null) {
715aa11d138b fixes in permission handling: admin and delete default to creator.
casties
parents: 16
diff changeset
172 // if not specified then only creator is allowed
715aa11d138b fixes in permission handling: admin and delete default to creator.
casties
parents: 16
diff changeset
173 deleter = creator;
14
629e15b345aa permissions mostly work. need more server-side checking.
casties
parents: 10
diff changeset
174 }
20
715aa11d138b fixes in permission handling: admin and delete default to creator.
casties
parents: 16
diff changeset
175 return deleter.isEquivalentWith(user, store);
105
7417f5915181 check admin permission before changing permissions.
casties
parents: 95
diff changeset
176 } else if (action == Action.admin) {
14
629e15b345aa permissions mostly work. need more server-side checking.
casties
parents: 10
diff changeset
177 // require at least an authenticated user
15
58357a4b86de ASSIGNED - # 249: Annotations shared in groups
casties
parents: 14
diff changeset
178 if (user == null) return false;
14
629e15b345aa permissions mostly work. need more server-side checking.
casties
parents: 10
diff changeset
179 Actor admin = getAdminPermission();
629e15b345aa permissions mostly work. need more server-side checking.
casties
parents: 10
diff changeset
180 if (admin == null) {
20
715aa11d138b fixes in permission handling: admin and delete default to creator.
casties
parents: 16
diff changeset
181 // if not specified then only creator is allowed
715aa11d138b fixes in permission handling: admin and delete default to creator.
casties
parents: 16
diff changeset
182 admin = creator;
14
629e15b345aa permissions mostly work. need more server-side checking.
casties
parents: 10
diff changeset
183 }
20
715aa11d138b fixes in permission handling: admin and delete default to creator.
casties
parents: 16
diff changeset
184 return admin.isEquivalentWith(user, store);
14
629e15b345aa permissions mostly work. need more server-side checking.
casties
parents: 10
diff changeset
185 }
629e15b345aa permissions mostly work. need more server-side checking.
casties
parents: 10
diff changeset
186 return false;
629e15b345aa permissions mostly work. need more server-side checking.
casties
parents: 10
diff changeset
187 }
629e15b345aa permissions mostly work. need more server-side checking.
casties
parents: 10
diff changeset
188
4
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
189 /**
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
190 * @return the uri
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
191 */
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
192 public String getUri() {
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
193 return uri;
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
194 }
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
195
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
196 /**
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
197 * @param uri the uri to set
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
198 */
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
199 public void setUri(String uri) {
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
200 this.uri = uri;
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
201 }
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
202
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
203 /**
50
64aa756c60cc annotations ui can show and delete annotations now.
casties
parents: 48
diff changeset
204 * Returns an URL-compatible id.
64aa756c60cc annotations ui can show and delete annotations now.
casties
parents: 48
diff changeset
205 * Currently the uri as base64 encoded string.
64aa756c60cc annotations ui can show and delete annotations now.
casties
parents: 48
diff changeset
206 * @return
64aa756c60cc annotations ui can show and delete annotations now.
casties
parents: 48
diff changeset
207 */
64aa756c60cc annotations ui can show and delete annotations now.
casties
parents: 48
diff changeset
208 public String getUrlId() {
64aa756c60cc annotations ui can show and delete annotations now.
casties
parents: 48
diff changeset
209 if (uri == null) return null;
64aa756c60cc annotations ui can show and delete annotations now.
casties
parents: 48
diff changeset
210 try {
64aa756c60cc annotations ui can show and delete annotations now.
casties
parents: 48
diff changeset
211 return Base64.encodeBase64URLSafeString(uri.getBytes("UTF-8"));
64aa756c60cc annotations ui can show and delete annotations now.
casties
parents: 48
diff changeset
212 } catch (UnsupportedEncodingException e) {
64aa756c60cc annotations ui can show and delete annotations now.
casties
parents: 48
diff changeset
213 return null;
64aa756c60cc annotations ui can show and delete annotations now.
casties
parents: 48
diff changeset
214 }
64aa756c60cc annotations ui can show and delete annotations now.
casties
parents: 48
diff changeset
215 }
64aa756c60cc annotations ui can show and delete annotations now.
casties
parents: 48
diff changeset
216
64aa756c60cc annotations ui can show and delete annotations now.
casties
parents: 48
diff changeset
217 public static String decodeId(String id) {
64aa756c60cc annotations ui can show and delete annotations now.
casties
parents: 48
diff changeset
218 if (id == null) return null;
64aa756c60cc annotations ui can show and delete annotations now.
casties
parents: 48
diff changeset
219 try {
64aa756c60cc annotations ui can show and delete annotations now.
casties
parents: 48
diff changeset
220 return new String(Base64.decodeBase64(id), "UTF-8");
64aa756c60cc annotations ui can show and delete annotations now.
casties
parents: 48
diff changeset
221 } catch (UnsupportedEncodingException e) {
64aa756c60cc annotations ui can show and delete annotations now.
casties
parents: 48
diff changeset
222 return null;
64aa756c60cc annotations ui can show and delete annotations now.
casties
parents: 48
diff changeset
223 }
64aa756c60cc annotations ui can show and delete annotations now.
casties
parents: 48
diff changeset
224 }
64aa756c60cc annotations ui can show and delete annotations now.
casties
parents: 48
diff changeset
225
64aa756c60cc annotations ui can show and delete annotations now.
casties
parents: 48
diff changeset
226 /**
4
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
227 * @return the bodyText
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
228 */
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
229 public String getBodyText() {
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
230 return bodyText;
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
231 }
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
232
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
233 /**
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
234 * @param bodyText the bodyText to set
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
235 */
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
236 public void setBodyText(String bodyText) {
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
237 this.bodyText = bodyText;
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
238 }
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
239
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
240 /**
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
241 * @return the bodyUri
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
242 */
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
243 public String getBodyUri() {
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
244 return bodyUri;
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
245 }
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
246
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
247 /**
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
248 * @param bodyUri the bodyUri to set
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
249 */
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
250 public void setBodyUri(String bodyUri) {
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
251 this.bodyUri = bodyUri;
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
252 }
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
253
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
254 /**
48
0e00bf8e27fb targets and resources of Annotation object are objects now.
casties
parents: 40
diff changeset
255 * @return the target
0e00bf8e27fb targets and resources of Annotation object are objects now.
casties
parents: 40
diff changeset
256 */
0e00bf8e27fb targets and resources of Annotation object are objects now.
casties
parents: 40
diff changeset
257 public Target getTarget() {
0e00bf8e27fb targets and resources of Annotation object are objects now.
casties
parents: 40
diff changeset
258 return target;
0e00bf8e27fb targets and resources of Annotation object are objects now.
casties
parents: 40
diff changeset
259 }
0e00bf8e27fb targets and resources of Annotation object are objects now.
casties
parents: 40
diff changeset
260
0e00bf8e27fb targets and resources of Annotation object are objects now.
casties
parents: 40
diff changeset
261 /**
0e00bf8e27fb targets and resources of Annotation object are objects now.
casties
parents: 40
diff changeset
262 * @param target the target to set
0e00bf8e27fb targets and resources of Annotation object are objects now.
casties
parents: 40
diff changeset
263 */
0e00bf8e27fb targets and resources of Annotation object are objects now.
casties
parents: 40
diff changeset
264 public void setTarget(Target target) {
0e00bf8e27fb targets and resources of Annotation object are objects now.
casties
parents: 40
diff changeset
265 this.target = target;
0e00bf8e27fb targets and resources of Annotation object are objects now.
casties
parents: 40
diff changeset
266 }
0e00bf8e27fb targets and resources of Annotation object are objects now.
casties
parents: 40
diff changeset
267
0e00bf8e27fb targets and resources of Annotation object are objects now.
casties
parents: 40
diff changeset
268 /**
4
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
269 * @return the targetBaseUri
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
270 */
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
271 public String getTargetBaseUri() {
48
0e00bf8e27fb targets and resources of Annotation object are objects now.
casties
parents: 40
diff changeset
272 if (target == null) return null;
0e00bf8e27fb targets and resources of Annotation object are objects now.
casties
parents: 40
diff changeset
273 return target.getUri();
4
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
274 }
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
275
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
276 /**
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
277 * @return the targetFragment
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
278 */
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
279 public String getTargetFragment() {
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
280 return targetFragment;
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
281 }
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
282
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
283 /**
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
284 * @param targetFragment the targetFragment to set
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
285 */
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
286 public void setTargetFragment(String targetFragment) {
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
287 this.targetFragment = targetFragment;
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
288 }
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
289
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
290 /**
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
291 * @return the targetType
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
292 */
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
293 public FragmentTypes getFragmentType() {
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
294 return fragmentType;
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
295 }
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
296
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
297 /**
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
298 * @param fragmentType the fragmentType to set
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
299 */
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
300 public void setFragmentType(FragmentTypes fragmentType) {
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
301 this.fragmentType = fragmentType;
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
302 }
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
303
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
304 /**
76
4e2dc67997a0 save text quote from Annotator.
casties
parents: 70
diff changeset
305 * @return the quote
4e2dc67997a0 save text quote from Annotator.
casties
parents: 70
diff changeset
306 */
4e2dc67997a0 save text quote from Annotator.
casties
parents: 70
diff changeset
307 public String getQuote() {
4e2dc67997a0 save text quote from Annotator.
casties
parents: 70
diff changeset
308 return quote;
4e2dc67997a0 save text quote from Annotator.
casties
parents: 70
diff changeset
309 }
4e2dc67997a0 save text quote from Annotator.
casties
parents: 70
diff changeset
310
4e2dc67997a0 save text quote from Annotator.
casties
parents: 70
diff changeset
311 /**
4e2dc67997a0 save text quote from Annotator.
casties
parents: 70
diff changeset
312 * @param quote the quote to set
4e2dc67997a0 save text quote from Annotator.
casties
parents: 70
diff changeset
313 */
4e2dc67997a0 save text quote from Annotator.
casties
parents: 70
diff changeset
314 public void setQuote(String quote) {
4e2dc67997a0 save text quote from Annotator.
casties
parents: 70
diff changeset
315 this.quote = quote;
4e2dc67997a0 save text quote from Annotator.
casties
parents: 70
diff changeset
316 }
4e2dc67997a0 save text quote from Annotator.
casties
parents: 70
diff changeset
317
4e2dc67997a0 save text quote from Annotator.
casties
parents: 70
diff changeset
318 /**
48
0e00bf8e27fb targets and resources of Annotation object are objects now.
casties
parents: 40
diff changeset
319 * @return the resource
0e00bf8e27fb targets and resources of Annotation object are objects now.
casties
parents: 40
diff changeset
320 */
0e00bf8e27fb targets and resources of Annotation object are objects now.
casties
parents: 40
diff changeset
321 public Resource getResource() {
0e00bf8e27fb targets and resources of Annotation object are objects now.
casties
parents: 40
diff changeset
322 return resource;
0e00bf8e27fb targets and resources of Annotation object are objects now.
casties
parents: 40
diff changeset
323 }
0e00bf8e27fb targets and resources of Annotation object are objects now.
casties
parents: 40
diff changeset
324
0e00bf8e27fb targets and resources of Annotation object are objects now.
casties
parents: 40
diff changeset
325 /**
0e00bf8e27fb targets and resources of Annotation object are objects now.
casties
parents: 40
diff changeset
326 * @param resource the resource to set
0e00bf8e27fb targets and resources of Annotation object are objects now.
casties
parents: 40
diff changeset
327 */
0e00bf8e27fb targets and resources of Annotation object are objects now.
casties
parents: 40
diff changeset
328 public void setResource(Resource resource) {
0e00bf8e27fb targets and resources of Annotation object are objects now.
casties
parents: 40
diff changeset
329 this.resource = resource;
0e00bf8e27fb targets and resources of Annotation object are objects now.
casties
parents: 40
diff changeset
330 }
0e00bf8e27fb targets and resources of Annotation object are objects now.
casties
parents: 40
diff changeset
331
0e00bf8e27fb targets and resources of Annotation object are objects now.
casties
parents: 40
diff changeset
332 /**
40
03e0f7574224 saving and loading resource targets should work now (no searching yet)
casties
parents: 20
diff changeset
333 * @return the resourceUri
03e0f7574224 saving and loading resource targets should work now (no searching yet)
casties
parents: 20
diff changeset
334 */
03e0f7574224 saving and loading resource targets should work now (no searching yet)
casties
parents: 20
diff changeset
335 public String getResourceUri() {
48
0e00bf8e27fb targets and resources of Annotation object are objects now.
casties
parents: 40
diff changeset
336 if (resource == null) return null;
0e00bf8e27fb targets and resources of Annotation object are objects now.
casties
parents: 40
diff changeset
337 return resource.getUri();
40
03e0f7574224 saving and loading resource targets should work now (no searching yet)
casties
parents: 20
diff changeset
338 }
03e0f7574224 saving and loading resource targets should work now (no searching yet)
casties
parents: 20
diff changeset
339
03e0f7574224 saving and loading resource targets should work now (no searching yet)
casties
parents: 20
diff changeset
340 /**
9
b2bfc3bc9ba8 new internal actor class for creator.
casties
parents: 8
diff changeset
341 * @return the creator
b2bfc3bc9ba8 new internal actor class for creator.
casties
parents: 8
diff changeset
342 */
b2bfc3bc9ba8 new internal actor class for creator.
casties
parents: 8
diff changeset
343 public Actor getCreator() {
b2bfc3bc9ba8 new internal actor class for creator.
casties
parents: 8
diff changeset
344 return creator;
b2bfc3bc9ba8 new internal actor class for creator.
casties
parents: 8
diff changeset
345 }
b2bfc3bc9ba8 new internal actor class for creator.
casties
parents: 8
diff changeset
346
b2bfc3bc9ba8 new internal actor class for creator.
casties
parents: 8
diff changeset
347 /**
b2bfc3bc9ba8 new internal actor class for creator.
casties
parents: 8
diff changeset
348 * @param creator the creator to set
b2bfc3bc9ba8 new internal actor class for creator.
casties
parents: 8
diff changeset
349 */
b2bfc3bc9ba8 new internal actor class for creator.
casties
parents: 8
diff changeset
350 public void setCreator(Actor creator) {
b2bfc3bc9ba8 new internal actor class for creator.
casties
parents: 8
diff changeset
351 this.creator = creator;
b2bfc3bc9ba8 new internal actor class for creator.
casties
parents: 8
diff changeset
352 }
b2bfc3bc9ba8 new internal actor class for creator.
casties
parents: 8
diff changeset
353
b2bfc3bc9ba8 new internal actor class for creator.
casties
parents: 8
diff changeset
354 /**
4
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
355 * @return the creatorUri
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
356 */
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
357 public String getCreatorUri() {
9
b2bfc3bc9ba8 new internal actor class for creator.
casties
parents: 8
diff changeset
358 if (creator != null) {
b2bfc3bc9ba8 new internal actor class for creator.
casties
parents: 8
diff changeset
359 return creator.getUri();
b2bfc3bc9ba8 new internal actor class for creator.
casties
parents: 8
diff changeset
360 }
b2bfc3bc9ba8 new internal actor class for creator.
casties
parents: 8
diff changeset
361 return null;
4
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
362 }
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
363
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
364 /**
5
bbf0cc5bee29 version 0.2 really works now
casties
parents: 4
diff changeset
365 * @return the creatorName
bbf0cc5bee29 version 0.2 really works now
casties
parents: 4
diff changeset
366 */
bbf0cc5bee29 version 0.2 really works now
casties
parents: 4
diff changeset
367 public String getCreatorName() {
9
b2bfc3bc9ba8 new internal actor class for creator.
casties
parents: 8
diff changeset
368 if (creator != null) {
b2bfc3bc9ba8 new internal actor class for creator.
casties
parents: 8
diff changeset
369 return creator.getName();
b2bfc3bc9ba8 new internal actor class for creator.
casties
parents: 8
diff changeset
370 }
b2bfc3bc9ba8 new internal actor class for creator.
casties
parents: 8
diff changeset
371 return null;
5
bbf0cc5bee29 version 0.2 really works now
casties
parents: 4
diff changeset
372 }
bbf0cc5bee29 version 0.2 really works now
casties
parents: 4
diff changeset
373
bbf0cc5bee29 version 0.2 really works now
casties
parents: 4
diff changeset
374 /**
4
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
375 * @return the created
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
376 */
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
377 public String getCreated() {
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
378 return created;
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
379 }
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
380
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
381 /**
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
382 * @param created the created to set
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
383 */
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
384 public void setCreated(String created) {
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
385 this.created = created;
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
386 }
10
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
387
95
acd44dfec9c8 added last update field for annotations in database.
casties
parents: 84
diff changeset
388 public String getUpdated() {
acd44dfec9c8 added last update field for annotations in database.
casties
parents: 84
diff changeset
389 return updated;
acd44dfec9c8 added last update field for annotations in database.
casties
parents: 84
diff changeset
390 }
acd44dfec9c8 added last update field for annotations in database.
casties
parents: 84
diff changeset
391
acd44dfec9c8 added last update field for annotations in database.
casties
parents: 84
diff changeset
392 public void setUpdated(String updated) {
acd44dfec9c8 added last update field for annotations in database.
casties
parents: 84
diff changeset
393 this.updated = updated;
acd44dfec9c8 added last update field for annotations in database.
casties
parents: 84
diff changeset
394 }
acd44dfec9c8 added last update field for annotations in database.
casties
parents: 84
diff changeset
395
acd44dfec9c8 added last update field for annotations in database.
casties
parents: 84
diff changeset
396 /**
10
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
397 * @return the adminPermission
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
398 */
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
399 public Actor getAdminPermission() {
20
715aa11d138b fixes in permission handling: admin and delete default to creator.
casties
parents: 16
diff changeset
400 if (adminPermission != null) {
715aa11d138b fixes in permission handling: admin and delete default to creator.
casties
parents: 16
diff changeset
401 return adminPermission;
715aa11d138b fixes in permission handling: admin and delete default to creator.
casties
parents: 16
diff changeset
402 } else {
715aa11d138b fixes in permission handling: admin and delete default to creator.
casties
parents: 16
diff changeset
403 // if not specified then only creator is allowed
715aa11d138b fixes in permission handling: admin and delete default to creator.
casties
parents: 16
diff changeset
404 return this.creator;
715aa11d138b fixes in permission handling: admin and delete default to creator.
casties
parents: 16
diff changeset
405 }
10
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
406 }
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
407
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
408 /**
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
409 * @param adminPermission the adminPermission to set
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
410 */
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
411 public void setAdminPermission(Actor adminPermission) {
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
412 this.adminPermission = adminPermission;
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
413 }
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
414
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
415 /**
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
416 * @return the deletePermission
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
417 */
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
418 public Actor getDeletePermission() {
20
715aa11d138b fixes in permission handling: admin and delete default to creator.
casties
parents: 16
diff changeset
419 if (deletePermission != null) {
715aa11d138b fixes in permission handling: admin and delete default to creator.
casties
parents: 16
diff changeset
420 return deletePermission;
715aa11d138b fixes in permission handling: admin and delete default to creator.
casties
parents: 16
diff changeset
421 } else {
715aa11d138b fixes in permission handling: admin and delete default to creator.
casties
parents: 16
diff changeset
422 // if not specified then only creator is allowed
715aa11d138b fixes in permission handling: admin and delete default to creator.
casties
parents: 16
diff changeset
423 return this.creator;
715aa11d138b fixes in permission handling: admin and delete default to creator.
casties
parents: 16
diff changeset
424 }
10
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
425 }
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
426
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
427 /**
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
428 * @param deletePermission the deletePermission to set
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
429 */
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
430 public void setDeletePermission(Actor deletePermission) {
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
431 this.deletePermission = deletePermission;
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
432 }
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
433
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
434 /**
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
435 * @return the updatePermission
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
436 */
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
437 public Actor getUpdatePermission() {
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
438 return updatePermission;
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
439 }
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
440
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
441 /**
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
442 * @param updatePermission the updatePermission to set
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
443 */
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
444 public void setUpdatePermission(Actor updatePermission) {
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
445 this.updatePermission = updatePermission;
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
446 }
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
447
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
448 /**
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
449 * @return the readPermission
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
450 */
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
451 public Actor getReadPermission() {
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
452 return readPermission;
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
453 }
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
454
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
455 /**
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
456 * @param readPermission the readPermission to set
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
457 */
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
458 public void setReadPermission(Actor readPermission) {
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
459 this.readPermission = readPermission;
90911b2da322 more work on permissions...
casties
parents: 9
diff changeset
460 }
16
794077e6288c CLOSED - # 252: Tags for Annotations
casties
parents: 15
diff changeset
461
794077e6288c CLOSED - # 252: Tags for Annotations
casties
parents: 15
diff changeset
462 /**
794077e6288c CLOSED - # 252: Tags for Annotations
casties
parents: 15
diff changeset
463 * @return the tags
794077e6288c CLOSED - # 252: Tags for Annotations
casties
parents: 15
diff changeset
464 */
794077e6288c CLOSED - # 252: Tags for Annotations
casties
parents: 15
diff changeset
465 public Set<String> getTags() {
794077e6288c CLOSED - # 252: Tags for Annotations
casties
parents: 15
diff changeset
466 return tags;
794077e6288c CLOSED - # 252: Tags for Annotations
casties
parents: 15
diff changeset
467 }
794077e6288c CLOSED - # 252: Tags for Annotations
casties
parents: 15
diff changeset
468
794077e6288c CLOSED - # 252: Tags for Annotations
casties
parents: 15
diff changeset
469 /**
794077e6288c CLOSED - # 252: Tags for Annotations
casties
parents: 15
diff changeset
470 * @param tags the tags to set
794077e6288c CLOSED - # 252: Tags for Annotations
casties
parents: 15
diff changeset
471 */
794077e6288c CLOSED - # 252: Tags for Annotations
casties
parents: 15
diff changeset
472 public void setTags(Set<String> tags) {
794077e6288c CLOSED - # 252: Tags for Annotations
casties
parents: 15
diff changeset
473 this.tags = tags;
794077e6288c CLOSED - # 252: Tags for Annotations
casties
parents: 15
diff changeset
474 }
4
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
475
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
476
3599b29c393f store seems to work now :-)
casties
parents:
diff changeset
477 }