From 278bd3d0230e5194b47c9a3192a4f1b7a5e8d64b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=93scar=20Gonz=C3=A1lez=20Fern=C3=A1ndez?= Date: Tue, 21 Sep 2010 12:45:04 +0200 Subject: [PATCH] Add javadoc FEA: ItEr60S04ValidacionEProbasFuncionaisItEr59S04 --- .../search/IResourceSearchModel.java | 44 +++++++++++++++++++ 1 file changed, 44 insertions(+) diff --git a/navalplanner-webapp/src/main/java/org/navalplanner/web/resources/search/IResourceSearchModel.java b/navalplanner-webapp/src/main/java/org/navalplanner/web/resources/search/IResourceSearchModel.java index 427c45dda..7e1f12746 100644 --- a/navalplanner-webapp/src/main/java/org/navalplanner/web/resources/search/IResourceSearchModel.java +++ b/navalplanner-webapp/src/main/java/org/navalplanner/web/resources/search/IResourceSearchModel.java @@ -41,12 +41,38 @@ public interface IResourceSearchModel { public interface IResourcesQuery { + /** + * Restrict the result to resources that have name as a substring. The + * match is case insensitive. + * + * @param name + * @return this same object in order to cascade calls + */ IResourcesQuery byName(String name); + /** + * Restrict the result to a list of {@link Resource} satisfying all + * criteria at some point in time + * + * @param criteria + * @return this same object in order to cascade calls + */ IResourcesQuery byCriteria(Collection criteria); + /** + * Restrict resources to the ones having the provided limiting value. By + * default, if this method is not called, the resources are restricted + * to the ones not limiting. + * @param limiting + * @return this same object in order to cascade calls + */ IResourcesQuery byLimiting(boolean limiting); + /** + * Retrieve the list of resources that match the restrictions specified. + * + * @return + */ List execute(); /** @@ -63,12 +89,30 @@ public interface IResourceSearchModel { Map> getCriteria(); } + /** + * Do the search limited to workers + * + * @return + */ public IResourcesQuery searchWorkers(); + /** + * Do the search limited to machines + * @return + */ public IResourcesQuery searchMachines(); + /** + * Search machines or workers based on the value of resourceType + * @param resourceType + * @return + */ public IResourcesQuery searchBy(ResourceEnum resourceType); + /** + * Search both resources and machines + * @return + */ public IResourcesQuery searchBoth(); }