2 * Copyright (C) 2007 EDIT
3 * European Distributed Institute of Taxonomy
4 * http://www.e-taxonomy.eu
6 * The contents of this file are subject to the Mozilla Public License Version 1.1
7 * See LICENSE.TXT at the top of this package for the full license terms.
10 package eu
.etaxonomy
.cdm
.api
.service
;
12 import java
.util
.Collection
;
13 import java
.util
.List
;
14 import java
.util
.UUID
;
17 import eu
.etaxonomy
.cdm
.model
.reference
.ReferenceBase
;
20 public interface IReferenceService
<T
extends ReferenceBase
> extends IIdentifiableEntityService
<T
> {
21 //public interface IReferenceService extends IIdentifiableEntityService<ReferenceBase> {
23 /** Finds reference by UUID **/
24 public abstract ReferenceBase
getReferenceByUuid(UUID uuid
);
26 /** Finds reference by title **/
27 public List
<T
> getReferencesByTitle(String title
);
29 /** Gets all references **/
30 public abstract List
<ReferenceBase
> getAllReferences(int limit
, int start
);
32 // public abstract UUID saveReference(ReferenceBase reference);
34 /** Saves a reference and return its UUID **/
35 public abstract UUID
saveReference(T reference
);
37 // public abstract Map<UUID, ReferenceBase> saveReferenceAll(Collection<ReferenceBase> referenceCollection);
39 /** Saves a collection of references **/
40 public abstract Map
<UUID
, T
> saveReferenceAll(Collection
<T
> referenceCollection
);