Project

General

Profile

1
package eu.dnetlib.enabling.datasources.common;
2

    
3
import java.sql.Date;
4
import java.util.Set;
5
import javax.persistence.*;
6

    
7
/**
8
 * Datasource
9
 */
10
@MappedSuperclass
11
public class Datasource<ORG extends Organization, ID extends Identity> {
12

    
13
	@Id
14
	protected String id = null;
15
	protected String officialname = null;
16
	protected String englishname = null;
17
	protected String websiteurl = null;
18
	protected String logourl = null;
19
	protected String contactemail = null;
20
	protected Double latitude;
21
	protected Double longitude;
22
	protected String timezone = null;
23

    
24
	@Column(name = "namespaceprefix", columnDefinition = "bpchar(12)")
25
	protected String namespaceprefix;
26

    
27
	protected String languages;
28

    
29
	protected String od_contenttypes;
30
	protected String collectedfrom = null;
31
	protected Date dateofvalidation = null;
32
	protected String typology = null;
33
	protected String provenanceaction;
34
	protected Date dateofcollection;
35
	protected String platform;
36

    
37
	@Column(name = "activationid")
38
	protected String activationId;
39
	protected String description = null;
40

    
41
	protected Date releasestartdate;
42
	protected Date releaseenddate;
43
	protected String missionstatementurl;
44
	protected Boolean dataprovider;
45
	protected Boolean serviceprovider;
46

    
47
	protected String databaseaccesstype;
48
	protected String datauploadtype;
49
	protected String databaseaccessrestriction;
50
	protected String datauploadrestriction;
51

    
52
	protected Boolean versioning;
53
	protected String citationguidelineurl;
54
	protected String qualitymanagementkind;
55
	protected String pidsystems;
56

    
57
	protected String certificates;
58
	protected String aggregator;
59

    
60
	protected String issn = null;
61
	protected String eissn = null;
62
	protected String lissn = null;
63

    
64
	protected String registeredby = null;
65

    
66
	protected String subjects;
67

    
68
	protected Boolean managed;
69

    
70
	@ManyToMany(
71
			cascade = { CascadeType.PERSIST, CascadeType.MERGE },
72
			fetch = FetchType.LAZY)
73
	@JoinTable(
74
			name = "dsm_datasource_organization",
75
			joinColumns = @JoinColumn(name="datasource"),
76
			inverseJoinColumns = @JoinColumn(name="organization"))
77
	protected Set<ORG> organizations;
78

    
79
	@ManyToMany(
80
			cascade = { CascadeType.PERSIST, CascadeType.MERGE },
81
			fetch = FetchType.LAZY )
82
	@JoinTable(
83
			name = "dsm_datasourcepids",
84
			joinColumns = @JoinColumn(name = "datasource"),
85
			inverseJoinColumns = @JoinColumn(name = "pid"))
86
	protected Set<ID> identities;
87

    
88
	public Datasource() {}
89

    
90
	public String getId() {
91
		return id;
92
	}
93

    
94
	public String getOfficialname() {
95
		return officialname;
96
	}
97

    
98
	public String getEnglishname() {
99
		return englishname;
100
	}
101

    
102
	public String getWebsiteurl() {
103
		return websiteurl;
104
	}
105

    
106
	public String getLogourl() {
107
		return logourl;
108
	}
109

    
110
	public String getContactemail() {
111
		return contactemail;
112
	}
113

    
114
	public Double getLatitude() {
115
		return latitude;
116
	}
117

    
118
	public Double getLongitude() {
119
		return longitude;
120
	}
121

    
122
	public String getTimezone() {
123
		return timezone;
124
	}
125

    
126
	public String getNamespaceprefix() {
127
		return namespaceprefix;
128
	}
129

    
130
	public String getLanguages() {
131
		return languages;
132
	}
133

    
134
	public String getOd_contenttypes() {
135
		return od_contenttypes;
136
	}
137

    
138
	public String getCollectedfrom() {
139
		return collectedfrom;
140
	}
141

    
142
	public Date getDateofvalidation() {
143
		return dateofvalidation;
144
	}
145

    
146
	public String getTypology() {
147
		return typology;
148
	}
149

    
150
	public String getProvenanceaction() {
151
		return provenanceaction;
152
	}
153

    
154
	public Date getDateofcollection() {
155
		return dateofcollection;
156
	}
157

    
158
	public String getPlatform() {
159
		return platform;
160
	}
161

    
162
	public String getActivationId() {
163
		return activationId;
164
	}
165

    
166
	public String getDescription() {
167
		return description;
168
	}
169

    
170
	public Date getReleasestartdate() {
171
		return releasestartdate;
172
	}
173

    
174
	public Date getReleaseenddate() {
175
		return releaseenddate;
176
	}
177

    
178
	public String getMissionstatementurl() {
179
		return missionstatementurl;
180
	}
181

    
182
	public Boolean isDataprovider() {
183
		return dataprovider;
184
	}
185

    
186
	public Boolean isServiceprovider() {
187
		return serviceprovider;
188
	}
189

    
190
	public String getDatabaseaccesstype() {
191
		return databaseaccesstype;
192
	}
193

    
194
	public String getDatauploadtype() {
195
		return datauploadtype;
196
	}
197

    
198
	public String getDatabaseaccessrestriction() {
199
		return databaseaccessrestriction;
200
	}
201

    
202
	public String getDatauploadrestriction() {
203
		return datauploadrestriction;
204
	}
205

    
206
	public Boolean isVersioning() {
207
		return versioning;
208
	}
209

    
210
	public String getCitationguidelineurl() {
211
		return citationguidelineurl;
212
	}
213

    
214
	public String getQualitymanagementkind() {
215
		return qualitymanagementkind;
216
	}
217

    
218
	public String getPidsystems() {
219
		return pidsystems;
220
	}
221

    
222
	public String getCertificates() {
223
		return certificates;
224
	}
225

    
226
	public String getAggregator() {
227
		return aggregator;
228
	}
229

    
230
	public String getIssn() {
231
		return issn;
232
	}
233

    
234
	public String getEissn() {
235
		return eissn;
236
	}
237

    
238
	public String getLissn() {
239
		return lissn;
240
	}
241

    
242
	public String getRegisteredby() {
243
		return registeredby;
244
	}
245

    
246
	public String getSubjects() {
247
		return subjects;
248
	}
249

    
250
	public Boolean isManaged() {
251
		return managed;
252
	}
253

    
254
	public Set<ORG> getOrganizations() {
255
		return organizations;
256
	}
257

    
258
	public Set<ID> getIdentities() {
259
		return identities;
260
	}
261

    
262
	public Datasource<ORG, ID> setId(final String id) {
263
		this.id = id;
264
		return this;
265
	}
266

    
267
	public Datasource<ORG, ID> setOfficialname(final String officialname) {
268
		this.officialname = officialname;
269
		return this;
270
	}
271

    
272
	public Datasource<ORG, ID> setEnglishname(final String englishname) {
273
		this.englishname = englishname;
274
		return this;
275
	}
276

    
277
	public Datasource<ORG, ID> setWebsiteurl(final String websiteurl) {
278
		this.websiteurl = websiteurl;
279
		return this;
280
	}
281

    
282
	public Datasource<ORG, ID> setLogourl(final String logourl) {
283
		this.logourl = logourl;
284
		return this;
285
	}
286

    
287
	public Datasource<ORG, ID> setContactemail(final String contactemail) {
288
		this.contactemail = contactemail;
289
		return this;
290
	}
291

    
292
	public Datasource<ORG, ID> setLatitude(final Double latitude) {
293
		this.latitude = latitude;
294
		return this;
295
	}
296

    
297
	public Datasource<ORG, ID> setLongitude(final Double longitude) {
298
		this.longitude = longitude;
299
		return this;
300
	}
301

    
302
	public Datasource<ORG, ID> setTimezone(final String timezone) {
303
		this.timezone = timezone;
304
		return this;
305
	}
306

    
307
	public Datasource<ORG, ID> setNamespaceprefix(final String namespaceprefix) {
308
		this.namespaceprefix = namespaceprefix;
309
		return this;
310
	}
311

    
312
	public Datasource<ORG, ID> setLanguages(final String languages) {
313
		this.languages = languages;
314
		return this;
315
	}
316

    
317
	public Datasource<ORG, ID> setOd_contenttypes(final String od_contenttypes) {
318
		this.od_contenttypes = od_contenttypes;
319
		return this;
320
	}
321

    
322
	public Datasource<ORG, ID> setCollectedfrom(final String collectedfrom) {
323
		this.collectedfrom = collectedfrom;
324
		return this;
325
	}
326

    
327
	public Datasource<ORG, ID> setDateofvalidation(final Date dateofvalidation) {
328
		this.dateofvalidation = dateofvalidation;
329
		return this;
330
	}
331

    
332
	public Datasource<ORG, ID> setTypology(final String typology) {
333
		this.typology = typology;
334
		return this;
335
	}
336

    
337
	public Datasource<ORG, ID> setProvenanceaction(final String provenanceaction) {
338
		this.provenanceaction = provenanceaction;
339
		return this;
340
	}
341

    
342
	public Datasource<ORG, ID> setDateofcollection(final Date dateofcollection) {
343
		this.dateofcollection = dateofcollection;
344
		return this;
345
	}
346

    
347
	public Datasource<ORG, ID> setPlatform(final String platform) {
348
		this.platform = platform;
349
		return this;
350
	}
351

    
352
	public Datasource<ORG, ID> setActivationId(final String activationId) {
353
		this.activationId = activationId;
354
		return this;
355
	}
356

    
357
	public Datasource<ORG, ID> setDescription(final String description) {
358
		this.description = description;
359
		return this;
360
	}
361

    
362
	public Datasource<ORG, ID> setReleasestartdate(final Date releasestartdate) {
363
		this.releasestartdate = releasestartdate;
364
		return this;
365
	}
366

    
367
	public Datasource<ORG, ID> setReleaseenddate(final Date releaseenddate) {
368
		this.releaseenddate = releaseenddate;
369
		return this;
370
	}
371

    
372
	public Datasource<ORG, ID> setMissionstatementurl(final String missionstatementurl) {
373
		this.missionstatementurl = missionstatementurl;
374
		return this;
375
	}
376

    
377
	public Datasource<ORG, ID> setDataprovider(final Boolean dataprovider) {
378
		this.dataprovider = dataprovider;
379
		return this;
380
	}
381

    
382
	public Datasource<ORG, ID> setServiceprovider(final Boolean serviceprovider) {
383
		this.serviceprovider = serviceprovider;
384
		return this;
385
	}
386

    
387
	public Datasource<ORG, ID> setDatabaseaccesstype(final String databaseaccesstype) {
388
		this.databaseaccesstype = databaseaccesstype;
389
		return this;
390
	}
391

    
392
	public Datasource<ORG, ID> setDatauploadtype(final String datauploadtype) {
393
		this.datauploadtype = datauploadtype;
394
		return this;
395
	}
396

    
397
	public Datasource<ORG, ID> setDatabaseaccessrestriction(final String databaseaccessrestriction) {
398
		this.databaseaccessrestriction = databaseaccessrestriction;
399
		return this;
400
	}
401

    
402
	public Datasource<ORG, ID> setDatauploadrestriction(final String datauploadrestriction) {
403
		this.datauploadrestriction = datauploadrestriction;
404
		return this;
405
	}
406

    
407
	public Datasource<ORG, ID> setVersioning(final Boolean versioning) {
408
		this.versioning = versioning;
409
		return this;
410
	}
411

    
412
	public Datasource<ORG, ID> setCitationguidelineurl(final String citationguidelineurl) {
413
		this.citationguidelineurl = citationguidelineurl;
414
		return this;
415
	}
416

    
417
	public Datasource<ORG, ID> setQualitymanagementkind(final String qualitymanagementkind) {
418
		this.qualitymanagementkind = qualitymanagementkind;
419
		return this;
420
	}
421

    
422
	public Datasource<ORG, ID> setPidsystems(final String pidsystems) {
423
		this.pidsystems = pidsystems;
424
		return this;
425
	}
426

    
427
	public Datasource<ORG, ID> setCertificates(final String certificates) {
428
		this.certificates = certificates;
429
		return this;
430
	}
431

    
432
	public Datasource<ORG, ID> setAggregator(final String aggregator) {
433
		this.aggregator = aggregator;
434
		return this;
435
	}
436

    
437
	public Datasource<ORG, ID> setIssn(final String issn) {
438
		this.issn = issn;
439
		return this;
440
	}
441

    
442
	public Datasource<ORG, ID> setEissn(final String eissn) {
443
		this.eissn = eissn;
444
		return this;
445
	}
446

    
447
	public Datasource<ORG, ID> setLissn(final String lissn) {
448
		this.lissn = lissn;
449
		return this;
450
	}
451

    
452
	public Datasource<ORG, ID> setRegisteredby(final String registeredby) {
453
		this.registeredby = registeredby;
454
		return this;
455
	}
456

    
457
	public Datasource<ORG, ID> setSubjects(final String subjects) {
458
		this.subjects = subjects;
459
		return this;
460
	}
461

    
462
	public Datasource<ORG, ID> setManaged(final Boolean managed) {
463
		this.managed = managed;
464
		return this;
465
	}
466

    
467
	public Datasource<ORG, ID> setOrganizations(final Set<ORG> organizations) {
468
		this.organizations = organizations;
469
		return this;
470
	}
471

    
472
	public Datasource<ORG, ID> setIdentities(final Set<ID> identities) {
473
		this.identities = identities;
474
		return this;
475
	}
476

    
477
}
(8-8/16)