Reference service method getReferencesByTitle() added
[cdmlib.git] / cdmlib-services / src / main / java / eu / etaxonomy / cdm / api / service / IReferenceService.java
1 /**
2 * Copyright (C) 2007 EDIT
3 * European Distributed Institute of Taxonomy
4 * http://www.e-taxonomy.eu
5 *
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.
8 */
9
10 package eu.etaxonomy.cdm.api.service;
11
12 import java.util.Collection;
13 import java.util.List;
14 import java.util.UUID;
15 import java.util.Map;
16
17 import eu.etaxonomy.cdm.model.reference.ReferenceBase;
18
19
20 public interface IReferenceService<T extends ReferenceBase> extends IIdentifiableEntityService<T> {
21 //public interface IReferenceService extends IIdentifiableEntityService<ReferenceBase> {
22
23 /** Finds reference by UUID **/
24 public abstract ReferenceBase getReferenceByUuid(UUID uuid);
25
26 /** Finds reference by title **/
27 public List<T> getReferencesByTitle(String title);
28
29 /** Gets all references **/
30 public abstract List<ReferenceBase> getAllReferences(int limit, int start);
31
32 // public abstract UUID saveReference(ReferenceBase reference);
33
34 /** Saves a reference and return its UUID **/
35 public abstract UUID saveReference(T reference);
36
37 // public abstract Map<UUID, ReferenceBase> saveReferenceAll(Collection<ReferenceBase> referenceCollection);
38
39 /** Saves a collection of references **/
40 public abstract Map<UUID, T> saveReferenceAll(Collection<T> referenceCollection);
41
42 }