Mercurial > dive4elements > river
comparison flys-client/src/main/java/de/intevation/flys/client/shared/model/ThemeList.java @ 1473:71ba43bd0e3f
Added convenient accessor.
flys-client/trunk@3518 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author | Felix Wolfsteller <felix.wolfsteller@intevation.de> |
---|---|
date | Thu, 22 Dec 2011 08:53:15 +0000 |
parents | 1d82a2c695a6 |
children | e0f4ea518d59 |
comparison
equal
deleted
inserted
replaced
1472:a2b0b2af529f | 1473:71ba43bd0e3f |
---|---|
29 } | 29 } |
30 | 30 |
31 | 31 |
32 public int getThemeCount() { | 32 public int getThemeCount() { |
33 return themes.size(); | 33 return themes.size(); |
34 } | |
35 | |
36 | |
37 /** | |
38 * Returns (first) theme of which the artifact has given uuid, null if none | |
39 * found. | |
40 * @param uuid Artifacts identifier for which to search theme. | |
41 * @return theme of which getArtifact() equals given uuid. | |
42 */ | |
43 public Theme getTheme(String uuid) { | |
44 for (Theme theme: themes) { | |
45 if (theme.getArtifact().equals(uuid)) { | |
46 return theme; | |
47 } | |
48 } | |
49 return null; | |
34 } | 50 } |
35 | 51 |
36 | 52 |
37 /** | 53 /** |
38 * Returns a theme at a specific position. <b>NOTE: Themes start at position | 54 * Returns a theme at a specific position. <b>NOTE: Themes start at position |