Jean-Francois Leveque

Documentation

...@@ -18,7 +18,11 @@ import java.util.List; ...@@ -18,7 +18,11 @@ import java.util.List;
18 public class PublisherSearchView implements Serializable { 18 public class PublisherSearchView implements Serializable {
19 19
20 transient List<PublisherVersion> publisherVersions = new ArrayList<>(); 20 transient List<PublisherVersion> publisherVersions = new ArrayList<>();
21 - String searchString = new String(); 21 + String searchString = new String(); /**
22 + *
23 + * @return whether search with non-empty string has returned an empty result
24 + */
25 +
22 26
23 transient PublisherService publisherService; 27 transient PublisherService publisherService;
24 28
...@@ -36,12 +40,16 @@ public class PublisherSearchView implements Serializable { ...@@ -36,12 +40,16 @@ public class PublisherSearchView implements Serializable {
36 //no args constructor to make it proxyable 40 //no args constructor to make it proxyable
37 } 41 }
38 42
43 + /**
44 + *
45 + * @return whether search with non-empty string has returned an empty result
46 + */
39 public boolean searchEmpty() { 47 public boolean searchEmpty() {
40 return (!searchString.isEmpty()) && publisherVersions.isEmpty(); 48 return (!searchString.isEmpty()) && publisherVersions.isEmpty();
41 } 49 }
42 50
43 /** 51 /**
44 - * 52 + * Searches for publishers containing searchString
45 */ 53 */
46 public void search() throws SearchingException { 54 public void search() throws SearchingException {
47 this.publisherVersions = publisherService.search(this.searchString); 55 this.publisherVersions = publisherService.search(this.searchString);
......