You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
+ moved initialisation and properties to Manager.java
+ using filtered copy
git-svn-id: svn://code/p/joggle/trunk@19 62b0412d-8fe6-4ae7-94e2-c7691c08b19d
privatestaticfinalStringaat = " order by s.artist, s.album, s.track";
@@ -25,6 +49,10 @@ public static Manager getInstance() {
25
49
privateManager() {
26
50
}
27
51
52
+
publicStringgetProperty(Stringkey) {
53
+
returnproperties.getProperty(key);
54
+
}
55
+
28
56
publicList<String> albums() {
29
57
returnmanager.createQuery("select distinct(s.album) from Song as s order by s.album").getResultList();
30
58
}
@@ -49,10 +77,6 @@ public Song find(String id) {
49
77
returnmanager.find(Song.class, id);
50
78
}
51
79
52
-
publicList<Song> list() {
53
-
returnmanager.createQuery("select s from Song as s" + aat).getResultList();
54
-
}
55
-
56
80
publicvoidmerge(Songs) {
57
81
if (log.isDebugEnabled()) log.debug("merging " + s);
58
82
manager.getTransaction().begin();
@@ -65,4 +89,8 @@ public List<Song> search(String keyword) {
65
89
if (log.isDebugEnabled()) log.debug("searching " + search);
66
90
returnmanager.createQuery("select s from Song as s where lower(s.album) like :search or lower(s.artist) like :search or lower(s.title) like :search" + aat).setParameter("search", search).getResultList();
67
91
}
92
+
93
+
publicList<Song> songs() {
94
+
returnmanager.createQuery("select s from Song as s" + aat).getResultList();
0 commit comments