3 * Copyright (C) 2007 EDIT
4 * European Distributed Institute of Taxonomy
5 * http://www.e-taxonomy.eu
7 * The contents of this file are subject to the Mozilla Public License Version 1.1
8 * See LICENSE.TXT at the top of this package for the full license terms.
11 package eu
.etaxonomy
.cdm
.api
.service
;
13 import java
.util
.List
;
15 import eu
.etaxonomy
.cdm
.api
.service
.pager
.Pager
;
16 import eu
.etaxonomy
.cdm
.model
.agent
.Person
;
17 import eu
.etaxonomy
.cdm
.model
.common
.Annotation
;
18 import eu
.etaxonomy
.cdm
.model
.common
.MarkerType
;
19 import eu
.etaxonomy
.cdm
.model
.common
.User
;
20 import eu
.etaxonomy
.cdm
.persistence
.dao
.initializer
.IBeanInitializer
;
21 import eu
.etaxonomy
.cdm
.persistence
.query
.OrderHint
;
23 public interface IAnnotationService
extends IAnnotatableService
<Annotation
> {
25 * return a count of the number of annotations made by this person, optionally filtered by the status of those annotations
27 * @param commentator the person who created those annotations
28 * @param status the status of those annotations (can be null)
31 public int count(Person commentator
, MarkerType status
);
35 * @param commentator the person who created those annotations
36 * @param status the status of those annotations (can be null)
37 * @param pageSize The maximum number of annotations returned (can be null for all annotations)
38 * @param pageNumber The offset (in pageSize chunks) from the start of the result set (0 - based)
39 * @param orderHints Properties to order by
40 * @param propertyPaths Properties to initialize in the returned entities, following the syntax described in {@link IBeanInitializer#initialize(Object, List)}
41 * @return a paged list of Annotation instances
43 public Pager
<Annotation
> list(Person commentator
, MarkerType status
, Integer pageSize
, Integer pageNumber
, List
<OrderHint
> orderHints
, List
<String
> propertyPaths
);
46 * return a count of the number of annotations created by this user, optionally filtered by the status of those annotations
48 * @param creator the user who created those annotations
49 * @param status the status of those annotations (can be null)
52 public int count(User creator
, MarkerType status
);
56 * @param creator the user who created those annotations
57 * @param status the status of those annotations (can be null)
58 * @param pageSize The maximum number of annotations returned (can be null for all annotations)
59 * @param pageNumber The offset (in pageSize chunks) from the start of the result set (0 - based)
60 * @param orderHints Properties to order by
61 * @param propertyPaths Properties to initialize in the returned entities, following the syntax described in {@link IBeanInitializer#initialize(Object, List)}
62 * @return a paged list of Annotation instances
64 public Pager
<Annotation
> list(User creator
, MarkerType status
, Integer pageSize
, Integer pageNumber
, List
<OrderHint
> orderHints
, List
<String
> propertyPaths
);